Bug 1201081 - Skip some code paths. r=sebastian, a=sylvestre
authorChenxia Liu <liuche@mozilla.com>
Tue, 20 Oct 2015 13:55:00 -0700
changeset 291294 13d1f4216f93
parent 291293 45403faf67cf
child 291295 5c768aafbaa7
push id934
push userraliiev@mozilla.com
push date2015-10-26 12:58 +0000
treeherdermozilla-release@05704e35c1d0 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssebastian, sylvestre
bugs1201081
milestone42.0
Bug 1201081 - Skip some code paths. r=sebastian, a=sylvestre
mobile/android/base/widget/RoundedCornerLayout.java
--- a/mobile/android/base/widget/RoundedCornerLayout.java
+++ b/mobile/android/base/widget/RoundedCornerLayout.java
@@ -49,16 +49,20 @@ public class RoundedCornerLayout extends
                 getResources().getDimensionPixelSize(R.dimen.doorhanger_rounded_corner_radius), metrics);
 
         setWillNotDraw(false);
     }
 
     @Override
     protected void onSizeChanged(int w, int h, int oldw, int oldh) {
         super.onSizeChanged(w, h, oldw, oldh);
+        if (cannotClipPath) {
+            return;
+        }
+
         final RectF r = new RectF(0, 0, w, h);
         path = new Path();
         path.addRoundRect(r, cornerRadius, cornerRadius, Path.Direction.CW);
         path.close();
     }
 
     @Override
     public void draw(Canvas canvas) {