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

Side by Side Diff: third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp

Issue 1851743002: Simplify Supplementables post Oilpan. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix component build Created 4 years, 8 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 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 1480 matching lines...) Expand 10 before | Expand all | Expand 10 after
1491 return targetFrame->domWindow(); 1491 return targetFrame->domWindow();
1492 } 1492 }
1493 1493
1494 WindowFeatures features(windowFeaturesString); 1494 WindowFeatures features(windowFeaturesString);
1495 RawPtr<DOMWindow> newWindow = createWindow(urlString, frameName, features, * callingWindow, *firstFrame, *frame()); 1495 RawPtr<DOMWindow> newWindow = createWindow(urlString, frameName, features, * callingWindow, *firstFrame, *frame());
1496 return features.noopener ? nullptr : newWindow; 1496 return features.noopener ? nullptr : newWindow;
1497 } 1497 }
1498 1498
1499 DEFINE_TRACE(LocalDOMWindow) 1499 DEFINE_TRACE(LocalDOMWindow)
1500 { 1500 {
1501 #if ENABLE(OILPAN)
1502 visitor->trace(m_frameObserver); 1501 visitor->trace(m_frameObserver);
1503 visitor->trace(m_document); 1502 visitor->trace(m_document);
1504 visitor->trace(m_properties); 1503 visitor->trace(m_properties);
1505 visitor->trace(m_screen); 1504 visitor->trace(m_screen);
1506 visitor->trace(m_history); 1505 visitor->trace(m_history);
1507 visitor->trace(m_locationbar); 1506 visitor->trace(m_locationbar);
1508 visitor->trace(m_menubar); 1507 visitor->trace(m_menubar);
1509 visitor->trace(m_personalbar); 1508 visitor->trace(m_personalbar);
1510 visitor->trace(m_scrollbars); 1509 visitor->trace(m_scrollbars);
1511 visitor->trace(m_statusbar); 1510 visitor->trace(m_statusbar);
1512 visitor->trace(m_toolbar); 1511 visitor->trace(m_toolbar);
1513 visitor->trace(m_console); 1512 visitor->trace(m_console);
1514 visitor->trace(m_navigator); 1513 visitor->trace(m_navigator);
1515 visitor->trace(m_media); 1514 visitor->trace(m_media);
1516 visitor->trace(m_applicationCache); 1515 visitor->trace(m_applicationCache);
1517 visitor->trace(m_eventQueue); 1516 visitor->trace(m_eventQueue);
1518 visitor->trace(m_postMessageTimers); 1517 visitor->trace(m_postMessageTimers);
1519 HeapSupplementable<LocalDOMWindow>::trace(visitor);
1520 #endif
1521 DOMWindow::trace(visitor); 1518 DOMWindow::trace(visitor);
1519 Supplementable<LocalDOMWindow>::trace(visitor);
1522 DOMWindowLifecycleNotifier::trace(visitor); 1520 DOMWindowLifecycleNotifier::trace(visitor);
1523 } 1521 }
1524 1522
1525 LocalFrame* LocalDOMWindow::frame() const 1523 LocalFrame* LocalDOMWindow::frame() const
1526 { 1524 {
1527 // If the LocalDOMWindow still has a frame reference, that frame must point 1525 // If the LocalDOMWindow still has a frame reference, that frame must point
1528 // back to this LocalDOMWindow: otherwise, it's easy to get into a situation 1526 // back to this LocalDOMWindow: otherwise, it's easy to get into a situation
1529 // where script execution leaks between different LocalDOMWindows. 1527 // where script execution leaks between different LocalDOMWindows.
1530 if (m_frameObserver->frame()) 1528 if (m_frameObserver->frame())
1531 ASSERT_WITH_SECURITY_IMPLICATION(m_frameObserver->frame()->domWindow() = = this); 1529 ASSERT_WITH_SECURITY_IMPLICATION(m_frameObserver->frame()->domWindow() = = this);
1532 return m_frameObserver->frame(); 1530 return m_frameObserver->frame();
1533 } 1531 }
1534 1532
1535 } // namespace blink 1533 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/frame/LocalDOMWindow.h ('k') | third_party/WebKit/Source/core/frame/LocalFrame.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698