Mailinglist Archive: opensuse-commit (1670 mails)
| < Previous | Next > |
commit yast2-control-center-gnome
- From: root@xxxxxxx (h_root)
- Date: Thu, 26 Oct 2006 20:36:32 +0200 (CEST)
- Message-id: <20061026183632.6BD7C848F6@xxxxxxxxxxxxxxx>
Hello community,
here is the log from the commit of package yast2-control-center-gnome
checked in at Thu Oct 26 20:36:32 CEST 2006.
--------
--- yast2-control-center-gnome/yast2-control-center-gnome.changes 2006-10-09 13:10:33.000000000 +0200
+++ /mounts/work_src_done/STABLE/yast2-control-center-gnome/yast2-control-center-gnome.changes 2006-10-24 17:51:27.000000000 +0200
@@ -1,0 +2,5 @@
+Tue Oct 24 17:50:01 CEST 2006 - sreeves@xxxxxxx
+
+- Fix to build with new gnome-main-menu
+
+-------------------------------------------------------------------
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-control-center-gnome.spec ++++++
--- /var/tmp/diff_new_pack.FujWob/_old 2006-10-26 20:35:06.000000000 +0200
+++ /var/tmp/diff_new_pack.FujWob/_new 2006-10-26 20:35:06.000000000 +0200
@@ -14,11 +14,11 @@
BuildRequires: gnome-main-menu-devel libgnome-devel libgnomeui-devel
%define prefix /opt/gnome
%define sysconfdir /etc%{prefix}
-License: GPL
+License: GNU General Public License (GPL) - all versions
Group: System/Management
Autoreqprov: on
Version: 0.1.1
-Release: 1
+Release: 4
Summary: GNOME control center
Source: %{name}-%{version}.tar.gz
URL: http://en.opensuse.org/YaST2-GTK
@@ -94,5 +94,7 @@
/usr/share/YaST2/theme/SuSELinux/hicolor
%changelog -n yast2-control-center-gnome
+* Tue Oct 24 2006 - sreeves@xxxxxxx
+- Fix to build with new gnome-main-menu
* Mon Oct 09 2006 - mmichael@xxxxxxx
- import 1st cut.
++++++ yast2-control-center-gnome-0.1.1.tar.gz ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-control-center-gnome-0.1.1/src/control-center.c new/yast2-control-center-gnome-0.1.1/src/control-center.c
--- old/yast2-control-center-gnome-0.1.1/src/control-center.c 2006-10-09 15:01:22.000000000 +0200
+++ new/yast2-control-center-gnome-0.1.1/src/control-center.c 2006-10-24 02:08:13.000000000 +0200
@@ -13,99 +13,120 @@
void handle_static_action_clicked(Tile * tile, TileEvent * event, gpointer data);
static GSList * get_actions_list();
-#define CONTROL_CENTER_ACTIONS_LIST_KEY "/desktop/gnome/applications/y2cc-gnome/cc_actions_list"
-#define CONTROL_CENTER_ACTIONS_SEPARATOR ";"
#define CONTROL_CENTER_PREFIX "/desktop/gnome/applications/y2cc-gnome/cc_"
+#define CONTROL_CENTER_ACTIONS_LIST_KEY (CONTROL_CENTER_PREFIX "actions_list")
+#define CONTROL_CENTER_ACTIONS_SEPARATOR ";"
#define EXIT_SHELL_ON_STATIC_ACTION "exit_shell_on_static_action"
-static GSList * get_actions_list()
+static GSList *
+get_actions_list ()
{
- GSList * key_list;
- GSList * actions_list = NULL;
- AppAction * action;
-
- key_list = get_slab_gconf_slist(CONTROL_CENTER_ACTIONS_LIST_KEY);
- if(!key_list)
- {
- g_warning ("key not found [%s]\n", CONTROL_CENTER_ACTIONS_LIST_KEY);
+ GSList *key_list;
+ GSList *actions_list = NULL;
+ AppAction *action;
+
+ key_list = get_slab_gconf_slist (CONTROL_CENTER_ACTIONS_LIST_KEY);
+ if (!key_list)
+ {
+ g_warning (_("key not found [%s]\n"), CONTROL_CENTER_ACTIONS_LIST_KEY);
return NULL;
}
- for( ; key_list; key_list = key_list->next)
- {
- const gchar * entry = (const gchar *) key_list->data;
-
- action = g_new(AppAction, 1);
- gchar ** temp = g_strsplit(entry, CONTROL_CENTER_ACTIONS_SEPARATOR, 2);
- action->name = g_strdup(temp[0]);
- if((action->item = load_desktop_item_from_unknown(temp[1])) == NULL)
- {
- g_warning("get_actions_list() - PROBLEM - Can't load %s\n", temp[1]);
- g_strfreev(temp);
- continue;
- }
- g_strfreev(temp);
-
- actions_list = g_slist_append (actions_list, action);
+ for (; key_list; key_list = key_list->next)
+ {
+ gchar *entry = (gchar *) key_list->data;
+
+ action = g_new (AppAction, 1);
+ gchar **temp = g_strsplit (entry, CONTROL_CENTER_ACTIONS_SEPARATOR, 2);
+ action->name = g_strdup (temp[0]);
+ if ((action->item = load_desktop_item_from_unknown (temp[1])) == NULL)
+ {
+ g_warning ("get_actions_list() - PROBLEM - Can't load %s\n", temp[1]);
+ }
+ else
+ {
+ actions_list = g_slist_append (actions_list, action);
+ }
+ g_strfreev (temp);
+ g_free (entry);
}
+ g_slist_free (key_list);
return actions_list;
}
-void handle_static_action_clicked(Tile * tile, TileEvent * event, gpointer data)
+void
+handle_static_action_clicked (Tile * tile, TileEvent * event, gpointer data)
{
- AppShellData * app_data = (AppShellData *) data;
- GnomeDesktopItem * item = (GnomeDesktopItem *) g_object_get_data(G_OBJECT(tile), APP_ACTION_KEY);
- open_desktop_item_exec(item);
+ gchar *temp;
- if(get_slab_gconf_bool(g_strdup_printf("%s%s", app_data->gconf_prefix, EXIT_SHELL_ON_STATIC_ACTION)))
- gtk_main_quit();
+ AppShellData *app_data = (AppShellData *) data;
+ GnomeDesktopItem *item =
+ (GnomeDesktopItem *) g_object_get_data (G_OBJECT (tile), APP_ACTION_KEY);
+ open_desktop_item_exec (item);
+
+ temp = g_strdup_printf("%s%s", app_data->gconf_prefix, EXIT_SHELL_ON_STATIC_ACTION);
+ if (get_slab_gconf_bool(temp))
+ gtk_main_quit ();
+ g_free (temp);
}
-int main (int argc, char *argv [])
+int
+main (int argc, char *argv[])
{
- BonoboApplication * bonobo_app = NULL;
- gboolean hidden = FALSE;
-
- gtk_init (&argc, &argv);
+ BonoboApplication *bonobo_app = NULL;
+ gboolean hidden = FALSE;
+ gchar * startup_id;
+
+#ifdef ENABLE_NLS
+ bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR);
+ bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
+ textdomain (GETTEXT_PACKAGE);
+#endif
+
+ if (argc > 1)
+ {
+ if (argc != 2 || strcmp ("-h", argv[1]))
+ {
+ printf ("Usage - y2controlcenter-gnome [-h]\n");
+ printf ("Options: -h : hide on start\n");
+ printf ("\tUseful if you want to autostart the control-center singleton so it can get all it's slow loading done\n");
+ exit (1);
+ }
+ hidden = TRUE;
+ }
- // gnome_program_init clears the env variable that we depend on, so call this first
- if(apss_already_running(argc, argv, &bonobo_app, "YaST-gnome"))
- {
- gnome_program_init("YaST2 Gnome Control Center", "0.1", LIBGNOMEUI_MODULE, argc, argv, NULL, NULL);
- gdk_notify_startup_complete();
- bonobo_debug_shutdown ();
- exit(1);
- }
-
- gnome_program_init("YaST2 Gnome Control Center", "0.1", LIBGNOMEUI_MODULE, argc, argv, NULL, NULL);
-
- if(argc > 1)
- {
- if(argc != 2 || strcmp("-h", argv[1]))
- {
- printf("Usage - y2cc-gnome [-h]\n");
- printf("Options: -h : hide on start\n");
- printf("\tUseful if you want to autostart the control-center singleton so it can get all it's slow loading done\n");
- exit(1);
- }
- hidden = TRUE;
- }
+ startup_id = g_strdup (g_getenv (DESKTOP_STARTUP_ID));
+ gnome_program_init ("YaST2 Gnome Control Center", "0.1", LIBGNOMEUI_MODULE,
+ argc, argv, NULL, NULL);
+
+ if (apss_already_running (argc, argv, &bonobo_app, "YaST-gnome", startup_id))
+ {
+ gdk_notify_startup_complete ();
+ bonobo_debug_shutdown ();
+ g_free (startup_id);
+ exit (1);
+ }
GtkIconTheme * theme;
theme = gtk_icon_theme_get_default();
gtk_icon_theme_prepend_search_path (theme, "/usr/share/YaST2/theme/NLD");
- AppShellData * app_data = appshelldata_new("YaST-gnome.menu", NULL, CONTROL_CENTER_PREFIX, GTK_ICON_SIZE_LARGE_TOOLBAR);
- generate_categories(app_data);
- GSList * actions = get_actions_list();
- layout_shell(app_data, _("Filter"), _("Groups"), _("Common Tasks"), actions, handle_static_action_clicked);
-
- g_signal_connect (bonobo_app, "new-instance", G_CALLBACK (apss_new_instance_cb), app_data);
- create_main_window(app_data, "MyControlCenter", _("Control Center"), "y2cc-gnome", 975, 600, hidden);
-
- if(bonobo_app) bonobo_object_unref(bonobo_app);
- bonobo_debug_shutdown();
- return 0;
+ AppShellData *app_data = appshelldata_new (
+ "YaST-gnome.menu", NULL, CONTROL_CENTER_PREFIX, GTK_ICON_SIZE_LARGE_TOOLBAR);
+ generate_categories (app_data);
+
+ GSList *actions = get_actions_list ();
+ layout_shell (app_data, _("Filter"), _("Groups"), _("Common Tasks"), actions,
+ handle_static_action_clicked);
+
+ g_signal_connect (bonobo_app, "new-instance", G_CALLBACK (apss_new_instance_cb), app_data);
+ create_main_window (app_data, "MyControlCenter", _("Control Center"),
+ "y2cc-gnome", 975, 600, hidden);
+
+ if (bonobo_app)
+ bonobo_object_unref (bonobo_app);
+ bonobo_debug_shutdown ();
+ g_free (startup_id);
+ return 0;
};
-
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-commit+help@xxxxxxxxxxxx
| < Previous | Next > |