summaryrefslogtreecommitdiffstats
blob: 482be58b9358ced1cb383ba0518e4cb51b587717 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#ifndef SWIFTEN_EventController_H
#define SWIFTEN_EventController_H


#include <boost/signals.hpp>
#include <boost/shared_ptr.hpp>
#include <vector>

#include "Swiften/Events/Event.h"
#include "Swiften/Events/MessageEvent.h"

namespace Swift {
	class EventController {
		public:
			EventController();
			void handleIncomingEvent(boost::shared_ptr<Event> sourceEvent);
			boost::signal<void (int)> onEventQueueLengthChange;
			boost::signal<void (boost::shared_ptr<Event>)> onEventQueueEventAdded;

		private:
			void handleEventConcluded(boost::shared_ptr<Event> event);
			std::vector<boost::shared_ptr<Event> > events_;
	};
}
#endif