Procházet zdrojové kódy

只显示默认四分音符的图标

Pq před 2 roky
rodič
revize
f9bbd95837

+ 15 - 14
metronome/src/main/java/com/cooleshow/metronome/constants/MetronomeConfig.java

@@ -17,20 +17,21 @@ public class MetronomeConfig {
 
 
     public static int getNoteDrawable(MetronomeType metronomeType) {
-        if (TextUtils.equals(metronomeType.getNoteValue(), "4")) {
-            return R.mipmap.icon_quarter_note;
-        }
-        if (TextUtils.equals(metronomeType.getNoteValue(), "2")) {
-            return R.mipmap.icon_half_note;
-        }
-
-        if (TextUtils.equals(metronomeType.getNoteValue(), "8")) {
-            return R.mipmap.icon_one_eighth_note;
-        }
-
-        if (TextUtils.equals(metronomeType.getNoteValue(), "16")) {
-            return R.mipmap.icon_sixteenth_note;
-        }
         return R.mipmap.icon_quarter_note;
+//        if (TextUtils.equals(metronomeType.getNoteValue(), "4")) {
+//            return R.mipmap.icon_quarter_note;
+//        }
+//        if (TextUtils.equals(metronomeType.getNoteValue(), "2")) {
+//            return R.mipmap.icon_half_note;
+//        }
+//
+//        if (TextUtils.equals(metronomeType.getNoteValue(), "8")) {
+//            return R.mipmap.icon_one_eighth_note;
+//        }
+//
+//        if (TextUtils.equals(metronomeType.getNoteValue(), "16")) {
+//            return R.mipmap.icon_sixteenth_note;
+//        }
+//        return R.mipmap.icon_quarter_note;
     }
 }