Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(75)

Side by Side Diff: Source/core/frame/LocalDOMWindow.h

Issue 1148383012: Oilpan: prefer eager finalization over prefinalizers. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2009, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2009, 2010 Apple Inc. All rights reserved.
3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) 3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies)
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 59
60 enum PageshowEventPersistence { 60 enum PageshowEventPersistence {
61 PageshowEventNotPersisted = 0, 61 PageshowEventNotPersisted = 0,
62 PageshowEventPersisted = 1 62 PageshowEventPersisted = 1
63 }; 63 };
64 64
65 // Note: if you're thinking of returning something DOM-related by reference, 65 // Note: if you're thinking of returning something DOM-related by reference,
66 // please ping dcheng@chromium.org first. You probably don't want to do that. 66 // please ping dcheng@chromium.org first. You probably don't want to do that.
67 class CORE_EXPORT LocalDOMWindow final : public DOMWindow, public WillBeHeapSupp lementable<LocalDOMWindow>, public DOMWindowLifecycleNotifier { 67 class CORE_EXPORT LocalDOMWindow final : public DOMWindow, public WillBeHeapSupp lementable<LocalDOMWindow>, public DOMWindowLifecycleNotifier {
68 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(LocalDOMWindow); 68 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(LocalDOMWindow);
69 WILL_BE_USING_PRE_FINALIZER(LocalDOMWindow, dispose);
70 public: 69 public:
71 static PassRefPtrWillBeRawPtr<Document> createDocument(const String& mimeTyp e, const DocumentInit&, bool forceXHTML); 70 static PassRefPtrWillBeRawPtr<Document> createDocument(const String& mimeTyp e, const DocumentInit&, bool forceXHTML);
72 static PassRefPtrWillBeRawPtr<LocalDOMWindow> create(LocalFrame& frame) 71 static PassRefPtrWillBeRawPtr<LocalDOMWindow> create(LocalFrame& frame)
73 { 72 {
74 return adoptRefWillBeNoop(new LocalDOMWindow(frame)); 73 return adoptRefWillBeNoop(new LocalDOMWindow(frame));
75 } 74 }
76 virtual ~LocalDOMWindow(); 75 virtual ~LocalDOMWindow();
77 void dispose(); 76 EAGERLY_FINALIZE();
haraken 2015/06/04 01:02:31 Add a comment. Ditto for the other EAGERLY_FINALIZ
sof 2015/06/04 07:54:39 Done.
77 DECLARE_VIRTUAL_TRACE();
78 78
79 PassRefPtrWillBeRawPtr<Document> installNewDocument(const String& mimeType, const DocumentInit&, bool forceXHTML = false); 79 PassRefPtrWillBeRawPtr<Document> installNewDocument(const String& mimeType, const DocumentInit&, bool forceXHTML = false);
80 80
81 // EventTarget overrides: 81 // EventTarget overrides:
82 virtual ExecutionContext* executionContext() const override; 82 virtual ExecutionContext* executionContext() const override;
83 virtual LocalDOMWindow* toDOMWindow() override; 83 virtual LocalDOMWindow* toDOMWindow() override;
84 84
85 // DOMWindow overrides: 85 // DOMWindow overrides:
86 DECLARE_VIRTUAL_TRACE();
87 bool isLocalDOMWindow() const override { return true; } 86 bool isLocalDOMWindow() const override { return true; }
88 virtual LocalFrame* frame() const override; 87 virtual LocalFrame* frame() const override;
89 Screen* screen() const override; 88 Screen* screen() const override;
90 History* history() const override; 89 History* history() const override;
91 BarProp* locationbar() const override; 90 BarProp* locationbar() const override;
92 BarProp* menubar() const override; 91 BarProp* menubar() const override;
93 BarProp* personalbar() const override; 92 BarProp* personalbar() const override;
94 BarProp* scrollbars() const override; 93 BarProp* scrollbars() const override;
95 BarProp* statusbar() const override; 94 BarProp* statusbar() const override;
96 BarProp* toolbar() const override; 95 BarProp* toolbar() const override;
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
285 } 284 }
286 285
287 inline String LocalDOMWindow::defaultStatus() const 286 inline String LocalDOMWindow::defaultStatus() const
288 { 287 {
289 return m_defaultStatus; 288 return m_defaultStatus;
290 } 289 }
291 290
292 } // namespace blink 291 } // namespace blink
293 292
294 #endif // LocalDOMWindow_h 293 #endif // LocalDOMWindow_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698