Android屬性動畫簡寫

以下以最簡單的代碼實現view向左平移至屏幕最左邊位置

    ObjectAnimator animator = ObjectAnimator.ofFloat(view, "translationX", getX(), 0);
        animator.setDuration(100);
        animator.start();
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章