#ifndef FullscreenController_h
#define FullscreenController_h
+#include "platform/geometry/FloatPoint.h"
#include "platform/geometry/IntSize.h"
+#include "platform/heap/Handle.h"
#include "wtf/PassOwnPtr.h"
#include "wtf/RefPtr.h"
-namespace WebCore {
-class Element;
-class Frame;
-}
-
namespace blink {
+
+class Element;
+class LocalFrame;
class WebViewImpl;
-class FullscreenController {
+class FullscreenController FINAL : public NoBaseWillBeGarbageCollected<FullscreenController> {
public:
- static PassOwnPtr<FullscreenController> create(WebViewImpl*);
+ static PassOwnPtrWillBeRawPtr<FullscreenController> create(WebViewImpl*);
- void willEnterFullScreen();
void didEnterFullScreen();
- void willExitFullScreen();
void didExitFullScreen();
- void enterFullScreenForElement(WebCore::Element*);
- void exitFullScreenForElement(WebCore::Element*);
+ void enterFullScreenForElement(Element*);
+ void exitFullScreenForElement(Element*);
+
+ bool isFullscreen() { return m_fullScreenFrame; }
+
+ void trace(Visitor*);
protected:
explicit FullscreenController(WebViewImpl*);
WebViewImpl* m_webViewImpl;
float m_exitFullscreenPageScaleFactor;
- WebCore::IntSize m_exitFullscreenScrollOffset;
+ IntSize m_exitFullscreenScrollOffset;
+ FloatPoint m_exitFullscreenPinchViewportOffset;
// If set, the WebView is transitioning to fullscreen for this element.
- RefPtr<WebCore::Element> m_provisionalFullScreenElement;
+ RefPtrWillBeMember<Element> m_provisionalFullScreenElement;
// If set, the WebView is in fullscreen mode for an element in this frame.
- RefPtr<WebCore::Frame> m_fullScreenFrame;
+ RefPtrWillBeMember<LocalFrame> m_fullScreenFrame;
bool m_isCancelingFullScreen;
};
-}
+} // namespace blink
#endif
-