Remove dual-state icons for call buttons.

Per discussion with design, it'll be simpler to just have one icon
which does not toggle/change on state (besides color accent).

Bug: 15165717
Change-Id: I2856c403b549e734e8f6c55b5be65f9a337730d6
diff --git a/InCallUI/res/drawable-hdpi/ic_toolbar_mic_on.png b/InCallUI/res/drawable-hdpi/ic_toolbar_mic_on.png
deleted file mode 100644
index 9a5afbc..0000000
--- a/InCallUI/res/drawable-hdpi/ic_toolbar_mic_on.png
+++ /dev/null
Binary files differ
diff --git a/InCallUI/res/drawable-hdpi/ic_toolbar_speaker_off.png b/InCallUI/res/drawable-hdpi/ic_toolbar_speaker_off.png
deleted file mode 100644
index a73c0dc..0000000
--- a/InCallUI/res/drawable-hdpi/ic_toolbar_speaker_off.png
+++ /dev/null
Binary files differ
diff --git a/InCallUI/res/drawable-mdpi/ic_toolbar_mic_on.png b/InCallUI/res/drawable-mdpi/ic_toolbar_mic_on.png
deleted file mode 100644
index 0be1d1f..0000000
--- a/InCallUI/res/drawable-mdpi/ic_toolbar_mic_on.png
+++ /dev/null
Binary files differ
diff --git a/InCallUI/res/drawable-mdpi/ic_toolbar_speaker_off.png b/InCallUI/res/drawable-mdpi/ic_toolbar_speaker_off.png
deleted file mode 100644
index 1040ca6..0000000
--- a/InCallUI/res/drawable-mdpi/ic_toolbar_speaker_off.png
+++ /dev/null
Binary files differ
diff --git a/InCallUI/res/drawable-xhdpi/ic_toolbar_mic_on.png b/InCallUI/res/drawable-xhdpi/ic_toolbar_mic_on.png
deleted file mode 100644
index 9ae4b41..0000000
--- a/InCallUI/res/drawable-xhdpi/ic_toolbar_mic_on.png
+++ /dev/null
Binary files differ
diff --git a/InCallUI/res/drawable-xhdpi/ic_toolbar_speaker_off.png b/InCallUI/res/drawable-xhdpi/ic_toolbar_speaker_off.png
deleted file mode 100644
index b332a20..0000000
--- a/InCallUI/res/drawable-xhdpi/ic_toolbar_speaker_off.png
+++ /dev/null
Binary files differ
diff --git a/InCallUI/res/drawable-xxhdpi/ic_toolbar_mic_on.png b/InCallUI/res/drawable-xxhdpi/ic_toolbar_mic_on.png
deleted file mode 100644
index 11b4655..0000000
--- a/InCallUI/res/drawable-xxhdpi/ic_toolbar_mic_on.png
+++ /dev/null
Binary files differ
diff --git a/InCallUI/res/drawable-xxhdpi/ic_toolbar_speaker_off.png b/InCallUI/res/drawable-xxhdpi/ic_toolbar_speaker_off.png
deleted file mode 100644
index 603a954..0000000
--- a/InCallUI/res/drawable-xxhdpi/ic_toolbar_speaker_off.png
+++ /dev/null
Binary files differ
diff --git a/InCallUI/res/drawable/btn_compound_audio.xml b/InCallUI/res/drawable/btn_compound_audio.xml
index 9b24d8b..adfb8c2 100644
--- a/InCallUI/res/drawable/btn_compound_audio.xml
+++ b/InCallUI/res/drawable/btn_compound_audio.xml
@@ -84,19 +84,12 @@
     </item>
 
     <!-- Speakerphone icon showing 'speaker on' state -->
-    <item android:id="@+id/speakerphoneOnItem">
+    <item android:id="@+id/speakerphoneItem">
         <bitmap android:src="@drawable/ic_toolbar_speaker_on"
                 android:gravity="center"
                 android:tint="@color/selectable_icon_tint" />
     </item>
 
-    <!-- Speakerphone icon showing 'speaker off' state -->
-    <item android:id="@+id/speakerphoneOffItem">
-        <bitmap android:src="@drawable/ic_toolbar_speaker_off"
-                android:gravity="center"
-                android:tint="@color/selectable_icon_tint" />
-    </item>
-
     <!-- Generic "audio mode" icon. -->
     <!-- TODO: is this actually needed? -->
     <!--
