← Back to team overview

touch-packages team mailing list archive

[Bug 1481147] [NEW] actons does not show in MainView

 

Public bug reported:

I created a very simple MainView app, and I got an action in the
MainView. The actions do not show up:

import QtQuick 2.0
import Ubuntu.Components 1.1

/*!
    \brief MainView with a Label and Button elements.
*/

MainView {
    // objectName for functional testing purposes (autopilot-qt5)
    objectName: "mainView"

    // Note! applicationName needs to match the "name" field of the click manifest
    applicationName: "maiviewactions.liu-xiao-guo"

    /*
     This property enables the application to change orientation
     when the device is rotated. The default is false.
    */
    //automaticOrientation: true

    // Removes the old toolbar and enables new features of the new header.
    useDeprecatedToolbar: false

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

    actions: [
        Action  {
            objectName: "action"

            // iconSource: Qt.resolvedUrl("images/avatar.jpg")
            iconName: "active-call"

            onTriggered: {
                console.log("action is clicked!");
            }
        }
    ]

    Page {
        title: i18n.tr("maiviewactions")

        Label {
            anchors.centerIn: parent
            text: "this is the label"
        }

    }
}

Thanks & best regards,
XiaoGuo

** Affects: ubuntu-ui-toolkit (Ubuntu)
     Importance: Undecided
         Status: New

-- 
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/1481147

Title:
  actons does not show in MainView

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

Bug description:
  I created a very simple MainView app, and I got an action in the
  MainView. The actions do not show up:

  import QtQuick 2.0
  import Ubuntu.Components 1.1

  /*!
      \brief MainView with a Label and Button elements.
  */

  MainView {
      // objectName for functional testing purposes (autopilot-qt5)
      objectName: "mainView"

      // Note! applicationName needs to match the "name" field of the click manifest
      applicationName: "maiviewactions.liu-xiao-guo"

      /*
       This property enables the application to change orientation
       when the device is rotated. The default is false.
      */
      //automaticOrientation: true

      // Removes the old toolbar and enables new features of the new header.
      useDeprecatedToolbar: false

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

      actions: [
          Action  {
              objectName: "action"

              // iconSource: Qt.resolvedUrl("images/avatar.jpg")
              iconName: "active-call"

              onTriggered: {
                  console.log("action is clicked!");
              }
          }
      ]

      Page {
          title: i18n.tr("maiviewactions")

          Label {
              anchors.centerIn: parent
              text: "this is the label"
          }

      }
  }

  Thanks & best regards,
  XiaoGuo

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


Follow ups