-
Notifications
You must be signed in to change notification settings - Fork 10k
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
[api-minor] Improve how we disable PDFThumbnailView.setImage
for documents with Optional Content
#15215
[api-minor] Improve how we disable PDFThumbnailView.setImage
for documents with Optional Content
#15215
Conversation
…methods To ensure that this data cannot be directly changed from the outside, use private fields/methods now that those are available.
be21d36
to
e9120f3
Compare
/botio integrationtest |
…e "outside" Given that Optional Content visibility is only intended/supported to be updated via the `OptionalContentConfig.setVisibility`-method, this patch actually enforces that now. Note that this will be used by the next patch in the series, and will help prevent inconsistent state in the `OptionalContentConfig`-class. *Please note:* This patch also uncovered a pre-existing bug, related to iterating through the visibility groups in the constructor, for the `baseState === "OFF"` case.
…he initial Optional Content visibility state This will allow us to improve the `PDFThumbnailView.setImage` handling in the viewer, and thanks to the added caching this should be reasonbly efficient.
… Optional Content (PR 12170 follow-up) Rather than always disable `PDFThumbnailView.setImage` as soon as user has changed the visibility of the Optional Content, we can utilize the new method added in the previous patch to improve thumbnail performance. Note in particular how, in the old code, even *resetting* of the Optional Content to its default state wouldn't enable `PDFThumbnailView.setImage` again. While slightly unrelated, this patch also removes the `PDFThumbnailViewer._optionalContentConfigPromise`-property since it's completely unused.
This code is completely unnecessary in e.g. the Firefox PDF Viewer.
dc84310
to
37dc0e7
Compare
From: Bot.io (Linux m4)ReceivedCommand cmd_test from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.241.84.105:8877/1f36ee9bec8cfc3/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_test from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.193.163.58:8877/b16d1fb576842b5/output.txt |
From: Bot.io (Linux m4)FailedFull output at http://54.241.84.105:8877/1f36ee9bec8cfc3/output.txt Total script time: 25.65 mins
Image differences available at: http://54.241.84.105:8877/1f36ee9bec8cfc3/reftest-analyzer.html#web=eq.log |
From: Bot.io (Windows)FailedFull output at http://54.193.163.58:8877/b16d1fb576842b5/output.txt Total script time: 29.09 mins
Image differences available at: http://54.193.163.58:8877/b16d1fb576842b5/reftest-analyzer.html#web=eq.log |
Thanks! |
Please refer to the individual commit messages for additional information.
Note that I'm not sure if the second commit is actually necessary, and it may quite frankly be overkill here. (More generally I think it's interesting, since it shows one way of effectively making a method "private" despite it still being available from the outside.)