Use dedicated volume keys in N9 to adjust game or media volume
This article explains how to have dedicated volume keys to adjust media volume in N9
Article Metadata
Tested with
Article
Introduction
By default in N9 when you press the volumekeys the ringing tone volume is adjusted. For Games and other media applications you might wish to enable support for "media volume" adjustments with volume keys instead.
This article explains how you can specify your application to require this behavior.
Summary
First, verify what is the target name of your application. Open the .pro file and see the "TARGET = " value.
For example:
TARGET = myqtgameCreate a folder under your project, named "n9volumekeys" (the folder name does not matter - as long as you use the same path in the latter part). Create a file named your target name, and use the extension ".conf". For this example the filename would be ""n9volumekeys/myqtgame.conf" In the file, include following lines:
[classify gaming]
/opt/usr/bin/myqtgame
Again, replace myqtgame with the exact target name you are using.
Finally, find the correct position in .pro file to add the .conf file to be installed in the device.
unix:!symbian {
...
maemo5 {
...
}
else {
# Classify the application as a game to support volume keys on Harmattan.
gameclassify.files += n9volumekeys/$${TARGET}.conf
gameclassify.path = /usr/share/policy/etc/syspart.conf.d
}
}
Build the application and test on device. You should see that pressing the volume keys on device while your application is running, is now changing the media volume.
For more thorough examples on how to do game audio, please see http://projects.developer.nokia.com/qtgameenabler


(no comments yet)