+capi-system-runtime-info (0.0.2-1) unstable; urgency=low
+
+ * Change key name
+ * Git: framework/api/runtime-info
+ * Tag: capi-system-runtime-info_0.0.2-1
+
+ -- Kwanwoo Nam <kw46.nam@samsung.com> Tue, 22 Jan 2013 15:40:00 +0900
+
capi-system-runtime-info (0.0.1-11) unstable; urgency=low
* Fixed prevent defect case : CID 10685
* 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.
*/
#ifndef __TIZEN_SYSTEM_RUNTIME_INFO_H__
/**
* @brief Enumeration of error code for runtime information
*/
-typedef enum
-{
+typedef enum {
RUNTIME_INFO_ERROR_NONE = TIZEN_ERROR_NONE, /**< Successful */
RUNTIME_INFO_ERROR_INVALID_PARAMETER = TIZEN_ERROR_INVALID_PARAMETER, /**< Invalid parameter */
RUNTIME_INFO_ERROR_OUT_OF_MEMORY = TIZEN_ERROR_OUT_OF_MEMORY, /**< Out of memory */
/**
* @brief Enumeration of key for runtime information
*/
-typedef enum
-{
+typedef enum {
RUNTIME_INFO_KEY_FLIGHT_MODE_ENABLED, /**<Indicates whether the device is in flight mode. */
RUNTIME_INFO_KEY_WIFI_STATUS, /**<Indicates the current status of Wi-Fi. */
RUNTIME_INFO_KEY_BLUETOOTH_ENABLED, /**<Indicates whether Bluetooth is enabled. */
RUNTIME_INFO_KEY_DATA_ROAMING_ENABLED, /**<Indicates whether data roaming is enabled. */
RUNTIME_INFO_KEY_SILENT_MODE_ENABLED, /**<Indicates whether the device is in silent mode. */
RUNTIME_INFO_KEY_VIBRATION_ENABLED, /**<Indicates whether vibration is enabled. */
- RUNTIME_INFO_KEY_ROTATION_LOCK_ENABLED, /**<Indicates whether rotation lock is enabled. */
+ RUNTIME_INFO_KEY_ROTATION_LOCK_ENABLED,
RUNTIME_INFO_KEY_24HOUR_CLOCK_FORMAT_ENABLED, /**<Indicates whether 24-hour clock is enabled. */
RUNTIME_INFO_KEY_FIRST_DAY_OF_WEEK, /**<Indicates the first day of week. */
RUNTIME_INFO_KEY_LANGUAGE, /**<Indicates the current language setting. */
RUNTIME_INFO_KEY_USB_CONNECTED, /**<Indicates whether USB is connected. */
RUNTIME_INFO_KEY_CHARGER_CONNECTED, /**<Indicates whether charger is connected. */
RUNTIME_INFO_KEY_VIBRATION_LEVEL_HAPTIC_FEEDBACK, /**<Indicates the current vibration level of haptic feedback. */
+ RUNTIME_INFO_KEY_AUTO_ROTATION_ENABLED, /**<Indicates whether auto rotation is enabled. */
} runtime_info_key_e;
/**
* @brief Enumeration of Wi-Fi status
*/
-typedef enum
-{
+typedef enum {
RUNTIME_INFO_WIFI_STATUS_DISABLED, /**< GPS is disabled. */
RUNTIME_INFO_WIFI_STATUS_UNCONNECTED, /**< Wi-Fi is enabled and network connection is not established. */
RUNTIME_INFO_WIFI_STATUS_CONNECTED, /**< Network connection is established in Wi-Fi network. */
/**
* @brief Enumeration of GPS status
*/
-typedef enum
-{
+typedef enum {
RUNTIME_INFO_GPS_STATUS_DISABLED, /**< GPS is disabled. */
RUNTIME_INFO_GPS_STATUS_SEARCHING, /**< GPS is searching for satellites. */
RUNTIME_INFO_GPS_STATUS_CONNECTED, /**< GPS connection is established. */
/**
* @brief Enumeration of first day of week
*/
-typedef enum
-{
+typedef enum {
RUNTIME_INFO_FIRST_DAY_OF_WEEK_SUNDAY, /**< Sunday */
RUNTIME_INFO_FIRST_DAY_OF_WEEK_MONDAY, /**< Monday */
RUNTIME_INFO_FIRST_DAY_OF_WEEK_TUESDAY, /**< Tuesday */
/**
* @brief Enumeration of audio jack status
*/
-typedef enum
-{
+typedef enum {
RUNTIME_INFO_AUDIO_JACK_STATUS_UNCONNECTED, /**< audio jack is not connected */
RUNTIME_INFO_AUDIO_JACK_STATUS_CONNECTED_3WIRE, /**< 3-conductor wire is connected. */
RUNTIME_INFO_AUDIO_JACK_STATUS_CONNECTED_4WIRE, /**< 4-conductor wire is connected. */
/**
* @brief Gets the string value for specified runtime information
* @details This function gets current state of the given key which represents specific runtime information.
- * @remarks @a value must be released with @c free() by you.
+ * @remarks @a value must be released with @c free() by you.
* @param[in] key The runtime information key from which data should be read
* @param[out] value The current value of the given key
* @return 0 on success, otherwise a negative error value.
/**
- * @brief Unregisters the callback function.
+ * @brief Unregisters the callback function.
*
* @param[in] key The runtime information type
* @return 0 on success, otherwise a negative error value.
* 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.
*/
char *s;
} runtime_info_value_u;
-typedef runtime_info_value_u *runtime_info_value_h;
+typedef runtime_info_value_u * runtime_info_value_h;
typedef int (*runtime_info_func_get_value) (runtime_info_value_h value);
typedef int (*runtime_info_func_set_event_cb) (void);
void runtime_info_vibration_enabled_unset_event_cb(void);
int runtime_info_rotation_lock_enabled_get_value(runtime_info_value_h);
-int runtime_info_rotation_lock_enabled_set_event_cb(void);
-void runtime_info_rotation_lock_enabled_unset_event_cb(void);
int runtime_info_24hour_format_get_value(runtime_info_value_h);
int runtime_info_24hour_format_set_event_cb(void);
int runtime_info_vibration_level_haptic_feedback_set_event_cb();
void runtime_info_vibration_level_haptic_feedback_unset_event_cb();
+int runtime_info_auto_rotation_enabled_get_value(runtime_info_value_h);
+int runtime_info_auto_rotation_enabled_set_event_cb(void);
+void runtime_info_auto_rotation_enabled_unset_event_cb(void);
+
#ifdef __cplusplus
}
#endif
Name: capi-system-runtime-info
Summary: A Runtime Information library in Tizen Native API
-Version: 0.0.1
-Release: 9
+Version: 0.0.2
+Release: 0
Group: System/Libraries
License: Apache License, Version 2.0
Source0: %{name}-%{version}.tar.gz
%install
rm -rf %{buildroot}
+
+mkdir -p %{buildroot}/usr/share/license
+cp -f LICENSE %{buildroot}/usr/share/license/%{name}
+
%make_install
%post -p /sbin/ldconfig
%files
%{_libdir}/lib*.so.*
+/usr/share/license/%{name}
%manifest runtime-info.manifest
%files devel
%{_includedir}/system/*.h
%{_libdir}/pkgconfig/*.pc
%{_libdir}/lib*.so
+
+
RUNTIME_INFO_KEY_ROTATION_LOCK_ENABLED, /**<Indicates whether rotation lock is enabled. */
RUNTIME_INFO_DATA_TYPE_BOOL,
runtime_info_rotation_lock_enabled_get_value,
- runtime_info_rotation_lock_enabled_set_event_cb,
- runtime_info_rotation_lock_enabled_unset_event_cb,
+ NULL,
+ NULL,
NULL
},
NULL
},
-
{
RUNTIME_INFO_KEY_BATTERY_IS_CHARGING, /**<Indicates the battery is currently charging. */
RUNTIME_INFO_DATA_TYPE_BOOL,
NULL
},
-
{
RUNTIME_INFO_KEY_TV_OUT_CONNECTED, /**<Indicates whether TV out is connected. */
RUNTIME_INFO_DATA_TYPE_BOOL,
NULL
},
-
{
RUNTIME_INFO_KEY_AUDIO_JACK_STATUS, /**<Indicates the current status of audio jack. */
RUNTIME_INFO_DATA_TYPE_INT,
NULL
},
-
{
RUNTIME_INFO_KEY_SLIDING_KEYBOARD_OPENED, /**<Indicates whether sliding keyboard is opened. */
RUNTIME_INFO_DATA_TYPE_BOOL,
NULL
},
-
{
RUNTIME_INFO_KEY_USB_CONNECTED, /**<Indicates whether usb is connected. */
RUNTIME_INFO_DATA_TYPE_BOOL,
NULL
},
+{
+ RUNTIME_INFO_KEY_AUTO_ROTATION_ENABLED, /**<Indicates whether auto rotation is enabled. */
+ RUNTIME_INFO_DATA_TYPE_BOOL,
+ runtime_info_auto_rotation_enabled_get_value,
+ runtime_info_auto_rotation_enabled_set_event_cb,
+ runtime_info_auto_rotation_enabled_unset_event_cb,
+ NULL
+},
{
RUNTIME_INFO_MAX, RUNTIME_INFO_DATA_TYPE_INT, NULL, NULL, NULL, NULL
int runtime_info_rotation_lock_enabled_get_value(runtime_info_value_h value)
{
+ value->b = false;
+
+ return RUNTIME_INFO_ERROR_INVALID_PARAMETER;
+}
+
+int runtime_info_auto_rotation_enabled_get_value(runtime_info_value_h value)
+{
bool vconf_value;
if (runtime_info_vconf_get_value_bool(VCONF_ROTATION_LOCK_ENABLED, &vconf_value))
return RUNTIME_INFO_ERROR_NONE;
}
-int runtime_info_rotation_lock_enabled_set_event_cb()
+int runtime_info_auto_rotation_enabled_set_event_cb()
{
- return runtime_info_vconf_set_event_cb(VCONF_ROTATION_LOCK_ENABLED, RUNTIME_INFO_KEY_ROTATION_LOCK_ENABLED, 0);
+ return runtime_info_vconf_set_event_cb(VCONF_ROTATION_LOCK_ENABLED, RUNTIME_INFO_KEY_AUTO_ROTATION_ENABLED, 0);
}
-void runtime_info_rotation_lock_enabled_unset_event_cb()
+void runtime_info_auto_rotation_enabled_unset_event_cb()
{
runtime_info_vconf_unset_event_cb(VCONF_ROTATION_LOCK_ENABLED, 0);
}