导航

2012年7月13日

摘要: 其他构造器的旋转也可参考这副图。 RotateAnimation旋转坐标系为以旋转点为坐标系(0,0)点。x轴为0度,顺时针方向旋转一定的角度。 1.RotateAnimation(fromDegrees, toDegrees) [默认以View左上角顶点为旋转点]。 X轴顺时针转动到fromDegrees为旋转的起始点, X轴顺时针转动到toDegrees为旋转的起始点。 如fromDegrees=0,toDegrees=90;为左上角顶点为旋转点。0度为起始点,90度为终点。进行旋转,旋转了90度 如fromDegrees=60,toDegrees=90;为左上角顶点为旋转点。60度为.. 阅读全文

posted @ 2012-07-13 16:08 曙光城邦 阅读(3832) 评论(0) 推荐(1) 编辑

摘要: 透明动画:1 不透明0 透明0-1中间的值为半透明度 final AlphaAnimation alphaAnimation = new AlphaAnimation(1, 0);//不透明到完全透明 alphaAnimation.setDuration(5000);//动画时间 alphaAnimation.setRepeatCount(4);//重复4次 阅读全文

posted @ 2012-07-13 15:29 曙光城邦 阅读(221) 评论(0) 推荐(0) 编辑

摘要: 1.ScaleAnimation(float fromX, float toX, float fromY, float toY) 从原始大小,放大到两倍.以左边为开始点。(fromX=1,fromY=1,toX=2,toY=2) 从零放大两倍(fromX=0,fromY=0,toX=2,toY=2) 2.ScaleAnimation(float fromX, float toX, float fromY, float toY, float pivotX, float pivotY) (pivotX,pivotY)为放大的中心点。 3.ScaleAnimation(1,2,1,2,Animat. 阅读全文

posted @ 2012-07-13 15:14 曙光城邦 阅读(1194) 评论(0) 推荐(0) 编辑

摘要: TranslateAnimation(float fromXDelta, float toXDelta, float fromYDelta, float toYDelta);从(fromXDelta,fromYDelta)坐标点移动到(toXDelta,toYDelta)坐标点。这些坐标点指的是增量坐标。如:当前View在(10,10)坐标点。 1.TranslateAnimation(0,10,0,10);即为以当前点为起始点偏移x=10,y=10的距离。效果为当前View从自己的位置移动到了自己位置下方的(10,10)点 2.TranslateAnimation(10,20,10,20); 阅读全文

posted @ 2012-07-13 11:48 曙光城邦 阅读(1758) 评论(0) 推荐(0) 编辑

摘要: 一、DecorView为整个Window界面的最顶层View。二、DecorView只有一个子元素为LinearLayout。代表整个Window界面,包含通知栏,标题栏,内容显示栏三块区域。三、LinearLayout里有两个FrameLayout子元素。 (20)为标题栏显示界面。只有一个TextView显示应用的名称。也可以自定义标题栏,载入后的自定义标题栏View将加入FrameLayout中。 (21)为内容栏显示界面。就是setContentView()方法载入的布局界面,加入其中。工具查看:1.下图为SDK中tools文件夹下hierarchyviewer bat 查看ViewT 阅读全文

posted @ 2012-07-13 10:26 曙光城邦 阅读(12772) 评论(2) 推荐(3) 编辑