mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-05 16:14:38 +00:00
HackStudio: Propagate errors using try_set_main_widget
The documentation tooltip and parameters hint tooltip initialization functions are now fallible and now call try_set_main_widget instead of set_main_widget. They are only called by Editor's new custom try_create function.
This commit is contained in:
committed by
Andreas Kling
parent
4c0b8a70e2
commit
d4484f4de3
@@ -30,7 +30,8 @@ EditorWrapper::EditorWrapper()
|
||||
m_filename_label->set_text_alignment(Gfx::TextAlignment::CenterLeft);
|
||||
m_filename_label->set_fixed_height(14);
|
||||
|
||||
m_editor = add<Editor>();
|
||||
// FIXME: Propagate errors instead of giving up
|
||||
m_editor = MUST(try_add<Editor>());
|
||||
m_editor->set_ruler_visible(true);
|
||||
m_editor->set_automatic_indentation_enabled(true);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user