summaryrefslogtreecommitdiff
path: root/Userland/Demos
diff options
context:
space:
mode:
authorSam Atkins <atkinssj@serenityos.org>2023-01-07 12:38:23 +0000
committerLinus Groh <mail@linusgroh.de>2023-01-07 14:39:30 +0100
commitf0395a20428230ee680c6f92efd68dedd040c658 (patch)
treee391a4ef7736281c4d2c93dcba862060e935825d /Userland/Demos
parente4e12f3a961efd5f0ce0204becd3ce762a458c4c (diff)
downloadserenity-f0395a20428230ee680c6f92efd68dedd040c658.zip
LibGUI+Userland: Rename `try_load_from_gml()` -> `load_from_gml()` :^)
It's the only one, so the `try` prefix is unnecessary now.
Diffstat (limited to 'Userland/Demos')
-rw-r--r--Userland/Demos/ModelGallery/GalleryWidget.cpp2
-rw-r--r--Userland/Demos/WidgetGallery/DemoWizardDialog.cpp4
-rw-r--r--Userland/Demos/WidgetGallery/GalleryWidget.cpp12
3 files changed, 9 insertions, 9 deletions
diff --git a/Userland/Demos/ModelGallery/GalleryWidget.cpp b/Userland/Demos/ModelGallery/GalleryWidget.cpp
index 5808d82cd8..6235cc252a 100644
--- a/Userland/Demos/ModelGallery/GalleryWidget.cpp
+++ b/Userland/Demos/ModelGallery/GalleryWidget.cpp
@@ -26,7 +26,7 @@ GalleryWidget::GalleryWidget()
ErrorOr<void> GalleryWidget::load_basic_model_tab()
{
auto tab = TRY(m_tab_widget->try_add_tab<GUI::Widget>("Basic Model"));
- TRY(tab->try_load_from_gml(basic_model_tab_gml));
+ TRY(tab->load_from_gml(basic_model_tab_gml));
m_basic_model = BasicModel::create();
m_basic_model_table = *tab->find_descendant_of_type_named<GUI::TableView>("model_table");
diff --git a/Userland/Demos/WidgetGallery/DemoWizardDialog.cpp b/Userland/Demos/WidgetGallery/DemoWizardDialog.cpp
index 2edea7f382..a9156e8dbe 100644
--- a/Userland/Demos/WidgetGallery/DemoWizardDialog.cpp
+++ b/Userland/Demos/WidgetGallery/DemoWizardDialog.cpp
@@ -28,7 +28,7 @@ DemoWizardDialog::DemoWizardDialog(GUI::Window* parent_window)
"Installation location",
"Choose where Demo Application is installed on your computer.")
.release_value_but_fixme_should_propagate_errors();
- m_page_1->body_widget().try_load_from_gml(demo_wizard_page_1_gml).release_value_but_fixme_should_propagate_errors();
+ m_page_1->body_widget().load_from_gml(demo_wizard_page_1_gml).release_value_but_fixme_should_propagate_errors();
m_page_1_location_text_box = m_page_1->body_widget().find_descendant_of_type_named<GUI::TextBox>("page_1_location_text_box");
m_page_1->on_next_page = [&]() {
return m_page_2;
@@ -39,7 +39,7 @@ DemoWizardDialog::DemoWizardDialog(GUI::Window* parent_window)
"Installation in progress...",
"Please wait. Do not turn off your computer.")
.release_value_but_fixme_should_propagate_errors();
- m_page_2->body_widget().try_load_from_gml(demo_wizard_page_2_gml).release_value_but_fixme_should_propagate_errors();
+ m_page_2->body_widget().load_from_gml(demo_wizard_page_2_gml).release_value_but_fixme_should_propagate_errors();
m_page_2_progressbar = m_page_2->body_widget().find_descendant_of_type_named<GUI::Progressbar>("page_2_progressbar");
m_page_2_timer = Core::Timer::try_create(this).release_value_but_fixme_should_propagate_errors();
m_page_2->on_page_enter = [&]() {
diff --git a/Userland/Demos/WidgetGallery/GalleryWidget.cpp b/Userland/Demos/WidgetGallery/GalleryWidget.cpp
index 02ce30f86b..fe2abe2e66 100644
--- a/Userland/Demos/WidgetGallery/GalleryWidget.cpp
+++ b/Userland/Demos/WidgetGallery/GalleryWidget.cpp
@@ -32,12 +32,12 @@
GalleryWidget::GalleryWidget()
{
- try_load_from_gml(window_gml).release_value_but_fixme_should_propagate_errors();
+ load_from_gml(window_gml).release_value_but_fixme_should_propagate_errors();
auto& tab_widget = *find_descendant_of_type_named<GUI::TabWidget>("tab_widget");
auto basics_tab = tab_widget.try_add_tab<GUI::Widget>("Basics").release_value_but_fixme_should_propagate_errors();
- basics_tab->try_load_from_gml(basics_tab_gml).release_value_but_fixme_should_propagate_errors();
+ basics_tab->load_from_gml(basics_tab_gml).release_value_but_fixme_should_propagate_errors();
m_enabled_label = basics_tab->find_descendant_of_type_named<GUI::Label>("enabled_label");
m_label_frame = basics_tab->find_descendant_of_type_named<GUI::Frame>("label_frame");
@@ -170,7 +170,7 @@ GalleryWidget::GalleryWidget()
};
auto sliders_tab = tab_widget.try_add_tab<GUI::Widget>("Sliders").release_value_but_fixme_should_propagate_errors();
- sliders_tab->try_load_from_gml(sliders_tab_gml).release_value_but_fixme_should_propagate_errors();
+ sliders_tab->load_from_gml(sliders_tab_gml).release_value_but_fixme_should_propagate_errors();
m_vertical_progressbar_left = sliders_tab->find_descendant_of_type_named<GUI::VerticalProgressbar>("vertical_progressbar_left");
m_vertical_progressbar_left->set_value(0);
@@ -231,7 +231,7 @@ GalleryWidget::GalleryWidget()
};
auto wizards_tab = tab_widget.try_add_tab<GUI::Widget>("Wizards").release_value_but_fixme_should_propagate_errors();
- wizards_tab->try_load_from_gml(wizards_tab_gml).release_value_but_fixme_should_propagate_errors();
+ wizards_tab->load_from_gml(wizards_tab_gml).release_value_but_fixme_should_propagate_errors();
m_wizard_button = wizards_tab->find_descendant_of_type_named<GUI::Button>("wizard_button");
m_wizard_output = wizards_tab->find_descendant_of_type_named<GUI::TextEditor>("wizard_output");
@@ -287,7 +287,7 @@ GalleryWidget::GalleryWidget()
};
auto cursors_tab = tab_widget.try_add_tab<GUI::Widget>("Cursors").release_value_but_fixme_should_propagate_errors();
- cursors_tab->try_load_from_gml(cursors_tab_gml).release_value_but_fixme_should_propagate_errors();
+ cursors_tab->load_from_gml(cursors_tab_gml).release_value_but_fixme_should_propagate_errors();
m_cursors_tableview = cursors_tab->find_descendant_of_type_named<GUI::TableView>("cursors_tableview");
m_cursors_tableview->set_highlight_selected_rows(true);
@@ -310,7 +310,7 @@ GalleryWidget::GalleryWidget()
};
auto icons_tab = tab_widget.try_add_tab<GUI::Widget>("Icons").release_value_but_fixme_should_propagate_errors();
- icons_tab->try_load_from_gml(icons_tab_gml).release_value_but_fixme_should_propagate_errors();
+ icons_tab->load_from_gml(icons_tab_gml).release_value_but_fixme_should_propagate_errors();
m_icons_tableview = icons_tab->find_descendant_of_type_named<GUI::TableView>("icons_tableview");
m_icons_tableview->set_highlight_selected_rows(true);