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

Bug Report: Chart-Editor's playbars Open Menus without it indicating in 'Window' Dropdown #4141

Open
3 tasks done
Trofem opened this issue Feb 14, 2025 · 4 comments
Open
3 tasks done
Labels
status: pending pull request Dependent on a pull request that is currently awaiting review. type: minor bug Involves a minor bug or issue.

Comments

@Trofem
Copy link

Trofem commented Feb 14, 2025

Issue Checklist

  • I have read the Contributing Guide
  • I have checked the Issues/Discussions pages to see if my issue has already been reported
  • I have properly titled my issue

Platform

Itch.io (Downloadable Build) - Windows

Browser

None

Version

0.5.3

Description (include any images, videos, errors, or crash logs)

Chart-Editor's playbars in bottom left corner opens popup menus without it indicating in 'Window' menu.

Image

The checkmarks of corresponding menus turn on only when pressed manually on dropdown menu, isn't updating in any of playbars's pressing occurence
(variable names from ChartEditorState.hx):

playbarDifficulty (Difficulty Window)
playbarBPM (Metadata Window)

2025-02-14.19-40-34.mp4

P.S First click on inactive Window dropdown after reprodusing bug will do nothing except making check appear

Steps to Reproduce

  1. Open Chart Editor
  2. CTRL+Click on playbarDifficulty or playbarBPM
  3. Popup menus appear
  4. But when looking to 'Window' dropdown it stays unchecked.
@Trofem Trofem added status: pending triage Awaiting review. type: minor bug Involves a minor bug or issue. labels Feb 14, 2025
@Trofem
Copy link
Author

Trofem commented Feb 14, 2025

I just found out yesterday about this way of opening menus through bottom-left ctrl+left click action, and found bug accidentally too.
For fixing bug i think its only needed to make call of playbars also call code parts that changes state of corresponding checkmark, playbarBPM.onClick in ChartEditorState i guess. I am not that good in haxe.ui stuff, so this is my closest guess.

// line 2879:
playbarBPM.onClick = _ -> {
      if (FlxG.keys.pressed.CONTROL)
      {
        this.setToolboxState(CHART_EDITOR_TOOLBOX_METADATA_LAYOUT, true);
        /*
            Update Window's Dropdown toggle checks, 
            some kind of switch case or loop for check
       */
      }
      else
      {
        Conductor.instance.currentTimeChange.bpm += 1;
        this.refreshToolbox(CHART_EDITOR_TOOLBOX_METADATA_LAYOUT);
      }
    }

@Lasercar
Copy link
Contributor

Lasercar commented Feb 15, 2025

snip

Hey, thankyou for doing the legwork for this tiny issue. I'll look into fixing this.

Hmm, I'd have to add a way for it to check whether a toolbox is open or not, or a way to cancel the onchange event of the window toolbox stuff and I don't really know if there's a way or how to do either.

But then again, it's not a big deal that it just simply opens twice.

@Lasercar
Copy link
Contributor

Now has a pending PR.

@Hundrec Hundrec added status: pending pull request Dependent on a pull request that is currently awaiting review. and removed status: pending triage Awaiting review. labels Feb 15, 2025
@amyspark-ng
Copy link
Contributor

woah nice caaatch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: pending pull request Dependent on a pull request that is currently awaiting review. type: minor bug Involves a minor bug or issue.
Projects
None yet
Development

No branches or pull requests

4 participants