mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-29 08:11:13 +00:00
UI/Qt: Do not perform search if query text is empty
Some checks are pending
CI / Lagom (false, FUZZ, ubuntu-22.04, Linux, Clang) (push) Waiting to run
CI / Lagom (false, NO_FUZZ, macos-14, macOS, Clang) (push) Waiting to run
CI / Lagom (false, NO_FUZZ, ubuntu-22.04, Linux, GNU) (push) Waiting to run
CI / Lagom (true, NO_FUZZ, ubuntu-22.04, Linux, Clang) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (macos-14, macOS, macOS-universal2) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (ubuntu-22.04, Linux, Linux-x86_64) (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Push notes / build (push) Waiting to run
Some checks are pending
CI / Lagom (false, FUZZ, ubuntu-22.04, Linux, Clang) (push) Waiting to run
CI / Lagom (false, NO_FUZZ, macos-14, macOS, Clang) (push) Waiting to run
CI / Lagom (false, NO_FUZZ, ubuntu-22.04, Linux, GNU) (push) Waiting to run
CI / Lagom (true, NO_FUZZ, ubuntu-22.04, Linux, Clang) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (macos-14, macOS, macOS-universal2) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (ubuntu-22.04, Linux, Linux-x86_64) (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Push notes / build (push) Waiting to run
This commit is contained in:
parent
d19b31529f
commit
276ad23b70
Notes:
github-actions[bot]
2024-09-19 22:06:18 +00:00
Author: https://github.com/ronak69 Commit: https://github.com/LadybirdBrowser/ladybird/commit/276ad23b709 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1444 Reviewed-by: https://github.com/tcl3 ✅
|
@ -31,6 +31,9 @@ LocationEdit::LocationEdit(QWidget* parent)
|
|||
});
|
||||
|
||||
connect(this, &QLineEdit::returnPressed, [&] {
|
||||
if (text().isEmpty())
|
||||
return;
|
||||
|
||||
clearFocus();
|
||||
|
||||
Optional<StringView> search_engine_url;
|
||||
|
|
|
@ -823,6 +823,8 @@ void Tab::copy_link_url(URL::URL const& url)
|
|||
|
||||
void Tab::location_edit_return_pressed()
|
||||
{
|
||||
if (m_location_edit->text().isEmpty())
|
||||
return;
|
||||
navigate(m_location_edit->url());
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue