-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix updating the measure/beat field in PlaybackToolBar
PlaybackToolbarModel emitted a "playback position changed" signal in response to notifications on the `playbackState->playbackPositionChanged()` channel. `PlaybackController` also listens to this channel, and uses it to update its `m_currentTick` value. The value is used to determine the current measure/beat position in PlaybackToolbar. The problem: the order in which channel listeners are invoked is undefined. And in this case we are unlucky: PlaybackToolbarModel's listener is invoked first, so it updates the QML view; and only after that, PlaybackController's listener is invoked, so its `m_currentTick` is updated too late. So, the QML view is updated based on the old `m_currentTick`. Solution: don't listen to `playbackState->playbackPositionChanged()` directly, but listen to a channel from PlaybackController. This channel sends the notification after updating `m_currentTick`. This commit also updates the name and signature of this channel, to better reflect its purpose. This problem was a regression, maybe caused by 8b95896, but that is an unverified conjecture.
- Loading branch information
1 parent
db9537d
commit 2f7f138
Showing
8 changed files
with
12 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters