webengine/osswebengine/WebCore/platform/Timer.cpp
changeset 5 10e98eab6f85
parent 0 dd21522fd290
child 11 c8a366e56285
equal deleted inserted replaced
1:7c90e6132015 5:10e98eab6f85
    47 
    47 
    48 static bool deferringTimers;
    48 static bool deferringTimers;
    49 static Vector<TimerBase*>* timerHeap;
    49 static Vector<TimerBase*>* timerHeap;
    50 static HashSet<const TimerBase*>* timersReadyToFire;
    50 static HashSet<const TimerBase*>* timersReadyToFire;
    51 
    51 
       
    52 struct timerCleaner {
       
    53     ~timerCleaner() {
       
    54         if( timerHeap ) {
       
    55             delete timerHeap;
       
    56             timerHeap = 0;
       
    57         }
       
    58     }
       
    59 };
       
    60 struct timerCleaner cleanTimer;
       
    61 
    52 // ----------------
    62 // ----------------
    53 
    63 
    54 // Class to represent elements in the heap when calling the standard library heap algorithms.
    64 // Class to represent elements in the heap when calling the standard library heap algorithms.
    55 // Maintains the m_heapIndex value in the timers themselves, which allows us to do efficient
    65 // Maintains the m_heapIndex value in the timers themselves, which allows us to do efficient
    56 // modification of the heap.
    66 // modification of the heap.