2018-08-21 14:57:15 +00:00
|
|
|
import QtQuick 2.9
|
2018-09-17 13:01:02 +00:00
|
|
|
import Spectral.Settings 0.1
|
2018-08-21 14:57:15 +00:00
|
|
|
|
|
|
|
MouseArea {
|
|
|
|
signal primaryClicked()
|
|
|
|
signal secondaryClicked()
|
|
|
|
|
2018-08-24 05:25:41 +00:00
|
|
|
acceptedButtons: MSettings.pressAndHold ? Qt.LeftButton : (Qt.LeftButton | Qt.RightButton)
|
2018-09-04 13:13:14 +00:00
|
|
|
|
2018-08-21 14:57:15 +00:00
|
|
|
onClicked: mouse.button == Qt.RightButton ? secondaryClicked() : primaryClicked()
|
2018-08-24 05:25:41 +00:00
|
|
|
onPressAndHold: MSettings.pressAndHold ? secondaryClicked() : {}
|
2018-08-21 14:57:15 +00:00
|
|
|
}
|