author | zecke <zecke> | 2004-04-07 18:01:16 (UTC) |
---|---|---|
committer | zecke <zecke> | 2004-04-07 18:01:16 (UTC) |
commit | 7c4c7920dd7c38db7a0bd49529ce0cd20a54a78a (patch) (unidiff) | |
tree | 20598f8c9085180a4a41e011fb5707a71142ec91 /library | |
parent | 51218a62632aa83a84d4ef23a0044c7f8cf5aa9c (diff) | |
download | opie-7c4c7920dd7c38db7a0bd49529ce0cd20a54a78a.zip opie-7c4c7920dd7c38db7a0bd49529ce0cd20a54a78a.tar.gz opie-7c4c7920dd7c38db7a0bd49529ce0cd20a54a78a.tar.bz2 |
Using the right mixer helps.. lets see if h5xxx breaks again
-rw-r--r-- | library/qpeapplication.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/library/qpeapplication.cpp b/library/qpeapplication.cpp index 3370264..755fb19 100644 --- a/library/qpeapplication.cpp +++ b/library/qpeapplication.cpp | |||
@@ -352,17 +352,17 @@ static void setVolume( int t = 0, int percent = -1 ) | |||
352 | if ( percent < 0 ) | 352 | if ( percent < 0 ) |
353 | percent = cfg.readNumEntry( "VolumePercent", 50 ); | 353 | percent = cfg.readNumEntry( "VolumePercent", 50 ); |
354 | #ifndef QT_NO_SOUND | 354 | #ifndef QT_NO_SOUND |
355 | int fd = 0; | 355 | int fd = 0; |
356 | if ( ( fd = open( "/dev/mixer", O_RDWR ) ) >= 0 ) { | 356 | if ( ( fd = open( "/dev/mixer", O_RDWR ) ) >= 0 ) { |
357 | int vol = muted ? 0 : percent; | 357 | int vol = muted ? 0 : percent; |
358 | // set both channels to same volume | 358 | // set both channels to same volume |
359 | vol |= vol << 8; | 359 | vol |= vol << 8; |
360 | ioctl( fd, MIXER_WRITE( SOUND_MIXER_PCM ), &vol ); | 360 | ioctl( fd, MIXER_WRITE( SOUND_MIXER_VOLUME ), &vol ); |
361 | ::close( fd ); | 361 | ::close( fd ); |
362 | } | 362 | } |
363 | #endif | 363 | #endif |
364 | } | 364 | } |
365 | break; | 365 | break; |
366 | } | 366 | } |
367 | } | 367 | } |
368 | 368 | ||