diff options
author | Be <be@mixxx.org> | 2021-09-30 10:44:39 -0500 |
---|---|---|
committer | Be <be@mixxx.org> | 2021-09-30 10:44:39 -0500 |
commit | f58f68ebb52c3d9af85101985a99800f0dd47487 (patch) | |
tree | b8b68d79b3355707fab512226d846f64c5a43529 /res/qml/EqKnob.qml | |
parent | 4d7bde1d00dd445b47edb46d93709a52bfc5a0fd (diff) | |
parent | 49e87f9889b9eef5c9cc7d13fa9395555b7729eb (diff) |
Merge remote-tracking branch 'upstream/main' into effects_refactoring
Diffstat (limited to 'res/qml/EqKnob.qml')
-rw-r--r-- | res/qml/EqKnob.qml | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/res/qml/EqKnob.qml b/res/qml/EqKnob.qml new file mode 100644 index 0000000000..e3102de623 --- /dev/null +++ b/res/qml/EqKnob.qml @@ -0,0 +1,54 @@ +import "." as Skin +import Mixxx 0.1 as Mixxx +import Mixxx.Controls 0.1 as MixxxControls +import QtQuick 2.12 +import "Theme" + +Rectangle { + id: root + + property alias knob: knob + property string statusGroup: root.knob.group // required + property string statusKey // required + + color: Theme.knobBackgroundColor + width: 56 + height: 56 + radius: 5 + + Skin.ControlKnob { + id: knob + + anchors.centerIn: root + width: 48 + height: 48 + } + + Mixxx.ControlProxy { + id: statusControl + + group: root.statusGroup + key: root.statusKey + } + + Rectangle { + id: statusButton + + anchors.left: root.left + anchors.bottom: root.bottom + anchors.leftMargin: 4 + anchors.bottomMargin: 4 + width: 8 + height: width + radius: width / 2 + border.width: 1 + border.color: Theme.buttonNormalColor + color: statusControl.value ? knob.color : "transparent" + + TapHandler { + onTapped: statusControl.value = !statusControl.value + } + + } + +} |