-
Notifications
You must be signed in to change notification settings - Fork 822
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
Update the MusicKeyboard widget on maximizing. #2857
Conversation
Please Review this @meganindya @walterbender. |
I need to do a bit more testing, but I am seeing the note duration cut off at the bottom of the screen. |
Co-authored-by: Vaibhav D. Aren <[email protected]>
I will try to resolve these issues. @walterbender |
I used the white space below it so as to eliminate the need for a vertical scroll. Also, I noticed another regression (not introduced in this patch), in which, if multiple notes are selected to be played at one time, then on clicking the Play button, the sound will stop at that particular step and not go any further. screen-capture.mkr.mp4 |
I rechecked this, and this doesn't seem to be happening in my system. Can you please verify this? @walterbender MusicKeyboard.mp4 |
I was in Chromium on Fedora 33. I'll check the same with Firefox. |
I also checked this firefox and this was working fine there too. Firefox_MuiscKeyboard.mp4 |
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.
Ohh....I have checked this on Google Chrome and Mozilla Firefox. |
;-; Brave is chromium based, more of it is exactly google chrome tbh. |
I now also checked on Brave browser and got the same results: Brave.mp4 |
So, is there any error shown in the console related to this or it is just not working? @walterbender @ricknjacky |
Regarding the issue where the cells are "unclickable" in the bottom around 2/3rd part of the grid (bottom 7 to be precise), it is happening as the
In this code, |
cell.style.fontSize = Math.floor(this._cellScale * StatusMatrix.FONTSCALEFACTOR)*0.90 + "%"; | ||
if(!(this.isMaximized)){ | ||
cell.style.fontSize = | ||
Math.floor(this._cellScale * StatusMatrix.FONTSCALEFACTOR) * 0.9 + "%"; |
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.
Status is different widget afaik, why is this file a part of this PR?
Sorry, I missed this file previously. But please do tell me If I have missed something and what has this file to do with maximizing musickeyboard widget in particular.
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.
Yeah, status is a different widget. Actually, after #2838 was merged, as always I deleted that branch and then realized that I left debug statements (that I used for #2838) in the code and did not Prettify the code. So just to rectify that, I did not feel that a different PR would be needed. Thus, I committed those changes first, so this could be rectified.
@@ -120,7 +120,8 @@ class StatusMatrix { | |||
const row = header.insertRow(); | |||
|
|||
cell = row.insertCell(); // i + 1); | |||
cell.style.fontSize = Math.floor(this._cellScale * StatusMatrix.FONTSCALEFACTOR)*0.90 + "%"; | |||
cell.style.fontSize = | |||
Math.floor(this._cellScale * StatusMatrix.FONTSCALEFACTOR) * 0.9 + "%"; |
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.
can you please explain what you've done here?
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.
As I mentioned in your previous review, this is just prettifying the code (as mentioned in #2609) and removing debug statement.
@@ -176,7 +177,8 @@ class StatusMatrix { | |||
if (_THIS_IS_MUSIC_BLOCKS_) { | |||
const row = header.insertRow(); | |||
cell = row.insertCell(); | |||
cell.style.fontSize = Math.floor(this._cellScale * StatusMatrix.FONTSCALEFACTOR)*0.90 + "%"; | |||
cell.style.fontSize = | |||
Math.floor(this._cellScale * StatusMatrix.FONTSCALEFACTOR) * 0.9 + "%"; |
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.
^^same here
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, is there any error shown in the console related to this or it is just not working? @walterbender @ricknjacky
Also, can you suggest how should I test this as on my system it works fine on all browsers?
Not sure what you mean by working fine, I tested again and
- there is still lot of unused space at the bottom
- maximize funcn doesn't work as it should, instead it malfunctions
Bug.mp4
See console log on the right of the screen
Thanks for the feedback. |
I am trying to figure out this. Don't know why it is working on my device. @walterbender |
Since it is not maximized until a new note is added, I suspect this could be happening in the |
I've just tested on a small screen and as soon as I click on any note, it jumps to full screen. Was that the intention? |
Is it just maximizing on clicking on the keyboard? If yes, then no actually. This should not be happening. |
Yes... just clicking on the keyboard. |
Although it seems to happen even w/o your latest changes. |
The state of
Now, I can't figure out why this won't work. |
I just realized that clicking on the "full screen" button vs double-clicking on the toolbar exhibits different behavior. Double-clicking is where I experience the problem. Clicking the button works fine. The double-click handler was missing some steps. Works fine now. |
Thanks @walterbender :) |
Issue Reference: #2767, #2808
This PR improves the UI and fixes some bugs in the music keyboard widget.
Firstly, there is an unnecessary scroll bar present (as shown below) on the right-most side of the widget which can be removed without any issues.
Secondly, the main issue was on maximizing this widget, as on maximizing it there was plenty of space left which was unused but could be used for a better User Experience. This PR enables this widget to enlarge the note matrix on maximizing, so as to take full advantage of a full screen.
Before:
mkscreen-capture.1.mp4
After: (without the right-most scroll bar as mentioned above)
mkscreen-capture.2.mp4