mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 16:17:45 +00:00
LibGUI: Convert GWindow to ObjectPtr
This commit is contained in:
parent
70412c7d4f
commit
7584480f62
25 changed files with 37 additions and 37 deletions
|
@ -28,7 +28,7 @@ GComboBox::GComboBox(GWidget* parent)
|
|||
open();
|
||||
};
|
||||
|
||||
m_list_window = new GWindow(this);
|
||||
m_list_window = GWindow::construct(this);
|
||||
// FIXME: This is obviously not a tooltip window, but it's the closest thing to what we want atm.
|
||||
m_list_window->set_window_type(GWindowType::Tooltip);
|
||||
m_list_window->set_should_destroy_on_close(false);
|
||||
|
|
|
@ -38,7 +38,7 @@ protected:
|
|||
private:
|
||||
ObjectPtr<GTextEditor> m_editor;
|
||||
GButton* m_open_button { nullptr };
|
||||
GWindow* m_list_window { nullptr };
|
||||
ObjectPtr<GWindow> m_list_window;
|
||||
ObjectPtr<GListView> m_list_view;
|
||||
bool m_only_allow_values_from_model { false };
|
||||
};
|
||||
|
|
|
@ -24,7 +24,6 @@ enum class GStandardCursor {
|
|||
class GWindow : public CObject {
|
||||
C_OBJECT(GWindow)
|
||||
public:
|
||||
GWindow(CObject* parent = nullptr);
|
||||
virtual ~GWindow() override;
|
||||
|
||||
static GWindow* from_window_id(int);
|
||||
|
@ -135,6 +134,7 @@ public:
|
|||
virtual void save_to(AK::JsonObject&) override;
|
||||
|
||||
protected:
|
||||
GWindow(CObject* parent = nullptr);
|
||||
virtual void wm_event(GWMEvent&);
|
||||
|
||||
private:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue