From c070eb7e43a3111b2ca1cfc2084394d3a11a75a5 Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Fri, 18 Mar 2016 12:45:51 +0100 Subject: Polish traffic light example Change-Id: I85f56f87b985ff966b975c571a399fa8f1f6e86f Reviewed-by: Diana de Sousa Reviewed-by: Leena Miettinen Reviewed-by: Erik Verbruggen --- examples/scxml/trafficlight-common/Button.qml | 28 +++++---------------------- 1 file changed, 5 insertions(+), 23 deletions(-) (limited to 'examples/scxml/trafficlight-common/Button.qml') diff --git a/examples/scxml/trafficlight-common/Button.qml b/examples/scxml/trafficlight-common/Button.qml index 36bec5f..24512ce 100644 --- a/examples/scxml/trafficlight-common/Button.qml +++ b/examples/scxml/trafficlight-common/Button.qml @@ -50,31 +50,13 @@ import QtQuick 2.5 -Item { +Image { id: button signal clicked - property string text: "hello" - Rectangle { - x: 5 - y: 5 - width: parent.width - 10 - height: parent.height - 10 - radius: 5 - color: "blue" - - Text { - anchors.fill: parent - color: "white" - text: button.text - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - } - - MouseArea { - id: mouse - anchors.fill: parent - onClicked: button.clicked() - } + MouseArea { + id: mouse + anchors.fill: parent + onClicked: button.clicked() } } -- cgit v1.2.3