[M69 Dev][TV][hotfix] Set the default geometry for webview when size is invalid 74/189974/8
authorSha Yuhong <yuhong.sha@samsung.com>
Fri, 1 Jun 2018 13:09:55 +0000 (21:09 +0800)
committerBot Blink <blinkbot@samsung.com>
Mon, 19 Nov 2018 05:38:21 +0000 (05:38 +0000)
In Tizen 5.0 on engine side we get invalid size(84*24)
in resize callback as a result web app is not displayed on TV.
We suspect this issue to be vd crosswalk or efl platform side.
This is a hotfix to display webapp on TV.

Reference:
https://review.tizen.org/gerrit/#/c/180736/

Change-Id: Ica3e434be6c995a25e7c2062143ae06b6118b0ae
Signed-off-by: Sha Yuhong <yuhong.sha@samsung.com>
Signed-off-by: Uzair <uzair.jaleel@samsung.com>
tizen_src/ewk/efl_integration/private/ewk_view_private.cc

index 56a3dfb..5b24d8a 100644 (file)
@@ -131,6 +131,17 @@ void handleEvasObjectResize(Evas_Object* o, Evas_Coord width, Evas_Coord height)
   if (!wv) {
     return;
   }
+
+#if defined(OS_TIZEN_TV_PRODUCT) && defined(EWK_BRINGUP)
+  // FIXME: Need to be checked from vd crosswalk or efl side as
+  // to why web engine gets invalid size here
+  if (width == 82 && height == 24) {
+    LOG(ERROR) << "hardcode size as 1920 * 1080 for invalid size";
+    width = 1920;
+    height = 1080;
+    evas_object_geometry_set(o, 0, 0, width, height);
+  }
+#endif
   d->view.w = width;
   d->view.h = height;
   wv->HandleResize(width, height);