|
4 | 4 | **********************************************************************/ |
5 | 5 | // TrackEndWarning: "true": when you reach the end of the track, |
6 | 6 | // the jog wheel Button will flash. "false": No flash of Jog Wheel Button |
7 | | -var TrackEndWarning = true; |
| 7 | +const TrackEndWarning = engine.getSetting("TrackEndWarning") === "true"; |
8 | 8 |
|
9 | 9 | //iCutEnabled: iCut mode will automatically cut your track with the cross fader |
10 | 10 | // when SHIFT enabled and scratching with the jog wheel |
11 | | -var iCutEnabled = true; |
| 11 | +const iCutEnabled = engine.getSetting("iCutEnabled") === "true"; |
12 | 12 |
|
13 | 13 | //activate PFL of deck on track load |
14 | | -var smartPFL = true; |
| 14 | +const smartPFL = engine.getSetting("smartPFL") === "true"; |
15 | 15 |
|
16 | 16 | //Disable Play on Sync button Double Press |
17 | | -var noPlayOnSyncDoublePress = false; |
| 17 | +const noPlayOnSyncDoublePress = engine.getSetting("noPlayOnSyncDoublePress") === "true"; |
18 | 18 |
|
19 | 19 | // Shift+Filter control behavior |
20 | 20 | // true (default) - FX parameter 4 (when the FX is focused) |
21 | 21 | // false - Channel Gain |
22 | | -var ShiftFilterFX4 = true; |
| 22 | +const ShiftFilterFX4 = engine.getSetting("ShiftFilterFX4") === "true"; |
23 | 23 |
|
24 | 24 | // allow pitch bend with wheel when wheel is not active |
25 | | -var PitchBendOnWheelOff = true; |
| 25 | +const PitchBendOnWheelOff = engine.getSetting("PitchBendOnWheelOff") === "true"; |
26 | 26 |
|
27 | 27 | /************************** |
28 | 28 | * scriptpause |
@@ -1078,36 +1078,55 @@ NumarkMixtrack3.PlayButton = function(channel, control, value, status, group) { |
1078 | 1078 | }; |
1079 | 1079 |
|
1080 | 1080 | NumarkMixtrack3.BrowseButton = function(channel, control, value, status, group) { |
1081 | | - var shifted = (NumarkMixtrack3.decks.D1.shiftKey || NumarkMixtrack3.decks. |
1082 | | - D2.shiftKey || NumarkMixtrack3.decks.D3.shiftKey || NumarkMixtrack3.decks.D4.shiftKey); |
| 1081 | + const shifted = ( |
| 1082 | + NumarkMixtrack3.decks.D1.shiftKey || NumarkMixtrack3.decks.D2.shiftKey || |
| 1083 | + NumarkMixtrack3.decks.D3.shiftKey || NumarkMixtrack3.decks.D4.shiftKey |
| 1084 | + ); |
1083 | 1085 |
|
1084 | 1086 | if (value === ON) { |
1085 | | - if (shifted) { |
1086 | | - // SHIFT + BROWSE push : directory mode -- > Open/Close selected side bar item |
1087 | | - engine.setValue("[Library]", "GoToItem", true); |
1088 | | - } else { |
1089 | | - // Browse push : maximize/minimize library view |
1090 | | - if (value === ON) { |
1091 | | - script.toggleControl("[Skin]", "show_maximized_library"); |
1092 | | - } |
1093 | | - } |
| 1087 | + if (engine.getSetting("libraryMode") === "focus") { |
| 1088 | + if (shifted) { |
| 1089 | + // SHIFT + BROWSE push : maximize/minimize library view |
| 1090 | + script.toggleControl("[Skin]", "show_maximized_library"); |
| 1091 | + } else { |
| 1092 | + // Browse push : expand sidebar item or load track when in track table |
| 1093 | + engine.setValue("[Library]", "GoToItem", true); |
| 1094 | + } |
| 1095 | + } else { // Classic mode |
| 1096 | + if (shifted) { |
| 1097 | + // SHIFT + BROWSE push : directory mode -- > Open/Close selected side bar item |
| 1098 | + engine.setValue("[Library]", "GoToItem", true); |
| 1099 | + } else { |
| 1100 | + // Browse push : maximize/minimize library view |
| 1101 | + script.toggleControl("[Skin]", "show_maximized_library"); |
| 1102 | + } |
| 1103 | + } |
1094 | 1104 | } |
1095 | 1105 | }; |
1096 | 1106 |
|
1097 | 1107 | NumarkMixtrack3.BrowseKnob = function(channel, control, value, status, group) { |
1098 | | - var shifted = ( |
| 1108 | + const shifted = ( |
1099 | 1109 | NumarkMixtrack3.decks.D1.shiftKey || NumarkMixtrack3.decks.D2.shiftKey || |
1100 | 1110 | NumarkMixtrack3.decks.D3.shiftKey || NumarkMixtrack3.decks.D4.shiftKey |
1101 | 1111 | ); |
1102 | 1112 |
|
1103 | 1113 | // value = 1 / 2 / 3 ... for positive //value = 1 / 2 / 3 |
1104 | 1114 | var nval = (value > 0x40 ? value - 0x80 : value); |
1105 | 1115 |
|
1106 | | - // SHIFT+Turn BROWSE Knob : directory mode --> select Play List/Side bar item |
1107 | | - if (shifted) { |
1108 | | - engine.setValue("[Playlist]", "SelectPlaylist", nval); |
1109 | | - } else { |
1110 | | - engine.setValue("[Playlist]", "SelectTrackKnob", nval); |
| 1116 | + if (engine.getSetting("libraryMode") === "focus") { |
| 1117 | + // SHIFT+Turn BROWSE Knob : change focus between search, track table, and sidebar |
| 1118 | + if (shifted) { |
| 1119 | + engine.setValue("[Library]", "MoveFocus", nval); |
| 1120 | + } else { |
| 1121 | + engine.setValue("[Library]", "MoveVertical", nval); |
| 1122 | + } |
| 1123 | + } else { // Classic mode |
| 1124 | + // SHIFT+Turn BROWSE Knob : directory mode --> select Play List/Side bar item |
| 1125 | + if (shifted) { |
| 1126 | + engine.setValue("[Playlist]", "SelectPlaylist", nval); |
| 1127 | + } else { |
| 1128 | + engine.setValue("[Playlist]", "SelectTrackKnob", nval); |
| 1129 | + } |
1111 | 1130 | } |
1112 | 1131 | }; |
1113 | 1132 |
|
|
0 commit comments