Skip to content

Commit

Permalink
QML-based components API for controllers
Browse files Browse the repository at this point in the history
  • Loading branch information
christophehenry committed Jul 10, 2024
1 parent 50b10e5 commit d051ebb
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 0 deletions.
15 changes: 15 additions & 0 deletions res/controllers/Denon-DN-S3700.midi.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version='1.0' encoding='utf-8'?>
<MixxxControllerPreset mixxxVersion="2.2.3" schemaVersion="1">
<info>
<name>Denon DN-S3700 (QML)</name>
<author>christophehenry</author>
<description>Controller preset for Denon DN-S3700 turntable</description>
</info>
<controller id="DN-S3700">
<scriptfiles>
<file filename="Denon-DN-S3700.qml" functionprefix=""/>
</scriptfiles>
<controls />
<outputs/>
</controller>
</MixxxControllerPreset>
17 changes: 17 additions & 0 deletions res/controllers/Denon-DN-S3700.qml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import QtQuick

QtObject {
id: controller
property string controllerId: ""
property bool debugMode: false

function init(controllerId, debugMode) {
controller.controllerId = controllerId
controller.debugMode = debugMode
console.log(controllerId, debugMode)
}

function shutdown() {
console.log(`Shutting down ${controller.controllerId} with debug mode ${controller.controllerId}`)
}
}

0 comments on commit d051ebb

Please sign in to comment.