diff options
author | Andreas Kling <awesomekling@gmail.com> | 2019-04-03 16:50:08 +0200 |
---|---|---|
committer | Andreas Kling <awesomekling@gmail.com> | 2019-04-03 16:52:25 +0200 |
commit | c02c9880b61569455eeea1dacaa15d29c33021ea (patch) | |
tree | 35580c7110f28edd9ef5b41a043f38619c0f96f1 /LibGUI/GToolBar.cpp | |
parent | 528054d192448f93789fedc3782550b3a80bee27 (diff) | |
download | serenity-c02c9880b61569455eeea1dacaa15d29c33021ea.zip |
AK: Add Eternal<T> and use it in various places.
This is useful for static locals that never need to be destroyed:
Thing& Thing::the()
{
static Eternal<Thing> the;
return the;
}
The object will be allocated in data segment memory and will never have
its destructor invoked.
Diffstat (limited to 'LibGUI/GToolBar.cpp')
-rw-r--r-- | LibGUI/GToolBar.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/LibGUI/GToolBar.cpp b/LibGUI/GToolBar.cpp index 9eb87574f8..14e58e9d51 100644 --- a/LibGUI/GToolBar.cpp +++ b/LibGUI/GToolBar.cpp @@ -79,5 +79,5 @@ void GToolBar::paint_event(GPaintEvent& event) { GPainter painter(*this); painter.add_clip_rect(event.rect()); - StylePainter::the().paint_surface(painter, rect(), !spans_entire_window_horizontally()); + StylePainter::paint_surface(painter, rect(), !spans_entire_window_horizontally()); } |