EventManager: Rename queue accessor and remove cast operator

This patch renames the queue() accessor to the less ambigious
eventQueue, and also removes the cast operator. The queue() member
function cause problems in derived classes that declare members with
the same name, e.g. a MemObject subclass that has a packet queue on
its own. The operator is not causing any harm at this point, but as it
is not used there is little point in keeping it.
This commit is contained in:
Andreas Hansson
2012-07-09 12:35:46 -04:00
parent d2f458e7b5
commit 745274cbd4

View File

@@ -431,17 +431,12 @@ class EventManager
EventQueue *eventq;
public:
EventManager(EventManager &em) : eventq(em.queue()) {}
EventManager(EventManager *em) : eventq(em ? em->queue() : NULL) {}
EventManager(EventManager &em) : eventq(em.eventq) {}
EventManager(EventManager *em) : eventq(em ? em->eventq : NULL) {}
EventManager(EventQueue *eq) : eventq(eq) {}
EventQueue *
queue() const
{
return eventq;
}
operator EventQueue *() const
eventQueue() const
{
return eventq;
}