RuntimeInfo : remove deprecated enum values
authorKichan Kwon <k_c.kwon@samsung.com>
Fri, 24 Mar 2017 02:01:57 +0000 (11:01 +0900)
committerKichan Kwon <k_c.kwon@samsung.com>
Fri, 24 Mar 2017 02:03:29 +0000 (11:03 +0900)
- These can be replaced with location API

Change-Id: I27124bdd38522711bda9cd2776a8482088f0ede5
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
src/Tizen.System.Information/RuntimeInfo/Enumerations.cs [changed mode: 0644->0755]
src/Tizen.System.Information/RuntimeInfo/RuntimeInformation.cs [changed mode: 0644->0755]

old mode 100644 (file)
new mode 100755 (executable)
index b998d3b..c35afeb
@@ -41,14 +41,6 @@ namespace Tizen.System
         /// </summary>
         UsbTethering = 5,
         /// <summary>
-        /// Indicates whether the location service is allowed to use location data from GPS satellites.
-        /// </summary>
-        LocationService = 6,
-        /// <summary>
-        /// Indicates whether the location service is allowed to use location data from cellular and Wi-Fi.
-        /// </summary>
-        LocationNetworkPosition = 8,
-        /// <summary>
         /// Indicates Whether the packet data through 3G network is enabled.
         /// </summary>
         PacketData = 9,
old mode 100644 (file)
new mode 100755 (executable)
index b8b0c7c..591347e
@@ -72,16 +72,6 @@ namespace Tizen.System
                         s_usbTetheringEnabled?.Invoke(null, eventArgs);
                         break;
                     };
-                case RuntimeInformationKey.LocationService:
-                    {
-                        s_locationServiceEnabled?.Invoke(null, eventArgs);
-                        break;
-                    };
-                case RuntimeInformationKey.LocationNetworkPosition:
-                    {
-                        s_locationNetworkPositionEnabled?.Invoke(null, eventArgs);
-                        break;
-                    };
                 case RuntimeInformationKey.PacketData:
                     {
                         s_packetDataEnabled?.Invoke(null, eventArgs);
@@ -143,8 +133,6 @@ namespace Tizen.System
             [RuntimeInformationKey.WifiHotspot] = typeof(bool),
             [RuntimeInformationKey.BluetoothTethering] = typeof(bool),
             [RuntimeInformationKey.UsbTethering] = typeof(bool),
-            [RuntimeInformationKey.LocationService] = typeof(bool),
-            [RuntimeInformationKey.LocationNetworkPosition] = typeof(bool),
             [RuntimeInformationKey.PacketData] = typeof(bool),
             [RuntimeInformationKey.DataRoaming] = typeof(bool),
             [RuntimeInformationKey.Vibration] = typeof(bool),
@@ -494,66 +482,6 @@ namespace Tizen.System
             }
         }
         /// <summary>
-        /// (event) LocationServiceEnabled is raised when system preference for location service is changed.
-        /// </summary>
-        public static event EventHandler<RuntimeKeyStatusChangedEventArgs> LocationServiceEnabled
-        {
-            add
-            {
-                if (s_locationServiceEnabled == null)
-                {
-                    int ret = Interop.RuntimeInfo.SetRuntimeInfoChangedCallback(RuntimeInformationKey.LocationService, s_runtimeInfoChangedCallback, IntPtr.Zero);
-                    if (ret != (int)RuntimeInfoError.None)
-                    {
-                        Log.Error(RuntimeInfoErrorFactory.LogTag, "Interop failed to add event handler");
-                        RuntimeInfoErrorFactory.ThrowException(ret);
-                    }
-                }
-                s_locationServiceEnabled += value;
-            }
-            remove
-            {
-                s_locationServiceEnabled -= value;
-                if (s_locationServiceEnabled == null)
-                {
-                    int ret = Interop.RuntimeInfo.UnsetRuntimeInfoChangedCallback(RuntimeInformationKey.LocationService);
-                    RuntimeInfoErrorFactory.ThrowException(ret);
-                }
-            }
-        }
-        /// <summary>
-        /// (event) LocationNetworkPositionEnabled is raised when system preference for allowing location service to use location data from cellular and Wi-Fi is changed.
-        /// </summary>
-        public static event EventHandler<RuntimeKeyStatusChangedEventArgs> LocationNetworkPositionEnabled
-        {
-            add
-            {
-                if (s_locationNetworkPositionEnabled == null)
-                {
-                    int ret = Interop.RuntimeInfo.SetRuntimeInfoChangedCallback(RuntimeInformationKey.LocationNetworkPosition, s_runtimeInfoChangedCallback, IntPtr.Zero);
-                    if (ret != (int)RuntimeInfoError.None)
-                    {
-                        Log.Error(RuntimeInfoErrorFactory.LogTag, "Interop failed to add event handler");
-                        RuntimeInfoErrorFactory.ThrowException(ret);
-                    }
-                }
-                s_locationNetworkPositionEnabled += value;
-            }
-            remove
-            {
-                s_locationNetworkPositionEnabled -= value;
-                if (s_locationNetworkPositionEnabled == null)
-                {
-                    int ret = Interop.RuntimeInfo.UnsetRuntimeInfoChangedCallback(RuntimeInformationKey.LocationNetworkPosition);
-                    if (ret != (int)RuntimeInfoError.None)
-                    {
-                        Log.Error(RuntimeInfoErrorFactory.LogTag, "Interop failed to add event handler");
-                        RuntimeInfoErrorFactory.ThrowException(ret);
-                    }
-                }
-            }
-        }
-        /// <summary>
         /// (event) PacketDataEnabled is raised when system preference for package data through 3G network is changed.
         /// </summary>
         public static event EventHandler<RuntimeKeyStatusChangedEventArgs> PacketDataEnabled
@@ -587,7 +515,6 @@ namespace Tizen.System
         }
         /// <summary>
         /// (event) DataRoamingEnabled is raised when system preference for data roaming is changed.
-
         /// </summary>
         public static event EventHandler<RuntimeKeyStatusChangedEventArgs> DataRoamingEnabled
         {