diff --git a/InCallUI/res/drawable/btn_compound_mute.xml b/InCallUI/res/drawable/btn_compound_mute.xml
index c224dfc..68a8c9b 100644
--- a/InCallUI/res/drawable/btn_compound_mute.xml
+++ b/InCallUI/res/drawable/btn_compound_mute.xml
@@ -21,16 +21,10 @@
     <item android:drawable="@drawable/btn_compound_background" />
 
     <!-- Use an explicit <bitmap> to avoid scaling the icon up to the full size of the button. -->
-    <item android:id="@+id/muteOffItem">
-        <bitmap android:src="@drawable/ic_toolbar_mic_on"
+    <item>
+        <bitmap android:src="@drawable/ic_toolbar_mic_off"
             android:gravity="center"
             android:tint="@color/selectable_icon_tint" />
     </item>
 
-    <item android:id="@+id/muteOnItem">
-        <bitmap android:src="@drawable/ic_toolbar_mic_off"
-                android:gravity="center"
-                android:tint="@color/selectable_icon_tint" />
-    </item>
-
 </layer-list>
diff --git a/InCallUI/src/com/android/incallui/CallButtonFragment.java b/InCallUI/src/com/android/incallui/CallButtonFragment.java
index d9fc68d..76055f2 100644
--- a/InCallUI/src/com/android/incallui/CallButtonFragment.java
+++ b/InCallUI/src/com/android/incallui/CallButtonFragment.java
@@ -209,13 +209,6 @@
 
     @Override
     public void setMute(boolean value) {
-        final LayerDrawable layers = (LayerDrawable) mMuteButton.getBackground();
-
-        layers.findDrawableByLayerId(R.id.muteOffItem)
-                .setAlpha(value ? HIDDEN : VISIBLE);
-        layers.findDrawableByLayerId(R.id.muteOnItem)
-                .setAlpha(value ? VISIBLE : HIDDEN);
-
         mMuteButton.setSelected(value);
     }
 
@@ -359,8 +352,7 @@
         boolean showMoreIndicator = false;
 
         boolean showBluetoothIcon = false;
-        boolean showSpeakerphoneOnIcon = false;
-        boolean showSpeakerphoneOffIcon = false;
+        boolean showSpeakerphoneIcon = false;
         boolean showHandsetIcon = false;
 
         boolean showToggleIndicator = false;
@@ -378,7 +370,7 @@
             if (isAudio(AudioMode.BLUETOOTH)) {
                 showBluetoothIcon = true;
             } else if (isAudio(AudioMode.SPEAKER)) {
-                showSpeakerphoneOnIcon = true;
+                showSpeakerphoneIcon = true;
             } else {
                 showHandsetIcon = true;
                 // TODO: if a wired headset is plugged in, that takes precedence
@@ -397,9 +389,7 @@
 
             // update desired layers:
             showToggleIndicator = true;
-
-            showSpeakerphoneOnIcon = isAudio(AudioMode.SPEAKER);
-            showSpeakerphoneOffIcon = !showSpeakerphoneOnIcon;
+            showSpeakerphoneIcon = true;
         } else {
             Log.d(this, "updateAudioButtons - disabled...");
 
@@ -410,7 +400,7 @@
 
             // update desired layers:
             showToggleIndicator = true;
-            showSpeakerphoneOffIcon = true;
+            showSpeakerphoneIcon = true;
         }
 
         // Finally, update it all!
@@ -419,8 +409,7 @@
         Log.v(this, "audioButtonChecked: " + audioButtonChecked);
         Log.v(this, "showMoreIndicator: " + showMoreIndicator);
         Log.v(this, "showBluetoothIcon: " + showBluetoothIcon);
-        Log.v(this, "showSpeakerphoneOnIcon: " + showSpeakerphoneOnIcon);
-        Log.v(this, "showSpeakerphoneOffIcon: " + showSpeakerphoneOffIcon);
+        Log.v(this, "showSpeakerphoneIcon: " + showSpeakerphoneIcon);
         Log.v(this, "showHandsetIcon: " + showHandsetIcon);
 
         // Only enable the audio button if the fragment is enabled.
@@ -442,11 +431,8 @@
         layers.findDrawableByLayerId(R.id.handsetItem)
                 .setAlpha(showHandsetIcon ? VISIBLE : HIDDEN);
 
-        layers.findDrawableByLayerId(R.id.speakerphoneOnItem)
-                .setAlpha(showSpeakerphoneOnIcon ? VISIBLE : HIDDEN);
-
-        layers.findDrawableByLayerId(R.id.speakerphoneOffItem)
-                .setAlpha(showSpeakerphoneOffIcon ? VISIBLE : HIDDEN);
+        layers.findDrawableByLayerId(R.id.speakerphoneItem)
+                .setAlpha(showSpeakerphoneIcon ? VISIBLE : HIDDEN);
 
     }