Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/controls/qml/BorderGestureArea.qml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ import org.asteroid.utils 1.0
acceptsRight: true
acceptsLeft: true
acceptsDown: true
onGestureFinished: {
onGestureFinished: (gesture) => {
if (gesture == "right") {
square.color = "red"
}
Expand Down Expand Up @@ -95,7 +95,7 @@ import org.asteroid.utils 1.0
anchors.fill: parent
acceptsUp: true
acceptsDown: true
onGestureFinished: {
onGestureFinished: (gesture) => {
if (gesture == "up") {
square.color = "green"
}
Expand Down Expand Up @@ -157,7 +157,7 @@ MouseArea {
property int _mouseStart
property variant _gestures: ["down", "left", "up", "right"]

onPressed: {
onPressed: (mouse) => {
if (mouse.x < boundary && acceptsRight) {
gesture = "right"
max = width - mouse.x
Expand All @@ -184,7 +184,7 @@ MouseArea {
gestureStarted(gesture)
}

onPositionChanged: {
onPositionChanged: (mouse) => {
var p = horizontal ? mouse.x : mouse.y
value = Math.max(Math.min(p - _mouseStart, max), -max)
}
Expand Down
2 changes: 1 addition & 1 deletion src/controls/qml/TextBase.qml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ FocusScope {

signal enterKeyClicked

Keys.onReleased: {
Keys.onReleased: (event) => {
if (event.key === Qt.Key_Return)
enterKeyClicked()
}
Expand Down