[cheese/gsettings-vala: 1/2] Initial GSettings port
- From: Yuvaraj Pandian <yuvipanda src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [cheese/gsettings-vala: 1/2] Initial GSettings port
- Date: Fri, 6 Aug 2010 12:28:19 +0000 (UTC)
commit e986e51bea30e19d66c19350f29dc7a0cad3e973
Author: Yuvaraj Pandian T <yuvipanda gmail com>
Date: Fri Aug 6 17:22:40 2010 +0530
Initial GSettings port
INSTALL | 97 ++++++++++++++---
configure.ac | 10 +--
data/Makefile.am | 21 +---
libcheese/cheese-gconf.c | 261 +++++++++-------------------------------------
4 files changed, 138 insertions(+), 251 deletions(-)
---
diff --git a/INSTALL b/INSTALL
index 2550dab..7d1c323 100644
--- a/INSTALL
+++ b/INSTALL
@@ -4,8 +4,10 @@ Installation Instructions
Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
2006, 2007, 2008, 2009 Free Software Foundation, Inc.
- This file is free documentation; the Free Software Foundation gives
-unlimited permission to copy, distribute and modify it.
+ Copying and distribution of this file, with or without modification,
+are permitted in any medium without royalty provided the copyright
+notice and this notice are preserved. This file is offered as-is,
+without warranty of any kind.
Basic Installation
==================
@@ -13,7 +15,11 @@ Basic Installation
Briefly, the shell commands `./configure; make; make install' should
configure, build, and install this package. The following
more-detailed instructions are generic; see the `README' file for
-instructions specific to this package.
+instructions specific to this package. Some packages provide this
+`INSTALL' file but do not implement all of the features documented
+below. The lack of an optional feature in a given package is not
+necessarily a bug. More recommendations for GNU packages can be found
+in *note Makefile Conventions: (standards)Makefile Conventions.
The `configure' shell script attempts to guess correct values for
various system-dependent variables used during compilation. It uses
@@ -42,7 +48,7 @@ may remove or edit it.
you want to change it or regenerate `configure' using a newer version
of `autoconf'.
-The simplest way to compile this package is:
+ The simplest way to compile this package is:
1. `cd' to the directory containing the package's source code and type
`./configure' to configure the package for your system.
@@ -53,12 +59,22 @@ The simplest way to compile this package is:
2. Type `make' to compile the package.
3. Optionally, type `make check' to run any self-tests that come with
- the package.
+ the package, generally using the just-built uninstalled binaries.
4. Type `make install' to install the programs and any data files and
- documentation.
-
- 5. You can remove the program binaries and object files from the
+ documentation. When installing into a prefix owned by root, it is
+ recommended that the package be configured and built as a regular
+ user, and only the `make install' phase executed with root
+ privileges.
+
+ 5. Optionally, type `make installcheck' to repeat any self-tests, but
+ this time using the binaries in their final installed location.
+ This target does not install anything. Running this target as a
+ regular user, particularly if the prior `make install' required
+ root privileges, verifies that the installation completed
+ correctly.
+
+ 6. You can remove the program binaries and object files from the
source code directory by typing `make clean'. To also remove the
files that `configure' created (so you can compile the package for
a different kind of computer), type `make distclean'. There is
@@ -67,8 +83,15 @@ The simplest way to compile this package is:
all sorts of other programs in order to regenerate files that came
with the distribution.
- 6. Often, you can also type `make uninstall' to remove the installed
- files again.
+ 7. Often, you can also type `make uninstall' to remove the installed
+ files again. In practice, not all packages have tested that
+ uninstallation works correctly, even though it is required by the
+ GNU Coding Standards.
+
+ 8. Some packages, particularly those that use Automake, provide `make
+ distcheck', which can by used by developers to test that all other
+ targets like `make install' and `make uninstall' work correctly.
+ This target is generally not run by end users.
Compilers and Options
=====================
@@ -93,7 +116,8 @@ same time, by placing the object files for each architecture in their
own directory. To do this, you can use GNU `make'. `cd' to the
directory where you want the object files and executables to go and run
the `configure' script. `configure' automatically checks for the
-source code in the directory that `configure' is in and in `..'.
+source code in the directory that `configure' is in and in `..'. This
+is known as a "VPATH" build.
With a non-GNU `make', it is safer to compile the package for one
architecture at a time in the source code directory. After you have
@@ -120,7 +144,8 @@ Installation Names
By default, `make install' installs the package's commands under
`/usr/local/bin', include files under `/usr/local/include', etc. You
can specify an installation prefix other than `/usr/local' by giving
-`configure' the option `--prefix=PREFIX'.
+`configure' the option `--prefix=PREFIX', where PREFIX must be an
+absolute file name.
You can specify separate installation prefixes for
architecture-specific files and architecture-independent files. If you
@@ -131,15 +156,46 @@ Documentation and other data files still use the regular prefix.
In addition, if you use an unusual directory layout you can give
options like `--bindir=DIR' to specify different values for particular
kinds of files. Run `configure --help' for a list of the directories
-you can set and what kinds of files go in them.
+you can set and what kinds of files go in them. In general, the
+default for these options is expressed in terms of `${prefix}', so that
+specifying just `--prefix' will affect all of the other directory
+specifications that were not explicitly provided.
+
+ The most portable way to affect installation locations is to pass the
+correct locations to `configure'; however, many packages provide one or
+both of the following shortcuts of passing variable assignments to the
+`make install' command line to change installation locations without
+having to reconfigure or recompile.
+
+ The first method involves providing an override variable for each
+affected directory. For example, `make install
+prefix=/alternate/directory' will choose an alternate location for all
+directory configuration variables that were expressed in terms of
+`${prefix}'. Any directories that were specified during `configure',
+but not in terms of `${prefix}', must each be overridden at install
+time for the entire installation to be relocated. The approach of
+makefile variable overrides for each directory variable is required by
+the GNU Coding Standards, and ideally causes no recompilation.
+However, some platforms have known limitations with the semantics of
+shared libraries that end up requiring recompilation when using this
+method, particularly noticeable in packages that use GNU Libtool.
+
+ The second method involves providing the `DESTDIR' variable. For
+example, `make install DESTDIR=/alternate/directory' will prepend
+`/alternate/directory' before all installation names. The approach of
+`DESTDIR' overrides is not required by the GNU Coding Standards, and
+does not work on platforms that have drive letters. On the other hand,
+it does better at avoiding recompilation issues, and works well even
+when some directory options were not specified in terms of `${prefix}'
+at `configure' time.
+
+Optional Features
+=================
If the package supports it, you can cause programs to be installed
with an extra prefix or suffix on their names by giving `configure' the
option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
-Optional Features
-=================
-
Some packages pay attention to `--enable-FEATURE' options to
`configure', where FEATURE indicates an optional part of the package.
They may also pay attention to `--with-PACKAGE' options, where PACKAGE
@@ -152,6 +208,13 @@ find the X include and library files automatically, but if it doesn't,
you can use the `configure' options `--x-includes=DIR' and
`--x-libraries=DIR' to specify their locations.
+ Some packages offer the ability to configure how verbose the
+execution of `make' will be. For these packages, running `./configure
+--enable-silent-rules' sets the default to minimal output, which can be
+overridden with `make V=1'; while running `./configure
+--disable-silent-rules' sets the default to verbose, which can be
+overridden with `make V=0'.
+
Particular systems
==================
@@ -288,7 +351,7 @@ operates.
`configure' can determine that directory automatically.
`--prefix=DIR'
- Use DIR as the installation prefix. *Note Installation Names::
+ Use DIR as the installation prefix. *note Installation Names::
for more details, including other options available for fine-tuning
the installation locations.
diff --git a/configure.ac b/configure.ac
index 8a86c6d..45384de 100644
--- a/configure.ac
+++ b/configure.ac
@@ -75,13 +75,12 @@ GNOME_DOC_INIT
# Check required libraries
#*******************************************************************************
-GLIB_REQUIRED=2.16.0
+GLIB_REQUIRED=2.25.12
GOBJECT_REQUIRED=2.12.0
-GIO_REQUIRED=2.16.0
+GIO_REQUIRED=2.25.11
GTK_REQUIRED=2.19.1
GDK_REQUIRED=2.14.0
LIBGNOMEDESKTOP_REQUIRED=2.26.0
-GCONF_REQUIRED=2.16.0
GSTREAMER_REQUIRED=0.10.23
CAIRO_REQUIRED=1.4.0
DBUS_REQUIRED=1.0
@@ -140,7 +139,6 @@ PKG_CHECK_MODULES(CHEESE, \
gtk+-2.0 >= $GTK_REQUIRED \
gdk-2.0 >= $GDK_REQUIRED \
gnome-desktop-2.0 >= $LIBGNOMEDESKTOP_REQUIRED \
- gconf-2.0 >= $GCONF_REQUIRED \
gstreamer-0.10 >= $GSTREAMER_REQUIRED \
gstreamer-plugins-base-0.10 >= $GSTREAMER_REQUIRED \
cairo >= $CAIRO_REQUIRED \
@@ -169,9 +167,7 @@ GLIB_MKENUMS=`$PKG_CONFIG --variable=glib_mkenums glib-2.0`
AC_SUBST(GLIB_GENMARSHAL)
AC_SUBST(GLIB_MKENUMS)
-AC_PATH_PROG(GCONFTOOL, gconftool-2)
-AM_GCONF_SOURCE_2
-
+GLIB_GSETTINGS
#*******************************************************************************
AC_OUTPUT([
diff --git a/data/Makefile.am b/data/Makefile.am
index dc277b6..48b23c3 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -5,10 +5,8 @@ desktopdir = $(datadir)/applications
desktop_in_files = cheese.desktop.in
desktop_DATA = $(desktop_in_files:.desktop.in=.desktop)
- INTLTOOL_SCHEMAS_RULE@
-schemadir = $(sysconfdir)/gconf/schemas
-schema_in_files = cheese.schemas.in
-schema_DATA = $(schema_in_files:.schemas.in=.schemas)
+gsettings_SCHEMAS = org.gnome.Cheese.gschema.xml
+ GSETTINGS_RULES@
gtkrcdir = $(pkgdatadir)
gtkrc_DATA = gtkrc
@@ -31,7 +29,7 @@ pkgdata_DATA = \
EXTRA_DIST = \
$(desktop_in_files) \
- $(schema_in_files) \
+ $(gsettings_SCHEMAS) \
$(service_in_files) \
$(pkgdata_DATA) \
$(gtkrc_DATA) \
@@ -40,22 +38,9 @@ EXTRA_DIST = \
bugreportdir = $(libexecdir)/cheese
bugreport_SCRIPTS = cheese-bugreport.sh
-if GCONF_SCHEMAS_INSTALL
-install-data-local:
- -GCONF_CONFIG_SOURCE=$(GCONF_SCHEMA_CONFIG_SOURCE) \
- $(GCONFTOOL) --makefile-install-rule $(schema_DATA)
-endif
-
-if GCONF_SCHEMAS_INSTALL
-uninstall-local:
- -GCONF_CONFIG_SOURCE=$(GCONF_SCHEMA_CONFIG_SOURCE) \
- $(GCONFTOOL) --makefile-uninstall-rule $(schema_DATA)
-endif
-
clean-local :
rm -f *~
DISTCLEANFILES = \
cheese.desktop \
- cheese.schemas \
org.gnome.Cheese.service
diff --git a/libcheese/cheese-gconf.c b/libcheese/cheese-gconf.c
index 984e0a7..ca958f7 100644
--- a/libcheese/cheese-gconf.c
+++ b/libcheese/cheese-gconf.c
@@ -22,15 +22,13 @@
#endif
#include <glib.h>
+#include <glib-object.h>
+#include <glib.h>
+#include <gio/gio.h>
#include <stdlib.h>
-#include <gconf/gconf.h>
-#include <gconf/gconf-client.h>
-
#include "cheese-gconf.h"
-#define CHEESE_GCONF_PREFIX "/apps/cheese"
-
G_DEFINE_TYPE (CheeseGConf, cheese_gconf, G_TYPE_OBJECT)
#define CHEESE_GCONF_GET_PRIVATE(o) \
@@ -38,7 +36,7 @@ G_DEFINE_TYPE (CheeseGConf, cheese_gconf, G_TYPE_OBJECT)
typedef struct
{
- GConfClient *client;
+ GSettings *settings;
} CheeseGConfPrivate;
static void
@@ -50,142 +48,69 @@ cheese_gconf_get_property (GObject *object, guint prop_id, GValue *value,
self = CHEESE_GCONF (object);
CheeseGConfPrivate *priv = CHEESE_GCONF_GET_PRIVATE (self);
- char *effects;
GSList *list, *tmp;
+ char *temp_str;
+ gboolean temp_bool;
+ int temp_int;
+ double temp_dbl;
switch (prop_id)
{
case GCONF_PROP_COUNTDOWN:
- g_value_set_boolean (value, gconf_client_get_bool (priv->client,
- CHEESE_GCONF_PREFIX "/countdown",
- NULL));
+ g_settings_get (priv->settings, "countdown", "b", &temp_bool);
+ g_value_set_boolean (value, temp_bool);
break;
case GCONF_PROP_CAMERA:
- g_value_set_string (value, gconf_client_get_string (priv->client,
- CHEESE_GCONF_PREFIX "/camera",
- NULL));
- break;
- case GCONF_PROP_SELECTED_EFFECTS:
- effects = NULL;
- list = gconf_client_get_list (priv->client,
- CHEESE_GCONF_PREFIX "/selected_effects",
- GCONF_VALUE_STRING,
- NULL);
- tmp = list;
- while (tmp != NULL)
- {
- char *str = tmp->data;
- int j;
- str[0] = g_ascii_toupper (str[0]);
- for (j = 1; j < g_utf8_strlen (str, -1); j++)
- {
- if (str[j] == '-')
- {
- str[j] = ' ';
- str[j + 1] = g_ascii_toupper (str[j + 1]);
- }
- else if (str[j] == '_')
- {
- str[j] = '/';
- str[j + 1] = g_ascii_toupper (str[j + 1]);
- }
- }
- if (effects == NULL)
- effects = g_strdup (str);
- else
- {
- gchar *dummy = effects;
- effects = g_strjoin (",", effects, str, NULL);
- g_free (dummy);
- }
-
- g_free (tmp->data);
- tmp = g_slist_next (tmp);
- }
- g_value_set_string (value, effects);
-
- g_slist_free (list);
- g_slist_free (tmp);
+ g_settings_get (priv->settings, "camera", "s", &temp_str);
+ g_value_set_string (value, temp_str);
break;
case GCONF_PROP_X_RESOLUTION:
- g_value_set_int (value, gconf_client_get_int (priv->client,
- CHEESE_GCONF_PREFIX "/x_resolution",
- NULL));
+ g_settings_get (priv->settings, "x-resolution", "i", &temp_int);
+ g_value_set_int (value, temp_int);
break;
case GCONF_PROP_Y_RESOLUTION:
- g_value_set_int (value, gconf_client_get_int (priv->client,
- CHEESE_GCONF_PREFIX "/y_resolution",
- NULL));
+ g_settings_get (priv->settings, "y-resolution", "i", &temp_int);
+ g_value_set_int (value, temp_int);
break;
case GCONF_PROP_BRIGHTNESS:
- if (!gconf_client_get (priv->client,
- CHEESE_GCONF_PREFIX "/brightness",
- NULL))
- g_value_set_double (value, G_PARAM_SPEC_DOUBLE (pspec)->default_value);
- else
- g_value_set_double (value, gconf_client_get_float (priv->client,
- CHEESE_GCONF_PREFIX "/brightness",
- NULL));
+ g_settings_get (priv->settings, "brightness", "d", &temp_dbl);
+ g_value_set_double (value, temp_dbl);
break;
case GCONF_PROP_CONTRAST:
- if (!gconf_client_get (priv->client,
- CHEESE_GCONF_PREFIX "/contrast",
- NULL))
- g_value_set_double (value, G_PARAM_SPEC_DOUBLE (pspec)->default_value);
- else
- g_value_set_double (value, gconf_client_get_float (priv->client,
- CHEESE_GCONF_PREFIX "/contrast",
- NULL));
+ g_settings_get (priv->settings, "contrast", "d", &temp_dbl);
+ g_value_set_double (value, temp_dbl);
break;
case GCONF_PROP_SATURATION:
- if (!gconf_client_get (priv->client,
- CHEESE_GCONF_PREFIX "/saturation",
- NULL))
- g_value_set_double (value, G_PARAM_SPEC_DOUBLE (pspec)->default_value);
- else
- g_value_set_double (value, gconf_client_get_float (priv->client,
- CHEESE_GCONF_PREFIX "/saturation",
- NULL));
+ g_settings_get (priv->settings, "saturation", "d", &temp_dbl);
+ g_value_set_double (value, temp_dbl);
break;
case GCONF_PROP_HUE:
- if (!gconf_client_get (priv->client,
- CHEESE_GCONF_PREFIX "/hue",
- NULL))
- g_value_set_double (value, G_PARAM_SPEC_DOUBLE (pspec)->default_value);
- else
- g_value_set_double (value, gconf_client_get_float (priv->client,
- CHEESE_GCONF_PREFIX "/hue",
- NULL));
+ g_settings_get (priv->settings, "hue", "d", &temp_dbl);
+ g_value_set_double (value, temp_dbl);
break;
case GCONF_PROP_VIDEO_PATH:
- g_value_set_string (value, gconf_client_get_string (priv->client,
- CHEESE_GCONF_PREFIX "/video_path",
- NULL));
+ g_settings_get (priv->settings, "video-path", "s", &temp_str);
+ g_value_set_string (value, temp_str);
break;
case GCONF_PROP_PHOTO_PATH:
- g_value_set_string (value, gconf_client_get_string (priv->client,
- CHEESE_GCONF_PREFIX "/photo_path",
- NULL));
+ g_settings_get (priv->settings, "photo-path", "s", &temp_str);
+ g_value_set_string (value, temp_str);
break;
case GCONF_PROP_ENABLE_DELETE:
- g_value_set_boolean (value, gconf_client_get_bool (priv->client,
- CHEESE_GCONF_PREFIX "/enable_delete",
- NULL));
+ g_settings_get (priv->settings, "enable-delete", "b", &temp_bool);
+ g_value_set_boolean (value, temp_bool);
break;
case GCONF_PROP_WIDE_MODE:
- g_value_set_boolean (value, gconf_client_get_bool (priv->client,
- CHEESE_GCONF_PREFIX "/wide_mode",
- NULL));
+ g_settings_get (priv->settings, "wide-mode", "b", &temp_bool);
+ g_value_set_boolean (value, temp_bool);
break;
case GCONF_PROP_BURST_DELAY:
- g_value_set_int (value, gconf_client_get_int (priv->client,
- CHEESE_GCONF_PREFIX "/burst_delay",
- NULL));
+ g_settings_get (priv->settings, "burst-delay", "i", &temp_int);
+ g_value_set_int (value, temp_int);
break;
case GCONF_PROP_BURST_REPEAT:
- g_value_set_int (value, gconf_client_get_int (priv->client,
- CHEESE_GCONF_PREFIX "/burst_repeat",
- NULL));
+ g_settings_get (priv->settings, "burst-repeat", "i", &temp_int);
+ g_value_set_int (value, temp_int);
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
@@ -209,128 +134,46 @@ cheese_gconf_set_property (GObject *object, guint prop_id, const GValue *value,
switch (prop_id)
{
case GCONF_PROP_COUNTDOWN:
- gconf_client_set_bool (priv->client,
- CHEESE_GCONF_PREFIX "/countdown",
- g_value_get_boolean (value),
- NULL);
+ g_settings_set (priv->settings, "countdown", "b", g_value_get_boolean (value));
break;
case GCONF_PROP_CAMERA:
- gconf_client_set_string (priv->client,
- CHEESE_GCONF_PREFIX "/camera",
- g_value_get_string (value),
- NULL);
- break;
- case GCONF_PROP_SELECTED_EFFECTS:
-
- if (g_value_get_string (value) == NULL)
- {
- list = NULL;
- }
- else
- {
- char *str = g_value_dup_string (value);
- int j;
- for (j = 0; j < g_utf8_strlen (str, -1); j++)
- {
- if (g_ascii_isupper (str[j]))
- {
- str[j] = g_ascii_tolower (str[j]);
- }
- else if (str[j] == ' ')
- {
- str[j] = '-';
- }
- else if (str[j] == '/')
- {
- str[j] = '_';
- }
- }
- effects = g_strsplit (str, ",", 12);
- for (i = 0; effects[i] != NULL; i++)
- {
- list = g_slist_append (list, effects[i]);
- }
- g_free (str);
- }
- gconf_client_set_list (priv->client,
- CHEESE_GCONF_PREFIX "/selected_effects",
- GCONF_VALUE_STRING,
- list,
- NULL);
- g_slist_free (list);
- g_strfreev (effects);
+ g_settings_set (priv->settings, "camera", "s", g_value_get_string (value));
break;
case GCONF_PROP_X_RESOLUTION:
- gconf_client_set_int (priv->client,
- CHEESE_GCONF_PREFIX "/x_resolution",
- g_value_get_int (value),
- NULL);
+ g_settings_set (priv->settings, "x-resolution", "i", g_value_get_int (value));
break;
case GCONF_PROP_Y_RESOLUTION:
- gconf_client_set_int (priv->client,
- CHEESE_GCONF_PREFIX "/y_resolution",
- g_value_get_int (value),
- NULL);
+ g_settings_set (priv->settings, "y-resolution", "i", g_value_get_int (value));
break;
case GCONF_PROP_BRIGHTNESS:
- gconf_client_set_float (priv->client,
- CHEESE_GCONF_PREFIX "/brightness",
- g_value_get_double (value),
- NULL);
+ g_settings_set (priv->settings, "brightness", "d", g_value_get_double (value));
break;
case GCONF_PROP_CONTRAST:
- gconf_client_set_float (priv->client,
- CHEESE_GCONF_PREFIX "/contrast",
- g_value_get_double (value),
- NULL);
+ g_settings_set (priv->settings, "contrast", "d", g_value_get_double (value));
break;
case GCONF_PROP_SATURATION:
- gconf_client_set_float (priv->client,
- CHEESE_GCONF_PREFIX "/saturation",
- g_value_get_double (value),
- NULL);
+ g_settings_set (priv->settings, "saturation", "d", g_value_get_double (value));
break;
case GCONF_PROP_HUE:
- gconf_client_set_float (priv->client,
- CHEESE_GCONF_PREFIX "/hue",
- g_value_get_double (value),
- NULL);
+ g_settings_set (priv->settings, "hue", "d", g_value_get_double (value));
break;
case GCONF_PROP_VIDEO_PATH:
- gconf_client_set_string (priv->client,
- CHEESE_GCONF_PREFIX "/video_path",
- g_value_get_string (value),
- NULL);
+ g_settings_set (priv->settings, "video-path", "s", g_value_get_string (value));
break;
case GCONF_PROP_PHOTO_PATH:
- gconf_client_set_string (priv->client,
- CHEESE_GCONF_PREFIX "/photo_path",
- g_value_get_string (value),
- NULL);
+ g_settings_set (priv->settings, "photo-path", "s", g_value_get_string (value));
break;
case GCONF_PROP_ENABLE_DELETE:
- gconf_client_set_bool (priv->client,
- CHEESE_GCONF_PREFIX "/enable_delete",
- g_value_get_boolean (value),
- NULL);
+ g_settings_set (priv->settings, "enable-delete", "b", g_value_get_boolean (value));
break;
case GCONF_PROP_WIDE_MODE:
- gconf_client_set_bool (priv->client,
- CHEESE_GCONF_PREFIX "/wide_mode",
- g_value_get_boolean (value),
- NULL);
+ g_settings_set (priv->settings, "wide-mode", "b", g_value_get_boolean (value));
break;
case GCONF_PROP_BURST_DELAY:
- gconf_client_set_int (priv->client,
- CHEESE_GCONF_PREFIX "/burst_delay",
- g_value_get_int (value),
- NULL);
+ g_settings_set (priv->settings, "burst-delay", "i", g_value_get_int (value));
break;
case GCONF_PROP_BURST_REPEAT:
- gconf_client_set_int (priv->client,
- CHEESE_GCONF_PREFIX "/burst_repeat",
- g_value_get_int (value),
- NULL);
+ g_settings_set (priv->settings, "burst-repeat", "i", g_value_get_int (value));
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
@@ -346,7 +189,7 @@ cheese_gconf_finalize (GObject *object)
gconf = CHEESE_GCONF (object);
CheeseGConfPrivate *priv = CHEESE_GCONF_GET_PRIVATE (gconf);
- g_object_unref (priv->client);
+ g_object_unref (priv->settings);
G_OBJECT_CLASS (cheese_gconf_parent_class)->finalize (object);
}
@@ -487,7 +330,7 @@ cheese_gconf_init (CheeseGConf *gconf)
{
CheeseGConfPrivate *priv = CHEESE_GCONF_GET_PRIVATE (gconf);
- priv->client = gconf_client_get_default ();
+ priv->settings = g_settings_new ("org.gnome.Cheese");
}
CheeseGConf *
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]