1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 20:17:44 +00:00

LibGUI: Convert GTextBox, GTextEditor and GResizeCorner to ObjectPtr

This commit is contained in:
Andreas Kling 2019-09-21 15:43:52 +02:00
parent 4ea229accd
commit 93851c3832
25 changed files with 38 additions and 36 deletions

View file

@ -31,7 +31,7 @@ public:
BoolModelEditingDelegate() {}
virtual ~BoolModelEditingDelegate() override {}
virtual GWidget* create_widget() override
virtual ObjectPtr<GWidget> create_widget() override
{
auto* combo = new GComboBox(nullptr);
combo->set_only_allow_values_from_model(true);

View file

@ -95,7 +95,7 @@ static GWidget* build_gwidget(VBWidgetType type, GWidget* parent)
return box;
}
case VBWidgetType::GTextEditor: {
auto* editor = new GTextEditor(GTextEditor::Type::MultiLine, parent);
auto editor = GTextEditor::construct(GTextEditor::Type::MultiLine, parent);
editor->set_ruler_visible(false);
return editor;
}