效果
使⽤
compile 'site.gemus:openingstartanimation:1.0.0' //在gradle中导⼊项⽬
OpeningStartAnimation openingStartAnimation = new OpeningStartAnimation.Builder(this) .setDrawStategy(new NormalDrawStrategy()) //设置动画效果 .create();
openingStartAnimation.show(this);
除此之外,还可以设置⽂字、图标、⼀句话描述、动画时间等等,也可以⾃定义开屏动画,开放了策略接⼝,像这样
OpeningStartAnimation openingStartAnimation = new OpeningStartAnimation.Builder(this) .setDrawStategy(new DrawStrategy() { @Override
public void drawAppName(Canvas canvas, float fraction, String name, int colorOfAppName, WidthAndHeightOfView widthAndHeightOfView) { }
@Override
public void drawAppIcon(Canvas canvas, float fraction, Drawable icon, int colorOfIcon, WidthAndHeightOfView widthAndHeightOfView) { }
@Override
public void drawAppStatement(Canvas canvas, float fraction, String statement, int colorOfStatement, WidthAndHeightOfView widthAndHeightOfView) { } })
.create();
总结
以上所述是⼩编给⼤家介绍的通过FancyView提供 Android 酷炫的开屏动画,希望对⼤家有所帮助,如果⼤家有任何疑问请给我留⾔,⼩编会及时回复⼤家的。在此也⾮常感谢⼤家对⽹站的⽀持!
因篇幅问题不能全部显示,请点此查看更多更全内容
Copyright © 2019- huatuo6.com 版权所有 湘ICP备2023023988号-11
违法及侵权请联系:TEL:199 1889 7713 E-MAIL:2724546146@qq.com
本站由北京市万商天勤律师事务所王兴未律师提供法律服务