IME_ATTR_FONTSTYLE, /**< A font style attribute, e.g., underline, etc. */
} ime_attribute_type;
+/**
+ * @brief Enumeration containing input panel events.
+ *
+ * @since_tizen 5.5
+ *
+ * @see ime_update_input_panel_event()
+ */
+typedef enum {
+ IME_EVENT_TYPE_LANGUAGE = 1, /**< The language of the input panel */
+ IME_EVENT_TYPE_SHIFT_MODE, /**< The shift key state of the input panel */
+ IME_EVENT_TYPE_GEOMETRY, /**< The size of the input panel */
+} ime_event_type_e;
+
/**
* @brief Value for #IME_ATTR_FONTSTYLE. Draw a line under the text.
* @since_tizen @if MOBILE 2.4 @else 3.0 @endif
*/
int ime_request_hide(void);
+/**
+ * @brief Updates the state of input panel event.
+ *
+ * @since_tizen 5.5
+ *
+ * @privlevel public
+ *
+ * @privilege %http://tizen.org/privilege/ime
+ *
+ * @param[in] type The input panel event type
+ * @param[in] value The value of event type
+ *
+ * @return 0 on success, otherwise a negative error value
+ * @retval #IME_ERROR_NONE No error
+ * @retval #IME_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #IME_ERROR_PERMISSION_DENIED The application does not have the privilege to call this function
+ * @retval #IME_ERROR_NOT_RUNNING IME main loop isn't started yet
+ *
+ * @see ime_event_type_e
+ */
+int ime_update_input_panel_event(ime_event_type_e type, unsigned int value);
+
/**
* @}
*/
return IME_ERROR_NONE;
}
-//LCOV_EXCL_STOP
\ No newline at end of file
+//LCOV_EXCL_STOP
+
+EXPORT_API int ime_update_input_panel_event(ime_event_type_e type, unsigned int value)
+{
+ ime_error_e retVal = IME_ERROR_NONE;
+
+ if (type >= IME_EVENT_TYPE_LANGUAGE && type <= IME_EVENT_TYPE_GEOMETRY) {
+ LOGW("IME_ERROR_INVALID_PARAMETER");
+ return IME_ERROR_INVALID_PARAMETER;
+ }
+
+ if (!g_running) {
+ LOGW("IME_ERROR_NOT_RUNNING");
+ return IME_ERROR_NOT_RUNNING;
+ }
+
+ retVal = _check_privilege();
+ if (retVal != IME_ERROR_NONE) return retVal;
+
+ g_core.update_input_context(type, value);
+
+ return IME_ERROR_NONE;
+}