Add shortcut key to exit

pull/1/head
reionwong 5 years ago
parent e9f402a95c
commit d4591239c9

@ -30,10 +30,13 @@ Item {
height: size
width: size
property color hoveredColor: FishUI.Theme.darkMode ? Qt.lighter(FishUI.Theme.backgroundColor, 2)
: Qt.darker(FishUI.Theme.backgroundColor, 1.2)
property color pressedColor: FishUI.Theme.darkMode ? Qt.lighter(FishUI.Theme.backgroundColor, 1.5)
: Qt.darker(FishUI.Theme.backgroundColor, 1.3)
property color backgroundColor: "white"
property color hoveredColor: Qt.darker(backgroundColor, 1.2)
property color pressedColor: Qt.darker(backgroundColor, 1.3)
// property color hoveredColor: FishUI.Theme.darkMode ? Qt.lighter(FishUI.Theme.backgroundColor, 2)
// : Qt.darker(FishUI.Theme.backgroundColor, 1.2)
// property color pressedColor: FishUI.Theme.darkMode ? Qt.lighter(FishUI.Theme.backgroundColor, 1.5)
// : Qt.darker(FishUI.Theme.backgroundColor, 1.3)
property alias source: _image.source
property alias image: _image
signal clicked()

@ -27,9 +27,14 @@ import FishUI 1.0 as FishUI
Item {
id: control
focus: true
property rect cropRect
property bool cropping: false
Keys.enabled: true
Keys.onEscapePressed: view.quit()
function refreshImage() {
image.source = ""
image.source = "file:///tmp/cutefish-screenshot.png"
@ -189,7 +194,7 @@ Item {
}
radius: FishUI.Theme.smallRadius
color: FishUI.Theme.backgroundColor
color: "white"
MouseArea {
anchors.fill: parent

Loading…
Cancel
Save