Fix horizontal scroll issue
authorGyuyoung Kim <gyuyoung.kim@samsung.com>
Wed, 3 Jul 2013 06:21:08 +0000 (15:21 +0900)
committerGerrit Code Review <gerrit@gerrit.vlan144.tizendev.org>
Wed, 3 Jul 2013 06:23:50 +0000 (06:23 +0000)
[Issue#] N_SE-41768
[Problem] A page doesn't be scrolled on skype.com after logging in.
[Cause] A workaround patch of Viewport meta tag influences on this issue.
[Solution] Change existing condition for this issue

Change-Id: Id0d785c8b59bd3aee24d32a021fbf758fece4577

Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp

index acb4939..5d47646 100755 (executable)
@@ -506,6 +506,7 @@ PlatformPageClient WebChromeClient::platformPageClient() const
 }
 
 #if ENABLE(TIZEN_VIEWPORT_META_TAG)
+static const int landscapeWidth = 640;
 bool WebChromeClient::canContentsSizeChange(Frame* frame, const IntSize& size) const
 {
     // FIXME1: This patch should be removed AS SOON AS unexpected layout change problem is fixed.
@@ -515,13 +516,9 @@ bool WebChromeClient::canContentsSizeChange(Frame* frame, const IntSize& size) c
     // ex) www.adobe.com - fixedLayoutSize.width: 360, changedContentsSize: 950
     // ex) www.mt.co.kr (desktop site) - fixedLayoutSize.width: 980, changedContentsSize: 1090
     FrameView* view = m_page->mainFrame()->view();
-    if (view->fixedLayoutSize().width() != size.width()
-        && size.width() < m_page->viewportSize().width()
-        // This condition is for regression by this work-around patch.
-        // http://en.wordpress.com/wp-login.php?action=lostpassword site doesn't work by this patch.
-        // This patch should be removed as soon as possible.
-        && m_page->corePage()->viewportArguments().initialScale > 0.9)
+    if (view->fixedLayoutSize().width() < size.width() && size.width() < landscapeWidth)
         return false;
+
     return true;
 }
 #endif