}
// Dispatch event for this thread.
- void Dispatch(HANDLE hThreadContext, Event& event)
+ void Dispatch(HANDLE hThreadContext, const Event& event)
{
EventManager* pManager = FromHandle(hThreadContext);
SWR_ASSERT(pManager != nullptr);
void DestroyThreadContext(HANDLE hThreadContext);
// Dispatch event for this thread.
- void Dispatch(HANDLE hThreadContext, Event& event);
+ void Dispatch(HANDLE hThreadContext, const Event& event);
void FlushDraw(HANDLE hThreadContext, uint32_t drawId);
};
mHandlers.push_back(pHandler);
}
- void Dispatch(Event& event)
+ void Dispatch(const Event& event)
{
///@todo Add event filter check here.
using namespace ArchRast;
% for name in protos['event_names']:
-void ${name}::Accept(EventHandler* pHandler)
+void ${name}::Accept(EventHandler* pHandler) const
{
pHandler->Handle(*this);
}
Event() {}
virtual ~Event() {}
- virtual void Accept(EventHandler* pHandler) = 0;
+ virtual void Accept(EventHandler* pHandler) const = 0;
};
% for name in protos['event_names']:
% endfor
}
- virtual void Accept(EventHandler* pHandler);
+ virtual void Accept(EventHandler* pHandler) const;
};
% endfor
}
\ No newline at end of file