mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 16:57:46 +00:00
LibGUI+Userland: Improve error and font handling for InputBox
Adds fallible factories, ports DeprecatedString, and rebuilds the layout to accomodate system font changes.
This commit is contained in:
parent
9c2bcffe83
commit
02a9e5d3f6
19 changed files with 135 additions and 124 deletions
|
@ -116,10 +116,10 @@ ContentFilterSettingsWidget::ContentFilterSettingsWidget()
|
|||
m_enable_content_filtering_checkbox->on_checked = [&](auto) { set_modified(true); };
|
||||
|
||||
m_add_new_domain_button->on_click = [&](unsigned) {
|
||||
DeprecatedString text;
|
||||
String text;
|
||||
|
||||
if (GUI::InputBox::show(window(), text, "Enter domain name"sv, "Add domain to Content Filter"sv, GUI::InputType::NonemptyText) == GUI::Dialog::ExecResult::OK) {
|
||||
m_domain_list_model->add_domain(move(text));
|
||||
m_domain_list_model->add_domain(move(text).to_deprecated_string());
|
||||
set_modified(true);
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue