summaryrefslogtreecommitdiff
path: root/Libraries
diff options
context:
space:
mode:
authorcampital <33563097+campital@users.noreply.github.com>2021-01-11 05:42:06 -0500
committerGitHub <noreply@github.com>2021-01-11 11:42:06 +0100
commitc7fc9d185d26438b8b5f37b15e42825c64ad550f (patch)
tree24e6ce5b844d74aa9994cc6b12b301e71c4cd520 /Libraries
parent603147f47a2255298ab62e776ccd8bc5c003ce32 (diff)
downloadserenity-c7fc9d185d26438b8b5f37b15e42825c64ad550f.zip
LibGUI: Update TextEditor after triple-click to select (#4897)
Previously, it was "relying" on the cursor blink timer to update the visual selection. This caused some delay after the whole line was selected by triple-clicking specifically the last word in a line. Now, the widget is updated after triple-clicking.
Diffstat (limited to 'Libraries')
-rw-r--r--Libraries/LibGUI/TextEditor.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/Libraries/LibGUI/TextEditor.cpp b/Libraries/LibGUI/TextEditor.cpp
index 19458a19a6..bd2e220d19 100644
--- a/Libraries/LibGUI/TextEditor.cpp
+++ b/Libraries/LibGUI/TextEditor.cpp
@@ -286,6 +286,8 @@ void TextEditor::mousedown_event(MouseEvent& event)
m_selection.set(start, end);
set_cursor(end);
+ update();
+ did_update_selection();
return;
}