Skip to content

Commit

Permalink
new animators, Landing and TakingOff
Browse files Browse the repository at this point in the history
  • Loading branch information
daimajia committed Aug 8, 2014
1 parent 7c66c6b commit d4b96ae
Show file tree
Hide file tree
Showing 7 changed files with 53 additions and 8 deletions.
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@
# org.gradle.parallel=true


VERSION_NAME=1.1.1
VERSION_CODE=12
VERSION_NAME=1.1.2
VERSION_CODE=13
GROUP=com.daimajia.androidanimations

POM_DESCRIPTION=Collect android animations
Expand Down
4 changes: 2 additions & 2 deletions library/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ android {
applicationId "com.daimajia.androidanimations.library"
minSdkVersion 8
targetSdkVersion 20
versionCode 12
versionName "1.1.1"
versionCode 13
versionName "1.1.2"
}
buildTypes {
release {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ public BaseViewAnimator setInterpolator(Interpolator interpolator) {
}

public long getDuration() {
return mDuration
return mDuration;
}

public AnimatorSet getAnimatorAgent() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
package com.daimajia.androidanimations.library;

import com.daimajia.androidanimations.library.attention.BounceAnimator;
import com.daimajia.androidanimations.library.attention.DropOutAnimator;
import com.daimajia.androidanimations.library.attention.FlashAnimator;
import com.daimajia.androidanimations.library.attention.PulseAnimator;
import com.daimajia.androidanimations.library.attention.RubberBandAnimator;
Expand Down Expand Up @@ -75,6 +74,9 @@
import com.daimajia.androidanimations.library.specials.HingeAnimator;
import com.daimajia.androidanimations.library.specials.RollInAnimator;
import com.daimajia.androidanimations.library.specials.RollOutAnimator;
import com.daimajia.androidanimations.library.specials.in.DropOutAnimator;
import com.daimajia.androidanimations.library.specials.in.LandingAnimator;
import com.daimajia.androidanimations.library.specials.out.TakingOffAnimator;
import com.daimajia.androidanimations.library.zooming_entrances.ZoomInAnimator;
import com.daimajia.androidanimations.library.zooming_entrances.ZoomInDownAnimator;
import com.daimajia.androidanimations.library.zooming_entrances.ZoomInLeftAnimator;
Expand All @@ -88,6 +90,10 @@

public enum Techniques {

DropOut(DropOutAnimator.class),
Landing(LandingAnimator.class),
TakingOff(TakingOffAnimator.class),

Flash(FlashAnimator.class),
Pulse(PulseAnimator.class),
RubberBand(RubberBandAnimator.class),
Expand All @@ -98,7 +104,6 @@ public enum Techniques {
Tada(TadaAnimator.class),
StandUp(StandUpAnimator.class),
Wave(WaveAnimator.class),
DropOut(DropOutAnimator.class),

Hinge(HingeAnimator.class),
RollIn(RollInAnimator.class),
Expand Down Expand Up @@ -160,6 +165,8 @@ public enum Techniques {
ZoomOutRight(ZoomOutRightAnimator.class),
ZoomOutUp(ZoomOutUpAnimator.class);



private Class animatorClazz;

private Techniques(Class clazz) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.daimajia.androidanimations.library.attention;
package com.daimajia.androidanimations.library.specials.in;

import android.view.View;

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package com.daimajia.androidanimations.library.specials.in;

import android.view.View;

import com.daimajia.androidanimations.library.BaseViewAnimator;
import com.daimajia.easing.Glider;
import com.daimajia.easing.Skill;
import com.nineoldandroids.animation.ObjectAnimator;

public class LandingAnimator extends BaseViewAnimator{
@Override
protected void prepare(View target) {
getAnimatorAgent().playTogether(
Glider.glide(Skill.QuintEaseOut, getDuration(), ObjectAnimator.ofFloat(target, "scaleX", 1.5f, 1f)),
Glider.glide(Skill.QuintEaseOut, getDuration(), ObjectAnimator.ofFloat(target, "scaleY", 1.5f, 1f)),
Glider.glide(Skill.QuintEaseOut, getDuration(), ObjectAnimator.ofFloat(target, "alpha", 0, 1f))
);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package com.daimajia.androidanimations.library.specials.out;

import android.view.View;

import com.daimajia.androidanimations.library.BaseViewAnimator;
import com.daimajia.easing.Glider;
import com.daimajia.easing.Skill;
import com.nineoldandroids.animation.ObjectAnimator;

public class TakingOffAnimator extends BaseViewAnimator {
@Override
protected void prepare(View target) {
getAnimatorAgent().playTogether(
Glider.glide(Skill.QuintEaseOut, getDuration(), ObjectAnimator.ofFloat(target, "scaleX", 1f, 1.5f)),
Glider.glide(Skill.QuintEaseOut, getDuration(), ObjectAnimator.ofFloat(target, "scaleY", 1f, 1.5f)),
Glider.glide(Skill.QuintEaseOut, getDuration(), ObjectAnimator.ofFloat(target, "alpha", 1, 0))
);
}
}

0 comments on commit d4b96ae

Please sign in to comment.