shell: Move cheese_gtk_init() call earlier
Now that we handle local command line arguments, the 'command_line' vfunc can no longer get the initial argc/argv passed to the process. Now, cheese_gtk_init() is called unconditionally from main() where argc/argv are available. https://bugzilla.gnome.org/show_bug.cgi?id=751597
This commit is contained in:
parent
3f586c4a95
commit
a70172cfea
2 changed files with 8 additions and 13 deletions
|
@ -34,10 +34,6 @@
|
|||
#include <clutter-gtk/clutter-gtk.h>
|
||||
#endif /* HAVE_CHEESE || HAVE_WACOM */
|
||||
|
||||
#ifdef HAVE_CHEESE
|
||||
#include <cheese-gtk.h>
|
||||
#endif /* HAVE_CHEESE */
|
||||
|
||||
struct _CcApplicationPrivate
|
||||
{
|
||||
CcWindow *window;
|
||||
|
@ -131,21 +127,14 @@ cc_application_command_line (GApplication *application,
|
|||
GApplicationCommandLine *command_line)
|
||||
{
|
||||
CcApplication *self = CC_APPLICATION (application);
|
||||
int argc;
|
||||
char **argv;
|
||||
GVariantDict *options;
|
||||
int retval = 0;
|
||||
char *search_str;
|
||||
GStrv start_panels = NULL;
|
||||
gboolean debug;
|
||||
|
||||
argv = g_application_command_line_get_arguments (command_line, &argc);
|
||||
options = g_application_command_line_get_options_dict (command_line);
|
||||
|
||||
#ifdef HAVE_CHEESE
|
||||
cheese_gtk_init (&argc, &argv);
|
||||
#endif /* HAVE_CHEESE */
|
||||
|
||||
debug = g_variant_dict_contains (options, "verbose");
|
||||
cc_shell_log_set_debug (debug);
|
||||
|
||||
|
@ -196,8 +185,6 @@ cc_application_command_line (GApplication *application,
|
|||
g_free (start_panels);
|
||||
start_panels = NULL;
|
||||
|
||||
g_strfreev (argv);
|
||||
|
||||
return retval;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue