-
Notifications
You must be signed in to change notification settings - Fork 819
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
FIXES #4070 The Pitch piemenu do not remember the last selected accidental value #4071
base: master
Are you sure you want to change the base?
Conversation
|
||
// Store the selected accidental in the block for later use. | ||
prevAccidental = selection["attr"]; | ||
block.prevAccidental = prevAccidental; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This retains the value during the session, but not between sessions. Maybe we need to think about saving/restoring this attribute with the block (much the way we do with the start block attributes).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Like do you want the pitch block to save the data for last session like this @walterbender
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So what should I change in this pr regarding the issue @walterbender
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you don't need to change anything in what you have already done, but in this function in activity.js, this.prepareExport
, you can see how some attributes are stored in the start
block. We'll want to do something similar with the pitch block. And then restore the state on project import (in loadNewBlocks
in blocks.js
.
But maybe all that complexity can be dealt with in a separate PR. Let me test this code as is.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay @walterbender i ll make a new PR in regards to these changes and will resolve soon.
@walterbender yaa i see this issue will make it resolved soon |
fixing issue #4070
Now the pitch piemenu remembers the last selected accidental value
custom pitch selected ;
the wheel represents the same value as selected ;