summaryrefslogtreecommitdiff
path: root/Source/WebCore/page/DOMWindow.h
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@digia.com>2013-09-13 12:51:20 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-09-19 20:50:05 +0200
commitd441d6f39bb846989d95bcf5caf387b42414718d (patch)
treee367e64a75991c554930278175d403c072de6bb8 /Source/WebCore/page/DOMWindow.h
parent0060b2994c07842f4c59de64b5e3e430525c4b90 (diff)
downloadqtwebkit-d441d6f39bb846989d95bcf5caf387b42414718d.tar.gz
Import Qt5x2 branch of QtWebkit for Qt 5.2
Importing a new snapshot of webkit. Change-Id: I2d01ad12cdc8af8cb015387641120a9d7ea5f10c Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com>
Diffstat (limited to 'Source/WebCore/page/DOMWindow.h')
-rw-r--r--Source/WebCore/page/DOMWindow.h52
1 files changed, 34 insertions, 18 deletions
diff --git a/Source/WebCore/page/DOMWindow.h b/Source/WebCore/page/DOMWindow.h
index 79029d08b..38f07828f 100644
--- a/Source/WebCore/page/DOMWindow.h
+++ b/Source/WebCore/page/DOMWindow.h
@@ -35,7 +35,7 @@
namespace WebCore {
- class BarInfo;
+ class BarProp;
class CSSRuleList;
class CSSStyleDeclaration;
class Console;
@@ -59,6 +59,7 @@ namespace WebCore {
class Navigator;
class Node;
class Page;
+ class PageConsole;
class Performance;
class PostMessageTimer;
class ScheduledAction;
@@ -69,6 +70,7 @@ namespace WebCore {
class Storage;
class StyleMedia;
class WebKitPoint;
+ class DOMWindowCSS;
#if ENABLE(REQUEST_ANIMATION_FRAME)
class RequestAnimationFrameCallback;
@@ -122,9 +124,6 @@ namespace WebCore {
static FloatRect adjustWindowRect(Page*, const FloatRect& pendingChanges);
- // FIXME: We can remove this function once V8 showModalDialog is changed to use DOMWindow.
- static void parseModalDialogFeatures(const String&, HashMap<String, String>&);
-
bool allowPopUp(); // Call on first window, not target window.
static bool allowPopUp(Frame* firstFrame);
static bool canShowModalDialog(const Frame*);
@@ -135,12 +134,12 @@ namespace WebCore {
Screen* screen() const;
History* history() const;
Crypto* crypto() const;
- BarInfo* locationbar() const;
- BarInfo* menubar() const;
- BarInfo* personalbar() const;
- BarInfo* scrollbars() const;
- BarInfo* statusbar() const;
- BarInfo* toolbar() const;
+ BarProp* locationbar() const;
+ BarProp* menubar() const;
+ BarProp* personalbar() const;
+ BarProp* scrollbars() const;
+ BarProp* statusbar() const;
+ BarProp* toolbar() const;
Navigator* navigator() const;
Navigator* clientInformation() const { return navigator(); }
@@ -235,12 +234,13 @@ namespace WebCore {
PassRefPtr<WebKitPoint> webkitConvertPointFromNodeToPage(Node*, const WebKitPoint*) const;
Console* console() const;
+ PageConsole* pageConsole() const;
void printErrorMessage(const String&);
String crossDomainAccessErrorMessage(DOMWindow* activeWindow);
void postMessage(PassRefPtr<SerializedScriptValue> message, const MessagePortArray*, const String& targetOrigin, DOMWindow* source, ExceptionCode&);
- // FIXME: remove this when we update the ObjC bindings (bug #28774).
+ // Needed for Objective-C bindings (see bug 28774).
void postMessage(PassRefPtr<SerializedScriptValue> message, MessagePort*, const String& targetOrigin, DOMWindow* source, ExceptionCode&);
void postMessageTimerFired(PassOwnPtr<PostMessageTimer>);
void dispatchMessageEventWithOriginCheck(SecurityOrigin* intendedTargetOrigin, PassRefPtr<Event>, PassRefPtr<ScriptCallStack>);
@@ -268,6 +268,10 @@ namespace WebCore {
void cancelAnimationFrame(int id);
#endif
+#if ENABLE(CSS3_CONDITIONAL_RULES)
+ DOMWindowCSS* css();
+#endif
+
// Events
// EventTarget API
virtual bool addEventListener(const AtomicString& eventType, PassRefPtr<EventListener>, bool useCapture);
@@ -276,6 +280,7 @@ namespace WebCore {
using EventTarget::dispatchEvent;
bool dispatchEvent(PassRefPtr<Event> prpEvent, PassRefPtr<EventTarget> prpTarget);
+
void dispatchLoadEvent();
DEFINE_ATTRIBUTE_EVENT_LISTENER(abort);
@@ -311,6 +316,8 @@ namespace WebCore {
DEFINE_ATTRIBUTE_EVENT_LISTENER(loadstart);
DEFINE_ATTRIBUTE_EVENT_LISTENER(message);
DEFINE_ATTRIBUTE_EVENT_LISTENER(mousedown);
+ DEFINE_ATTRIBUTE_EVENT_LISTENER(mouseenter);
+ DEFINE_ATTRIBUTE_EVENT_LISTENER(mouseleave);
DEFINE_ATTRIBUTE_EVENT_LISTENER(mousemove);
DEFINE_ATTRIBUTE_EVENT_LISTENER(mouseout);
DEFINE_ATTRIBUTE_EVENT_LISTENER(mouseover);
@@ -348,6 +355,7 @@ namespace WebCore {
DEFINE_MAPPED_ATTRIBUTE_EVENT_LISTENER(webkitanimationiteration, webkitAnimationIteration);
DEFINE_MAPPED_ATTRIBUTE_EVENT_LISTENER(webkitanimationend, webkitAnimationEnd);
DEFINE_MAPPED_ATTRIBUTE_EVENT_LISTENER(webkittransitionend, webkitTransitionEnd);
+ DEFINE_MAPPED_ATTRIBUTE_EVENT_LISTENER(transitionend, transitionend);
void captureEvents();
void releaseEvents();
@@ -404,10 +412,14 @@ namespace WebCore {
void willDetachDocumentFromFrame();
void willDestroyCachedFrame();
+ void enableSuddenTermination();
+ void disableSuddenTermination();
+
private:
explicit DOMWindow(Document*);
Page* page();
+ bool allowedToChangeWindowGeometry() const;
virtual void frameDestroyed() OVERRIDE;
virtual void willDetachPage() OVERRIDE;
@@ -417,7 +429,7 @@ namespace WebCore {
virtual EventTargetData* eventTargetData();
virtual EventTargetData* ensureEventTargetData();
- static Frame* createWindow(const String& urlString, const AtomicString& frameName, const WindowFeatures&,
+ static PassRefPtr<Frame> createWindow(const String& urlString, const AtomicString& frameName, const WindowFeatures&,
DOMWindow* activeWindow, Frame* firstFrame, Frame* openerFrame,
PrepareDialogFunction = 0, void* functionContext = 0);
bool isInsecureScriptAccess(DOMWindow* activeWindow, const String& urlString);
@@ -435,12 +447,12 @@ namespace WebCore {
mutable RefPtr<Screen> m_screen;
mutable RefPtr<History> m_history;
mutable RefPtr<Crypto> m_crypto;
- mutable RefPtr<BarInfo> m_locationbar;
- mutable RefPtr<BarInfo> m_menubar;
- mutable RefPtr<BarInfo> m_personalbar;
- mutable RefPtr<BarInfo> m_scrollbars;
- mutable RefPtr<BarInfo> m_statusbar;
- mutable RefPtr<BarInfo> m_toolbar;
+ mutable RefPtr<BarProp> m_locationbar;
+ mutable RefPtr<BarProp> m_menubar;
+ mutable RefPtr<BarProp> m_personalbar;
+ mutable RefPtr<BarProp> m_scrollbars;
+ mutable RefPtr<BarProp> m_statusbar;
+ mutable RefPtr<BarProp> m_toolbar;
mutable RefPtr<Console> m_console;
mutable RefPtr<Navigator> m_navigator;
mutable RefPtr<Location> m_location;
@@ -458,6 +470,10 @@ namespace WebCore {
#if ENABLE(WEB_TIMING)
mutable RefPtr<Performance> m_performance;
#endif
+
+#if ENABLE(CSS3_CONDITIONAL_RULES)
+ mutable RefPtr<DOMWindowCSS> m_css;
+#endif
};
inline String DOMWindow::status() const