From 23ac52bc80fb3d82542664a27325a9a7e7b474e0 Mon Sep 17 00:00:00 2001 From: Karol Kosek Date: Tue, 9 May 2023 17:03:03 +0200 Subject: GMLPlayground: Use `try_make` for syntax highlighting and autocomplete --- Userland/DevTools/GMLPlayground/MainWidget.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Userland/DevTools/GMLPlayground/MainWidget.cpp b/Userland/DevTools/GMLPlayground/MainWidget.cpp index c9fc0c2df4..ccd6411569 100644 --- a/Userland/DevTools/GMLPlayground/MainWidget.cpp +++ b/Userland/DevTools/GMLPlayground/MainWidget.cpp @@ -77,8 +77,8 @@ ErrorOr> MainWidget::try_create(GUI::Icon const& icon) main_widget->m_preview = main_widget->m_preview_frame_widget; - main_widget->m_editor->set_syntax_highlighter(make()); - main_widget->m_editor->set_autocomplete_provider(make()); + main_widget->m_editor->set_syntax_highlighter(TRY(try_make())); + main_widget->m_editor->set_autocomplete_provider(TRY(try_make())); main_widget->m_editor->set_should_autocomplete_automatically(true); main_widget->m_editor->set_automatic_indentation_enabled(true); main_widget->m_editor->set_ruler_visible(true); -- cgit v1.2.3