@@ -54,6 +54,7 @@ import funkin.ui.debug.charting.commands.ChartEditorCommand;
5454import funkin .ui .debug .charting .commands .CopyItemsCommand ;
5555import funkin .ui .debug .charting .commands .CutItemsCommand ;
5656import funkin .ui .debug .charting .commands .DeselectAllItemsCommand ;
57+ import funkin .ui .debug .charting .commands .DeselectAllItemsBetweenTimeCommand ;
5758import funkin .ui .debug .charting .commands .DeselectItemsCommand ;
5859import funkin .ui .debug .charting .commands .ExtendNoteLengthCommand ;
5960import funkin .ui .debug .charting .commands .FlipNotesCommand ;
@@ -67,6 +68,7 @@ import funkin.ui.debug.charting.commands.RemoveItemsCommand;
6768import funkin .ui .debug .charting .commands .RemoveNotesCommand ;
6869import funkin .ui .debug .charting .commands .RemoveStackedNotesCommand ;
6970import funkin .ui .debug .charting .commands .SelectAllItemsCommand ;
71+ import funkin .ui .debug .charting .commands .SelectAllItemsBetweenTimeCommand ;
7072import funkin .ui .debug .charting .commands .SelectItemsCommand ;
7173import funkin .ui .debug .charting .commands .SetItemSelectionCommand ;
7274import funkin .ui .debug .charting .components .ChartEditorEventSprite ;
@@ -1879,14 +1881,14 @@ class ChartEditorState extends UIState // UIState derives from MusicBeatState
18791881 var menubarItemSelectRegion : MenuItem ;
18801882
18811883 /**
1882- * The `Edit -> Select Before Cursor ` menu item.
1884+ * The `Edit -> Select Before Playhead ` menu item.
18831885 */
1884- var menubarItemSelectBeforeCursor : MenuItem ;
1886+ var menubarItemSelectBeforePlayhead : MenuItem ;
18851887
18861888 /**
1887- * The `Edit -> Select After Cursor ` menu item.
1889+ * The `Edit -> Select After Playhead ` menu item.
18881890 */
1889- var menubarItemSelectAfterCursor : MenuItem ;
1891+ var menubarItemSelectAfterPlayhead : MenuItem ;
18901892
18911893 /**
18921894 * The `Edit -> Decrease Note Snap Precision` menu item.
@@ -3114,6 +3116,10 @@ class ChartEditorState extends UIState // UIState derives from MusicBeatState
31143116
31153117 menubarItemSelectNone .onClick = _ -> performCommand (new DeselectAllItemsCommand ());
31163118
3119+ menubarItemSelectBeforePlayhead .onClick = _ -> performCommand (new SelectAllItemsBetweenTimeCommand (scrollPositionInMs + playheadPositionInMs , true , true , true ));
3120+
3121+ menubarItemSelectAfterPlayhead .onClick = _ -> performCommand (new SelectAllItemsBetweenTimeCommand (scrollPositionInMs + playheadPositionInMs , false , true , true ));
3122+
31173123 menubarItemPlaytestFull .onClick = _ -> testSongInPlayState (false );
31183124 menubarItemPlaytestMinimal .onClick = _ -> testSongInPlayState (true );
31193125
@@ -4267,7 +4273,7 @@ class ChartEditorState extends UIState // UIState derives from MusicBeatState
42674273 }
42684274
42694275 // HOME = Scroll to Top
4270- if (FlxG .keys .justPressed .HOME )
4276+ if (! FlxG . keys . pressed . SHIFT && FlxG .keys .justPressed .HOME )
42714277 {
42724278 // Scroll amount is the difference between the current position and the top.
42734279 scrollAmount = 0 - this .scrollPositionInPixels ;
@@ -4283,7 +4289,7 @@ class ChartEditorState extends UIState // UIState derives from MusicBeatState
42834289 }
42844290
42854291 // END = Scroll to Bottom
4286- if (FlxG .keys .justPressed .END )
4292+ if (! FlxG . keys . pressed . SHIFT && FlxG .keys .justPressed .END )
42874293 {
42884294 // Scroll amount is the difference between the current position and the bottom.
42894295 scrollAmount = this .songLengthInPixels - this .scrollPositionInPixels ;
@@ -5921,6 +5927,26 @@ class ChartEditorState extends UIState // UIState derives from MusicBeatState
59215927 // Deselect all items.
59225928 performCommand (new DeselectAllItemsCommand ());
59235929 }
5930+
5931+ // SHIFT + Home = Select all above playhead
5932+ if (FlxG .keys .pressed .SHIFT && FlxG .keys .justPressed .HOME )
5933+ {
5934+ // CTRL + SHIFT + Home = Inverse - deselect all above playhead
5935+ if (FlxG .keys .pressed .CONTROL )
5936+ performCommand (new DeselectAllItemsBetweenTimeCommand (scrollPositionInMs + playheadPositionInMs , true , true , true ));
5937+ else
5938+ performCommand (new SelectAllItemsBetweenTimeCommand (scrollPositionInMs + playheadPositionInMs , true , true , true ));
5939+ }
5940+
5941+ // SHIFT + End = Select all below playhead
5942+ if (FlxG .keys .pressed .SHIFT && FlxG .keys .justPressed .END )
5943+ {
5944+ // CTRL + SHIFT + Home = Inverse - deselect all below playhead
5945+ if (FlxG .keys .pressed .CONTROL )
5946+ performCommand (new DeselectAllItemsBetweenTimeCommand (scrollPositionInMs + playheadPositionInMs , false , true , true ));
5947+ else
5948+ performCommand (new SelectAllItemsBetweenTimeCommand (scrollPositionInMs + playheadPositionInMs , false , true , true ));
5949+ }
59245950 }
59255951
59265952 /**
0 commit comments