Skip to content
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

Followup fix for entering/exiting Presentation mode #5360

Merged
merged 1 commit into from
Sep 30, 2014
Merged

Followup fix for entering/exiting Presentation mode #5360

merged 1 commit into from
Sep 30, 2014

Conversation

Snuffleupagus
Copy link
Collaborator

Even after PR #5359, switching to/from Presentation mode is still sluggish and I'm still seeing too much recursion printed in the console.
I've managed to track down the issue to line https://github.com/mozilla/pdf.js/blob/master/web/page_view.js#L371. It appears that for this particular case, we actually need to set noScroll = true when calling the _setScale function. (Note that it only applies to this line, and not to Presentation mode in general.)
Given the amount of refactoring done to the viewer, I'm not sure what the best way to fix this would be. However I'm submitting this patch as an easy workaround for now, but we should probably refactor this to avoid calling a "private" method directly.

/cc @yurydelendik

Even after PR 5359, switching to/from Presentation mode is still sluggish and I'm still seeing `too much recursion` printed in the console.
I've managed to track down the issue to line https://github.com/mozilla/pdf.js/blob/master/web/page_view.js#L371. It appears that for this particular case, we actually *need* to set `noScroll = true` when calling the `_setScale` function. (Note that it only applies to *this* line, and not to Presentation mode in general.)
Given the amount of refactoring done to the viewer, I'm not sure what the best way to fix this would be. However I'm submitting this patch as an easy workaround for now, but we should probably refactor this to avoid calling a "private" method directly.
yurydelendik added a commit that referenced this pull request Sep 30, 2014
Followup fix for entering/exiting Presentation mode
@yurydelendik yurydelendik merged commit f5d416c into mozilla:master Sep 30, 2014
@yurydelendik
Copy link
Contributor

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants