2015-11-09 AndroidのUI - ImageButtonとZoomButton ┗━UI Android activity_main.xml <?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical"> <!-- 固定 --> <ImageButton android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/red"/> <!-- クリック時変更 --> <ImageButton android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/button_selector"/> <LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:gravity="center_horizontal"> <ZoomButton android:id="@+id/plus" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@android:drawable/btn_plus" /> <ZoomButton android:id="@+id/minus" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@android:drawable/btn_minus" /> </LinearLayout> <ZoomControls android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center_horizontal"> </ZoomControls></LinearLayout>