Diff of /cmd.c [5a5ce9] .. [84e0b8] Maximize Restore

  Switch to side-by-side view

--- a/cmd.c
+++ b/cmd.c
@@ -184,23 +184,14 @@
     break;
 
   case CMD_SET_OPTIONS:
-    switch(arg)
-    {
-      case ARG_SET_OPTIONS_JOINTSTEREO:
-        vs1063_options.aictrl3 = (vs1063_options.aictrl3 & ~VS1063_AICTRL3_ADC_MASK) | VS1063_AICTRL3_ADC_JOINTSTEREO;
-        break;
-      case ARG_SET_OPTIONS_DOWNMIXMONO:
-        vs1063_options.aictrl3 = (vs1063_options.aictrl3 & ~VS1063_AICTRL3_ADC_MASK) | VS1063_AICTRL3_ADC_DOWNMIXMONO;
-        break;
-      case ARG_SET_OPTIONS_ENCODER_OGG:
-        vs1063_options.aictrl3 = (vs1063_options.aictrl3 & ~VS1063_AICTRL3_ENCODER_MASK) | VS1063_AICTRL3_ENCODER_OGG;
-        break;
-      case ARG_SET_OPTIONS_ENCODER_MP3:
-        vs1063_options.aictrl3 = (vs1063_options.aictrl3 & ~VS1063_AICTRL3_ENCODER_MASK) | VS1063_AICTRL3_ENCODER_MP3;
-        break;
-      default:
-        break;
-     }
+    if(arg & ARG_SET_OPTIONS_DOWNMIXMONO)
+      vs1063_options.aictrl3 = (vs1063_options.aictrl3 & ~VS1063_AICTRL3_ADC_MASK) | VS1063_AICTRL3_ADC_DOWNMIXMONO; 
+    else
+      vs1063_options.aictrl3 = (vs1063_options.aictrl3 & ~VS1063_AICTRL3_ADC_MASK) | VS1063_AICTRL3_ADC_JOINTSTEREO; 
+    if(arg & ARG_SET_OPTIONS_ENCODER_MP3)
+      vs1063_options.aictrl3 = (vs1063_options.aictrl3 & ~VS1063_AICTRL3_ENCODER_MASK) | VS1063_AICTRL3_ENCODER_MP3;
+    else
+      vs1063_options.aictrl3 = (vs1063_options.aictrl3 & ~VS1063_AICTRL3_ENCODER_MASK) | VS1063_AICTRL3_ENCODER_OGG; 
     break;
 
   default: