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

Fix adopting hotcue button color #12785

Merged
merged 1 commit into from
Feb 11, 2024
Merged

Fix adopting hotcue button color #12785

merged 1 commit into from
Feb 11, 2024

Conversation

daschuer
Copy link
Member

This fixes #12778

@ronso0
Copy link
Member

ronso0 commented Feb 11, 2024

This should go to 2.4

I don't understand why we didn't see this earlier. I did a lot of test for #12733

@ronso0 ronso0 changed the base branch from main to 2.4 February 11, 2024 05:15
@ronso0
Copy link
Member

ronso0 commented Feb 11, 2024

I'd like to understand what exactly went wrong, but I don't have time atm.
@daschuer could you give a brief summary before we merge?
Shall we add a hotcue color test?

@daschuer
Copy link
Member Author

Sorry, I have not tested you latest changes after my suggestions. They have introduced more checks regarding color changes via CO, like if the hotcue exists exists in slotHotcueColorChangeRequest()
When creating a new cue, the color and all properties are set before it is created, to avoid a glitch with a cue point with default values. This PR bypasses these checks in slotHotcueColorChangeRequest().

@ronso0
Copy link
Member

ronso0 commented Feb 11, 2024

Thank you, this fix LGTM.

However, I have a feeling we're working around flaws in CueControl.

FWIW the calls when setting a new hotcue are these (no guarantee for completeness):

hotcueSet
hotcueClear
  -> !pCue, return
trackCuesUpdated
loadCuesFromTrack
  -> hotcue 4
  -> pOldCue != pCue
attachCue
(detachCue)
setCue
  -> setColor #ff8000
  -> slotHotcueColorChangeRequest #ff8000
    -> !m_pCue, return
  -> set m_pCue
(detachCue for all cue controls)
attachCue
detachCue 4
resetCue 4
setCue
  -> setColor #ff8000
  -> slotHotcueColorChangeRequest #ff8000
    -> !m_pCue, return
  -> set m_pCue
setHotcueFocusIndex 3
setHotcueFocusIndex 3
setHotcueFocusIndex 3

@ronso0 ronso0 merged commit 605b091 into mixxxdj:2.4 Feb 11, 2024
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Hotcues: first time a UI button is clicked, it turns black
2 participants