2012-01-23 4 views

답변

2

당신은 핸들로 이미지에 ImageViewsrc와 포인팅을 사용할 수 있습니다

<SlidingDrawer 
    android:id="@+id/drawer" 
    android:layout_width="fill_parent" 
    android:layout_height="fill_parent" 

    android:handle="@+id/handle" 
    android:content="@+id/content"> 

    <ImageView 
     android:id="@id/handle" 
     android:src="@drawable/my_image" 
     android:layout_width="wrap_content" 
     android:layout_height="fill_parent" /> 

    .... 

</SlidingDrawer> 

당신은 아마이 윈도우의 높이를 채우기 위해 기지개 할 수 있도록 9patch에 해당 이미지를 변환 할 것입니다.

0

SlidingDrawer의 버튼에 배경 이미지를 추가합니다.

1

서로 다른 상태에 대한 다른 이미지를 가질 수 있도록 슬라이더 버튼에 대한 선택기를 사용한다 (집중, 비 초점을 맞춘 등)

<?xml version="1.0" encoding="utf-8"?> 
<selector xmlns:android="http://schemas.android.com/apk/res/android"> 
    <item android:state_focused="true" android:state_pressed="false" android:drawable="@drawable/focused" /> 
    <item android:state_focused="true" android:state_pressed="true" android:drawable="@drawable/focusedpressed" /> 
    <item android:state_focused="false" android:state_pressed="true" android:drawable="@drawable/pressed" /> 
    <item android:drawable="@drawable/defaultbutton" /> 
</selector>