Merge lp:~osomon/unity-2d/crash-rtl into lp:unity-2d

Proposed by Olivier Tilloy
Status: Merged
Approved by: Gerry Boland
Approved revision: 781
Merged at revision: 782
Proposed branch: lp:~osomon/unity-2d/crash-rtl
Merge into: lp:unity-2d
Diff against target: 25 lines (+11/-1)
1 file modified
places/dash.qml (+11/-1)
To merge this branch: bzr merge lp:~osomon/unity-2d/crash-rtl
Reviewer Review Type Date Requested Status
Gerry Boland Pending
Review via email: mp+82417@code.launchpad.net

Commit message

[dash] Work around a bug in QML that causes a crash when the layout is mirrored (RTL locales).

Description of the change

Notes to the reviewer:
 - This is merely a workaround to a bug in QML, it will eventually be removed once the actual bug is fixed in Qt.
 - To reproduce the crash, either run the dash with an RTL locale (e.g. with LANGUAGE=he_IL.utf8), or modify libunity-2d-private/src/unity2dapplication.cpp to comment out the code that makes the call to QApplication::setLayoutDirection(Qt::RightToLeft) conditional. Then open the dash, click on "More Apps" and then click any application.

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'places/dash.qml'
2--- places/dash.qml 2011-11-14 10:45:33 +0000
3+++ places/dash.qml 2011-11-16 15:53:40 +0000
4@@ -53,10 +53,20 @@
5 */
6 deactivateActiveLens()
7 currentPage = undefined
8- pageLoader.source = ""
9+ // Delay the following instruction by 1 millisecond using a
10+ // timer. This is enough to work around a crash that happens
11+ // when the layout is mirrored (RTL locales). See QTBUG-22776
12+ // for details.
13+ //pageLoader.source = ""
14+ delayPageLoaderReset.restart()
15 }
16 }
17 }
18+ Timer {
19+ id: delayPageLoaderReset
20+ interval: 1
21+ onTriggered: pageLoader.source = ""
22+ }
23
24 function activatePage(page) {
25 /* Always give the focus to the search entry when switching pages */

Subscribers

People subscribed via source and target branches