bool
_WebImpl::OnFocusGained(const _ControlImpl& source)
{
- Ewk_Settings* pSettings = ewk_view_settings_get(__pWebCore->GetWebNativeNode());
- SysAssertf(pSettings, "Failed to get webkit instance.");
+ Evas_Object* pWebview = __pWebCore->GetWebNativeNode();
+ if (!pWebview)
+ {
+ return false;
+ }
+
+ Ewk_Settings* pSettings = ewk_view_settings_get(pWebview);
+ SysAssertf(pSettings, "Failed to get settings instance.");
ewk_settings_clear_text_selection_automatically_set(pSettings, true);
return false;
bool
_WebImpl::OnFocusLost(const _ControlImpl& source)
{
+ Evas_Object* pWebview = __pWebCore->GetWebNativeNode();
+ if (!pWebview)
+ {
+ return false;
+ }
+
if(IsKeypadVisible() == true)
{
SetKeypadOpened(true);
-
SetKeypadVisibleState(false);
}
- Ewk_Settings* pSettings = ewk_view_settings_get(__pWebCore->GetWebNativeNode());
- SysAssertf(pSettings, "Failed to get webkit instance.");
+ Ewk_Settings* pSettings = ewk_view_settings_get(pWebview);
+ SysAssertf(pSettings, "Failed to get settings instance.");
ewk_settings_clear_text_selection_automatically_set(pSettings, false);
- evas_object_focus_set(__pWebCore->GetWebNativeNode(), EINA_FALSE);
+ evas_object_focus_set(pWebview, EINA_FALSE);
return false;
}