diff options
author | Morten Johan Sorvig <morten.sorvig@nokia.com> | 2012-10-17 10:16:07 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2012-10-30 07:24:17 +0100 |
commit | adb156e4dd64609ba6c0b172e9c428a79e306a7c (patch) | |
tree | 23755292b01f80d649a6cd4de854dec86f272d1f /src/plugins | |
parent | 9fb536adda4b0c87aa28b8549715e3762ad2a177 (diff) |
Cocoa: Disable touch events.
Enabling touch events has a negative impact on overall
performance. In particular, enabling touch events seems
to disable scroll event compression, resulting scroll
processing lag.
Until we find a solution where we can have both proper
scrolling and touch events we choose scrolling over
touch events. Applications that disagree can enable
touch events manually:
NSView *qtView = (NSView *)QGuiApplication::platformNativeInterface()->
nativeResourceForWindow("nsview", qtWindow);
[qtView setAcceptsTouchEvents:YES];
Change-Id: I85cdd6e8c8ed8685c6cd5418c89fed6af02887cd
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
Diffstat (limited to 'src/plugins')
-rw-r--r-- | src/plugins/platforms/cocoa/qcocoawindow.mm | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/src/plugins/platforms/cocoa/qcocoawindow.mm b/src/plugins/platforms/cocoa/qcocoawindow.mm index b9ad35600e..d6b4ee68a9 100644 --- a/src/plugins/platforms/cocoa/qcocoawindow.mm +++ b/src/plugins/platforms/cocoa/qcocoawindow.mm @@ -703,11 +703,6 @@ void QCocoaWindow::setNSWindow(NSWindow *window) name:nil // Get all notifications object:m_nsWindow]; - // ### Accept touch events by default. - // Beware that enabling touch events has a negative impact on the overall performance. - // We probably need a QWindowSystemInterface API to enable/disable touch events. - [m_contentView setAcceptsTouchEvents:YES]; - [window setContentView:m_contentView]; } |