Exemplo n.º 1
0
static void
builder_context_constructed (GObject *object)
{
  BuilderContext *self = BUILDER_CONTEXT (object);

  self->state_dir = g_file_get_child (self->base_dir, ".xdg-app-builder");
  self->download_dir = g_file_get_child (self->state_dir, "downloads");
  self->cache_dir = g_file_get_child (self->state_dir, "cache");
  self->ccache_dir = g_file_get_child (self->state_dir, "ccache");
}
Exemplo n.º 2
0
static void
builder_context_get_property (GObject    *object,
                              guint       prop_id,
                              GValue     *value,
                              GParamSpec *pspec)
{
  BuilderContext *self = BUILDER_CONTEXT (object);

  switch (prop_id)
    {
    case PROP_BASE_DIR:
      g_value_set_object (value, self->base_dir);
      break;

    case PROP_APP_DIR:
      g_value_set_object (value, self->app_dir);
      break;

    default:
      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
    }
}