Peoplemon  0.1.0
Peoplemon 3 game source documentation
Public Types | Public Member Functions | List of all members
editor::component::EventEditor Class Reference

Map event editor dialog. More...

#include <EventEditor.hpp>

Public Types

using OnEdit = std::function< void(const core::map::Event *, const core::map::Event &)>
 Callback called when an event is created or modified. More...
 

Public Member Functions

 EventEditor (const OnEdit &onEdit)
 Construct a new Event Editor dialog. More...
 
void open (bl::gui::GUI *parent, const core::map::Event *source, const sf::Vector2i &pos)
 Opens the dialog window and optionally populates with event info. More...
 

Detailed Description

Map event editor dialog.

Definition at line 18 of file EventEditor.hpp.

Member Typedef Documentation

◆ OnEdit

using editor::component::EventEditor::OnEdit = std::function<void(const core::map::Event*, const core::map::Event&)>

Callback called when an event is created or modified.

Definition at line 21 of file EventEditor.hpp.

Constructor & Destructor Documentation

◆ EventEditor()

editor::component::EventEditor::EventEditor ( const OnEdit onEdit)

Construct a new Event Editor dialog.

Parameters
onEditCallback to call when an event is created or modified

Definition at line 9 of file EventEditor.cpp.

Member Function Documentation

◆ open()

void editor::component::EventEditor::open ( bl::gui::GUI *  parent,
const core::map::Event source,
const sf::Vector2i &  pos 
)

Opens the dialog window and optionally populates with event info.

Parameters
parentThe parent GUI object
sourceOptional event to populate from
posThe position to populate if not editing an existing event

Definition at line 84 of file EventEditor.cpp.


The documentation for this class was generated from the following files: