Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deere: deactivate beatgrid edit controls if BPM is locked + LateNight fix #13323

Merged
merged 5 commits into from
Jun 4, 2024
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
786 changes: 388 additions & 398 deletions res/skins/Deere/deck_text_row.xml

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions res/skins/Deere/icon/ic_bpm_locked_48px.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions res/skins/Deere/icon/ic_bpm_unlocked_48px.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
35 changes: 35 additions & 0 deletions res/skins/Deere/left_right_1state_button_optional.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<!DOCTYPE template>
<!--
Description:
Wrapper for a single-state left-click and right-click push button.
Is cover if `cover_control` is > 0
Variables:
ObjectName: The object name.
Size: the button size.
state_0_text:
state_0_pressed:
state_0_unpressed:
left_connection_control:
-->
<Template>
<WidgetGroup><!-- Curr. pos & Lock -->
<Layout>stacked</Layout>
<MinimumSize><Variable name="MinimumSize"/></MinimumSize>
<MaximumSize><Variable name="MaximumSize"/></MaximumSize>
<SizePolicy><Variable name="SizePolicy"/></SizePolicy>
<Children>
<Label>
<TooltipId><Variable name="TooltipId"/></TooltipId>
<ObjectName><Variable name="CoverName"/></ObjectName>
<MinimumSize><Variable name="MinimumSize"/></MinimumSize>
<MaximumSize><Variable name="MaximumSize"/></MaximumSize>
<SizePolicy><Variable name="SizePolicy"/></SizePolicy>
<Connection>
<BindProperty>visible</BindProperty>
<ConfigKey><Variable name="cover_control"/></ConfigKey>
</Connection>
</Label>
<Template src="skin:left_right_1state_button.xml"/>
</Children>
</WidgetGroup>
</Template>
51 changes: 40 additions & 11 deletions res/skins/Deere/style.qss
Original file line number Diff line number Diff line change
Expand Up @@ -1111,37 +1111,40 @@ WBeatSpinBox,

/* Start editable widgets in decks */
/* emphasize editable widgets on hover */
#BpmKeyEditRowCollapsed:hover,
#BpmKeyEditRowExpanded:hover,
#BpmKeyEditTriggerRow:hover,
#PositionGutter:hover,
#PlayPositionTextSmall:hover,
#StarratingGutter:hover,
WTrackProperty:hover {
background-color: rgba(255, 102, 0, 128);
}
#BpmKeyEditRowCollapsed:hover,
#BpmKeyEditRowExpanded:hover,
WTrackProperty[selected="true"] {
border: 1px solid #FF6600;
}

#BpmKeyEditRowCollapsed {
#BpmKeyEditTriggerRow[value="1"] {
qproperty-layoutAlignment: 'AlignCenter';
/* emphasize active widget */
border: 1px solid #666666;
border-left: 0px;
}

#BpmKeyEditRowExpanded {
/* emphasize active widget */
border: 1px solid #FF6600;
background-color: rgba(255, 102, 0, 64);
border-right: 0px;
color: #D6D6D6;
}

#BpmKeyEditTrigger {
/* make trigger button transparent */
background-color: none;
border: none;
border-radius: 0px;
}
#BpmKeyEditTrigger[value="1"] {
border: 1px solid #FF6600;
border-left: 0px;
}

#BpmKeyEditRowControls {
Expand All @@ -1153,6 +1156,31 @@ WTrackProperty:hover {
qproperty-layoutSpacing: 2;
}

#BeatEditCover {
background-color: rgba(51, 51, 51, 120);
}

/* This defines the width of the key/cents display per selected notation. */
#KeyLabelExpander[highlight="0"], /* Invalid */
#KeyLabelExpander[highlight="1"], /* Custom */
#KeyLabelExpander[highlight="2"], /* OpenKey */
#KeyLabelExpander[highlight="3"] { /* Lancelot */
/* Widest key is 12A + cents */
min-width: 97px;
max-width: 97px;
}
#KeyLabelExpander[highlight="4"] { /*Traditional */
/* The widest key is "D#m/Ebm" + cents */
min-width: 138px;
max-width: 138px;
}
#KeyLabelExpander[highlight="5"], /* OpenKeyAndTraditional */
#KeyLabelExpander[highlight="6"] { /* LancelotAndTraditional */
/* The widest key is "7m (D#m/Ebm)" + cents */
min-width: 175px;
max-width: 175px;
}

#HotcueShiftButtons {
qproperty-layoutSpacing: 2;
}
Expand All @@ -1161,11 +1189,10 @@ WTrackProperty:hover {
padding-right: 1px;
}

#BpmKeyInfoShow {
#BpmKeyInfoShowHide[highlight="0"] {
image: url(skin:/../Deere/icon/ic_chevron_left_24x48px.svg) center center;
}

