Skip to content

Commit

Permalink
Those KaraokeEditAction should for ruby only.
Browse files Browse the repository at this point in the history
  • Loading branch information
andy840119 committed Sep 29, 2023
1 parent dff6246 commit 5e662d5
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 25 deletions.
18 changes: 9 additions & 9 deletions osu.Game.Rulesets.Karaoke/KaraokeEditInputManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -68,18 +68,18 @@ public enum KaraokeEditAction
[Description("Next edit mode")]
NextEditMode,

// Edit Ruby / romaji tag.
[Description("Reduce start index")]
EditTextTagReduceStartIndex,
// Edit Ruby tag.
[Description("Reduce ruby-tag start index")]
EditRubyTagReduceStartIndex,

[Description("Increase start index")]
EditTextTagIncreaseStartIndex,
[Description("Increase ruby-tag start index")]
EditRubyTagIncreaseStartIndex,

[Description("Reduce end index")]
EditTextTagReduceEndIndex,
[Description("Reduce ruby-tag end index")]
EditRubyTagReduceEndIndex,

[Description("Increase end index")]
EditTextTagIncreaseEndIndex,
[Description("Increase ruby-tag end index")]
EditRubyTagIncreaseEndIndex,

// Edit time-tag.
[Description("Create start time-tag")]
Expand Down
8 changes: 4 additions & 4 deletions osu.Game.Rulesets.Karaoke/KaraokeRuleset.cs
Original file line number Diff line number Diff line change
Expand Up @@ -109,10 +109,10 @@ public override IEnumerable<KeyBinding> GetDefaultKeyBindings(int variant = 0) =
new KeyBinding(new[] { InputKey.Alt, InputKey.BracketRight }, KaraokeEditAction.NextEditMode),

// Edit Ruby / romaji tag.
new KeyBinding(new[] { InputKey.Z, InputKey.Left }, KaraokeEditAction.EditTextTagReduceStartIndex),
new KeyBinding(new[] { InputKey.Z, InputKey.Right }, KaraokeEditAction.EditTextTagIncreaseStartIndex),
new KeyBinding(new[] { InputKey.X, InputKey.Left }, KaraokeEditAction.EditTextTagReduceEndIndex),
new KeyBinding(new[] { InputKey.X, InputKey.Right }, KaraokeEditAction.EditTextTagIncreaseEndIndex),
new KeyBinding(new[] { InputKey.Z, InputKey.Left }, KaraokeEditAction.EditRubyTagReduceStartIndex),
new KeyBinding(new[] { InputKey.Z, InputKey.Right }, KaraokeEditAction.EditRubyTagIncreaseStartIndex),
new KeyBinding(new[] { InputKey.X, InputKey.Left }, KaraokeEditAction.EditRubyTagReduceEndIndex),
new KeyBinding(new[] { InputKey.X, InputKey.Right }, KaraokeEditAction.EditRubyTagIncreaseEndIndex),

// edit time-tag.
new KeyBinding(InputKey.Q, KaraokeEditAction.CreateStartTimeTag),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,10 @@ protected override DescriptionFormat GetSelectionDescription(RomajiTagEditStep s
Text = "Keys",
AdjustableActions = new List<KaraokeEditAction>
{
KaraokeEditAction.EditTextTagReduceStartIndex,
KaraokeEditAction.EditTextTagIncreaseStartIndex,
KaraokeEditAction.EditTextTagReduceEndIndex,
KaraokeEditAction.EditTextTagIncreaseEndIndex,
KaraokeEditAction.EditRubyTagReduceStartIndex,
KaraokeEditAction.EditRubyTagIncreaseStartIndex,
KaraokeEditAction.EditRubyTagReduceEndIndex,
KaraokeEditAction.EditRubyTagIncreaseEndIndex,
},
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -275,10 +275,10 @@ public bool OnPressed(KeyBindingPressEvent<KaraokeEditAction> e)

return e.Action switch
{
KaraokeEditAction.EditTextTagReduceStartIndex => reduceStartIndexButton.TriggerClick(),
KaraokeEditAction.EditTextTagIncreaseStartIndex => increaseStartIndexButton.TriggerClick(),
KaraokeEditAction.EditTextTagReduceEndIndex => reduceEndIndexButton.TriggerClick(),
KaraokeEditAction.EditTextTagIncreaseEndIndex => increaseEndIndexButton.TriggerClick(),
KaraokeEditAction.EditRubyTagReduceStartIndex => reduceStartIndexButton.TriggerClick(),
KaraokeEditAction.EditRubyTagIncreaseStartIndex => increaseStartIndexButton.TriggerClick(),
KaraokeEditAction.EditRubyTagReduceEndIndex => reduceEndIndexButton.TriggerClick(),
KaraokeEditAction.EditRubyTagIncreaseEndIndex => increaseEndIndexButton.TriggerClick(),
_ => false,
};
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,10 @@ protected override DescriptionFormat GetSelectionDescription(RubyTagEditStep ste
Text = "Keys",
AdjustableActions = new List<KaraokeEditAction>
{
KaraokeEditAction.EditTextTagReduceStartIndex,
KaraokeEditAction.EditTextTagIncreaseStartIndex,
KaraokeEditAction.EditTextTagReduceEndIndex,
KaraokeEditAction.EditTextTagIncreaseEndIndex,
KaraokeEditAction.EditRubyTagReduceStartIndex,
KaraokeEditAction.EditRubyTagIncreaseStartIndex,
KaraokeEditAction.EditRubyTagReduceEndIndex,
KaraokeEditAction.EditRubyTagIncreaseEndIndex,
},
}
},
Expand Down

0 comments on commit 5e662d5

Please sign in to comment.