]> git.tdb.fi Git - libs/core.git/blobdiff - source/eventdispatcher.h
Move class members and comments around
[libs/core.git] / source / eventdispatcher.h
index dca659274f5cc3cdc6c1f48f003399f814290f25..7e89d4739e845f0e0c180845ffedb43184eefd9f 100644 (file)
@@ -14,22 +14,6 @@ on some of them.
 */
 class EventDispatcher: public sigc::trackable
 {
-public:
-       EventDispatcher();
-       void add(Base &);
-       void remove(Base &);
-
-       /**
-       Checks for and dispatches events.  If there are no events available, blocks
-       until there are.
-       */
-       void tick();
-
-       /**
-       Checks for and dispatches events.  If there are no events available, waits
-       at most the specified time before returning.
-       */
-       void tick(const Time::TimeDelta &);
 private:
        struct Slot
        {
@@ -39,11 +23,27 @@ private:
 
                Slot(Base *o): obj(o) { }
        };
+
        typedef std::map<Base *, Slot> SlotMap;
 
        Poller poller;
        SlotMap objects;
 
+public:
+       EventDispatcher();
+
+       void add(Base &);
+       void remove(Base &);
+
+       /** Checks for and dispatches events.  If there are no events available,
+       blocks until there are. */
+       void tick();
+
+       /** Checks for and dispatches events.  If there are no events available,
+       waits at most the specified time before returning. */
+       void tick(const Time::TimeDelta &);
+
+private:
        void object_events_changed(PollEvent, Base *);
        void object_deleted(Base *);
        void dispatch();