From: Jihoon Kim Date: Tue, 29 Dec 2020 11:39:39 +0000 (+0900) Subject: Add interface to notify the update of input hint X-Git-Tag: submit/tizen/20201231.041701~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F63%2F250563%2F3;p=platform%2Fcore%2Fuifw%2Flibscl-core.git Add interface to notify the update of input hint Change-Id: I5a25ff39181fef2a487f58fbc8a879aef833606d Signed-off-by: Jihoon Kim --- diff --git a/src/sclconnection-isf.cpp b/src/sclconnection-isf.cpp index 295f08e..667a1e3 100644 --- a/src/sclconnection-isf.cpp +++ b/src/sclconnection-isf.cpp @@ -765,6 +765,16 @@ static void slot_set_prediction_allow(const scim::HelperAgent *agent, scim::uint } } +static void slot_set_input_hint(const scim::HelperAgent *agent, scim::uint32 &input_hint) { + CSCLCoreImpl *impl = CSCLCoreImpl::get_instance(); + if (impl) { + ISCLCoreEventCallback *callback = impl->get_core_event_callback(); + if (callback) { + callback->on_set_input_hint(input_hint); + } + } +} + /* Internal input handler function */ Eina_Bool input_handler(void *data, Ecore_Fd_Handler *fd_handler) { @@ -867,6 +877,7 @@ sclboolean CSCLConnectionISF::init() m_helper_agent.signal_connect_process_key_event_with_imengine(scim::slot(slot_process_key_event_with_imengine)); m_helper_agent.signal_connect_set_autocapital_type(scim::slot(slot_set_autocapital_type)); m_helper_agent.signal_connect_set_prediction_allow(scim::slot(slot_set_prediction_allow)); + m_helper_agent.signal_connect_set_input_hint(scim::slot(slot_set_input_hint)); m_initialized = TRUE; } diff --git a/src/sclcorecallback.h b/src/sclcorecallback.h index 1b76360..08dbe9f 100644 --- a/src/sclcorecallback.h +++ b/src/sclcorecallback.h @@ -100,6 +100,7 @@ struct ISCLCoreEventCallback { virtual void on_set_optimization_hint(sclu32 hint) {} virtual void on_set_autocapital_type(sclu32 type) {} virtual void on_set_prediction_allow(sclu32 prediction_allow) {} + virtual void on_set_input_hint(sclu32 input_hint) {} virtual void on_trigger_property(const sclchar *property) {} ISCLCoreEventCallback() {