[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdebase/runtime/drkonqi
From:       Darío Andrés Rodríguez <andresbajotierra () gmail ! co
Date:       2009-11-24 21:11:51
Message-ID: 1259097111.999150.21606.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 1053832 by darioandres:

- Add a Retry button if loading the bug report (to compare it with the user crash, on \
the duplicates page) fails.



 M  +16 -1     reportassistantpages_bugzilla_duplicates.cpp  
 M  +2 -0      reportassistantpages_bugzilla_duplicates.h  
 M  +35 -4     ui/assistantpage_bugzilla_duplicates_dialog.ui  


--- trunk/KDE/kdebase/runtime/drkonqi/reportassistantpages_bugzilla_duplicates.cpp \
#1053831:1053832 @@ -478,7 +478,13 @@
     QWidget * widget = new QWidget(this);
     ui.setupUi(widget);
     setMainWidget(widget);
-        
+
+    ui.m_retryButton->setGuiItem(KGuiItem2(i18nc("@action:button", "Retry..."),
+                                  KIcon("view-refresh"),
+                                  i18nc("@info:tooltip", "Use this button to retry "
+                                                  "loading the bug report.")));
+    connect(ui.m_retryButton, SIGNAL(clicked()), this, SLOT(reloadReport()));
+    
     setButtonGuiItem(KDialog::User2, 
                 KGuiItem2(i18nc("@action:button", "Add as a possible duplicate"),
                     KIcon("list-add"), i18nc("@info:tooltip", "Use this button to \
mark your " @@ -515,8 +521,15 @@
     saveDialogSize(config);
 }
 
+void BugzillaReportInformationDialog::reloadReport()
+{
+    showBugReport(m_bugNumber);
+}
+
 void BugzillaReportInformationDialog::showBugReport(int bugNumber)
 {
+    ui.m_retryButton->setVisible(false);
+
     m_closedStateString.clear();
     m_bugNumber = bugNumber;
     m_parent->bugzillaManager()->fetchBugReport(m_bugNumber, this);
@@ -723,8 +736,10 @@
                                         "<message>%1.</message><nl/>"
                                         "Please wait some time and try again.", \
err));  button(KDialog::User1)->setEnabled(false);
+        button(KDialog::User2)->setEnabled(false);
         ui.m_infoBrowser->setText(i18nc("@info","Error fetching the bug report"));
         ui.m_statusWidget->setIdle(i18nc("@info:status","Error fetching the bug \
report")); +        ui.m_retryButton->setVisible(true);
     }
 }
 
--- trunk/KDE/kdebase/runtime/drkonqi/reportassistantpages_bugzilla_duplicates.h \
#1053831:1053832 @@ -115,6 +115,8 @@
     void bugFetchFinished(BugReport,QObject *);
     void bugFetchError(QString, QObject *);
 
+    void reloadReport();
+
     int proceedOnAlreadyClosedReport();
     void mayBeDuplicateClicked();
     void attachToBugReportClicked();
--- trunk/KDE/kdebase/runtime/drkonqi/ui/assistantpage_bugzilla_duplicates_dialog.ui \
#1053831:1053832 @@ -6,8 +6,8 @@
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>531</width>
-    <height>564</height>
+    <width>572</width>
+    <height>542</height>
    </rect>
   </property>
   <property name="minimumSize">
@@ -16,7 +16,7 @@
     <height>300</height>
    </size>
   </property>
-  <layout class="QVBoxLayout" name="verticalLayout_2">
+  <layout class="QVBoxLayout" name="verticalLayout_3">
    <item>
     <widget class="StatusWidget" name="m_statusWidget" native="true">
      <property name="sizePolicy">
@@ -32,7 +32,33 @@
      <property name="orientation">
       <enum>Qt::Horizontal</enum>
      </property>
-     <widget class="KTextBrowser" name="m_infoBrowser"/>
+     <widget class="QWidget" name="verticalLayoutWidget">
+      <layout class="QVBoxLayout" name="verticalLayout_2">
+       <item>
+        <layout class="QHBoxLayout" name="horizontalLayout">
+         <item>
+          <widget class="KPushButton" name="m_retryButton"/>
+         </item>
+         <item>
+          <spacer name="m_retrySpacer">
+           <property name="orientation">
+            <enum>Qt::Horizontal</enum>
+           </property>
+           <property name="sizeHint" stdset="0">
+            <size>
+             <width>40</width>
+             <height>0</height>
+            </size>
+           </property>
+          </spacer>
+         </item>
+        </layout>
+       </item>
+       <item>
+        <widget class="KTextBrowser" name="m_infoBrowser"/>
+       </item>
+      </layout>
+     </widget>
      <widget class="QWidget" name="layoutWidget">
       <layout class="QVBoxLayout" name="verticalLayout">
        <item>
@@ -69,6 +95,11 @@
  </widget>
  <customwidgets>
   <customwidget>
+   <class>KPushButton</class>
+   <extends>QPushButton</extends>
+   <header>kpushbutton.h</header>
+  </customwidget>
+  <customwidget>
    <class>KTextBrowser</class>
    <extends>QTextBrowser</extends>
    <header>ktextbrowser.h</header>


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic