mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-26 09:30:24 +00:00
CharacterMap: Pause updates while generating search results
Co-authored-by: Tim Flynn <trflynn89@pm.me>
This commit is contained in:
parent
725a758c66
commit
bb8bd48dc0
Notes:
sideshowbarker
2024-07-17 03:19:14 +09:00
Author: https://github.com/AtkinsSJ Commit: https://github.com/SerenityOS/serenity/commit/bb8bd48dc0 Pull-request: https://github.com/SerenityOS/serenity/pull/17723 Reviewed-by: https://github.com/trflynn89
1 changed files with 4 additions and 1 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2022, Sam Atkins <atkinssj@serenityos.org>
|
||||
* Copyright (c) 2022-2023, Sam Atkins <atkinssj@serenityos.org>
|
||||
* Copyright (c) 2022, the SerenityOS developers.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
|
@ -79,6 +79,9 @@ CharacterSearchWidget::CharacterSearchWidget()
|
|||
|
||||
void CharacterSearchWidget::search()
|
||||
{
|
||||
ScopeGuard guard { [&] { m_results_table->set_updates_enabled(true); } };
|
||||
m_results_table->set_updates_enabled(false);
|
||||
|
||||
// TODO: Sort the results nicely. They're sorted by code-point for now, which is easy, but not the most useful.
|
||||
// Sorting intelligently in a style similar to Assistant would be nicer.
|
||||
auto& model = static_cast<CharacterSearchModel&>(*m_results_table->model());
|
||||
|
|
Loading…
Reference in a new issue