Hello community, here is the log from the commit of package gconf-editor checked in at Wed Mar 12 19:46:37 CET 2008. -------- --- GNOME/gconf-editor/gconf-editor.changes 2007-10-11 16:39:37.000000000 +0200 +++ /mounts/work_src_done/STABLE/gconf-editor/gconf-editor.changes 2008-03-12 18:31:10.000000000 +0100 @@ -1,0 +2,6 @@ +Wed Mar 12 18:13:09 CET 2008 - sbrabec@suse.cz + +- Added support for editing of vendor defaults (fate#301464, + bgo#522055). + +------------------------------------------------------------------- New: ---- gconf-editor-vendor-defaults-support.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ gconf-editor.spec ++++++ --- /var/tmp/diff_new_pack.u15470/_old 2008-03-12 19:45:12.000000000 +0100 +++ /var/tmp/diff_new_pack.u15470/_new 2008-03-12 19:45:12.000000000 +0100 @@ -1,7 +1,7 @@ # # spec file for package gconf-editor (Version 2.20.0) # -# Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany. # This file and all modifications and additions to the pristine # package are under the same license as the package itself. # @@ -10,16 +10,19 @@ # norootforbuild + Name: gconf-editor BuildRequires: docbook_4 fdupes gnome-common gnome-doc-utils gnome-doc-utils-devel intltool libgnomeui-devel libxslt perl-XML-Parser update-desktop-files License: GPL v2 or later Group: System/GUI/GNOME Version: 2.20.0 -Release: 9 +Release: 70 Summary: An Editor for the GCONF Database System Source: ftp://ftp.gnome.org/pub/GNOME/sources/gconf-editor/2.20/%{name}-%{version}.tar.bz2 Patch: gconf-editor-strict-aliasing.patch Patch1: %{name}-desktop.patch +# Support for editing of vendor defaults, fate#301464, bgo#522055 +Patch2: %{name}-vendor-defaults-support.patch Url: http://www.gnome.org BuildRoot: %{_tmppath}/%{name}-%{version}-build AutoReqProv: on @@ -38,13 +41,15 @@ %setup -q %patch %patch1 +%patch2 %build autoreconf -f -i %configure\ --disable-scrollkeeper\ --with-gconf-defaults-source=xml::%{_sysconfdir}/gconf/gconf.xml.defaults\ - --with-gconf-mandatory-source=xml::%{_sysconfdir}/gconf/gconf.xml.mandatory + --with-gconf-mandatory-source=xml::%{_sysconfdir}/gconf/gconf.xml.mandatory\ + --with-gconf-vendor-source=xml::%{_sysconfdir}/gconf/gconf.xml.vendor make %{?jobs:-j%jobs} %install @@ -74,30 +79,34 @@ %doc %{_mandir}/man?/*.* %files lang -f %{name}.lang + %changelog -* Thu Oct 11 2007 - sbrabec@suse.cz +* Wed Mar 12 2008 sbrabec@suse.cz +- Added support for editing of vendor defaults (fate#301464, + bgo#522055). +* Thu Oct 11 2007 sbrabec@suse.cz - Removed bogus dependency on mDNSResponder. -* Tue Sep 18 2007 - sbrabec@suse.cz +* Tue Sep 18 2007 sbrabec@suse.cz - Updated to version 2.20.0: * Install theme friendly icons. * Updated translations. -* Fri Aug 31 2007 - maw@suse.de +* Fri Aug 31 2007 maw@suse.de - Update to version 2.18.2: + Fix crashers in search + Code cleanups. -* Mon Aug 06 2007 - maw@suse.de +* Mon Aug 06 2007 maw@suse.de - Use %%fdupes - Split off a -lang subpackage. -* Thu May 24 2007 - stbinner@suse.de +* Thu May 24 2007 stbinner@suse.de - remove X-SuSE-translate from .desktop file patch -* Thu May 10 2007 - pgajdos@suse.cz +* Thu May 10 2007 pgajdos@suse.cz - removed gnome-icon-theme from Requires and BuildRequires [#247450] -* Wed Apr 11 2007 - maw@suse.de +* Thu Apr 12 2007 maw@suse.de - Update to version 2.18.0 - Bring the .desktop file up to spec - Minor build changes. -* Thu Mar 08 2007 - maw@suse.de +* Fri Mar 09 2007 maw@suse.de - Update to version 2.17.0. * src/gconf-search.c: (gconf_tree_model_search_iter_foreach): Fix a double-free crashing in searchs. Fix bug #361137 @@ -114,21 +123,21 @@ * configure.in: Require intltool 0.35.0. (both these were released in the 2.15.92 tarball but never commited to CVS :-/) -* Thu Jan 04 2007 - sbrabec@suse.cz +* Thu Jan 04 2007 sbrabec@suse.cz - Prefix changed to /usr. - Spec file cleanup. -* Fri Oct 13 2006 - ro@suse.de +* Fri Oct 13 2006 ro@suse.de - added gnome-doc-utils devel to buildreq -* Thu Sep 14 2006 - jhargadon@suse.de +* Thu Sep 14 2006 jhargadon@suse.de - update to version 2.16.0 - configure.in: Release 2.16.0 -* Tue Sep 05 2006 - aj@suse.de +* Tue Sep 05 2006 aj@suse.de - Cleanup BuildRequires. -* Wed Aug 23 2006 - jhargadon@suse.de +* Wed Aug 23 2006 jhargadon@suse.de - update to version 2.15.91 - Port to gnome-doc-utils - Port to gtk+ from deprecated libgnomeui -* Thu Aug 03 2006 - jhargadon@suse.de +* Thu Aug 03 2006 jhargadon@suse.de - update to 2.14.0 - configure.in: Added translations - Fix button sensitivity illness on the key list dialog. @@ -136,65 +145,65 @@ - configure.in: remove some redundant code which set GCONF_DEFAULTS_SOURCE with a value which was later overwritten. -* Fri Apr 14 2006 - sbrabec@suse.cz +* Fri Apr 14 2006 sbrabec@suse.cz - Explicitly define customization databases (#166223). -* Tue Apr 11 2006 - sbrabec@suse.cz +* Tue Apr 11 2006 sbrabec@suse.cz - Translate desktop file. -* Sun Feb 19 2006 - stbinner@suse.de +* Sun Feb 19 2006 stbinner@suse.de - fix gconf-editor-desktop.patch (GenericName) -* Wed Jan 25 2006 - mls@suse.de +* Wed Jan 25 2006 mls@suse.de - converted neededforbuild to BuildRequires -* Wed Nov 30 2005 - gekker@suse.de +* Wed Nov 30 2005 gekker@suse.de - Update to version 2.12.1 -* Wed Sep 07 2005 - sbrabec@suse.cz +* Wed Sep 07 2005 sbrabec@suse.cz - Updated to version 2.12.0 (GNOME 2.12). -* Tue Aug 23 2005 - gekker@suse.de +* Tue Aug 23 2005 gekker@suse.de - Update to version 2.11.92 -* Wed Mar 16 2005 - clahey@suse.de +* Wed Mar 16 2005 clahey@suse.de - Degeneralize menu item. -* Wed Mar 09 2005 - gekker@suse.de +* Wed Mar 09 2005 gekker@suse.de - Update to version 2.10.0 (GNOME 2.10). -* Thu Mar 03 2005 - gekker@suse.de +* Thu Mar 03 2005 gekker@suse.de - Update to version 2.9.92 -* Thu Feb 10 2005 - gekker@suse.de +* Fri Feb 11 2005 gekker@suse.de - Update to version 2.9.91 -* Sat Feb 05 2005 - gekker@suse.de +* Sat Feb 05 2005 gekker@suse.de - Update to version 2.9.3 -* Wed Jan 19 2005 - gekker@suse.de +* Wed Jan 19 2005 gekker@suse.de - Update to version 2.9.2 -* Tue Dec 14 2004 - hvogel@suse.de +* Tue Dec 14 2004 hvogel@suse.de - fix desktop file -* Mon Nov 01 2004 - mmj@suse.de +* Mon Nov 01 2004 mmj@suse.de - Locale rename no to nb -* Wed May 05 2004 - sbrabec@suse.cz +* Wed May 05 2004 sbrabec@suse.cz - Updated to version 2.6.1 (GNOME 2.6). -* Sat Jan 10 2004 - adrian@suse.de +* Sat Jan 10 2004 adrian@suse.de - fix build as user -* Wed Oct 08 2003 - sbrabec@suse.cz +* Wed Oct 08 2003 sbrabec@suse.cz - Updated to version 2.4.0 (GNOME 2.4). -* Mon Jul 14 2003 - sbrabec@suse.cz +* Mon Jul 14 2003 sbrabec@suse.cz - GNOME prefix change to /opt/gnome. -* Wed Jul 02 2003 - hhetter@suse.de +* Wed Jul 02 2003 hhetter@suse.de - updated to version 0.5.0 -* Mon Jun 30 2003 - sbrabec@suse.cz +* Mon Jun 30 2003 sbrabec@suse.cz - Updated to version 0.4.1. - Updated neededforbuild. -* Mon Jun 30 2003 - ro@suse.de +* Mon Jun 30 2003 ro@suse.de - added directory to filelist - use find_lang -* Wed May 28 2003 - ro@suse.de +* Wed May 28 2003 ro@suse.de - add other pixmaps to filelist -* Tue Jan 28 2003 - hhetter@suse.de +* Tue Jan 28 2003 hhetter@suse.de - updated to 0.4.0 - kde data dir fix -* Thu Nov 28 2002 - hhetter@suse.de +* Thu Nov 28 2002 hhetter@suse.de - updated to version 0.3.1 [GNOME 2.0.3] -* Mon Nov 11 2002 - ro@suse.de +* Tue Nov 12 2002 ro@suse.de - changed neededforbuild <xf86 xdevel> to <x-devel-packages> -* Tue Oct 22 2002 - hhetter@suse.de +* Tue Oct 22 2002 hhetter@suse.de - updated to version 0.3 - removed wrong docdir -* Fri Sep 27 2002 - ro@suse.de +* Fri Sep 27 2002 ro@suse.de - Added alsa alsa-devel to neededforbuild (esound) -* Fri Jun 07 2002 - hhetter@suse.de +* Fri Jun 07 2002 hhetter@suse.de - initial SuSE package ++++++ gconf-editor-vendor-defaults-support.patch ++++++ Support for editing of vendor defaults (fate#301464, bgo#522055). Many vendors create default configuration, which consists of four system path elements: * Keys defined in schemas * Defaults defined by vendor * Defaults defined by system administrator * Mandatory defined by system administrator It allows to provide vendor branding and make "Keys defined in schemas" unchanged. Attached patch allows to set vendor defaults using gconf-editor. In the current version, GUI for vendor defaults is equal to system defaults. ================================================================================ --- configure.in +++ configure.in @@ -66,6 +66,14 @@ AC_DEFINE_UNQUOTED(GCONF_MANDATORY_SOURCE, "$GCONF_MANDATORY_SOURCE", [GConf mandatory source]) AC_MSG_RESULT([Using config source $GCONF_MANDATORY_SOURCE for mandatory values]) +GCONF_VENDOR_SOURCE=`echo $GCONF_DEFAULTS_SOURCE | sed -e s/gconf.xml.defaults/gconf.xml.vendor/` +AC_ARG_WITH(gconf-vendor-source, + AC_HELP_STRING([--with-gconf-vendor-source], + [The GConf source of the vendor defaults values]), + GCONF_VENDOR_SOURCE="$withval",) +AC_DEFINE_UNQUOTED(GCONF_VENDOR_SOURCE, "$GCONF_VENDOR_SOURCE", [GConf vendor defaults source]) +AC_MSG_RESULT([Using config source $GCONF_VENDOR_SOURCE for vendor defaults values]) + AC_CONFIG_FILES([ Makefile data/Makefile @@ -81,4 +89,5 @@ echo " Configuration Sources: GConf default values source: ${GCONF_DEFAULTS_SOURCE} -GConf mandatory values source: ${GCONF_MANDATORY_SOURCE}" +GConf mandatory values source: ${GCONF_MANDATORY_SOURCE} +GConf vendor defaults values source: ${GCONF_VENDOR_SOURCE}" --- src/gconf-editor-application.c +++ src/gconf-editor-application.c @@ -73,6 +73,15 @@ gtk_widget_set_sensitive (gtk_ui_manager_get_widget (gconfwindow->ui_manager, "/GConfKeyPopupMenu/MandatoryKey"), FALSE); + if (!gconf_util_can_edit_vendor ()) { + gtk_widget_set_sensitive (gtk_ui_manager_get_widget (gconfwindow->ui_manager, "/GConfKeyPopupMenu/VendorKey"), + FALSE); + gtk_action_set_sensitive (gtk_ui_manager_get_action (gconfwindow->ui_manager, "/GConfEditorMenu/FileMenu/NewVendorWindow"), + FALSE); + } else if (gconfwindow->type == GCONF_EDITOR_WINDOW_TYPE_VENDOR) + gtk_widget_set_sensitive (gtk_ui_manager_get_widget (gconfwindow->ui_manager, "/GConfKeyPopupMenu/VendorKey"), + FALSE); + g_signal_connect (window, "destroy", G_CALLBACK (gconf_editor_application_window_destroyed), NULL); --- src/gconf-editor-window.c +++ src/gconf-editor-window.c @@ -357,6 +357,15 @@ } static void +gconf_editor_window_new_vendor_window (GtkAction *action, GtkWidget *callback_data) +{ + GtkWidget *new_window; + + new_window = gconf_editor_application_create_editor_window (GCONF_EDITOR_WINDOW_TYPE_VENDOR); + gtk_widget_show (new_window); +} + +static void help_cb (GtkAction *action, GtkWidget *callback_data) { GError *error = NULL; @@ -717,6 +726,41 @@ g_object_unref (client); } +static void +gconf_editor_popup_window_set_as_vendor (GtkAction *action, GtkWidget *callback_data) +{ + GConfEditorWindow *gconfwindow = GCONF_EDITOR_WINDOW (callback_data); + GtkWindow *window = GTK_WINDOW (callback_data); + + GError *error = NULL; + GtkTreeIter iter; + GConfValue *value; + char *path = NULL; + GConfClient *client; + + + client = gconf_editor_window_get_client (GCONF_EDITOR_WINDOW_TYPE_VENDOR); + if (client == NULL) { + g_print ("Could not create GConf client\n"); + return; + } + + gtk_tree_selection_get_selected (gtk_tree_view_get_selection (GTK_TREE_VIEW (gconfwindow->list_view)), + NULL, &iter); + gtk_tree_model_get (gconfwindow->sorted_list_model, &iter, + GCONF_LIST_MODEL_KEY_PATH_COLUMN, &path, + GCONF_LIST_MODEL_VALUE_COLUMN, &value, + -1); + + gconf_client_set (client, path, value, NULL); + + gconf_client_suggest_sync (client, &error); + if (error) { + gconf_editor_window_popup_error_dialog (window, _("Could not sync value. Error was:\n%s"), error); + } + g_object_unref (client); +} + static GtkActionEntry entries[] = { { "FileMenu", NULL, N_("_File"), NULL, NULL, NULL }, { "EditMenu", NULL, N_("_Edit"), NULL, NULL, NULL }, @@ -733,6 +777,9 @@ { "NewMandatoryWindow", GTK_STOCK_NEW, N_("New _Mandatory Window"), "<control>M", N_("Open a new Configuration Editor window editing system mandatory settings"), G_CALLBACK (gconf_editor_window_new_mandatory_window) }, + { "NewVendorWindow", GTK_STOCK_NEW, N_("New _Vendor Defaults Window"), "<control>B", + N_("Open a new Configuration Editor window editing vendor defaults settings"), + G_CALLBACK (gconf_editor_window_new_vendor_window) }, { "CloseWindow", GTK_STOCK_CLOSE, N_("_Close Window"), "<control>W", N_("Close this window"), G_CALLBACK (gconf_editor_window_close_window) }, { "QuitGConfEditor", GTK_STOCK_QUIT, N_("_Quit"), "<control>Q", N_("Quit the Configuration Editor"), @@ -764,7 +811,9 @@ { "DefaultKey", NULL, N_("Set as _Default"), NULL, N_("Set the selected key to be the default"), G_CALLBACK (gconf_editor_popup_window_set_as_default) }, { "MandatoryKey", NULL, N_("Set as _Mandatory"), NULL, N_("Set the selected key to the mandatory"), - G_CALLBACK (gconf_editor_popup_window_set_as_mandatory) } + G_CALLBACK (gconf_editor_popup_window_set_as_mandatory) }, + { "VendorKey", NULL, N_("Set as _Vendor Default"), NULL, N_("Set the selected key to be the vendor default"), + G_CALLBACK (gconf_editor_popup_window_set_as_vendor) } }; static const char *ui_description = @@ -774,6 +823,7 @@ " <menuitem action='NewWindow'/>" " <menuitem action='NewDefaultsWindow'/>" " <menuitem action='NewMandatoryWindow'/>" + " <menuitem action='NewVendorWindow'/>" " <menuitem action='CloseWindow'/>" " <separator/>" " <menuitem action='QuitGConfEditor'/>" @@ -803,6 +853,8 @@ " <menuitem action='DefaultKey'/>" " <separator/>" " <menuitem action='MandatoryKey'/>" + " <separator/>" + " <menuitem action='VendorKey'/>" " </popup>" "</ui>"; @@ -810,6 +862,7 @@ "/GConfEditorMenu/FileMenu/NewWindow", "/GConfEditorMenu/FileMenu/NewDefaultsWindow", "/GConfEditorMenu/FileMenu/NewMandatoryWindow", + "/GConfEditorMenu/FileMenu/NewVendorWindow", "/GConfEditorMenu/FileMenu/CloseWindow", "/GConfEditorMenu/FileMenu/QuitGConfEditor", @@ -850,6 +903,9 @@ case GCONF_EDITOR_WINDOW_TYPE_MANDATORY: base_title = _("Configuration Editor (Mandatory settings)"); break; + case GCONF_EDITOR_WINDOW_TYPE_VENDOR: + base_title = _("Configuration Editor (Vendor Defaults settings)"); + break; default: base_title = _("Configuration Editor"); } @@ -910,6 +966,8 @@ TRUE); gtk_widget_set_sensitive (gtk_ui_manager_get_widget (window->ui_manager, "/GConfKeyPopupMenu/MandatoryKey"), TRUE); + gtk_widget_set_sensitive (gtk_ui_manager_get_widget (window->ui_manager, "/GConfKeyPopupMenu/VendorKey"), + TRUE); gtk_tree_path_free (path); } @@ -922,6 +980,8 @@ FALSE); gtk_widget_set_sensitive (gtk_ui_manager_get_widget (window->ui_manager, "/GConfKeyPopupMenu/MandatoryKey"), FALSE); + gtk_widget_set_sensitive (gtk_ui_manager_get_widget (window->ui_manager, "/GConfKeyPopupMenu/VendorKey"), + FALSE); } @@ -1011,6 +1071,8 @@ TRUE); gtk_widget_set_sensitive (gtk_ui_manager_get_widget (window->ui_manager, "/GConfKeyPopupMenu/MandatoryKey"), TRUE); + gtk_widget_set_sensitive (gtk_ui_manager_get_widget (window->ui_manager, "/GConfKeyPopupMenu/VendorKey"), + TRUE); } else { @@ -1022,6 +1084,8 @@ FALSE); gtk_widget_set_sensitive (gtk_ui_manager_get_widget (window->ui_manager, "/GConfKeyPopupMenu/MandatoryKey"), FALSE); + gtk_widget_set_sensitive (gtk_ui_manager_get_widget (window->ui_manager, "/GConfKeyPopupMenu/VendorKey"), + FALSE); } @@ -1314,6 +1378,16 @@ client = gconf_client_get_for_engine (engine); gconf_engine_unref (engine); break; + case GCONF_EDITOR_WINDOW_TYPE_VENDOR: + engine = gconf_engine_get_for_address (GCONF_VENDOR_SOURCE, &error); + if (error) { + gconf_editor_window_popup_error_dialog (NULL, + _("Cannot create GConf engine. Error was:\n%s"), error); + return NULL; + } + client = gconf_client_get_for_engine (engine); + gconf_engine_unref (engine); + break; default: g_assert_not_reached (); } @@ -1341,6 +1415,9 @@ case GCONF_EDITOR_WINDOW_TYPE_MANDATORY: gtk_window_set_title (GTK_WINDOW (gconfwindow), _("Configuration Editor (Mandatory settings)")); break; + case GCONF_EDITOR_WINDOW_TYPE_VENDOR: + gtk_window_set_title (GTK_WINDOW (gconfwindow), _("Configuration Editor (Vendor Defaults settings)")); + break; default: gtk_window_set_title (GTK_WINDOW (gconfwindow), _("Configuration Editor")); } @@ -1406,7 +1483,7 @@ g_param_spec_int ("type", _("Type"), _("The Configuration Editor window type."), - GCONF_EDITOR_WINDOW_TYPE_NORMAL, GCONF_EDITOR_WINDOW_TYPE_MANDATORY, + GCONF_EDITOR_WINDOW_TYPE_NORMAL, GCONF_EDITOR_WINDOW_TYPE_VENDOR, GCONF_EDITOR_WINDOW_TYPE_NORMAL, (G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY))); --- src/gconf-editor-window.h +++ src/gconf-editor-window.h @@ -40,7 +40,8 @@ enum { GCONF_EDITOR_WINDOW_TYPE_NORMAL, GCONF_EDITOR_WINDOW_TYPE_DEFAULTS, - GCONF_EDITOR_WINDOW_TYPE_MANDATORY + GCONF_EDITOR_WINDOW_TYPE_MANDATORY, + GCONF_EDITOR_WINDOW_TYPE_VENDOR }; enum { --- src/gconf-util.c +++ src/gconf-util.c @@ -151,5 +151,16 @@ return can_edit_mandatory; } +gboolean +gconf_util_can_edit_vendor (void) +{ + static int can_edit_vendor = GCONF_NOT_SET; + + if (can_edit_vendor == GCONF_NOT_SET) + can_edit_vendor = can_edit_source (GCONF_VENDOR_SOURCE); + + return can_edit_vendor; +} + --- src/gconf-util.h +++ src/gconf-util.h @@ -34,5 +34,6 @@ GConfSchema *gconf_client_get_schema_for_key (GConfClient *client, const char *key); gboolean gconf_util_can_edit_defaults (void); gboolean gconf_util_can_edit_mandatory (void); +gboolean gconf_util_can_edit_vendor (void); #endif /* __GCONF_UTIL_H__ */ ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org