refactoring to interfaces complete
This commit is contained in:
@@ -41,7 +41,7 @@ void EventNotifier::unregister_event_handler(IEventHandler* handler)
|
||||
event_handler.erase(handler);
|
||||
}
|
||||
|
||||
void EventNotifier::distribute_event(IEvent& event)
|
||||
void EventNotifier::distribute_event(Event& event)
|
||||
{
|
||||
event_queue.push(event);
|
||||
}
|
||||
@@ -56,7 +56,7 @@ void EventNotifier::notify()
|
||||
std::lock_guard<std::mutex> event_handler_guard(event_handler_mutex);
|
||||
for(auto handler : event_handler)
|
||||
{
|
||||
boost::thread handler_caller(boost::bind(&EventHandler::handle, handler, event));
|
||||
boost::thread handler_caller(boost::bind(&IEventHandler::handle, handler, event));
|
||||
|
||||
if(!handler_caller.timed_join(boost::posix_time::milliseconds(HANDLER_TIMEOUT)))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user