1316674502946.jpg

 

원래 의도는 이렇게 하는건데요

그림들을 넣고 보니

이렇게 변환이 되더라구요

원본 그림파일은 위와같이 되어 있습니다.

 

1316674521624.jpg

 

ㅡㅡ;; 왜그런거죠?

 

@Override
 public boolean onCreateOptionsMenu(Menu menu) {
  getMenuInflater().inflate(R.menu.option, menu);
  return true;
 }

 @Override
 public boolean onOptionsItemSelected(MenuItem item) {
  switch (item.getItemId()) {
  case R.id.home_menu:
   
   break;
  case R.id.setting_menu:
   
   break;
  case R.id.bookmark_menu:
   
   break;
  case R.id.reset_menu:
   
   break;
  default:
   break;
  }
  return true;
 }

 

이렇게 생성하고 menu 메뉴 xml을 이렇게 했습니다.

 

<?xml version="1.0" encoding="utf-8"?>
<menu
  xmlns:android="http://schemas.android.com/apk/res/android">
    <item android:id="@+id/home_menu" android:icon="@drawable/bar_bt_home" android:orderInCategory="0"></item>
    <item android:id="@+id/setting_menu" android:icon="@drawable/bar_bt_setting" android:orderInCategory="1"></item>
    <item android:id="@+id/bookmark_menu" android:icon="@drawable/bar_bt_bookmark" android:orderInCategory="3"></item>
    <item android:id="@+id/reset_menu" android:icon="@drawable/bar_bt_reset" android:orderInCategory="4"></item>
</menu>

 

bar_bt_home 는 xml파일이구요

 

<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
 <item
  android:state_window_focused="false"
  android:state_enabled="true"
  android:drawable="@drawable/bar_bt_home_001" />
 <item
  android:state_window_focused="false"
  android:state_enabled="false"
  android:drawable="@drawable/bar_bt_home_001" />
 <item
  android:state_pressed="true"
  android:drawable="@drawable/bar_bt_home_002" />
 <item
  android:state_focused="true"
  android:state_enabled="true"
  android:drawable="@drawable/bar_bt_home_002" />
 <item
  android:state_enabled="true"
  android:drawable="@drawable/bar_bt_home_001" />
 <item
  android:state_focused="true"
  android:drawable="@drawable/bar_bt_home_002" />
 <item
  android:drawable="@drawable/bar_bt_home_001" />
</selector>

 

이렇게 스타일이 적용되어 있습니다.

bar_bt_home_001과 bar_bt_home_002 pnp 이미지 파일입니다.

 

이것저것 다 바꿔봤는데도 안돼네요 ㅡㅡ;; 뭐가 잘못된거죠?

어떻게 해야 맨 위의 그림처럼 변경이 될까요?

도와주세요 ㅠㅠ;;