mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-21 23:20:20 +00:00
UI/Qt: Don't change LocationEdit cursor position on right click
Previously, right clicking highlighted text in the location bar would cause the current selection to be lost.
This commit is contained in:
parent
dc18280f80
commit
6c608bac65
Notes:
github-actions[bot]
2024-09-10 05:41:19 +00:00
Author: https://github.com/tcl3 Commit: https://github.com/LadybirdBrowser/ladybird/commit/6c608bac659 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1351
1 changed files with 5 additions and 2 deletions
|
@ -73,8 +73,11 @@ void LocationEdit::focusOutEvent(QFocusEvent* event)
|
|||
if (text().isEmpty())
|
||||
setText(qstring_from_ak_string(m_url.serialize()));
|
||||
}
|
||||
setCursorPosition(0);
|
||||
highlight_location();
|
||||
|
||||
if (event->reason() != Qt::PopupFocusReason) {
|
||||
setCursorPosition(0);
|
||||
highlight_location();
|
||||
}
|
||||
}
|
||||
|
||||
void LocationEdit::update_placeholder()
|
||||
|
|
Loading…
Reference in a new issue