fix vconf location and network
authorNam KwanWoo <kw46.nam@samsung.com>
Wed, 12 Dec 2012 02:22:42 +0000 (11:22 +0900)
committerNam KwanWoo <kw46.nam@samsung.com>
Wed, 12 Dec 2012 02:22:42 +0000 (11:22 +0900)
Change-Id: I0674b8050e8f004364e4e8dcab460c7d29408421

src/runtime_info_location.c

index 458928f..14d7aee 100755 (executable)
@@ -11,7 +11,7 @@
  * distributed under the License is distributed on an AS IS BASIS,
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
- * limitations under the License. 
+ * limitations under the License.
  */
 
 #include <stdio.h>
 
 #define LOG_TAG "TIZEN_N_RUNTIME_INFO"
 
-static const char *VCONF_LOCATION_SERVICE_ENABLED = "db/location/setting/GpsEnabled";
+static const char *VCONF_LOCATION_SERVICE_ENABLED = VCONFKEY_LOCATION_ENABLED;
 static const char *VCONF_LOCATION_AGPS_ENABLED = "db/location/setting/AgpsEnabled";
-static const char *VCONF_LOCATION_NETWORK_ENABLED = "db/location/setting/NetworkEnabled";
+static const char *VCONF_LOCATION_NETWORK_ENABLED = VCONFKEY_LOCATION_NETWORK_ENABLED;
 static const char *VCONF_LOCATION_SENSOR_ENABLED = "db/location/setting/SensorEnabled";
 
 int runtime_info_location_service_get_value(runtime_info_value_h value)
 {
        int vconf_value;
-       
+
        if (runtime_info_vconf_get_value_int(VCONF_LOCATION_SERVICE_ENABLED, &vconf_value))
-       {
                return RUNTIME_INFO_ERROR_IO_ERROR;
-       }
 
        value->b = vconf_value;
 
@@ -62,11 +60,9 @@ void runtime_info_location_service_unset_event_cb()
 int runtime_info_location_agps_get_value(runtime_info_value_h value)
 {
        int vconf_value;
-       
+
        if (runtime_info_vconf_get_value_int(VCONF_LOCATION_AGPS_ENABLED, &vconf_value))
-       {
                return RUNTIME_INFO_ERROR_IO_ERROR;
-       }
 
        value->b = vconf_value;
 
@@ -86,11 +82,9 @@ void runtime_info_location_agps_unset_event_cb()
 int runtime_info_location_network_get_value(runtime_info_value_h value)
 {
        int vconf_value;
-       
+
        if (runtime_info_vconf_get_value_int(VCONF_LOCATION_NETWORK_ENABLED, &vconf_value))
-       {
                return RUNTIME_INFO_ERROR_IO_ERROR;
-       }
 
        value->b = vconf_value;
 
@@ -110,11 +104,9 @@ void runtime_info_location_network_unset_event_cb()
 int runtime_info_location_sensor_get_value(runtime_info_value_h value)
 {
        int vconf_value;
-       
+
        if (runtime_info_vconf_get_value_int(VCONF_LOCATION_SENSOR_ENABLED, &vconf_value))
-       {
                return RUNTIME_INFO_ERROR_IO_ERROR;
-       }
 
        value->b = vconf_value;