From ca8dd65f348fb276660a297b57f08f9ad81cddf6 Mon Sep 17 00:00:00 2001 From: miruka Date: Mon, 9 Mar 2020 08:09:58 -0400 Subject: [PATCH] Disable buggy composer backspace override --- TODO.md | 17 +++++++++-------- src/gui/Pages/Chat/Composer.qml | 29 +++++++++++++++-------------- 2 files changed, 24 insertions(+), 22 deletions(-) diff --git a/TODO.md b/TODO.md index 853c8846..eb3d381b 100644 --- a/TODO.md +++ b/TODO.md @@ -1,12 +1,16 @@ # TODO +## Before release + - "exception during sync" aren't caught +- nio ClientTimeout +- Handle upload file size limit +- Update docstrings +- Update TODO.md +- Update README.md ## Media -- nio ClientTimeout - -- Handle upload file size limit - Handle set avatar upload errors - Confirmation box after picking file to upload - Show real progression for mxc thumbnail loadings @@ -44,6 +48,7 @@ - Forget a room, it comes back because of the "you left" event - `EventImage`s for `m.image` sometimes appear broken, can be made normal by switching to another room and coming back + - First sent message in E2E room is sometimes undecryptable - Pausing uploads doesn't work well, servers end up dropping the connection @@ -53,10 +58,8 @@ - Ensure all the text that should be copied is copied - Multiple messages are currently copied out of order -- Pressing backspace in composer sometimes doesn't work - - `code` not colored in room subtitle -- Quote links color in room subtitles (e.g. "> http://foo.orgA)" ) +- Quote links color in room subtitles (e.g. "> http://foo.org" ) - If account not in config anymore, discard ui state last page on startup - Do something when access token is invalid @@ -205,8 +208,6 @@ ## Distribution & dependencies - Mistune v2.0 -- Include python dependencies in binary with rcc? -- Improve the README.md ## Notable changes for future Qt version upgrade diff --git a/src/gui/Pages/Chat/Composer.qml b/src/gui/Pages/Chat/Composer.qml index aacf0aef..ecff863b 100644 --- a/src/gui/Pages/Chat/Composer.qml +++ b/src/gui/Pages/Chat/Composer.qml @@ -45,10 +45,10 @@ Rectangle { readonly property string lineTextUntilCursor: lineText.substring(0, cursorX) - readonly property int deleteCharsOnBackspace: - lineTextUntilCursor.match(/^ +$/) ? - lineTextUntilCursor.match(/ {1,4}/g).slice(-1)[0].length : - 1 + // readonly property int deleteCharsOnBackspace: + // lineTextUntilCursor.match(/^ +$/) ? + // lineTextUntilCursor.match(/ {1,4}/g).slice(-1)[0].length : + // 1 function takeFocus() { areaScrollView.forceActiveFocus() } @@ -199,16 +199,17 @@ Rectangle { return } - if (ev.modifiers === Qt.NoModifier && - ev.key === Qt.Key_Backspace && - ! textArea.selectedText) - { - ev.accepted = true - textArea.remove( - cursorPosition - deleteCharsOnBackspace, - cursorPosition - ) - } + // FIXME: buggy + // if (ev.modifiers === Qt.NoModifier && + // ev.key === Qt.Key_Backspace && + // ! textArea.selectedText) + // { + // ev.accepted = true + // textArea.remove( + // cursorPosition - deleteCharsOnBackspace, + // cursorPosition + // ) + // } }) } }