Submitted by: eseidel
Reviewed by: mjs
* kwq/KWQTimer.h:
* kwq/KWQTimer.mm:
(QTimer::QTimer): added parent pointer (and warning)
http://bugzilla.opendarwin.org/show_bug.cgi?id=3825
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9581
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2005-07-03 Eric Seidel <eseidel@apple.com>
+
+ Reviewed by mjs.
+
+ * kwq/KWQTimer.h:
+ * kwq/KWQTimer.mm:
+ (QTimer::QTimer): added parent pointer (and warning)
+ http://bugzilla.opendarwin.org/show_bug.cgi?id=3825
+
2005-07-03 Eric Seidel <eseidel@apple.com>
Reviewed by mjs.
class QTimer : public QObject {
public:
- QTimer();
+ QTimer(QObject *parent = 0);
~QTimer() { stop(); }
bool isActive() const;
#import "KWQTimer.h"
#import "KWQAssertions.h"
+#import "KWQLogging.h"
#import "KWQFoundationExtras.h"
// We know the Cocoa calls in this file are safe because they are all
@end
-QTimer::QTimer()
+QTimer::QTimer(QObject *parent)
: m_timer(nil), m_monitorFunction(0), m_timeoutSignal(this, SIGNAL(timeout()))
{
+ if (parent) LOG(NotYetImplemented, "Parent pointer ignored. QTimer will be leaked and may fire after parent dealloc causing crash.");
}
bool QTimer::isActive() const