Chromium Code Reviews
DescriptionFix Android tab navigation "stretch" regression.
Fixes a regression in the tab-switching UI caused by
https://codereview.chromium.org/2702093002. The root cause was my
misunderstanding of the difference between RenderWidgtHostViewAndroid's
|current_frame_size_| and the "view size" value returned by
ContentViewCoreImpl.
Note: While this change fixes the regression, there still seems to be a
small (~2 pixel) width-stretching problem (barely noticeable). However,
I confirmed that behavior is the same on current Clank stable; so, this
isn't related to the bug at-hand. Something to look into later...
This change revisits all code paths leading to CopyFromSurface() on
Android, and fixes a few other pre-existing issues:
1. RWHVAndroid::GetScaledContentBitmap(), was substituting
|current_surface_size_| instead of ContentViewCore::GetViewSize() when
the source rect argument is empty. This is actually the same bug that I
fixed above to resolve the regression. ;-)
2. RWHVAndroid::SynchronousCopyContents() does not copy the correct
source region if the rect's origin is not at the point (0,0).
3. The plumbing from CustomTabObserver (Java code) into the eventual
RWHVA::CopyFromSurface() was simplified.
BUG=698157, 698974
TEST=Manually tested on Nexus 6, per bug repro steps.
Review-Url: https://codereview.chromium.org/2734043003
Cr-Commit-Position: refs/heads/master@{#455595}
(cherry picked from commit caa6a6165d28c3bb499fc0aec9bf391c6bda1578)
Review-Url: https://codereview.chromium.org/2741993004 .
Cr-Commit-Position: refs/branch-heads/3029@{#127}
Cr-Branched-From: 939b32ee5ba05c396eef3fd992822fcca9a2e262-refs/heads/master@{#454471}
Committed: https://chromium.googlesource.com/chromium/src/+/ad1ad1825e9b3190cbc399ab868f25eb3f50997f
Patch Set 1 #Messages
Total messages: 2 (1 generated)
|