r2862 - trunk/src/target/OM-2007.2/daemons/neod/src

mickey at sita.openmoko.org mickey at sita.openmoko.org
Thu Aug 30 23:20:02 CEST 2007


Author: mickey
Date: 2007-08-30 23:20:02 +0200 (Thu, 30 Aug 2007)
New Revision: 2862

Modified:
   trunk/src/target/OM-2007.2/daemons/neod/src/buttonactions.c
Log:
neod: change alsa amp mode on headphone insertion / removal. thanks XorA


Modified: trunk/src/target/OM-2007.2/daemons/neod/src/buttonactions.c
===================================================================
--- trunk/src/target/OM-2007.2/daemons/neod/src/buttonactions.c	2007-08-30 20:57:42 UTC (rev 2861)
+++ trunk/src/target/OM-2007.2/daemons/neod/src/buttonactions.c	2007-08-30 21:20:02 UTC (rev 2862)
@@ -317,18 +317,21 @@
                 if ( event.value == 0 ) /* inserted */
                 {
                     g_debug( "headphones IN" );
-                    neod_buttonactions_sound_play( "touchscreen" );
+                    g_spawn_command_line_async( "amixer sset \"Amp Mode\" \"Headphones\", NULL );
                 }
                 else if ( event.value == 1 ) /* released */
                 {
                     g_debug( "headphones OUT" );
+                    g_spawn_command_line_async( "amixer sset \"Amp Mode\" \"Stereo Speakers\", NULL );
                 }
                 neod_buttonactions_powersave_reset();
+#if 0
                 if ( power_state != NORMAL )
                 {
                     neod_buttonactions_set_display( 100 );
                     power_state = NORMAL;
                 }
+#endif
             }
         }
     }





More information about the commitlog mailing list