[SCM] ktp-contact-applet packaging branch, master, updated. debian/16.04.2-1-67-g066859a
Maximiliano Curia
maxy at moszumanska.debian.org
Tue Sep 12 14:08:29 UTC 2017
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-desktop-applets.git;a=commitdiff;h=d9c8536
The following commit has been merged in the master branch:
commit d9c85361b248d36f4fafaf054e332871e47eb49c
Author: Kai Uwe Broulik <kde at privat.broulik.de>
Date: Tue Sep 27 14:44:03 2016 +0200
[Quick Chat] Allow cycling through chats with Ctrl+(Shift)+Tab
This makes switching between conversations possible without using the mouse.
REVIEW: 128138
---
chat/org.kde.ktp-chat/contents/ui/ChatWidget.qml | 14 ++++++++++++++
chat/org.kde.ktp-chat/contents/ui/ConversationDelegate.qml | 10 +++++++++-
2 files changed, 23 insertions(+), 1 deletion(-)
diff --git a/chat/org.kde.ktp-chat/contents/ui/ChatWidget.qml b/chat/org.kde.ktp-chat/contents/ui/ChatWidget.qml
index 1485c4c..7e41910 100644
--- a/chat/org.kde.ktp-chat/contents/ui/ChatWidget.qml
+++ b/chat/org.kde.ktp-chat/contents/ui/ChatWidget.qml
@@ -29,6 +29,8 @@ FocusScope {
property Conversation conv
signal closeRequested
+ signal previousConversationRequested
+ signal nextConversationRequested
RowLayout {
id: titleArea
@@ -173,5 +175,17 @@ FocusScope {
chatWidget.closeRequested()
}
}
+
+ Keys.onPressed: {
+ if (event.modifiers & Qt.ControlModifier) {
+ if (event.key === Qt.Key_Tab) {
+ nextConversationRequested()
+ event.accepted = true
+ } else if (event.key === Qt.Key_Backtab) {
+ previousConversationRequested()
+ event.accepted = true
+ }
+ }
+ }
}
}
diff --git a/chat/org.kde.ktp-chat/contents/ui/ConversationDelegate.qml b/chat/org.kde.ktp-chat/contents/ui/ConversationDelegate.qml
index 701f721..a089fbc 100644
--- a/chat/org.kde.ktp-chat/contents/ui/ConversationDelegate.qml
+++ b/chat/org.kde.ktp-chat/contents/ui/ConversationDelegate.qml
@@ -43,7 +43,13 @@ ConversationDelegateButton {
base.currentIndex = -1
}
}
-
+ function openPreviousConversation() {
+ base.currentIndex = (base.currentIndex + conversationsView.count - 1) % conversationsView.count
+ }
+ function openNextConversation() {
+ base.currentIndex = (base.currentIndex + 1) % conversationsView.count
+ }
+
Component.onCompleted: setVisible(model.conversation.messages.shouldStartOpened)
PlasmaCore.Dialog {
@@ -59,6 +65,8 @@ ConversationDelegateButton {
conv: model.conversation
onCloseRequested: closeConversation()
+ onPreviousConversationRequested: openPreviousConversation()
+ onNextConversationRequested: openNextConversation()
}
//if we are opening the dialog right away (e.g. started chat from pinned)
--
ktp-contact-applet packaging
More information about the pkg-kde-commits
mailing list