summaryrefslogtreecommitdiffstats
path: root/media/libmedia/ToneGenerator.cpp
diff options
context:
space:
mode:
authorGlenn Kasten <gkasten@google.com>2012-02-03 08:00:52 -0800
committerAndroid (Google) Code Review <android-gerrit@google.com>2012-02-03 08:00:52 -0800
commitff3c83e04ae459c4252b86dd4440b4e37ee92c16 (patch)
tree8de4de832991dd2086313b6168f8523d002f6251 /media/libmedia/ToneGenerator.cpp
parenta0d68338a88c2ddb4502f95017b546d603ef1ec7 (diff)
parent3d2f877c1cb4e4ae4ddde7f57f4353de9341f11b (diff)
downloadframeworks_av-ff3c83e04ae459c4252b86dd4440b4e37ee92c16.zip
frameworks_av-ff3c83e04ae459c4252b86dd4440b4e37ee92c16.tar.gz
frameworks_av-ff3c83e04ae459c4252b86dd4440b4e37ee92c16.tar.bz2
Merge "Use ToneGenerator::tone_type consistently"
Diffstat (limited to 'media/libmedia/ToneGenerator.cpp')
-rw-r--r--media/libmedia/ToneGenerator.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/media/libmedia/ToneGenerator.cpp b/media/libmedia/ToneGenerator.cpp
index 1d1f645..e6e989d 100644
--- a/media/libmedia/ToneGenerator.cpp
+++ b/media/libmedia/ToneGenerator.cpp
@@ -751,7 +751,7 @@ const ToneGenerator::ToneDescriptor ToneGenerator::sToneDescriptors[] = {
// Used by ToneGenerator::getToneForRegion() to convert user specified supervisory tone type
// to actual tone for current region.
-const unsigned char ToneGenerator::sToneMappingTable[NUM_REGIONS-1][NUM_SUP_TONES] = {
+const unsigned char /*tone_type*/ ToneGenerator::sToneMappingTable[NUM_REGIONS-1][NUM_SUP_TONES] = {
{ // ANSI
TONE_ANSI_DIAL, // TONE_SUP_DIAL
TONE_ANSI_BUSY, // TONE_SUP_BUSY
@@ -878,7 +878,7 @@ ToneGenerator::~ToneGenerator() {
// none
//
////////////////////////////////////////////////////////////////////////////////
-bool ToneGenerator::startTone(int toneType, int durationMs) {
+bool ToneGenerator::startTone(tone_type toneType, int durationMs) {
bool lResult = false;
status_t lStatus;
@@ -1434,13 +1434,13 @@ void ToneGenerator::clearWaveGens() {
// none
//
////////////////////////////////////////////////////////////////////////////////
-int ToneGenerator::getToneForRegion(int toneType) {
- int regionTone;
+ToneGenerator::tone_type ToneGenerator::getToneForRegion(tone_type toneType) {
+ tone_type regionTone;
if (mRegion == CEPT || toneType < FIRST_SUP_TONE || toneType > LAST_SUP_TONE) {
regionTone = toneType;
} else {
- regionTone = sToneMappingTable[mRegion][toneType - FIRST_SUP_TONE];
+ regionTone = (tone_type) sToneMappingTable[mRegion][toneType - FIRST_SUP_TONE];
}
ALOGV("getToneForRegion, tone %d, region %d, regionTone %d", toneType, mRegion, regionTone);