我有一個框架佈局,填補了電話區域(fill_parent)。另外一個imageView保存在框架佈局centreInParent中。非動畫視圖內的動畫視圖android
現在我正在使用縮放動畫來減小幀佈局的大小。但我不想讓imageView縮小尺寸,除此之外,我想將imageView中心移動到框架佈局的縮放比例。
我該如何做到這一點?
我的xml:
<FrameLayout
android:layout_height="match_parent"
android:layout_width="match_parent"
android:id="@+id/id"
android:background="@drawable/bg" >
<ImageView
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:gravity="center"
android:layout_centerInParent="true"
android:src="@drawable/bglogo"/>
</FrameLayout>
謝謝!
從已應用的動畫 –
這是邏輯框架佈局只是要ImageView的獨立。但我不知道如何使用代碼來實現這一點 – arul
只需從FrameLayout中刪除圖像視圖並使其獨立;請發佈您的xml代碼 –