Skip to content
Permalink
Browse files
[BlackBerry] browser video player fullscreen mode (portrait) - out of…
… screen/focus - cannot navigate or use the buttons on the screen (PART III)

https://bugs.webkit.org/show_bug.cgi?id=88019

Reviewed by George Staikos.
Patch by Antonio Gomes <agomes@rim.com>

Enter 'pure-with-mouse-conversion' mode when going fullscreen, so
that it prevents user from scrolling the WebPage, pinch zooming,
touch-and-hold, enter selection mode, etc ...

Internally reviewed by Gen Mak.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::WebPagePrivate):
(BlackBerry::WebKit::WebPagePrivate::enterFullScreenForElement):
(BlackBerry::WebKit::WebPagePrivate::exitFullScreenForElement):
* Api/WebPage_p.h:
(WebPagePrivate):

Canonical link: https://commits.webkit.org/105998@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@119322 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
Antonio Gomes committed Jun 2, 2012
1 parent 7f0d5f8 commit 8f1660780056f748655dbc6ffe4a124bf44bf935
Showing 3 changed files with 34 additions and 0 deletions.
@@ -357,6 +357,9 @@ WebPagePrivate::WebPagePrivate(WebPage* webPage, WebPageClient* client, const In
#if ENABLE(EVENT_MODE_METATAGS)
, m_cursorEventMode(ProcessedCursorEvents)
, m_touchEventMode(ProcessedTouchEvents)
#if ENABLE(FULLSCREEN_API)
, m_touchEventModePriorGoingFullScreen(ProcessedTouchEvents)
#endif
#endif
#if ENABLE(FULLSCREEN_API)
, m_xScrollOffsetPriorGoingFullScreen(-1)
@@ -6095,6 +6098,10 @@ void WebPagePrivate::enterFullScreenForElement(Element* element)
m_xScrollOffsetPriorGoingFullScreen = scrollPosition.x();
m_mainFrame->view()->setScrollPosition(WebCore::IntPoint(0, scrollPosition.y()));

#if ENABLE(EVENT_MODE_METATAGS)
m_touchEventModePriorGoingFullScreen = m_touchEventMode;
didReceiveTouchEventMode(PureTouchEventsWithMouseConversion);
#endif
// No fullscreen video widget has been made available by the Browser
// chrome, or this is not a video element. The webkitRequestFullScreen
// Javascript call is often made on a div element.
@@ -6122,6 +6129,10 @@ void WebPagePrivate::exitFullScreenForElement(Element* element)
WebCore::IntPoint(m_xScrollOffsetPriorGoingFullScreen, scrollPosition.y()));
m_xScrollOffsetPriorGoingFullScreen = -1;

#if ENABLE(EVENT_MODE_METATAGS)
didReceiveTouchEventMode(m_touchEventModePriorGoingFullScreen);
m_touchEventModePriorGoingFullScreen = ProcessedTouchEvents;
#endif
// This is where we would restore the browser's chrome
// if hidden above.
client()->fullscreenStop();
@@ -491,6 +491,9 @@ class WebPagePrivate : public PageClientBlackBerry, public WebSettingsDelegate,
#endif

#if ENABLE(FULLSCREEN_API)
#if ENABLE(EVENT_MODE_METATAGS)
WebCore::TouchEventMode m_touchEventModePriorGoingFullScreen;
#endif
int m_xScrollOffsetPriorGoingFullScreen;
#endif

@@ -1,3 +1,23 @@
2012-06-02 Antonio Gomes <agomes@rim.com>

[BlackBerry] browser video player fullscreen mode (portrait) - out of screen/focus - cannot navigate or use the buttons on the screen (PART III)
https://bugs.webkit.org/show_bug.cgi?id=88019

Reviewed by George Staikos.

Enter 'pure-with-mouse-conversion' mode when going fullscreen, so
that it prevents user from scrolling the WebPage, pinch zooming,
touch-and-hold, enter selection mode, etc ...

Internally reviewed by Gen Mak.

* Api/WebPage.cpp:
(BlackBerry::WebKit::WebPagePrivate::WebPagePrivate):
(BlackBerry::WebKit::WebPagePrivate::enterFullScreenForElement):
(BlackBerry::WebKit::WebPagePrivate::exitFullScreenForElement):
* Api/WebPage_p.h:
(WebPagePrivate):

2012-06-02 Antonio Gomes <agomes@rim.com>

[BlackBerry] browser video player fullscreen mode (portrait) - out of screen/focus - cannot navigate or use the buttons on the screen (PART II)

0 comments on commit 8f16607

Please sign in to comment.