24#ifndef OBSERVABLE_EVT_H
25#define OBSERVABLE_EVT_H
41 : wxCommandEvent(commandType, id) {}
45 this->m_shared_ptr =
event.m_shared_ptr;
52 std::shared_ptr<const void>
GetSharedPtr()
const {
return m_shared_ptr; }
55 void SetSharedPtr(std::shared_ptr<const void> p) { m_shared_ptr = p; }
58 std::shared_ptr<const void> m_shared_ptr;
Adds a std::shared<void> element to wxCommandEvent.
ObservedEvt(const ObservedEvt &event)
Copy operation.
ObservedEvt(wxEventType commandType=obsNOTIFY, int id=0)
Construct an event using given commandType and id.
void SetSharedPtr(std::shared_ptr< const void > p)
Set a shared_ptr transferred to listeners.
wxEvent * Clone() const
Return a shallow copy of this.
std::shared_ptr< const void > GetSharedPtr() const
Retrieve pointer set by SetSharedPtr().