From: Somin Kim Date: Tue, 8 Sep 2015 06:21:35 +0000 (+0900) Subject: Fix coding style in ctx::device_status_battery X-Git-Tag: accepted/tizen/mobile/20150909.141018~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f1a430a78f8d7e905678671484828d5a6a94d858;p=platform%2Fcore%2Fcontext%2Fdevice-context-provider.git Fix coding style in ctx::device_status_battery Change-Id: I78630c072c925ab13ac484ec68622f5a27d9c070 Signed-off-by: Mu-Woong Signed-off-by: Somin Kim --- diff --git a/src/device_status/battery.cpp b/src/device_status/battery.cpp index 7aada51..8a11f8c 100644 --- a/src/device_status/battery.cpp +++ b/src/device_status/battery.cpp @@ -72,19 +72,19 @@ void ctx::device_status_battery::handle_update(device_callback_e device_type, vo const char* ctx::device_status_battery::trans_to_string(intptr_t level) { switch (level) { - case DEVICE_BATTERY_LEVEL_EMPTY : + case DEVICE_BATTERY_LEVEL_EMPTY: return DEVICE_ST_EMPTY; - case DEVICE_BATTERY_LEVEL_CRITICAL : + case DEVICE_BATTERY_LEVEL_CRITICAL: return DEVICE_ST_CRITICAL; - case DEVICE_BATTERY_LEVEL_LOW : + case DEVICE_BATTERY_LEVEL_LOW: return DEVICE_ST_LOW; - case DEVICE_BATTERY_LEVEL_HIGH : + case DEVICE_BATTERY_LEVEL_HIGH: return DEVICE_ST_NORMAL; - case DEVICE_BATTERY_LEVEL_FULL : + case DEVICE_BATTERY_LEVEL_FULL: { int percent; device_battery_get_percent(&percent); @@ -93,10 +93,12 @@ const char* ctx::device_status_battery::trans_to_string(intptr_t level) return DEVICE_ST_FULL; } else { return DEVICE_ST_HIGH; - } } + } + } break; - default: _E("battery_level receive abnormal value from device api"); + default: + _E("Invalid battery level"); return NULL; } }