1/* 2 * Copyright (C) 2006, 2007, 2009, 2010 Apple Inc. All rights reserved. 3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright 9 * notice, this list of conditions and the following disclaimer. 10 * 2. Redistributions in binary form must reproduce the above copyright 11 * notice, this list of conditions and the following disclaimer in the 12 * documentation and/or other materials provided with the distribution. 13 * 14 * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY 15 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 16 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 17 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR 18 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 19 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 20 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 21 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY 22 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 24 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25 */ 26 27#ifndef DOMWindow_h 28#define DOMWindow_h 29 30#include "ContextDestructionObserver.h" 31#include "EventTarget.h" 32#include "FrameDestructionObserver.h" 33#include "URL.h" 34#include "Supplementable.h" 35#include <functional> 36#include <memory> 37 38namespace Inspector { 39class ScriptCallStack; 40} 41 42namespace WebCore { 43 44 class BarProp; 45 class CSSRuleList; 46 class CSSStyleDeclaration; 47 class Crypto; 48 class DOMApplicationCache; 49 class DOMSelection; 50 class DOMURL; 51 class DOMWindowCSS; 52 class DOMWindowProperty; 53 class DOMWrapperWorld; 54 class Database; 55 class DatabaseCallback; 56 class Document; 57 class Element; 58 class EventListener; 59 class FloatRect; 60 class Frame; 61 class History; 62 class IDBFactory; 63 class Location; 64 class MediaQueryList; 65 class MessageEvent; 66 class Navigator; 67 class Node; 68 class Page; 69 class PageConsole; 70 class Performance; 71 class PostMessageTimer; 72 class ScheduledAction; 73 class Screen; 74 class SecurityOrigin; 75 class SerializedScriptValue; 76 class Storage; 77 class StyleMedia; 78 class WebKitNamespace; 79 class WebKitPoint; 80 81#if ENABLE(REQUEST_ANIMATION_FRAME) 82 class RequestAnimationFrameCallback; 83#endif 84 85 struct WindowFeatures; 86 87 typedef Vector<RefPtr<MessagePort>, 1> MessagePortArray; 88 89 typedef int ExceptionCode; 90 91 enum SetLocationLocking { LockHistoryBasedOnGestureState, LockHistoryAndBackForwardList }; 92 93 // FIXME: DOMWindow shouldn't subclass FrameDestructionObserver and instead should get to Frame via its Document. 94 class DOMWindow final 95 : public RefCounted<DOMWindow> 96 , public EventTargetWithInlineData 97 , public ContextDestructionObserver 98 , public FrameDestructionObserver 99 , public Supplementable<DOMWindow> { 100 public: 101 static PassRefPtr<DOMWindow> create(Document* document) { return adoptRef(new DOMWindow(document)); } 102 virtual ~DOMWindow(); 103 104 // In some rare cases, we'll re-used a DOMWindow for a new Document. For example, 105 // when a script calls window.open("..."), the browser gives JavaScript a window 106 // synchronously but kicks off the load in the window asynchronously. Web sites 107 // expect that modifications that they make to the window object synchronously 108 // won't be blown away when the network load commits. To make that happen, we 109 // "securely transition" the existing DOMWindow to the Document that results from 110 // the network load. See also SecurityContext::isSecureTransitionTo. 111 void didSecureTransitionTo(Document*); 112 113 virtual EventTargetInterface eventTargetInterface() const override { return DOMWindowEventTargetInterfaceType; } 114 virtual ScriptExecutionContext* scriptExecutionContext() const override { return ContextDestructionObserver::scriptExecutionContext(); } 115 116 virtual DOMWindow* toDOMWindow() override; 117 118 void registerProperty(DOMWindowProperty*); 119 void unregisterProperty(DOMWindowProperty*); 120 121 void resetUnlessSuspendedForPageCache(); 122 void suspendForPageCache(); 123 void resumeFromPageCache(); 124 125 PassRefPtr<MediaQueryList> matchMedia(const String&); 126 127 unsigned pendingUnloadEventListeners() const; 128 129 static bool dispatchAllPendingBeforeUnloadEvents(); 130 static void dispatchAllPendingUnloadEvents(); 131 132 static FloatRect adjustWindowRect(Page*, const FloatRect& pendingChanges); 133 134 bool allowPopUp(); // Call on first window, not target window. 135 static bool allowPopUp(Frame* firstFrame); 136 static bool canShowModalDialog(const Frame*); 137 static bool canShowModalDialogNow(const Frame*); 138 139 // DOM Level 0 140 141 Screen* screen() const; 142 History* history() const; 143 Crypto* crypto() const; 144 BarProp* locationbar() const; 145 BarProp* menubar() const; 146 BarProp* personalbar() const; 147 BarProp* scrollbars() const; 148 BarProp* statusbar() const; 149 BarProp* toolbar() const; 150 Navigator* navigator() const; 151 Navigator* clientInformation() const { return navigator(); } 152 153 Location* location() const; 154 void setLocation(const String& location, DOMWindow& activeWindow, DOMWindow& firstWindow, 155 SetLocationLocking = LockHistoryBasedOnGestureState); 156 157 DOMSelection* getSelection(); 158 159 Element* frameElement() const; 160 161 void focus(ScriptExecutionContext* = 0); 162 void blur(); 163 void close(ScriptExecutionContext* = 0); 164 void print(); 165 void stop(); 166 167 PassRefPtr<DOMWindow> open(const String& urlString, const AtomicString& frameName, const String& windowFeaturesString, 168 DOMWindow& activeWindow, DOMWindow& firstWindow); 169 170 void showModalDialog(const String& urlString, const String& dialogFeaturesString, DOMWindow& activeWindow, DOMWindow& firstWindow, std::function<void (DOMWindow&)> prepareDialogFunction); 171 172 void alert(const String& message); 173 bool confirm(const String& message); 174 String prompt(const String& message, const String& defaultValue); 175 String btoa(const String& stringToEncode, ExceptionCode&); 176 String atob(const String& encodedString, ExceptionCode&); 177 178 bool find(const String&, bool caseSensitive, bool backwards, bool wrap, bool wholeWord, bool searchInFrames, bool showDialog) const; 179 180 bool offscreenBuffering() const; 181 182 int outerHeight() const; 183 int outerWidth() const; 184 int innerHeight() const; 185 int innerWidth() const; 186 int screenX() const; 187 int screenY() const; 188 int screenLeft() const { return screenX(); } 189 int screenTop() const { return screenY(); } 190 int scrollX() const; 191 int scrollY() const; 192 int pageXOffset() const { return scrollX(); } 193 int pageYOffset() const { return scrollY(); } 194 195 bool closed() const; 196 197 unsigned length() const; 198 199 String name() const; 200 void setName(const String&); 201 202 String status() const; 203 void setStatus(const String&); 204 String defaultStatus() const; 205 void setDefaultStatus(const String&); 206 207 // Self-referential attributes 208 209 DOMWindow* self() const; 210 DOMWindow* window() const { return self(); } 211 DOMWindow* frames() const { return self(); } 212 213 DOMWindow* opener() const; 214 DOMWindow* parent() const; 215 DOMWindow* top() const; 216 217 // DOM Level 2 AbstractView Interface 218 219 Document* document() const; 220 221 // CSSOM View Module 222 223 PassRefPtr<StyleMedia> styleMedia() const; 224 225 // DOM Level 2 Style Interface 226 227 PassRefPtr<CSSStyleDeclaration> getComputedStyle(Element*, const String& pseudoElt) const; 228 229 // WebKit extensions 230 231 PassRefPtr<CSSRuleList> getMatchedCSSRules(Element*, const String& pseudoElt, bool authorOnly = true) const; 232 double devicePixelRatio() const; 233 234 PassRefPtr<WebKitPoint> webkitConvertPointFromPageToNode(Node*, const WebKitPoint*) const; 235 PassRefPtr<WebKitPoint> webkitConvertPointFromNodeToPage(Node*, const WebKitPoint*) const; 236 237 PageConsole* pageConsole() const; 238 239 void printErrorMessage(const String&); 240 String crossDomainAccessErrorMessage(const DOMWindow& activeWindow); 241 242 void postMessage(PassRefPtr<SerializedScriptValue> message, const MessagePortArray*, const String& targetOrigin, DOMWindow& source, ExceptionCode&); 243 // Needed for Objective-C bindings (see bug 28774). 244 void postMessage(PassRefPtr<SerializedScriptValue> message, MessagePort*, const String& targetOrigin, DOMWindow& source, ExceptionCode&); 245 void postMessageTimerFired(PostMessageTimer&); 246 void dispatchMessageEventWithOriginCheck(SecurityOrigin* intendedTargetOrigin, PassRefPtr<Event>, PassRefPtr<Inspector::ScriptCallStack>); 247 248 void scrollBy(int x, int y) const; 249 void scrollTo(int x, int y) const; 250 void scroll(int x, int y) const { scrollTo(x, y); } 251 252 void moveBy(float x, float y) const; 253 void moveTo(float x, float y) const; 254 255 void resizeBy(float x, float y) const; 256 void resizeTo(float width, float height) const; 257 258 // Timers 259 int setTimeout(std::unique_ptr<ScheduledAction>, int timeout, ExceptionCode&); 260 void clearTimeout(int timeoutId); 261 int setInterval(std::unique_ptr<ScheduledAction>, int timeout, ExceptionCode&); 262 void clearInterval(int timeoutId); 263 264 // WebKit animation extensions 265#if ENABLE(REQUEST_ANIMATION_FRAME) 266 int requestAnimationFrame(PassRefPtr<RequestAnimationFrameCallback>); 267 int webkitRequestAnimationFrame(PassRefPtr<RequestAnimationFrameCallback>); 268 void cancelAnimationFrame(int id); 269#endif 270 271#if ENABLE(CSS3_CONDITIONAL_RULES) 272 DOMWindowCSS* css(); 273#endif 274 275 // Events 276 // EventTarget API 277 virtual bool addEventListener(const AtomicString& eventType, PassRefPtr<EventListener>, bool useCapture) override; 278 virtual bool removeEventListener(const AtomicString& eventType, EventListener*, bool useCapture) override; 279 virtual void removeAllEventListeners() override; 280 281 using EventTarget::dispatchEvent; 282 bool dispatchEvent(PassRefPtr<Event> prpEvent, PassRefPtr<EventTarget> prpTarget); 283 284 void dispatchLoadEvent(); 285 286 DEFINE_ATTRIBUTE_EVENT_LISTENER(abort); 287 DEFINE_ATTRIBUTE_EVENT_LISTENER(beforeunload); 288 DEFINE_ATTRIBUTE_EVENT_LISTENER(blur); 289 DEFINE_ATTRIBUTE_EVENT_LISTENER(canplay); 290 DEFINE_ATTRIBUTE_EVENT_LISTENER(canplaythrough); 291 DEFINE_ATTRIBUTE_EVENT_LISTENER(change); 292 DEFINE_ATTRIBUTE_EVENT_LISTENER(click); 293 DEFINE_ATTRIBUTE_EVENT_LISTENER(contextmenu); 294 DEFINE_ATTRIBUTE_EVENT_LISTENER(dblclick); 295 DEFINE_ATTRIBUTE_EVENT_LISTENER(drag); 296 DEFINE_ATTRIBUTE_EVENT_LISTENER(dragend); 297 DEFINE_ATTRIBUTE_EVENT_LISTENER(dragenter); 298 DEFINE_ATTRIBUTE_EVENT_LISTENER(dragleave); 299 DEFINE_ATTRIBUTE_EVENT_LISTENER(dragover); 300 DEFINE_ATTRIBUTE_EVENT_LISTENER(dragstart); 301 DEFINE_ATTRIBUTE_EVENT_LISTENER(drop); 302 DEFINE_ATTRIBUTE_EVENT_LISTENER(durationchange); 303 DEFINE_ATTRIBUTE_EVENT_LISTENER(emptied); 304 DEFINE_ATTRIBUTE_EVENT_LISTENER(ended); 305 DEFINE_ATTRIBUTE_EVENT_LISTENER(error); 306 DEFINE_ATTRIBUTE_EVENT_LISTENER(focus); 307 DEFINE_ATTRIBUTE_EVENT_LISTENER(hashchange); 308 DEFINE_ATTRIBUTE_EVENT_LISTENER(input); 309 DEFINE_ATTRIBUTE_EVENT_LISTENER(invalid); 310 DEFINE_ATTRIBUTE_EVENT_LISTENER(keydown); 311 DEFINE_ATTRIBUTE_EVENT_LISTENER(keypress); 312 DEFINE_ATTRIBUTE_EVENT_LISTENER(keyup); 313 DEFINE_ATTRIBUTE_EVENT_LISTENER(load); 314 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadeddata); 315 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadedmetadata); 316 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadstart); 317 DEFINE_ATTRIBUTE_EVENT_LISTENER(message); 318 DEFINE_ATTRIBUTE_EVENT_LISTENER(mousedown); 319 DEFINE_ATTRIBUTE_EVENT_LISTENER(mouseenter); 320 DEFINE_ATTRIBUTE_EVENT_LISTENER(mouseleave); 321 DEFINE_ATTRIBUTE_EVENT_LISTENER(mousemove); 322 DEFINE_ATTRIBUTE_EVENT_LISTENER(mouseout); 323 DEFINE_ATTRIBUTE_EVENT_LISTENER(mouseover); 324 DEFINE_ATTRIBUTE_EVENT_LISTENER(mouseup); 325 DEFINE_ATTRIBUTE_EVENT_LISTENER(mousewheel); 326 DEFINE_ATTRIBUTE_EVENT_LISTENER(offline); 327 DEFINE_ATTRIBUTE_EVENT_LISTENER(online); 328 DEFINE_ATTRIBUTE_EVENT_LISTENER(pagehide); 329 DEFINE_ATTRIBUTE_EVENT_LISTENER(pageshow); 330 DEFINE_ATTRIBUTE_EVENT_LISTENER(pause); 331 DEFINE_ATTRIBUTE_EVENT_LISTENER(play); 332 DEFINE_ATTRIBUTE_EVENT_LISTENER(playing); 333 DEFINE_ATTRIBUTE_EVENT_LISTENER(popstate); 334 DEFINE_ATTRIBUTE_EVENT_LISTENER(progress); 335 DEFINE_ATTRIBUTE_EVENT_LISTENER(ratechange); 336 DEFINE_ATTRIBUTE_EVENT_LISTENER(reset); 337 DEFINE_ATTRIBUTE_EVENT_LISTENER(resize); 338 DEFINE_ATTRIBUTE_EVENT_LISTENER(scroll); 339 DEFINE_ATTRIBUTE_EVENT_LISTENER(search); 340 DEFINE_ATTRIBUTE_EVENT_LISTENER(seeked); 341 DEFINE_ATTRIBUTE_EVENT_LISTENER(seeking); 342 DEFINE_ATTRIBUTE_EVENT_LISTENER(select); 343 DEFINE_ATTRIBUTE_EVENT_LISTENER(stalled); 344 DEFINE_ATTRIBUTE_EVENT_LISTENER(storage); 345 DEFINE_ATTRIBUTE_EVENT_LISTENER(submit); 346 DEFINE_ATTRIBUTE_EVENT_LISTENER(suspend); 347 DEFINE_ATTRIBUTE_EVENT_LISTENER(timeupdate); 348 DEFINE_ATTRIBUTE_EVENT_LISTENER(unload); 349 DEFINE_ATTRIBUTE_EVENT_LISTENER(volumechange); 350 DEFINE_ATTRIBUTE_EVENT_LISTENER(waiting); 351 DEFINE_ATTRIBUTE_EVENT_LISTENER(webkitbeginfullscreen); 352 DEFINE_ATTRIBUTE_EVENT_LISTENER(webkitendfullscreen); 353#if ENABLE(WILL_REVEAL_EDGE_EVENTS) 354 DEFINE_ATTRIBUTE_EVENT_LISTENER(webkitwillrevealbottom); 355 DEFINE_ATTRIBUTE_EVENT_LISTENER(webkitwillrevealleft); 356 DEFINE_ATTRIBUTE_EVENT_LISTENER(webkitwillrevealright); 357 DEFINE_ATTRIBUTE_EVENT_LISTENER(webkitwillrevealtop); 358#endif 359 DEFINE_ATTRIBUTE_EVENT_LISTENER(wheel); 360 361 DEFINE_MAPPED_ATTRIBUTE_EVENT_LISTENER(webkitanimationstart, webkitAnimationStart); 362 DEFINE_MAPPED_ATTRIBUTE_EVENT_LISTENER(webkitanimationiteration, webkitAnimationIteration); 363 DEFINE_MAPPED_ATTRIBUTE_EVENT_LISTENER(webkitanimationend, webkitAnimationEnd); 364 DEFINE_MAPPED_ATTRIBUTE_EVENT_LISTENER(webkittransitionend, webkitTransitionEnd); 365 DEFINE_MAPPED_ATTRIBUTE_EVENT_LISTENER(transitionend, transitionend); 366 367 void captureEvents(); 368 void releaseEvents(); 369 370 void finishedLoading(); 371 372 using RefCounted<DOMWindow>::ref; 373 using RefCounted<DOMWindow>::deref; 374 375#if ENABLE(DEVICE_ORIENTATION) 376 DEFINE_ATTRIBUTE_EVENT_LISTENER(devicemotion); 377 DEFINE_ATTRIBUTE_EVENT_LISTENER(deviceorientation); 378#endif 379 380#if ENABLE(PROXIMITY_EVENTS) 381 DEFINE_ATTRIBUTE_EVENT_LISTENER(webkitdeviceproximity); 382#endif 383 384 // HTML 5 key/value storage 385 Storage* sessionStorage(ExceptionCode&) const; 386 Storage* localStorage(ExceptionCode&) const; 387 Storage* optionalSessionStorage() const { return m_sessionStorage.get(); } 388 Storage* optionalLocalStorage() const { return m_localStorage.get(); } 389 390 DOMApplicationCache* applicationCache() const; 391 DOMApplicationCache* optionalApplicationCache() const { return m_applicationCache.get(); } 392 393#if ENABLE(ORIENTATION_EVENTS) 394 // This is the interface orientation in degrees. Some examples are: 395 // 0 is straight up; -90 is when the device is rotated 90 clockwise; 396 // 90 is when rotated counter clockwise. 397 int orientation() const; 398 399 DEFINE_ATTRIBUTE_EVENT_LISTENER(orientationchange); 400#endif 401 402#if ENABLE(TOUCH_EVENTS) 403 DEFINE_ATTRIBUTE_EVENT_LISTENER(touchstart); 404 DEFINE_ATTRIBUTE_EVENT_LISTENER(touchmove); 405 DEFINE_ATTRIBUTE_EVENT_LISTENER(touchend); 406 DEFINE_ATTRIBUTE_EVENT_LISTENER(touchcancel); 407#endif 408 409#if ENABLE(IOS_GESTURE_EVENTS) 410 DEFINE_ATTRIBUTE_EVENT_LISTENER(gesturestart); 411 DEFINE_ATTRIBUTE_EVENT_LISTENER(gesturechange); 412 DEFINE_ATTRIBUTE_EVENT_LISTENER(gestureend); 413#endif 414 415#if ENABLE(WEB_TIMING) 416 Performance* performance() const; 417#endif 418 419#if PLATFORM(IOS) 420 void incrementScrollEventListenersCount(); 421 void decrementScrollEventListenersCount(); 422 unsigned scrollEventListenerCount() const { return m_scrollEventListenerCount; } 423#endif 424 425 void resetAllGeolocationPermission(); 426 427#if ENABLE(IOS_TOUCH_EVENTS) || ENABLE(IOS_GESTURE_EVENTS) 428 bool hasTouchEventListeners() const { return m_touchEventListenerCount > 0; } 429#endif 430 431#if ENABLE(USER_MESSAGE_HANDLERS) 432 bool shouldHaveWebKitNamespaceForWorld(DOMWrapperWorld&); 433 WebKitNamespace* webkitNamespace() const; 434#endif 435 436 // FIXME: When this DOMWindow is no longer the active DOMWindow (i.e., 437 // when its document is no longer the document that is displayed in its 438 // frame), we would like to zero out m_frame to avoid being confused 439 // by the document that is currently active in m_frame. 440 bool isCurrentlyDisplayedInFrame() const; 441 442 void willDetachDocumentFromFrame(); 443 void willDestroyCachedFrame(); 444 445 void enableSuddenTermination(); 446 void disableSuddenTermination(); 447 448 private: 449 explicit DOMWindow(Document*); 450 451 Page* page(); 452 bool allowedToChangeWindowGeometry() const; 453 454 virtual void frameDestroyed() override; 455 virtual void willDetachPage() override; 456 457 virtual void refEventTarget() override { ref(); } 458 virtual void derefEventTarget() override { deref(); } 459 460 static PassRefPtr<Frame> createWindow(const String& urlString, const AtomicString& frameName, const WindowFeatures&, DOMWindow& activeWindow, Frame* firstFrame, Frame* openerFrame, std::function<void (DOMWindow&)> prepareDialogFunction = nullptr); 461 bool isInsecureScriptAccess(DOMWindow& activeWindow, const String& urlString); 462 463 void resetDOMWindowProperties(); 464 void disconnectDOMWindowProperties(); 465 void reconnectDOMWindowProperties(); 466 void willDestroyDocumentInFrame(); 467 468#if ENABLE(GAMEPAD) 469 void incrementGamepadEventListenerCount(); 470 void decrementGamepadEventListenerCount(); 471#endif 472 473 bool m_shouldPrintWhenFinishedLoading; 474 bool m_suspendedForPageCache; 475 476 HashSet<DOMWindowProperty*> m_properties; 477 478 mutable RefPtr<Screen> m_screen; 479 mutable RefPtr<History> m_history; 480 mutable RefPtr<Crypto> m_crypto; 481 mutable RefPtr<BarProp> m_locationbar; 482 mutable RefPtr<BarProp> m_menubar; 483 mutable RefPtr<BarProp> m_personalbar; 484 mutable RefPtr<BarProp> m_scrollbars; 485 mutable RefPtr<BarProp> m_statusbar; 486 mutable RefPtr<BarProp> m_toolbar; 487 mutable RefPtr<Navigator> m_navigator; 488 mutable RefPtr<Location> m_location; 489 mutable RefPtr<StyleMedia> m_media; 490 491 String m_status; 492 String m_defaultStatus; 493 494 enum PageStatus { PageStatusNone, PageStatusShown, PageStatusHidden }; 495 PageStatus m_lastPageStatus; 496 497#if PLATFORM(IOS) 498 unsigned m_scrollEventListenerCount; 499#endif 500 501#if ENABLE(IOS_TOUCH_EVENTS) || ENABLE(IOS_GESTURE_EVENTS) 502 unsigned m_touchEventListenerCount; 503#endif 504 505#if ENABLE(GAMEPAD) 506 unsigned m_gamepadEventListenerCount; 507#endif 508 mutable RefPtr<Storage> m_sessionStorage; 509 mutable RefPtr<Storage> m_localStorage; 510 mutable RefPtr<DOMApplicationCache> m_applicationCache; 511 512#if ENABLE(WEB_TIMING) 513 mutable RefPtr<Performance> m_performance; 514#endif 515 516#if ENABLE(CSS3_CONDITIONAL_RULES) 517 mutable RefPtr<DOMWindowCSS> m_css; 518#endif 519 520#if ENABLE(USER_MESSAGE_HANDLERS) 521 mutable RefPtr<WebKitNamespace> m_webkitNamespace; 522#endif 523 }; 524 525 inline String DOMWindow::status() const 526 { 527 return m_status; 528 } 529 530 inline String DOMWindow::defaultStatus() const 531 { 532 return m_defaultStatus; 533 } 534 535} // namespace WebCore 536 537#endif // DOMWindow_h 538