mirror of
https://github.com/ninjamuffin99/Funkin.git
synced 2024-11-25 08:13:45 +00:00
Merge remote-tracking branch 'origin/bugfix/chart-editor-playbar-buttons' into HEAD
This commit is contained in:
commit
f8ae4b2a62
|
@ -1845,14 +1845,21 @@ class ChartEditorState extends HaxeUIState
|
|||
**/
|
||||
function handleScrollKeybinds():Void
|
||||
{
|
||||
// Don't scroll when the cursor is over the UI.
|
||||
if (isCursorOverHaxeUI) return;
|
||||
// Don't scroll when the cursor is over the UI, unless a playbar button (the << >> ones) is pressed.
|
||||
if (isCursorOverHaxeUI && playbarButtonPressed == null) return;
|
||||
|
||||
var scrollAmount:Float = 0; // Amount to scroll the grid.
|
||||
var playheadAmount:Float = 0; // Amount to scroll the playhead relative to the grid.
|
||||
var shouldPause:Bool = false; // Whether to pause the song when scrolling.
|
||||
var shouldEase:Bool = false; // Whether to ease the scroll.
|
||||
|
||||
// Mouse Wheel = Scroll
|
||||
if (FlxG.mouse.wheel != 0 && !FlxG.keys.pressed.CONTROL)
|
||||
{
|
||||
scrollAmount = -10 * FlxG.mouse.wheel;
|
||||
shouldPause = true;
|
||||
}
|
||||
|
||||
// Up Arrow = Scroll Up
|
||||
if (upKeyHandler.activated && currentLiveInputStyle != LiveInputStyle.WASD)
|
||||
{
|
||||
|
@ -1908,13 +1915,6 @@ class ChartEditorState extends HaxeUIState
|
|||
shouldPause = true;
|
||||
}
|
||||
|
||||
// Mouse Wheel = Scroll
|
||||
if (FlxG.mouse.wheel != 0 && !FlxG.keys.pressed.CONTROL)
|
||||
{
|
||||
scrollAmount = -10 * FlxG.mouse.wheel;
|
||||
shouldPause = true;
|
||||
}
|
||||
|
||||
// Middle Mouse + Drag = Scroll but move the playhead the same amount.
|
||||
if (FlxG.mouse.pressedMiddle)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue