[SCM] ktp-contact-list packaging branch, master, updated. debian/15.12.1-2-1070-g6c56f91
Maximiliano Curia
maxy at moszumanska.debian.org
Sat May 28 00:07:07 UTC 2016
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-contact-list.git;a=commitdiff;h=ecc5d29
The following commit has been merged in the master branch:
commit ecc5d290437a8195cafb50dfd704893f0a90ea51
Author: Martin Klapetek <martin.klapetek at gmail.com>
Date: Tue Jul 19 14:59:18 2011 +0200
Add Cancel button to the quit dialog
Reviewed-by: Francesco Nwokeka
---
main-widget.cpp | 17 ++++++++++++-----
1 file changed, 12 insertions(+), 5 deletions(-)
diff --git a/main-widget.cpp b/main-widget.cpp
index e924c61..b6b7cf8 100644
--- a/main-widget.cpp
+++ b/main-widget.cpp
@@ -32,6 +32,7 @@
#include <QtGui/QToolButton>
#include <QtCore/QWeakPointer>
#include <QWidgetAction>
+#include <QCloseEvent>
#include <TelepathyQt4/PendingReady>
#include <TelepathyQt4/PendingChannelRequest>
@@ -1458,16 +1459,22 @@ void MainWidget::closeEvent(QCloseEvent* e)
if (isAnyAccountOnline() && !dontCheckForPlasmoid) {
if (!isPresencePlasmoidPresent()) {
- if (KMessageBox::warningYesNo(this,
+ switch (KMessageBox::warningYesNoCancel(this,
i18n("You do not have any other presence controls active (a Presence widget for example).
"
"Do you want to stay online or would you rather go offline?"),
i18n("No Other Presence Controls Found"),
KGuiItem(i18n("Stay Online"), KIcon("user-online")),
KGuiItem(i18n("Go Offline"), KIcon("user-offline")),
- QString("dont_check_for_plasmoid")) == KMessageBox::No) {
-
- generalConfigGroup.writeEntry("go_offline_when_closing", true);
- goOffline();
+ KStandardGuiItem::cancel(),
+ QString("dont_check_for_plasmoid"))) {
+
+ case KMessageBox::No:
+ generalConfigGroup.writeEntry("go_offline_when_closing", true);
+ goOffline();
+ break;
+ case KMessageBox::Cancel:
+ e->ignore();
+ return;
}
}
} else if (isAnyAccountOnline() && dontCheckForPlasmoid) {
--
ktp-contact-list packaging
More information about the pkg-kde-commits
mailing list