Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4362: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4364: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4365: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4366: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
anddev.org • View topic - setVolumeControlStream, VOLUME, Control, Loudness, STREAM

setVolumeControlStream, VOLUME, Control, Loudness, STREAM

Quickly share your Android Code Snippets here...

setVolumeControlStream, VOLUME, Control, Loudness, STREAM

Postby plusminus » Fri Nov 14, 2008 3:32 am

This snippet makes the system know we want to control the volume on the MUSIC-Stream (or other streams) with the Hardware-Buttons.
Syntax: [ Download ] [ Hide ]
Using java Syntax Highlighting
  1. /* Make the system know we want to control the volume on the MUSIC-STREAM with the Hardware-Buttons. */
  2. this.setVolumeControlStream(AudioManager.STREAM_MUSIC);
Parsed in 0.010 seconds, using GeSHi 1.0.8.4


You do not need to save and restore the old suggested stream value in onPause and onResume.

SDK Version compatible: 1.0 (maybe prior versions too)
Image
Image | Android Development Community / Tutorials
User avatar
plusminus
Site Admin
Site Admin
 
Posts: 2688
Joined: Wed Nov 14, 2007 8:37 pm
Location: Schriesheim, Germany

Top

independent volume controlller

Postby shishir.bobby » Thu Feb 25, 2010 2:35 pm

HI plusMinus



can we make an independent volume controller, in an app?


Thanks and regards
Shishir.bobby
shishir.bobby
Experienced Developer
Experienced Developer
 
Posts: 76
Joined: Thu Apr 09, 2009 11:41 am

Top

Return to Code Snippets for Android

Who is online

Users browsing this forum: No registered users and 2 guests