diff options
author | Jonas Danielsson <jonas@threetimestwo.org> | 2014-08-13 07:06:36 -0400 |
---|---|---|
committer | Jonas Danielsson <jonas@threetimestwo.org> | 2014-08-20 16:02:59 +0200 |
commit | bf9c8625048d2adc5cbc5893fa27e7e9a3a9ba3e (patch) | |
tree | d0b992e750c19b7494a091459e3e3dc421aa3c90 /gio/gapplication.h | |
parent | 4f775b7b7ff38581b110ce1664451381ca3d88b6 (diff) | |
download | glib-bf9c8625048d2adc5cbc5893fa27e7e9a3a9ba3e.tar.gz |
GApplication: Add g_application_add_main_option
This function adds a single main option entry to be handeled by
GApplication. The option entry has it arg_data field set to NULL
and will be added to the applications packed_options.
The rationale for this is that bindings will be able to add
command line options even when they can't use the un-boxed struct
GOptionEntry.
https://bugzilla.gnome.org/show_bug.cgi?id=727455
Diffstat (limited to 'gio/gapplication.h')
-rw-r--r-- | gio/gapplication.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gio/gapplication.h b/gio/gapplication.h index b2b6a8a52..30995e2f4 100644 --- a/gio/gapplication.h +++ b/gio/gapplication.h @@ -168,6 +168,15 @@ void g_application_set_action_group (GApplic GLIB_AVAILABLE_IN_2_40 void g_application_add_main_option_entries (GApplication *application, const GOptionEntry *entries); + +GLIB_AVAILABLE_IN_2_42 +void g_application_add_main_option (GApplication *application, + const char *long_name, + char short_name, + gint flags, + GOptionArg arg, + const char *description, + const char *arg_description); GLIB_AVAILABLE_IN_2_40 void g_application_add_option_group (GApplication *application, GOptionGroup *group); |