![]() |
Peoplemon
0.1.0
Peoplemon 3 game source documentation
|
GUI component for selecting or writing scripts. Performs syntax validation as well. More...
#include <ScriptSelector.hpp>
Public Types | |
using | OnSelect = std::function< void(const std::string &)> |
Callback type for when a script is chosen. More... | |
using | OnCancel = std::function< void()> |
Called when the window is closed without a selection. More... | |
Public Member Functions | |
ScriptSelector (const OnSelect &onSelect, const OnCancel &onCancel) | |
Construct a new Script Selector dialog. More... | |
void | open (bl::gui::GUI *parent, const std::string &value={}) |
Opens the dialog to select a script. More... | |
GUI component for selecting or writing scripts. Performs syntax validation as well.
Definition at line 17 of file ScriptSelector.hpp.
using editor::component::ScriptSelector::OnCancel = std::function<void()> |
Called when the window is closed without a selection.
Definition at line 23 of file ScriptSelector.hpp.
using editor::component::ScriptSelector::OnSelect = std::function<void(const std::string&)> |
Callback type for when a script is chosen.
Definition at line 20 of file ScriptSelector.hpp.
editor::component::ScriptSelector::ScriptSelector | ( | const OnSelect & | onSelect, |
const OnCancel & | onCancel | ||
) |
Construct a new Script Selector dialog.
onSelect | Callback to call when a script is chosen |
onCancel | Called when the window is closed without a selection |
Definition at line 12 of file ScriptSelector.cpp.
void editor::component::ScriptSelector::open | ( | bl::gui::GUI * | parent, |
const std::string & | value = {} |
||
) |
Opens the dialog to select a script.
parent | The parent to add the GUI elements to |
value | The default script value to fill |
Definition at line 59 of file ScriptSelector.cpp.