diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/gtk-helpers/Makefile.am | 2 | ||||
-rw-r--r-- | src/gui-gtk/Makefile.am | 4 | ||||
-rw-r--r-- | src/gui-wizard-gtk/Makefile.am | 2 | ||||
-rw-r--r-- | src/gui-wizard-gtk/main.c | 4 | ||||
-rw-r--r-- | src/gui-wizard-gtk/wizard.c | 26 |
5 files changed, 32 insertions, 6 deletions
diff --git a/src/gtk-helpers/Makefile.am b/src/gtk-helpers/Makefile.am index de35d39b..90c9be7f 100644 --- a/src/gtk-helpers/Makefile.am +++ b/src/gtk-helpers/Makefile.am @@ -20,4 +20,4 @@ libreportgtk_la_LDFLAGS = \ libreportgtk_la_LIBADD = \ $(GTK_LIBS) \ $(GLIB_LIBS) \ - $(GNOME_KEYRING_CFLAGS) + $(GNOME_KEYRING_LIBS) diff --git a/src/gui-gtk/Makefile.am b/src/gui-gtk/Makefile.am index 978f9428..b5c6cd54 100644 --- a/src/gui-gtk/Makefile.am +++ b/src/gui-gtk/Makefile.am @@ -16,7 +16,6 @@ abrt_gui_CFLAGS = \ -DICON_DIR=\"${datadir}/abrt/icons/hicolor/48x48/status\" \ $(GTK_CFLAGS) \ $(DBUS_CFLAGS) \ - $(GNOME_KEYRING_CFLAGS) \ -D_GNU_SOURCE \ -Wall -Wwrite-strings -Werror # -I/usr/include/glib-2.0 @@ -30,8 +29,7 @@ abrt_gui_LDADD = \ -lglib-2.0 \ -lgthread-2.0 \ $(GTK_LIBS) \ - $(DBUS_LIBS) \ - $(GNOME_KEYRING_LIBS) + $(DBUS_LIBS) # $(LIBNOTIFY_LIBS) #test_report_SOURCES = \ diff --git a/src/gui-wizard-gtk/Makefile.am b/src/gui-wizard-gtk/Makefile.am index a44de58c..6be5a946 100644 --- a/src/gui-wizard-gtk/Makefile.am +++ b/src/gui-wizard-gtk/Makefile.am @@ -12,6 +12,7 @@ bug_reporting_wizard_SOURCES = \ bug_reporting_wizard_CFLAGS = \ -I$(srcdir)/../include/report -I$(srcdir)/../include \ -I$(srcdir)/../lib \ + -I$(srcdir)/../gtk-helpers \ -DBIN_DIR=\"$(bindir)\" \ -DVAR_RUN=\"$(VAR_RUN)\" \ -DCONF_DIR=\"$(CONF_DIR)\" \ @@ -32,6 +33,7 @@ bug_reporting_wizard_CFLAGS = \ bug_reporting_wizard_LDADD = \ ../lib/libreport.la \ ../lib/libabrt_dbus.la \ + ../gtk-helpers/libreportgtk.la \ $(GLIB_LIBS) \ $(GTK_LIBS) \ $(DBUS_LIBS) diff --git a/src/gui-wizard-gtk/main.c b/src/gui-wizard-gtk/main.c index 41ad3adc..8e00271a 100644 --- a/src/gui-wizard-gtk/main.c +++ b/src/gui-wizard-gtk/main.c @@ -20,6 +20,7 @@ #include "abrtlib.h" #include "parse_options.h" #include "wizard.h" +#include "libreport-gtk.h" #define PROGNAME "bug-reporting-wizard" @@ -52,7 +53,8 @@ void reload_crash_data_from_dump_dir(void) /* Load /etc/abrt/events/foo.{conf,xml} stuff */ load_event_config_data(); -//TODO: load overrides from keyring? Load ~/.abrt/events/foo.conf? + load_event_config_data_from_keyring(); +//TODO: Load ~/.abrt/events/foo.conf? } int main(int argc, char **argv) diff --git a/src/gui-wizard-gtk/wizard.c b/src/gui-wizard-gtk/wizard.c index e22b7630..1bf7e06b 100644 --- a/src/gui-wizard-gtk/wizard.c +++ b/src/gui-wizard-gtk/wizard.c @@ -20,6 +20,7 @@ #include "abrtlib.h" #include "abrt_dbus.h" #include "wizard.h" +#include "libreport-gtk.h" #define DEFAULT_WIDTH 800 #define DEFAULT_HEIGHT 500 @@ -879,7 +880,8 @@ static void start_event_run(const char *event_name, /* Load /etc/abrt/events/foo.{conf,xml} stuff */ load_event_config_data(); -//TODO: load overrides from keyring? Load ~/.abrt/events/foo.conf? + load_event_config_data_from_keyring(); + //TODO: Load ~/.abrt/events/foo.conf? GList *env_list = export_event_config(event_name); if (spawn_next_command(state, g_dump_dir_name, event_name) < 0) @@ -1066,6 +1068,11 @@ static void next_page(GtkAssistant *assistant, gpointer user_data) } } +static void on_show_event_list_cb(GtkWidget *button, gpointer user_data) +{ + show_events_list_dialog(GTK_WINDOW(g_assistant)); +} + static void on_page_prepare(GtkAssistant *assistant, GtkWidget *page, gpointer user_data) { if (pages[PAGENO_BACKTRACE_APPROVAL].page_widget == page) @@ -1231,6 +1238,23 @@ static void add_pages(void) pages[i].page_widget = page; + /* add a configure button wherever it makes sense to configure events */ + if (i == PAGENO_ANALYZE_SELECTOR + ||i == PAGENO_REPORTER_SELECTOR) + { + GtkWidget *configure = gtk_button_new_from_stock(GTK_STOCK_PREFERENCES); + g_signal_connect(G_OBJECT(configure), "clicked", G_CALLBACK(on_show_event_list_cb), NULL); + GtkWidget *align = gtk_alignment_new(0, 0, 0, 0); + GtkWidget *hbutton_box = gtk_hbox_new(false, 0); + + gtk_box_pack_start(GTK_BOX(hbutton_box), configure, false, false, 0); + gtk_box_pack_start(GTK_BOX(hbutton_box), align, false, true, 0); + + //we can do this only because we know that the page is gtk_vbox + gtk_box_pack_start(GTK_BOX(page), hbutton_box, false, false, 0); + gtk_widget_show_all(hbutton_box); + } + gtk_assistant_append_page(g_assistant, page); /* If we set all pages to complete the wizard thinks there is nothing * to do and shows the button "Last" which allows user to skip all pages |