← Back to team overview

ubuntu-sdk-team team mailing list archive

[Merge] lp:~daker/ubuntu-ui-toolkit/fix.1665938 into lp:ubuntu-ui-toolkit/staging

 

Adnane Belmadiaf has proposed merging lp:~daker/ubuntu-ui-toolkit/fix.1665938 into lp:ubuntu-ui-toolkit/staging.

Commit message:
Fix Pagestack backAction icon in RTL mode

Requested reviews:
  Ubuntu SDK team (ubuntu-sdk-team)
Related bugs:
  Bug #1665938 in ubuntu-ui-toolkit (Ubuntu): "Pagestack backAction should point to the right in RTL"
  https://bugs.launchpad.net/ubuntu/+source/ubuntu-ui-toolkit/+bug/1665938

For more details, see:
https://code.launchpad.net/~daker/ubuntu-ui-toolkit/fix.1665938/+merge/317804

I used the "next" icon in RTL mode since the arrow needs to points to the right instead of the left
-- 
Your team Ubuntu SDK team is requested to review the proposed merge of lp:~daker/ubuntu-ui-toolkit/fix.1665938 into lp:ubuntu-ui-toolkit/staging.
=== modified file 'src/imports/Components/1.3/PageStack.qml'
--- src/imports/Components/1.3/PageStack.qml	2016-05-25 12:48:10 +0000
+++ src/imports/Components/1.3/PageStack.qml	2017-02-20 21:17:23 +0000
@@ -219,8 +219,10 @@
         // used when the Page has a Page.header property set.
         id: backAction
         visible: pageStack.depth > 1
-        iconName: "back"
-        text: "Back"
+        // in RTL mode the icon should point to the right, so we will
+        // just "next" as "back" in to avoid API changes to Action
+        iconName: Qt.application.layoutDirection == Qt.RightToLeft ? "next": "back"
+        text: i18n.tr("Back")
         onTriggered: pageStack.pop()
         objectName: "pagestack_back_action"
     }


References