Centralize retained dialog close bindings
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
#include "pch.h"
|
||||
#include "log.h"
|
||||
#include "legacy_ui_overlay_services.h"
|
||||
#include "node_settings.h"
|
||||
#include "layout.h"
|
||||
|
||||
@@ -16,7 +17,7 @@ void NodeSettings::init()
|
||||
SetPositioning(YGPositionTypeAbsolute);
|
||||
add_child_file("data/dialogs/settings.xml", "settings");
|
||||
btnOk = find<NodeButton>("btn-ok");
|
||||
btnOk->on_click = [&](Node*) { destroy(); };
|
||||
pp::panopainter::bind_legacy_click_destroys_node(*btnOk, *this);
|
||||
}
|
||||
|
||||
kEventResult NodeSettings::handle_event(Event* e)
|
||||
|
||||
Reference in New Issue
Block a user