Skip to content

Commit

Permalink
Merge pull request #24 from shliama/hardware_acceleration_fix
Browse files Browse the repository at this point in the history
Changed API for hardware acceleration from 17 to 18.
  • Loading branch information
ozodrukh committed Apr 8, 2015
2 parents be8308d + 311d8c8 commit 63086ad
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,14 +94,14 @@ public void onAnimationEnd(Animator animation) {
}
}

static class RevealFinishedJellyBeanMr1 extends SimpleAnimationListener {
static class RevealFinishedJellyBeanMr2 extends SimpleAnimationListener {
WeakReference<RevealAnimator> mReference;
volatile Rect mInvalidateBounds;

int mLayerType;

@TargetApi(Build.VERSION_CODES.HONEYCOMB)
RevealFinishedJellyBeanMr1(RevealAnimator target, Rect bounds) {
RevealFinishedJellyBeanMr2(RevealAnimator target, Rect bounds) {
mReference = new WeakReference<>(target);
mInvalidateBounds = bounds;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,8 @@ public static SupportAnimator createCircularReveal(View view,


static Animator.AnimatorListener getRevealFinishListener(RevealAnimator target, Rect bounds){
if(SDK_INT >= 17){
return new RevealAnimator.RevealFinishedJellyBeanMr1(target, bounds);
if(SDK_INT >= 18){
return new RevealAnimator.RevealFinishedJellyBeanMr2(target, bounds);
}else if(SDK_INT >= 14){
return new RevealAnimator.RevealFinishedIceCreamSandwich(target, bounds);
}else {
Expand Down

0 comments on commit 63086ad

Please sign in to comment.