const int ORIENTATION_LANDSCAPE_ANGLE = 270;
const int ORIENTATION_PORTAIT_ANGLE = 0;
+const int W3C_SCREEN_ORI_PORTRAIT_PRIMARY = 0;
+const int W3C_SCREEN_ORI_LANDSCAPE_PRIMARY = 90;
+
static Eina_Bool exitAppIdlerCallback(void* /*data*/)
{
// webapp termination
{
LogInfo("Tizen scheme: " << uri << " orientation landscape");
elm_win_rotation_with_resize_set(window, ORIENTATION_LANDSCAPE_ANGLE);
+ ewk_view_orientation_send(wkView, W3C_SCREEN_ORI_LANDSCAPE_PRIMARY);
return true;
} else if (strncmp(uri,
TIZEN_ORIENTATION_PORTAIT,
{
LogInfo("Tizen scheme: " << uri << " orientation portait");
elm_win_rotation_with_resize_set(window, ORIENTATION_PORTAIT_ANGLE);
+ ewk_view_orientation_send(wkView, W3C_SCREEN_ORI_PORTRAIT_PRIMARY);
return true;
} else if (strncmp(uri,
TIZEN_ORIENTATION_RESET,
{
LogInfo("Tizen scheme: " << uri << " reset");
elm_win_rotation_with_resize_set(window, ORIENTATION_PORTAIT_ANGLE);
+ ewk_view_orientation_send(wkView, W3C_SCREEN_ORI_PORTRAIT_PRIMARY);
return true;
} else if (strncmp(uri,
TIZEN_CHANGE_USERAGNET,
WidgetSettingScreenLock rotationValue = settings.getRotationValue();
if (rotationValue == Screen_Portrait) {
elm_win_rotation_with_resize_set(m_windowData->m_win, 0);
+ ewk_view_orientation_send(m_widget->GetCurrentWebview(), 0);
} else if (rotationValue == Screen_Landscape) {
elm_win_rotation_with_resize_set(m_windowData->m_win, 270);
+ ewk_view_orientation_send(m_widget->GetCurrentWebview(), 90);
} else {
elm_win_rotation_with_resize_set(m_windowData->m_win, 0);
+ ewk_view_orientation_send(m_widget->GetCurrentWebview(), 0);
}
}
}