Panda3D
cIntervalManager.I
1 // Filename: cIntervalManager.I
2 // Created by: drose (10Sep02)
3 //
4 ////////////////////////////////////////////////////////////////////
5 //
6 // PANDA 3D SOFTWARE
7 // Copyright (c) Carnegie Mellon University. All rights reserved.
8 //
9 // All use of this software is subject to the terms of the revised BSD
10 // license. You should have received a copy of this license along
11 // with this source code in a file named "LICENSE."
12 //
13 ////////////////////////////////////////////////////////////////////
14 
15 
16 ////////////////////////////////////////////////////////////////////
17 // Function: CIntervalManager::set_event_queue
18 // Access: Published
19 // Description: Specifies a custom event queue to be used for
20 // throwing done events from intervals as they finish.
21 // If this is not specified, the global event queue is
22 // used.
23 //
24 // The caller maintains ownership of the EventQueue
25 // object; it is the caller's responsibility to ensure
26 // that the supplied EventQueue does not destruct during
27 // the lifetime of the CIntervalManager.
28 ////////////////////////////////////////////////////////////////////
29 INLINE void CIntervalManager::
30 set_event_queue(EventQueue *event_queue) {
31  _event_queue = event_queue;
32 }
33 
34 ////////////////////////////////////////////////////////////////////
35 // Function: CIntervalManager::get_event_queue
36 // Access: Published
37 // Description: Returns the custom event queue to be used for
38 // throwing done events from intervals as they finish.
39 ////////////////////////////////////////////////////////////////////
41 get_event_queue() const {
42  return _event_queue;
43 }
44 
45 INLINE ostream &
46 operator << (ostream &out, const CIntervalManager &ival_mgr) {
47  ival_mgr.output(out);
48  return out;
49 }
50 
void set_event_queue(EventQueue *event_queue)
Specifies a custom event queue to be used for throwing done events from intervals as they finish...
A queue of pending events.
Definition: eventQueue.h:32
This object holds a number of currently-playing intervals and is responsible for advancing them each ...
EventQueue * get_event_queue() const
Returns the custom event queue to be used for throwing done events from intervals as they finish...