-
Notifications
You must be signed in to change notification settings - Fork 10.1k
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 scroll to zoom jump between 25% and 1000% #6014
Conversation
I'm sorry, but this patch seem to "break" normal scroll wheels, since the loop in |
@@ -291,7 +291,8 @@ var PDFViewerApplication = { | |||
newScale = (newScale * DEFAULT_SCALE_DELTA).toFixed(2); | |||
newScale = Math.ceil(newScale * 10) / 10; | |||
newScale = Math.min(MAX_SCALE, newScale); | |||
} while (--ticks && newScale < MAX_SCALE); | |||
--ticks; | |||
} while (ticks >= 0 && newScale < MAX_SCALE); |
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 that changing these lines to } while (--ticks > 0 && newScale < MAX_SCALE);
should achieve what you want here (similar below).
@Snuffleupagus Fixed. The actual issue is the tick count is not always integer, so |
/botio-windows preview |
From: Bot.io (Windows)ReceivedCommand cmd_preview from @Snuffleupagus received. Current queue size: 1 Live output at: http://107.22.172.223:8877/efa0c0abda89763/output.txt |
From: Bot.io (Windows)SuccessFull output at http://107.22.172.223:8877/efa0c0abda89763/output.txt Total script time: 0.95 mins Published |
Fix scroll to zoom jump between 25% and 1000%
Thanks for the patch! |
Fixes #6013