From 41da349eb2bf25dba633578068b9bf2a7e7a6e24 Mon Sep 17 00:00:00 2001 From: Eike Ziller Date: Thu, 25 Aug 2011 12:33:08 +0200 Subject: uikit: get rid of the "min 30fps" for event handling. This is actually not needed if done correctly. --- src/plugins/platforms/uikit/quikiteventloop.mm | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/src/plugins/platforms/uikit/quikiteventloop.mm b/src/plugins/platforms/uikit/quikiteventloop.mm index 7df7ec8..152a34a 100644 --- a/src/plugins/platforms/uikit/quikiteventloop.mm +++ b/src/plugins/platforms/uikit/quikiteventloop.mm @@ -67,7 +67,6 @@ - (id)initWithEventLoopIntegration:(QUIKitEventLoop *)integration; -- (void)processEvents; - (void)processEventsAndSchedule; @end @@ -160,17 +159,11 @@ return self; } -- (void)processEvents -{ - QPlatformEventLoopIntegration::processEvents(); -} - - (void)processEventsAndSchedule { QPlatformEventLoopIntegration::processEvents(); - qint64 nextTime = qMin((qint64)33, mIntegration->nextTimerEvent()); // at least 30fps NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; - NSDate *nextDate = [[NSDate date] dateByAddingTimeInterval:((double)nextTime/1000)]; + NSDate *nextDate = [[NSDate date] dateByAddingTimeInterval:((double)mIntegration->nextTimerEvent()/1000.)]; [mIntegration->mTimer setFireDate:nextDate]; [pool release]; } @@ -211,7 +204,7 @@ void QUIKitEventLoop::quitEventLoop() void QUIKitEventLoop::qtNeedsToProcessEvents() { - [mHelper performSelectorOnMainThread:@selector(processEvents) withObject:nil waitUntilDone:NO]; + [mHelper performSelectorOnMainThread:@selector(processEventsAndSchedule) withObject:nil waitUntilDone:NO]; } static UIReturnKeyType keyTypeForObject(QObject *obj) -- cgit v0.12