-
-
Notifications
You must be signed in to change notification settings - Fork 613
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
Add zoom, zoom in, & zoom out shortcuts #122
base: master
Are you sure you want to change the base?
Add zoom, zoom in, & zoom out shortcuts #122
Conversation
Good point. I didn't think about that. We can probably move zoom in/out buttons to js functions. And the buttons in
Need to be cross-checked but great if it works. |
That makes sense in regard to having them work without needing the action bar open. I can update it to reflect that. Is there a specific js file you’d like the script to be in? Lastly, would I need to open up a new PR or just amend this one? |
Probably
this PR would be fine. I'll squash the changes before merging. Important: Please check following once you complete the PR
In case of confusion, you can share the screenshot or GIF for clear understanding. |
Alright I think I got everything working how it's supposed to. Just want to clarify some things.
Just want to clarify that the tags are supposed to scale with the image, correct?
No errors show in console
|
Yes! the labeled shapes are supposed to scale along with the image. But we've previously noticed that (due to a bug which is fixed now) if you label an image, change the zoom level, relabel and zoom again then the positions of label gets changed. |
Ok, the zoom functions have been added to a file called js/common-actions.js. And cleaned up from the other files. |
So keyboard shortcuts along with direct button click are working fine? |
Thanks. So keyboard shortcuts along with direct button click are working
fine?
…On Sun, 21 Oct 2018 at 20:02, Joe B. ***@***.***> wrote:
Ok, the zoom functions have been added to a file called common-actions.js.
And cleaned up from the other files.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#122 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHVgKNnnZDpR8xbi4WZVjaXTp0wLK_CFks5unIVogaJpZM4Xbki4>
.
--
Cheers
*Amit Gupta*
|
@bonez0607 Have you get the chance to test it from buttons as well as from shortcuts? |
Sorry, it's was a busy weekend. I can take a look to double check tomorrow night. |
Sure no problem. |
So the zoom shortcuts work and the buttons work w/out an error. However, when using the keyboard shortcut the percentage increments/decrements by 20% rather than the 10% change when using the buttons. I checked to make sure nothing was being called twice, as that seemed like a potential culprit. |
I hope you must have console log to check if that function is being called twice. and You must have prevented event propagation. |
Was able to track down the offending code. Checked in Chrome, Firefox, and Safari - buttons and keyboard are working. |
great. Now you have to remove the console.log statement from your code. I'll suggest you review your code one more time, just to avoid any bug in future. |
Doh! ok - should be good. |
Thanks for the changes. I'll separately check your changes after 2 days before merge. |
Purpose / Goal
Added zoom shortcuts specified in issue #107
Hello,
This is my first real PR - so I hope I'm doing things correctly...
I added a shortcut to 'click' the zoom button. From there the user can then use shortcuts to zoom in or out. I assumed this was the desired effect since the buttons aren't mounted until the zoom button is clicked, correct?
I'm on a mac and was having issues (even with existing shortcuts) with
e.key == [appropriate key] && e.altKey
working. However when I used the symbol created when pressing both alt and the event key it worked as expected.For example
e.key == '=' && e.altKey
didn't work bute.key == '≠' did
for the alt + '+' shortcut.If I need to change to the previous formatting of e.key && e.altKey let me know and I can change back. I checked the shortcuts in Chrome, Firefox and Safari.
There were also a couple of quick mis commented items that I fixed.
Type
Please mention the type of PR