Possible typing notification fixes
I've made few possible fixes for the typing notification getting stuck for long periods of time. I could use some help testing these to see if they help others too. For me the typing notification doesn't linger around that long after these changes.
This commit is contained in:
committed by
Tobias Fella
parent
fda433706b
commit
dfb569c0f6
@@ -137,6 +137,9 @@ QQC2.ToolBar {
|
||||
completionMenu.decrementIndex()
|
||||
} else if (event.key === Qt.Key_Down && completionMenu.visible) {
|
||||
completionMenu.incrementIndex()
|
||||
} else if (event.key === Qt.Key_Backspace && inputField.text.length <= 1) {
|
||||
currentRoom.sendTypingNotification(false)
|
||||
repeatTimer.stop()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -147,10 +150,10 @@ QQC2.ToolBar {
|
||||
|
||||
onTextChanged: {
|
||||
if (!repeatTimer.running && Config.typingNotifications) {
|
||||
currentRoom.sendTypingNotification(true)
|
||||
var textExists = text.length > 0
|
||||
currentRoom.sendTypingNotification(textExists)
|
||||
textExists ? repeatTimer.start() : repeatTimer.stop()
|
||||
}
|
||||
repeatTimer.start()
|
||||
|
||||
currentRoom.chatBoxText = text
|
||||
}
|
||||
}
|
||||
@@ -267,7 +270,7 @@ QQC2.ToolBar {
|
||||
|
||||
function postMessage() {
|
||||
actionsHandler.handleMessage();
|
||||
|
||||
repeatTimer.stop()
|
||||
currentRoom.markAllMessagesAsRead();
|
||||
inputField.clear();
|
||||
currentRoom.chatBoxReplyId = "";
|
||||
|
||||
Reference in New Issue
Block a user