#BpmKeyInfoHide {
#BpmKeyInfoShowHide[highlight="1"] {
image: url(skin:/../Deere/icon/ic_chevron_right_24x48px.svg) center center;
}
/* End editable widgets in decks */
Expand Down Expand Up @@ -1654,7 +1681,8 @@ WWidgetGroup {
*******************************************************************************/

WPushButton,
WEffectChainPresetButton {
WEffectChainPresetButton,
#BpmLockToggle[value="1"] {
color: #D2D2D2;
background-color: #4B4B4B;
border: 1px solid #4B4B4B;
Expand All @@ -1664,7 +1692,8 @@ WEffectChainPresetButton {

WPushButton:hover,
#PlayToggle:hover,
WEffectChainPresetButton:hover {
WEffectChainPresetButton:hover,
#BpmLockToggle[value="1"]:hover {
color: #D2D2D2;
background-color: #5F5F5F;
border: 1px solid #5F5F5F;
Expand Down
20 changes: 4 additions & 16 deletions res/skins/LateNight/controls/button_1state_optional.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,29 +19,17 @@ Variables:
<Size><Variable name="Size"/></Size>
<Children>
<Label>
<TooltipId><Variable name="TooltipId"/></TooltipId>
<ObjectName><Variable name="CoverName"/></ObjectName>
<Size><Variable name="Size"/></Size>
<Connection>
<BindProperty>visible</BindProperty>
<ConfigKey><Variable name="CoverConfigKey"/></ConfigKey>
</Connection>
</Label>
<PushButton>
<TooltipId><Variable name="TooltipId"/></TooltipId>
<ObjectName><Variable name="ButtonName"/></ObjectName>
<Size><Variable name="Size"/></Size>
<NumberStates>1</NumberStates>
<State>
<Number>0</Number>
<Text><Variable name="state_0_text"/></Text>
<Alignment><Variable name="Align"/></Alignment>
<Unpressed scalemode="STRETCH">skins:LateNight/<Variable name="BtnScheme"/>/buttons/btn_<Variable name="BtnType"/>_<Variable name="BtnSize"/>.svg</Unpressed>
<Pressed scalemode="STRETCH">skins:LateNight/<Variable name="BtnScheme"/>/buttons/btn_<Variable name="BtnType"/>_<Variable name="BtnSize"/>_active.svg</Pressed>
</State>
<Connection>
<ConfigKey><Variable name="ConfigKey"/></ConfigKey>
</Connection>
</PushButton>
<Template src="skins:LateNight/controls/button_1state.xml">
<SetVariable name="ObjectName"><Variable name="ButtonName"/></SetVariable>
</Template>
</Children>
</WidgetGroup>
</Template>
27 changes: 5 additions & 22 deletions res/skins/LateNight/controls/button_1state_right_optional.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<!--
Description:
A button that has click or display controls.
Wrapper for a button that has click or display controls.
It is covered by a label if a certain CO is 1
Variables:
ObjectName : object name
Expand All @@ -19,34 +19,17 @@ Variables:
<Size><Variable name="Size"/></Size>
<Children>
<Label>
<TooltipId><Variable name="TooltipId"/></TooltipId>
<ObjectName><Variable name="CoverName"/></ObjectName>
<Size><Variable name="Size"/></Size>
<Connection>
<BindProperty>visible</BindProperty>
<ConfigKey><Variable name="CoverConfigKey"/></ConfigKey>
</Connection>
</Label>
<PushButton>
<TooltipId><Variable name="TooltipId"/></TooltipId>
<ObjectName><Variable name="ButtonName"/></ObjectName>
<Size><Variable name="Size"/></Size>
<NumberStates>1</NumberStates>
<State>
<Number>0</Number>
<Text><Variable name="state_0_text"/></Text>
<Alignment><Variable name="Align"/></Alignment>
<Unpressed scalemode="STRETCH">skins:LateNight/<Variable name="BtnScheme"/>/buttons/btn_<Variable name="BtnType"/>_<Variable name="BtnSize"/>.svg</Unpressed>
<Pressed scalemode="STRETCH">skins:LateNight/<Variable name="BtnScheme"/>/buttons/btn_<Variable name="BtnType"/>_<Variable name="BtnSize"/>_active.svg</Pressed>
</State>
<Connection>
<ConfigKey><Variable name="ConfigKey"/></ConfigKey>
<ButtonState>LeftButton</ButtonState>
</Connection>
<Connection>
<ConfigKey><Variable name="ConfigKeyRight"/></ConfigKey>
<ButtonState>RightButton</ButtonState>
</Connection>
</PushButton>
<Template src="skins:LateNight/controls/button_1state_right.xml">
<SetVariable name="ObjectName"><Variable name="ButtonName"/></SetVariable>
</Template>
</Children>
</WidgetGroup>
</Template>
4 changes: 2 additions & 2 deletions res/skins/LateNight/waveform.xml
Original file line number Diff line number Diff line change
Expand Up @@ -242,14 +242,14 @@
<Children>
<Template src="skins:LateNight/controls/button_1state_right.xml">
<SetVariable name="TooltipId">shift_cues_earlier</SetVariable>
<SetVariable name="ButtonName">HotcuesEarlier</SetVariable>
<SetVariable name="ObjectName">HotcuesEarlier</SetVariable>
<SetVariable name="Size">26f,26f</SetVariable>
<SetVariable name="ConfigKey"><Variable name="Group"/>,shift_cues_earlier</SetVariable>
<SetVariable name="ConfigKeyRight"><Variable name="Group"/>,shift_cues_earlier_small</SetVariable>
</Template>
<Template src="skins:LateNight/controls/button_1state_right.xml">
<SetVariable name="TooltipId">shift_cues_later</SetVariable>
<SetVariable name="ButtonName">HotcuesLater</SetVariable>
<SetVariable name="ObjectName">HotcuesLater</SetVariable>
<SetVariable name="Size">26f,26f</SetVariable>
<SetVariable name="ConfigKey"><Variable name="Group"/>,shift_cues_later</SetVariable>
<SetVariable name="ConfigKeyRight"><Variable name="Group"/>,shift_cues_later_small</SetVariable>
Expand Down