==> common/ChangeLog <==
Fri Oct 24 18:22:06 2008 Søren Sandmann <sandmann@redhat.com> * capplet-util.[ch]: Add new capplet_init() function ==> default-applications/ChangeLog <== Fri Oct 24 18:22:22 2008 Søren Sandmann <sandmann@redhat.com> * gnome-da-capplet.c (main): Use new capplet_init() function svn path=/trunk/; revision=9105
This commit is contained in:
parent
0855f4bf5e
commit
2f8de6c511
5 changed files with 37 additions and 11 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
Fri Oct 24 18:22:06 2008 Søren Sandmann <sandmann@redhat.com>
|
||||||
|
|
||||||
|
* capplet-util.[ch]: Add new capplet_init() function
|
||||||
|
|
||||||
Fri Oct 24 17:21:56 2008 Søren Sandmann <sandmann@redhat.com>
|
Fri Oct 24 17:21:56 2008 Søren Sandmann <sandmann@redhat.com>
|
||||||
|
|
||||||
* capplet-stock-icons.c (capplet_register_stock_icons): Get rid of
|
* capplet-stock-icons.c (capplet_register_stock_icons): Get rid of
|
||||||
|
|
|
@ -179,3 +179,27 @@ capplet_file_delete_recursive (GFile *file, GError **error)
|
||||||
return g_file_delete (file, NULL, error);
|
return g_file_delete (file, NULL, error);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
capplet_init (GOptionContext *context,
|
||||||
|
int *argc,
|
||||||
|
char ***argv)
|
||||||
|
{
|
||||||
|
GError *err = NULL;
|
||||||
|
|
||||||
|
#ifdef ENABLE_NLS
|
||||||
|
bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR);
|
||||||
|
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
|
||||||
|
textdomain (GETTEXT_PACKAGE);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if (context) {
|
||||||
|
g_option_context_add_group (context, gtk_get_option_group (TRUE));
|
||||||
|
|
||||||
|
if (!g_option_context_parse (context, argc, argv, &err)) {
|
||||||
|
g_printerr ("%s\n", err->message);
|
||||||
|
exit (1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
gtk_init (argc, argv);
|
||||||
|
}
|
||||||
|
|
|
@ -48,5 +48,6 @@
|
||||||
void capplet_help (GtkWindow *parent, char const *section);
|
void capplet_help (GtkWindow *parent, char const *section);
|
||||||
void capplet_set_icon (GtkWidget *window, char const *icon_file_name);
|
void capplet_set_icon (GtkWidget *window, char const *icon_file_name);
|
||||||
gboolean capplet_file_delete_recursive (GFile *directory, GError **error);
|
gboolean capplet_file_delete_recursive (GFile *directory, GError **error);
|
||||||
|
void capplet_init (GOptionContext *context, int *argc, char ***argv);
|
||||||
|
|
||||||
#endif /* __CAPPLET_UTIL_H */
|
#endif /* __CAPPLET_UTIL_H */
|
||||||
|
|
|
@ -1,3 +1,7 @@
|
||||||
|
Fri Oct 24 18:22:22 2008 Søren Sandmann <sandmann@redhat.com>
|
||||||
|
|
||||||
|
* gnome-da-capplet.c (main): Use new capplet_init() function
|
||||||
|
|
||||||
Fri Oct 24 17:54:17 2008 Søren Sandmann <sandmann@redhat.com>
|
Fri Oct 24 17:54:17 2008 Søren Sandmann <sandmann@redhat.com>
|
||||||
|
|
||||||
* gnome-da-capplet.c (main): Fix to use gtk_init_with_args() correctly.
|
* gnome-da-capplet.c (main): Fix to use gtk_init_with_args() correctly.
|
||||||
|
|
|
@ -867,7 +867,7 @@ main (int argc, char **argv)
|
||||||
GnomeDACapplet *capplet;
|
GnomeDACapplet *capplet;
|
||||||
|
|
||||||
gchar *start_page = NULL;
|
gchar *start_page = NULL;
|
||||||
GError *err = NULL;
|
GOptionContext *context;
|
||||||
GOptionEntry option_entries[] = {
|
GOptionEntry option_entries[] = {
|
||||||
{ "show-page",
|
{ "show-page",
|
||||||
'p',
|
'p',
|
||||||
|
@ -880,17 +880,10 @@ main (int argc, char **argv)
|
||||||
{ NULL }
|
{ NULL }
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef ENABLE_NLS
|
context = g_option_context_new (_("- GNOME Default Applications"));
|
||||||
bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR);
|
g_option_context_add_main_entries (context, option_entries, GETTEXT_PACKAGE);
|
||||||
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
|
|
||||||
textdomain (GETTEXT_PACKAGE);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (!gtk_init_with_args (&argc, &argv, "- GNOME Default Applications",
|
capplet_init (context, &argc, &argv);
|
||||||
option_entries, GETTEXT_PACKAGE, &err)) {
|
|
||||||
g_printerr ("%s\n", err->message);
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
glade_init ();
|
glade_init ();
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue