mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-11 18:20:43 +09:00
UI/Qt: Move cursor to the front
Fix long URLs showing the end instead of domain
This commit is contained in:
parent
e926b4cbfb
commit
c380dcf15e
Notes:
github-actions[bot]
2024-08-20 18:52:08 +00:00
Author: https://github.com/Sidicer 🔰
Commit: c380dcf15e
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1097
Reviewed-by: https://github.com/jamierocks
Reviewed-by: https://github.com/tcl3 ✅
1 changed files with 2 additions and 0 deletions
|
@ -73,6 +73,7 @@ void LocationEdit::focusOutEvent(QFocusEvent* event)
|
|||
if (text().isEmpty())
|
||||
setText(qstring_from_ak_string(m_url.serialize()));
|
||||
}
|
||||
setCursorPosition(0);
|
||||
highlight_location();
|
||||
}
|
||||
|
||||
|
@ -134,6 +135,7 @@ void LocationEdit::set_url(URL::URL const& url)
|
|||
clear();
|
||||
} else {
|
||||
setText(qstring_from_ak_string(url.serialize()));
|
||||
setCursorPosition(0);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue