mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-30 06:52:52 +00:00
PDFViewer: Prevent infinity recursion
When removing all contents from the NumericInput box in PDFViewer the callback set the (empty) text again back in the box, triggering another callback in a recursive, non-stopping fashion. Not setting the text back in the box avoids the problem.
This commit is contained in:
parent
bc7da24fe6
commit
a740423e23
Notes:
sideshowbarker
2024-07-18 08:59:31 +09:00
Author: https://github.com/rtobar
Commit: a740423e23
Pull-request: https://github.com/SerenityOS/serenity/pull/16155
1 changed files with 0 additions and 1 deletions
|
@ -29,7 +29,6 @@ NumericInput::NumericInput()
|
|||
auto new_number_opt = builder.to_string().to_int();
|
||||
if (!new_number_opt.has_value()) {
|
||||
m_needs_text_reset = true;
|
||||
set_text(builder.to_string());
|
||||
return;
|
||||
} else {
|
||||
m_needs_text_reset = false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue