diff options
author | Karol Kosek <krkk@serenityos.org> | 2023-03-10 19:04:13 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2023-03-16 09:58:42 +0100 |
commit | 446c600d093059dd2af3b357ea1c0c698c66d27d (patch) | |
tree | 54e29f3921bda384934647cd6cc539ff71a74f6e /Userland/Applications | |
parent | 797968c310d3b13f74968ba292e0b360d6d2d9c2 (diff) | |
download | serenity-446c600d093059dd2af3b357ea1c0c698c66d27d.zip |
LibGUI+Applications: Port SettingsWindow::add_tab() to the new string
Diffstat (limited to 'Userland/Applications')
-rw-r--r-- | Userland/Applications/BrowserSettings/main.cpp | 4 | ||||
-rw-r--r-- | Userland/Applications/CalendarSettings/main.cpp | 2 | ||||
-rw-r--r-- | Userland/Applications/ClockSettings/main.cpp | 4 | ||||
-rw-r--r-- | Userland/Applications/DisplaySettings/main.cpp | 12 | ||||
-rw-r--r-- | Userland/Applications/GamesSettings/main.cpp | 4 | ||||
-rw-r--r-- | Userland/Applications/KeyboardSettings/main.cpp | 2 | ||||
-rw-r--r-- | Userland/Applications/MailSettings/main.cpp | 2 | ||||
-rw-r--r-- | Userland/Applications/MouseSettings/main.cpp | 6 | ||||
-rw-r--r-- | Userland/Applications/NetworkSettings/main.cpp | 2 | ||||
-rw-r--r-- | Userland/Applications/TerminalSettings/main.cpp | 4 |
10 files changed, 21 insertions, 21 deletions
diff --git a/Userland/Applications/BrowserSettings/main.cpp b/Userland/Applications/BrowserSettings/main.cpp index bfcbf26b54..4115546bb6 100644 --- a/Userland/Applications/BrowserSettings/main.cpp +++ b/Userland/Applications/BrowserSettings/main.cpp @@ -34,8 +34,8 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) auto window = TRY(GUI::SettingsWindow::create("Browser Settings", GUI::SettingsWindow::ShowDefaultsButton::Yes)); window->set_icon(app_icon.bitmap_for_size(16)); - (void)TRY(window->add_tab<BrowserSettingsWidget>("Browser"sv, "browser"sv)); - (void)TRY(window->add_tab<ContentFilterSettingsWidget>("Content Filtering"sv, "content-filtering"sv)); + (void)TRY(window->add_tab<BrowserSettingsWidget>("Browser"_short_string, "browser"sv)); + (void)TRY(window->add_tab<ContentFilterSettingsWidget>(TRY("Content Filtering"_string), "content-filtering"sv)); window->set_active_tab(selected_tab); window->show(); diff --git a/Userland/Applications/CalendarSettings/main.cpp b/Userland/Applications/CalendarSettings/main.cpp index 1ff2cf5fec..bbe1bd314b 100644 --- a/Userland/Applications/CalendarSettings/main.cpp +++ b/Userland/Applications/CalendarSettings/main.cpp @@ -33,7 +33,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) auto app_icon = GUI::Icon::default_icon("app-calendar"sv); auto window = TRY(GUI::SettingsWindow::create("Calendar Settings", GUI::SettingsWindow::ShowDefaultsButton::Yes)); - (void)TRY(window->add_tab<CalendarSettingsWidget>("Calendar"sv, "Calendar"sv)); + (void)TRY(window->add_tab<CalendarSettingsWidget>(TRY("Calendar"_string), "Calendar"sv)); window->set_icon(app_icon.bitmap_for_size(16)); window->set_active_tab(selected_tab); diff --git a/Userland/Applications/ClockSettings/main.cpp b/Userland/Applications/ClockSettings/main.cpp index 84fc48ddad..9b480d6ebf 100644 --- a/Userland/Applications/ClockSettings/main.cpp +++ b/Userland/Applications/ClockSettings/main.cpp @@ -36,9 +36,9 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) auto app_icon = GUI::Icon::default_icon("app-analog-clock"sv); // FIXME: Create a ClockSettings icon. auto window = TRY(GUI::SettingsWindow::create("Clock Settings", GUI::SettingsWindow::ShowDefaultsButton::Yes)); - (void)TRY(window->add_tab<ClockSettingsWidget>("Clock"sv, "clock"sv)); + (void)TRY(window->add_tab<ClockSettingsWidget>("Clock"_short_string, "clock"sv)); auto timezonesettings_widget = TRY(TimeZoneSettingsWidget::create()); - TRY(window->add_tab(timezonesettings_widget, "Time Zone"sv, "time-zone"sv)); + TRY(window->add_tab(timezonesettings_widget, TRY("Time Zone"_string), "time-zone"sv)); window->set_icon(app_icon.bitmap_for_size(16)); window->resize(540, 570); diff --git a/Userland/Applications/DisplaySettings/main.cpp b/Userland/Applications/DisplaySettings/main.cpp index 907a34b688..2985a2d407 100644 --- a/Userland/Applications/DisplaySettings/main.cpp +++ b/Userland/Applications/DisplaySettings/main.cpp @@ -37,12 +37,12 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) bool background_settings_changed = false; auto window = TRY(GUI::SettingsWindow::create("Display Settings")); - (void)TRY(window->add_tab<DisplaySettings::BackgroundSettingsWidget>("Background"sv, "background"sv, background_settings_changed)); - (void)TRY(window->add_tab<DisplaySettings::ThemesSettingsWidget>("Themes"sv, "themes"sv, background_settings_changed)); - (void)TRY(window->add_tab<DisplaySettings::FontSettingsWidget>("Fonts"sv, "fonts"sv)); - (void)TRY(window->add_tab<DisplaySettings::MonitorSettingsWidget>("Monitor"sv, "monitor"sv)); - (void)TRY(window->add_tab<DisplaySettings::DesktopSettingsWidget>("Workspaces"sv, "workspaces"sv)); - (void)TRY(window->add_tab<GUI::DisplaySettings::EffectsSettingsWidget>("Effects"sv, "effects"sv)); + (void)TRY(window->add_tab<DisplaySettings::BackgroundSettingsWidget>(TRY("Background"_string), "background"sv, background_settings_changed)); + (void)TRY(window->add_tab<DisplaySettings::ThemesSettingsWidget>("Themes"_short_string, "themes"sv, background_settings_changed)); + (void)TRY(window->add_tab<DisplaySettings::FontSettingsWidget>("Fonts"_short_string, "fonts"sv)); + (void)TRY(window->add_tab<DisplaySettings::MonitorSettingsWidget>("Monitor"_short_string, "monitor"sv)); + (void)TRY(window->add_tab<DisplaySettings::DesktopSettingsWidget>(TRY("Workspaces"_string), "workspaces"sv)); + (void)TRY(window->add_tab<GUI::DisplaySettings::EffectsSettingsWidget>("Effects"_short_string, "effects"sv)); window->set_active_tab(selected_tab); window->set_icon(app_icon.bitmap_for_size(16)); diff --git a/Userland/Applications/GamesSettings/main.cpp b/Userland/Applications/GamesSettings/main.cpp index 3e887f9495..f15e3f50bf 100644 --- a/Userland/Applications/GamesSettings/main.cpp +++ b/Userland/Applications/GamesSettings/main.cpp @@ -35,8 +35,8 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) auto window = TRY(GUI::SettingsWindow::create("Games Settings", GUI::SettingsWindow::ShowDefaultsButton::Yes)); window->set_icon(app_icon.bitmap_for_size(16)); - (void)TRY(window->add_tab<GamesSettings::CardSettingsWidget>("Cards"sv, "cards"sv)); - (void)TRY(window->add_tab<GamesSettings::ChessSettingsWidget>("Chess"sv, "chess"sv)); + (void)TRY(window->add_tab<GamesSettings::CardSettingsWidget>("Cards"_short_string, "cards"sv)); + (void)TRY(window->add_tab<GamesSettings::ChessSettingsWidget>("Chess"_short_string, "chess"sv)); window->set_active_tab(selected_tab); window->show(); diff --git a/Userland/Applications/KeyboardSettings/main.cpp b/Userland/Applications/KeyboardSettings/main.cpp index 7d36b7db9d..3d8fcb491e 100644 --- a/Userland/Applications/KeyboardSettings/main.cpp +++ b/Userland/Applications/KeyboardSettings/main.cpp @@ -35,7 +35,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) auto window = TRY(GUI::SettingsWindow::create("Keyboard Settings")); window->set_icon(app_icon.bitmap_for_size(16)); - auto keyboard_settings_widget = TRY(window->add_tab<KeyboardSettingsWidget>("Keyboard"sv, "keyboard"sv)); + auto keyboard_settings_widget = TRY(window->add_tab<KeyboardSettingsWidget>(TRY("Keyboard"_string), "keyboard"sv)); window->set_active_tab(selected_tab); window->on_active_window_change = [&](bool is_active_window) { diff --git a/Userland/Applications/MailSettings/main.cpp b/Userland/Applications/MailSettings/main.cpp index 75dc3c57a8..6146d81885 100644 --- a/Userland/Applications/MailSettings/main.cpp +++ b/Userland/Applications/MailSettings/main.cpp @@ -34,7 +34,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) auto app_icon = GUI::Icon::default_icon("app-mail"sv); auto window = TRY(GUI::SettingsWindow::create("Mail Settings", GUI::SettingsWindow::ShowDefaultsButton::Yes)); - (void)TRY(window->add_tab<MailSettingsWidget>("Mail"sv, "mail"sv)); + (void)TRY(window->add_tab<MailSettingsWidget>("Mail"_short_string, "mail"sv)); window->set_icon(app_icon.bitmap_for_size(16)); window->set_active_tab(selected_tab); diff --git a/Userland/Applications/MouseSettings/main.cpp b/Userland/Applications/MouseSettings/main.cpp index 9564f996e2..852e77429e 100644 --- a/Userland/Applications/MouseSettings/main.cpp +++ b/Userland/Applications/MouseSettings/main.cpp @@ -34,9 +34,9 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) auto app_icon = GUI::Icon::default_icon("app-mouse"sv); auto window = TRY(GUI::SettingsWindow::create("Mouse Settings", GUI::SettingsWindow::ShowDefaultsButton::Yes)); - (void)TRY(window->add_tab<MouseWidget>("Mouse"sv, "mouse"sv)); - (void)TRY(window->add_tab<ThemeWidget>("Cursor Theme"sv, "cursor-theme"sv)); - (void)TRY(window->add_tab<HighlightWidget>("Cursor Highlight"sv, "cursor-highlight"sv)); + (void)TRY(window->add_tab<MouseWidget>("Mouse"_short_string, "mouse"sv)); + (void)TRY(window->add_tab<ThemeWidget>(TRY("Cursor Theme"_string), "cursor-theme"sv)); + (void)TRY(window->add_tab<HighlightWidget>(TRY("Cursor Highlight"_string), "cursor-highlight"sv)); window->set_icon(app_icon.bitmap_for_size(16)); window->set_active_tab(selected_tab); diff --git a/Userland/Applications/NetworkSettings/main.cpp b/Userland/Applications/NetworkSettings/main.cpp index 63270f49cf..2c78fdc633 100644 --- a/Userland/Applications/NetworkSettings/main.cpp +++ b/Userland/Applications/NetworkSettings/main.cpp @@ -44,7 +44,7 @@ ErrorOr<int> serenity_main(Main::Arguments args) auto app_icon = GUI::Icon::default_icon("network"sv); auto window = TRY(GUI::SettingsWindow::create("Network Settings", GUI::SettingsWindow::ShowDefaultsButton::No)); - auto network_settings_widget = TRY(window->add_tab<NetworkSettings::NetworkSettingsWidget>("Network"sv, "network"sv)); + auto network_settings_widget = TRY(window->add_tab<NetworkSettings::NetworkSettingsWidget>("Network"_short_string, "network"sv)); if (!adapter.is_null()) { network_settings_widget->switch_adapter(adapter); } diff --git a/Userland/Applications/TerminalSettings/main.cpp b/Userland/Applications/TerminalSettings/main.cpp index af899f825c..22d79fe1c2 100644 --- a/Userland/Applications/TerminalSettings/main.cpp +++ b/Userland/Applications/TerminalSettings/main.cpp @@ -32,8 +32,8 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) auto window = TRY(GUI::SettingsWindow::create("Terminal Settings")); window->set_icon(app_icon.bitmap_for_size(16)); - (void)TRY(window->add_tab<TerminalSettingsViewWidget>("View"sv, "view"sv)); - (void)TRY(window->add_tab<TerminalSettingsMainWidget>("Terminal"sv, "terminal"sv)); + (void)TRY(window->add_tab<TerminalSettingsViewWidget>("View"_short_string, "view"sv)); + (void)TRY(window->add_tab<TerminalSettingsMainWidget>(TRY("Terminal"_string), "terminal"sv)); window->set_active_tab(selected_tab); window->show(); |