← Back to team overview

touch-packages team mailing list archive

[Bug 1480767] Re: Double icons on Page head

 

The MainView creates the header for the app and shows the title and
header actions, depending on which page is currently active.

Each app should have only one MainView. Inside that you can put Pages,
PageStack, etc.

See also
https://developer.ubuntu.com/api/apps/qml/sdk-14.10/Ubuntu.Components.MainView/

** Changed in: ubuntu-ui-toolkit (Ubuntu)
     Assignee: (unassigned) => Tim Peeters (tpeeters)

** Changed in: ubuntu-ui-toolkit (Ubuntu)
       Status: New => Invalid

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to ubuntu-ui-toolkit in
Ubuntu.
https://bugs.launchpad.net/bugs/1480767

Title:
  Double icons on Page head

Status in ubuntu-ui-toolkit package in Ubuntu:
  Invalid

Bug description:
  I have a MainView in a PageStack, as in the code below.
  The icon for the page head action appears twice, as in the attached screenshots: portrait.png and landscape.png
  Seems to be related to the PageStack, because if I run MainPage.qml directly the problem does not reproduce.

  It is more obvious on the device, but also reproduces on the desktop.
  On the desktop, the initial window looks fine, but if you resize by increasing the width, the second icon appears. One remains in the initial position and the other one is anchored to the right of the window.

  Using a BQ Aquaris E4.5 with OS build number 24.

  ----------
  // Main.qml

  import QtQuick 2.4
  import Ubuntu.Components 1.2

  MainView {
      objectName: "mainView"

      applicationName: "example.cos64"

      width: units.gu(40)
      height: units.gu(60)

      PageStack {
          id: pageStack

          Component {
              id: mainPage
              MainPage {}
          }

          Component.onCompleted: {
              push(mainPage)
          }
      }
  }
  ----------
  // MainPage.qml

  import QtQuick 2.4
  import QtQuick.Layouts 1.1

  import Ubuntu.Components 1.2

  MainView {

      width: units.gu(40)
      height: units.gu(60)

      Page {

          title: i18n.tr("Example")

          head.actions: [
              Action {
                  id: openHelp
                  iconName: "help"
              }
          ]
      }
  }
  ----------

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-ui-toolkit/+bug/1480767/+subscriptions


References