White screen and scrollbar while touching big and fitted image.
authorRyuan Choi <ryuan.choi@samsung.com>
Tue, 8 Oct 2013 03:15:23 +0000 (12:15 +0900)
committerGerrit Code Review <gerrit@gerrit.vlan144.tizendev.org>
Tue, 8 Oct 2013 07:13:45 +0000 (07:13 +0000)
[Title] White screen and scrollbar while touching big and fitted image.
[Issue#] N_SE-45748
[Problem] When loaded image, fitting is a feature of webkit and scaled up when clicked.
          But, scaling is consist of two step.
          scaling and scroll.
          Because of multi process arch, these are sent individusaly.
          So, screen was blinked one time.
[Cause] clicking is not proper mobile.
[Solution] Disable scale behavior of clicking image.
           webkit have an option to disable it, but it has another side effect.
           So I just guard it as workaround.

Change-Id: I6ea74d3b22e7207a5cac772c522f51bb141499a1

Source/WTF/wtf/Platform.h
Source/WebCore/html/ImageDocument.cpp

index f59a8e8..e29f937 100644 (file)
 #define ENABLE_TIZEN_DISABLE_CUSTOM_SCROLLBAR 1 /* Ryuan Choi(ryuan.choi@samsung.com) : disable custom scrollbar (modified from r134878) */
 #define ENABLE_TIZEN_SYSTEM_FONT 1 /* Ryuan Choi(ryuan.choi@samsung.com) : Bug fix, default width of input field is too big. */
 #define ENABLE_TIZEN_THEME_STYLE_WORKAROUND 1 /* Ryuan Choi(ryuan.choi@samsung.com) : css of input should be flexible. workaround until trunk is upstreamed.*/
+#define ENABLE_TIZEN_CLICK_IMAGE_WORKAROUND 1 /* Ryuan Choi(ryuan.choi@samsung.com) : clicking image(with fitted) is a feature of browser but buggy on WK2 */
 #define ENABLE_TIZEN_THEME_SCALE_SUPPORT 1 /* Ryuan Choi(ryuan.choi@samsung.com) : scaled theme support.*/
 #define ENABLE_TIZEN_VIEWPORT_META_TAG 1 /* Gyuyoung Kim(gyuyoung.kim@samsung.com) : Support viewport meta tag */
 #define ENABLE_TIZEN_CERTIFICATE_HANDLING 1 /* Krzysztof Czech(k.czech@samsung.com) : support for certificate callback function set by UI */ /* DongJae KIM : Enable Patch*/
index 9789953..b6ecbf5 100644 (file)
@@ -265,6 +265,7 @@ void ImageDocument::resizeImageToFit()
 
 void ImageDocument::imageClicked(int x, int y)
 {
+#if !ENABLE(TIZEN_CLICK_IMAGE_WORKAROUND)
     if (!m_imageSizeIsKnown || imageFitsInWindow())
         return;
 
@@ -284,6 +285,7 @@ void ImageDocument::imageClicked(int x, int y)
         
         frame()->view()->setScrollPosition(IntPoint(scrollX, scrollY));
     }
+#endif
 }
 
 void ImageDocument::imageUpdated()