Changeset 180
- Timestamp:
- Mar 1, 2008, 4:42:34 PM (17 years ago)
- Location:
- trunk/src/kernel
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kernel/qapplication.cpp
r174 r180 1026 1026 #endif 1027 1027 1028 if ( eventloop )1029 eventloop->appClosingDown();1030 1028 if ( postRList ) { 1031 1029 QVFuncList::Iterator it = postRList->begin(); … … 1082 1080 delete qt_dnd_manager; 1083 1081 #endif 1082 1083 // make sure eventloop is cleaned up after all post-routines and some object 1084 // destructors (that may still use some eventloop services such as timers) 1085 // are called. Note that this place is still not perfect as destructors of 1086 // children of QApplication will be called (by the QObject dtor) after this 1087 // method anyway and nothing prevents them from using e.g. timers. 1088 if ( eventloop ) 1089 eventloop->appClosingDown(); 1084 1090 1085 1091 qt_cleanup(); -
trunk/src/kernel/qeventloop_pm.cpp
r177 r180 764 764 // to properly destroy the window). 765 765 766 static bool timersCleanedUp = false; 767 766 768 static void cleanupTimers() // remove pending timers 767 769 { 770 timersCleanedUp = true; 771 768 772 #ifndef QT_PM_NO_DOSTIMERS 769 773 if ( !timerDict ) // no timers were used … … 792 796 timerDict = 0; 793 797 delete timerVec; 794 timerVec 798 timerVec = 0; 795 799 #endif // ifndef QT_PM_NO_DOSTIMERS 800 801 numZeroTimers = 0; 796 802 } 797 803 … … 804 810 int qStartTimer( int interval, QObject *obj ) 805 811 { 812 // ignore start timer requests after application termination has started 813 Q_ASSERT( !timersCleanedUp ); 814 if ( timersCleanedUp ) 815 return 0; 816 806 817 Q_ASSERT( obj ); 807 818 if ( !obj || interval < 0 )
Note:
See TracChangeset
for help on using the changeset viewer.