Debian Codegraph @

src/GUI/qml/EnableDisableButton.qml

raw
1 import QtQuick 2.0
2 import FlightGear 1.0
3
4 Item {
5 id: root
6
7 width: height
8 height: icon.implicitHeight + 1
9
10 property bool enable: true
11
12 signal clicked();
13
14 Image {
15 id: icon
16 source: "image://colored-icon/hide"
17 }
18
19 MouseArea {
20 id: mouse
21 // hoverEnabled: true
22 onClicked: root.clicked();
23 anchors.fill: parent
24 }
25
26 // Text {
27 // anchors.right: root.left
28 // anchors.rightMargin: Style.margin
29 // anchors.verticalCenter: root.verticalCenter
30 // visible: mouse.containsMouse
31 // color: Style.baseTextColor
32 // font.pixelSize: Style.baseFontPixelSize
33 // text: root.enable ? qsTr("Click_to_disable")
34 // : qsTr("Click_to_enable")
35 // }
36 }