for( int i = 0; i < navigation.getMenu().size(); i++ ) {
MenuItem tot = navigation.getMenu().getItem( i );
int tmpSize = tot.getSubMenu().size();
for( int j = 0; j < tmpSize; j++ ) {
MenuItem temp = tot.getSubMenu().getItem( j );
temp.setChecked( false );
temp.setCheckable( true ); // 이놈을 해줘야 selector 에서 checked가 먹힘
}
}
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:drawable="@color/left_menu_background_over"
android:state_checked="true" /> // 이친구
<item
android:drawable="@android:color/transparent"
android:state_checked="false" />
</selector>