[PATCH 2 of 2] Merged

Wald Commits scm-commit at wald.intevation.org
Tue Sep 23 14:53:58 CEST 2014


# HG changeset patch
# User Emanuel Schuetze <emanuel at intevation.de>
# Date 1411476730 -7200
# Node ID 939f26d3db5901f2798ae3aa8b849a342dc76039
# Parent  b4185dd3810f55d3431c68093026527da47224fc
# Parent  407f2c1286ae0162caf9688eec3d685a14fefa64
Merged.

diff -r b4185dd3810f -r 939f26d3db59 ui/icons.qrc
--- a/ui/icons.qrc	Tue Sep 23 14:51:53 2014 +0200
+++ b/ui/icons.qrc	Tue Sep 23 14:52:10 2014 +0200
@@ -9,7 +9,7 @@
     <file>img/document-open.png</file>
     <file>img/document-new.png</file>
     <file>img/document-close.png</file>
-    <file>img/view-refresh.png</file>
+    <file>img/pending-changes-overview-48.png</file>
     <file>img/view-refresh_16px.png</file>
     <file>img/document-encrypt.png</file>
     <file>img/dialog-warning.png</file>
diff -r b4185dd3810f -r 939f26d3db59 ui/img/README.txt
--- a/ui/img/README.txt	Tue Sep 23 14:51:53 2014 +0200
+++ b/ui/img/README.txt	Tue Sep 23 14:52:10 2014 +0200
@@ -56,3 +56,6 @@
 cert-is-installed-bad.svg ->
 Inkscape: tools -> rgb "tonne"
 
+== pending-changes-overview
+renamed from 48x48/places/bookmarks.png
+
diff -r b4185dd3810f -r 939f26d3db59 ui/img/pending-changes-overview-48.png
Binary file ui/img/pending-changes-overview-48.png has changed
diff -r b4185dd3810f -r 939f26d3db59 ui/img/view-refresh.png
Binary file ui/img/view-refresh.png has changed
diff -r b4185dd3810f -r 939f26d3db59 ui/mainwindow.cpp
--- a/ui/mainwindow.cpp	Tue Sep 23 14:51:53 2014 +0200
+++ b/ui/mainwindow.cpp	Tue Sep 23 14:52:10 2014 +0200
@@ -1001,7 +1001,7 @@
     TextOverlayButton *updatesButton = new TextOverlayButton;
     updatesButton->setToolButtonStyle(Qt::ToolButtonTextUnderIcon);
     updatesButton->setBackgroundIcon(":/img/red-circle.png");
-    updatesButton->setIcon(QIcon(":/img/view-refresh.png"));
+    updatesButton->setIcon(QIcon(":/img/pending-changes-overview-48.png"));
     updatesButton->setIconSize(QSize(48, 48));
     updatesButton->setText(tr("Pending\nchanges"));
     updatesButton->setFixedWidth(120);
@@ -1493,10 +1493,19 @@
     if (!mUpdatesManual->contains(cert)) {
         QToolButton* actionBtn = new QToolButton();
         QIcon btnIcon;
-        btnIcon.addFile(":/img/write-into-48.png", QSize(48, 48), QIcon::Normal, QIcon::On);
-        btnIcon.addFile(":/img/write-remove-48.png", QSize(48, 48), QIcon::Normal, QIcon::Off);
-        actionBtn->setProperty("ToolTip_On", tr("Certificate will be installed."));
-        actionBtn->setProperty("ToolTip_Off", tr("Certificate will be removed."));
+        if (mRemoveList->contains(cert)) {
+            btnIcon.addFile(":/img/write-remove-48.png", QSize(48, 48), QIcon::Normal, QIcon::On);
+            btnIcon.addFile(":/img/cert-is-installed-bad-48.png", QSize(48, 48), QIcon::Normal, QIcon::Off);
+            actionBtn->setProperty("ToolTip_On", tr("Certificate will be removed."));
+            /* Off should never be possible here
+             * As the manual change of removed certificates is disabled */
+            actionBtn->setProperty("ToolTip_Off", tr("Certificate will not be removed."));
+        } else {
+            btnIcon.addFile(":/img/write-into-48.png", QSize(48, 48), QIcon::Normal, QIcon::On);
+            btnIcon.addFile(":/img/write-remove-48.png", QSize(48, 48), QIcon::Normal, QIcon::Off);
+            actionBtn->setProperty("ToolTip_On", tr("Certificate will be installed."));
+            actionBtn->setProperty("ToolTip_Off", tr("Certificate will be removed."));
+        }
         actionBtn->setIcon(btnIcon);
         mUpdatesManual->addCertificate(cert, state, actionBtn);
     }


More information about the Trustbridge-commits mailing list