Mercurial > trustbridge
diff ui/mainwindow.cpp @ 1204:939f26d3db59
Merged.
author | Emanuel Schuetze <emanuel@intevation.de> |
---|---|
date | Tue, 23 Sep 2014 14:52:10 +0200 |
parents | 407f2c1286ae |
children | 3815a0d2017b |
line wrap: on
line diff
--- 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); }