ResourceManager.java should take DIP scale at the time of resource loading
Reported by
ti...@chromium.org,
Dec 2 2016
|
|||||||
Issue descriptionResourceManager in Java layer obtains DIP scale during construction https://cs.chromium.org/chromium/src/ui/android/java/src/org/chromium/ui/resources/ResourceManager.java?rcl=0&l=44 and later passes it to the LayoutResource creation. Instead it should obtain the DIP scale after resource is loaded since it might have changed since the ResourceManager creation time. The Java ResourceManager is owned by ResourceManagerImpl and then by compositor_impl_android, i.e. it is not used by WebView.
,
Sep 5 2017
,
Sep 27 2017
,
Sep 28
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue. Sorry for the inconvenience if the bug really should have been left as Available. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Sep 29
I have no clue if this is still an issue. Passing this to UI/Android OWNERS.
,
Sep 29
I stumbled across this doc from timav@, which is likely related: https://docs.google.com/document/d/1Ty9PhAtkwz82dlYYR6rQkuODaf3QpBrRReXoKSOti1U/edit#
,
Oct 1
I would have naively expected that the DIP scale never changes without a process restart, so I must be missing some context here. +some other folks who may have background on this class.
,
Oct 1
I think this is supposed to deal with multi-display, but I don't know if Android currently supports multi-display DIP query or if we just use the primary and always key off of that for native. Do we have a plan to implement the doc in #6? If so we can change this but if we aren't planning on doing that any time soon it's probably not worth it here.
,
Oct 1
It seems we landed some support for this in issue 625089 . boliu@ is this issue worth pursuing?
,
Oct 2
> I would have naively expected that the DIP scale never changes without a process restart, so I must be missing some context here. That's true for chrome, but not for webview. Which means the general rule is that code in content layer and below needs to handle DIP change correctly (or as well as possible) without process restart. But ResourceManager in particular is never used in webview. So we don't have to worry about that. And looking at the code, looks like it should handle multi-display correctly. It's already using the density and context from a WindowAndroid, rather than querying some global state. So nothing to do here I think. |
|||||||
►
Sign in to add a comment |
|||||||
Comment 1 by sheriffbot@chromium.org
, Sep 4 2017Owner: ----
Status: Untriaged (was: Assigned)