summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrius Štikonas <andrius@stikonas.eu>2016-06-08 11:53:07 (GMT)
committerAndrius Štikonas <andrius@stikonas.eu>2016-06-08 12:19:18 (GMT)
commit42d05fedc25cbdf666b2f9bfc34d7b591c969474 (patch)
treec8a015056456bced57fdbabdc81298d2ab49abeb
parent60a9bbf891945a21d7a947cbc50ddc28b069aa24 (diff)
Finish port to QStatusBar.
-rw-r--r--keysmanager.cpp9
-rw-r--r--keysmanager.h2
2 files changed, 6 insertions, 5 deletions
diff --git a/keysmanager.cpp b/keysmanager.cpp
index 34965b5..e78cf38 100644
--- a/keysmanager.cpp
+++ b/keysmanager.cpp
@@ -73,7 +73,6 @@
#include <KStandardAction>
#include <KStandardGuiItem>
#include <KStandardShortcut>
-#include <KStatusBar>
#include <KStatusNotifierItem>
#include <KToggleAction>
#include <KToolInvocation>
@@ -97,6 +96,7 @@
#include <QPrintDialog>
#include <QPrinter>
#include <QProcess>
+#include <QStatusBar>
#include <QUrl>
#include <QWidget>
#include <QWidgetAction>
@@ -457,9 +457,8 @@ KeysManager::KeysManager(QWidget *parent)
iview->setColumnHidden(5, !KGpgSettings::showExpi());
iproxy->setOnlySecret(KGpgSettings::showSecret());
- QStatusBar *statusbar = statusBar();
-// statusbar->insertPermanentFixedItem(KGpgItemModel::statusCountMessageString(9999, 999), 0); FIXME: KF5
-// statusbar->changeItem(QString(), 0); FIXME: KF5
+ m_statusBarLabel.setAlignment (Qt::AlignCenter);
+ statusBar()->addPermanentWidget(&m_statusBarLabel);
cg = KConfigGroup(KSharedConfig::openConfig().data(), "MainWindow");
setAutoSaveSettings(cg, true);
@@ -553,7 +552,7 @@ void KeysManager::changeMessage(const QString &msg, const bool keep)
void KeysManager::updateStatusCounter()
{
-// statusBar()->changeItem(imodel->statusCountMessage(), 0); FIXME: KF5
+ m_statusBarLabel.setText(imodel->statusCountMessage());
}
void KeysManager::slotGenerateKeyDone(KJob *job)
diff --git a/keysmanager.h b/keysmanager.h
index e1ab90a..e541642 100644
--- a/keysmanager.h
+++ b/keysmanager.h
@@ -257,6 +257,8 @@ private:
QLineEdit *m_listviewsearch;
KDialog *addUidWidget;
+ QLabel m_statusBarLabel;
+
QAction *importSignatureKey;
QAction *importAllSignKeys;
QAction *signKey;