summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/PagedView.java
diff options
context:
space:
mode:
authorSunny Goyal <sunnygoyal@google.com>2015-12-01 22:49:42 +0000
committerandroid-build-merger <android-build-merger@google.com>2015-12-01 22:49:42 +0000
commitcc4c22008c287418e7701eaef12782f27f3f1e26 (patch)
tree637edf265551a5e3d48f20f347a440eaaca2b06f /src/com/android/launcher3/PagedView.java
parentdc893151f0b5fc751a2bfc77946f833a985cc78f (diff)
parent9326461652c36c2ddd888d1452cf7f075a391868 (diff)
downloadandroid_packages_apps_Trebuchet-cc4c22008c287418e7701eaef12782f27f3f1e26.tar.gz
android_packages_apps_Trebuchet-cc4c22008c287418e7701eaef12782f27f3f1e26.tar.bz2
android_packages_apps_Trebuchet-cc4c22008c287418e7701eaef12782f27f3f1e26.zip
Adding margin to Drag layer instead of checking for right insets at every place
am: 9326461652 * commit '9326461652c36c2ddd888d1452cf7f075a391868': Adding margin to Drag layer instead of checking for right insets at every place
Diffstat (limited to 'src/com/android/launcher3/PagedView.java')
-rw-r--r--src/com/android/launcher3/PagedView.java11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/com/android/launcher3/PagedView.java b/src/com/android/launcher3/PagedView.java
index d053d4dd5..68208c644 100644
--- a/src/com/android/launcher3/PagedView.java
+++ b/src/com/android/launcher3/PagedView.java
@@ -187,9 +187,6 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc
protected final Rect mInsets = new Rect();
protected final boolean mIsRtl;
- // When set to true, full screen content and overscroll effect is shited inside by right inset.
- protected boolean mIgnoreRightInset;
-
// Edge effect
private final LauncherEdgeEffect mEdgeGlowLeft = new LauncherEdgeEffect();
private final LauncherEdgeEffect mEdgeGlowRight = new LauncherEdgeEffect();
@@ -801,8 +798,7 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc
childWidthMode = MeasureSpec.EXACTLY;
childHeightMode = MeasureSpec.EXACTLY;
- childWidth = getViewportWidth() - mInsets.left
- - (mIgnoreRightInset ? mInsets.right : 0);
+ childWidth = getViewportWidth() - mInsets.left - mInsets.right;
childHeight = getViewportHeight();
}
if (referenceChildWidth == 0) {
@@ -1157,9 +1153,8 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc
getEdgeVerticalPostion(sTmpIntPoint);
- int width = mIgnoreRightInset ? (display.width() - mInsets.right) : display.width();
- canvas.translate(sTmpIntPoint[0] - display.top, -width);
- mEdgeGlowRight.setSize(sTmpIntPoint[1] - sTmpIntPoint[0], width);
+ canvas.translate(sTmpIntPoint[0] - display.top, -display.width());
+ mEdgeGlowRight.setSize(sTmpIntPoint[1] - sTmpIntPoint[0], display.width());
if (mEdgeGlowRight.draw(canvas)) {
postInvalidateOnAnimation();
}