summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFabian Bumberger <fbumberger@rim.com>2012-11-15 11:16:23 (GMT)
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-11-16 12:10:40 (GMT)
commitdd95ad45ad228cebd5c067a60859b45e569dca5f (patch)
tree1d572748c1dd9d5e0da1ebcb3d6802fa45a9f488
parent62d159e977b137402da17a0eb3866af958dc4fca (diff)
downloadQt-dd95ad45ad228cebd5c067a60859b45e569dca5f.zip
Qt-dd95ad45ad228cebd5c067a60859b45e569dca5f.tar.gz
Qt-dd95ad45ad228cebd5c067a60859b45e569dca5f.tar.bz2
Blackberry fixed crash when plugging in a secondary display.
This bug is only in the Qt4 version of the plugin. In Qt5 attaching a screen works just fine. Change-Id: I45ebc51c6da9999e7d2e4f453379fbc18dd6f857 Reviewed-by: James Turner <james.turner@kdab.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
-rw-r--r--src/plugins/platforms/blackberry/qbbintegration.cpp6
-rw-r--r--src/plugins/platforms/blackberry/qbbintegration.h2
2 files changed, 4 insertions, 4 deletions
diff --git a/src/plugins/platforms/blackberry/qbbintegration.cpp b/src/plugins/platforms/blackberry/qbbintegration.cpp
index e329bbe..5137431 100644
--- a/src/plugins/platforms/blackberry/qbbintegration.cpp
+++ b/src/plugins/platforms/blackberry/qbbintegration.cpp
@@ -361,13 +361,13 @@ void QBBIntegration::createDisplays()
if (!isAttached)
continue;
- createDisplay(displays[i], i == 0);
+ createDisplay(displays[i], i);
} // of displays iteration
}
-void QBBIntegration::createDisplay(screen_display_t display, bool isPrimary)
+void QBBIntegration::createDisplay(screen_display_t display, int screenIndex)
{
- QBBScreen *screen = new QBBScreen(mContext, display, isPrimary);
+ QBBScreen *screen = new QBBScreen(mContext, display, screenIndex);
mScreens.append(screen);
QObject::connect(mScreenEventHandler, SIGNAL(newWindowCreated(screen_window_t)),
diff --git a/src/plugins/platforms/blackberry/qbbintegration.h b/src/plugins/platforms/blackberry/qbbintegration.h
index b524950..921695a 100644
--- a/src/plugins/platforms/blackberry/qbbintegration.h
+++ b/src/plugins/platforms/blackberry/qbbintegration.h
@@ -88,7 +88,7 @@ public:
QBBScreen *screenForNative(screen_display_t screen) const;
- void createDisplay(screen_display_t display, bool isPrimary);
+ void createDisplay(screen_display_t display, int screenIndex);
void removeDisplay(QBBScreen *screen);
private:
QBBScreen *primaryDisplay() const;