Some ubuntu-ui-toolkit component muse be eating or overriding that MouseArea's cursor.
If you have a qml file just with that inner Rectangle + MouseArea it works fine:
""" import QtQuick 2.4 import Ubuntu.Components 1.3
MainView { objectName: "mainView" applicationName: "mouseTest"
width: units.gu(100) height: units.gu(75)
Page { header: PageHeader { id: pageHeader title: i18n.tr("Cursor Test") }
Rectangle{ anchors.fill: parent color: UbuntuColors.coolGrey
MouseArea{ anchors.fill: parent cursorShape: Qt.CrossCursor hoverEnabled: true onClicked: console.log("In MouseArea")
} } } } """
Some ubuntu-ui-toolkit component muse be eating or overriding that MouseArea's cursor.
If you have a qml file just with that inner Rectangle + MouseArea it works fine:
"""
import QtQuick 2.4
import Ubuntu.Components 1.3
MainView { Name: "mouseTest"
objectName: "mainView"
application
width: units.gu(100)
height: units.gu(75)
Page {
header: PageHeader {
id: pageHeader
title: i18n.tr("Cursor Test")
}
Rectangle{
anchors. fill: parent coolGrey
color: UbuntuColors.
}
}
}
}
"""