summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJiri Moskovcak <jmoskovc@redhat.com>2010-06-16 15:24:11 +0200
committerJiri Moskovcak <jmoskovc@redhat.com>2010-06-16 15:24:11 +0200
commitf24be51c89dfe4e36c815d23eda54b5d2b04aa38 (patch)
tree8983cad070bfad78afd2cfbf9173a62544497644
parent774dfcd6100f1c3346a2180f15562891870db611 (diff)
downloadabrt-f24be51c89dfe4e36c815d23eda54b5d2b04aa38.tar.gz
abrt-f24be51c89dfe4e36c815d23eda54b5d2b04aa38.tar.xz
abrt-f24be51c89dfe4e36c815d23eda54b5d2b04aa38.zip
GUI: skip the plugin selection, if it's not needed
- if there's only one reporter, then we can skip the first page in the wizard - the page is skipped only if the plugin options are properly configured
-rw-r--r--src/Gui/CReporterAssistant.py15
1 files changed, 10 insertions, 5 deletions
diff --git a/src/Gui/CReporterAssistant.py b/src/Gui/CReporterAssistant.py
index 5f46c000..643e6fec 100644
--- a/src/Gui/CReporterAssistant.py
+++ b/src/Gui/CReporterAssistant.py
@@ -311,13 +311,18 @@ class ReporterAssistant():
self.warn_user(error_msgs)
#bSend.set_sensitive(send)
self.assistant.set_page_complete(self.pdict_get_page(PAGE_BACKTRACE_APPROVAL), send)
- #self.assistant.set_page_complete(page, togglebutton.get_active())
- #if not send:
- # bSend.set_tooltip_text(_("Reporting disabled, please fix the problems shown above."))
- #else:
- # bSend.set_tooltip_text(_("Sends the report using selected plugin."))
def on_page_prepare(self, assistant, page):
+ if page == self.pdict_get_page(PAGE_REPORTER_SELECTOR):
+ # skip the first page if we have only one reporter plugin
+ if len(self.reporters) == 1:
+ # we want to skip it only if the plugin is properly configured
+ if self.reporters[0].Settings.check():
+ self.selected_reporters.append(self.reporters[0])
+ log1(_("Only one reporter plugin is configured, "
+ "skipping the selection dialog"))
+ self.assistant.set_current_page(PAGE_BACKTRACE_APPROVAL)
+
# this is where dehydrate happens
if page == self.pdict_get_page(PAGE_EXTRA_INFO):
if not self.howto_changed: