Title: [124913] trunk/Source/WebKit/blackberry
- Revision
- 124913
- Author
- [email protected]
- Date
- 2012-08-07 13:15:57 -0700 (Tue, 07 Aug 2012)
Log Message
[BlackBerry] [FullScreen] No need to scroll 'x' to 0 before entering fullscreen
https://bugs.webkit.org/show_bug.cgi?id=91750
PR #178293
Reviewed by Rob Buis.
Patchby Antonio Gomes <[email protected]>
We are not adjusting the 'left' CSS property of the fullscreen wrapper
properly, so no need to scroll 'x' to 0 anymore.
Internally reviewed by Jacky Jiang.
* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::enterFullScreenForElement):
Modified Paths
Diff
Modified: trunk/Source/WebKit/blackberry/Api/WebPage.cpp (124912 => 124913)
--- trunk/Source/WebKit/blackberry/Api/WebPage.cpp 2012-08-07 20:15:26 UTC (rev 124912)
+++ trunk/Source/WebKit/blackberry/Api/WebPage.cpp 2012-08-07 20:15:57 UTC (rev 124913)
@@ -6083,14 +6083,11 @@
// is so that exitFullScreenForElement() gets called later.
enterFullscreenForNode(element);
} else {
- // When an element goes fullscreen, it gets cloned and added to a higher index
- // wrapper/container node, created out of the DOM tree. This wrapper is fixed
- // position, but since our fixed position logic respects only the 'y' coordinate,
- // we temporarily scroll the WebPage to x:0 so that the wrapper gets properly
- // positioned. The original scroll position is restored once element leaves fullscreen.
+ // When an element goes fullscreen, the viewport size changes and the scroll
+ // position might change. So we keep track of it here, in order to restore it
+ // once element leaves fullscreen.
WebCore::IntPoint scrollPosition = m_mainFrame->view()->scrollPosition();
m_xScrollOffsetBeforeFullScreen = scrollPosition.x();
- m_mainFrame->view()->setScrollPosition(WebCore::IntPoint(0, scrollPosition.y()));
// The current scale can be clamped to a greater minimum scale when we relayout contents during
// the change of the viewport size. Cache the current scale so that we can restore it when
Modified: trunk/Source/WebKit/blackberry/ChangeLog (124912 => 124913)
--- trunk/Source/WebKit/blackberry/ChangeLog 2012-08-07 20:15:26 UTC (rev 124912)
+++ trunk/Source/WebKit/blackberry/ChangeLog 2012-08-07 20:15:57 UTC (rev 124913)
@@ -1,5 +1,21 @@
2012-08-07 Antonio Gomes <[email protected]>
+ [BlackBerry] [FullScreen] No need to scroll 'x' to 0 before entering fullscreen
+ https://bugs.webkit.org/show_bug.cgi?id=91750
+ PR #178293
+
+ Reviewed by Rob Buis.
+
+ We are not adjusting the 'left' CSS property of the fullscreen wrapper
+ properly, so no need to scroll 'x' to 0 anymore.
+
+ Internally reviewed by Jacky Jiang.
+
+ * Api/WebPage.cpp:
+ (BlackBerry::WebKit::WebPagePrivate::enterFullScreenForElement):
+
+2012-08-07 Antonio Gomes <[email protected]>
+
[BlackBerry][FullScreen] Remove the set/reset of touch modes code when entering/leaving fullscreen
https://bugs.webkit.org/show_bug.cgi?id=92520
PR #184511
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes