标签:exit pos 退出 target logs ati odi androi title
此篇博客只简短的介绍navigation如何添加跳转页面的动画属性,如果你还为接触了解过navigation.建议你看我另一篇博客 Android开发 navigation入门详解
in_from_right.xml
<?xml version="1.0" encoding="utf-8"?> <set xmlns:android="http://schemas.android.com/apk/res/android" android:interpolator="@android:anim/accelerate_interpolator"> <translate android:duration="200" android:fromXDelta="100%p" android:toXDelta="0%p" /> </set>
out_to_left.xml
<?xml version="1.0" encoding="utf-8"?> <set xmlns:android="http://schemas.android.com/apk/res/android" android:interpolator="@android:anim/accelerate_interpolator"> <translate android:duration="200" android:fromXDelta="0%p" android:toXDelta="-100%p" /> </set>
<fragment android:id="@+id/editManagerNameFragment" android:name="net.wt.gate.dev.user.fragment.EditManagerNameFragment" android:label="EditManagerNameFragment" tools:layout="@layout/fragment_edit_manager_name"> <action android:id="@+id/action_editManagerNameFragment_to_editManagerHeadFragment" app:destination="@id/editManagerHeadFragment" app:enterAnim="@anim/in_from_right" app:exitAnim="@anim/out_to_left" /> </fragment>
app:enterAnim="@anim/in_from_right" 碎片进入动画
app:exitAnim="@anim/out_to_left" 碎片退出动画
标签:exit pos 退出 target logs ati odi androi title
原文地址:https://www.cnblogs.com/guanxinjing/p/11555947.html