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

Unified Diff: Source/core/page/DragController.cpp

Issue 603193005: Move the Widget hierarchy to the Oilpan heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add ~Scrollbar assert Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: Source/core/page/DragController.cpp
diff --git a/Source/core/page/DragController.cpp b/Source/core/page/DragController.cpp
index 3f324a723d2bac1ed811dfb6b1716ab726fff17b..c9334f115c11cff2a725b408315aa2c10dc27a81 100644
--- a/Source/core/page/DragController.cpp
+++ b/Source/core/page/DragController.cpp
@@ -216,7 +216,7 @@ void DragController::dragExited(DragData* dragData)
ASSERT(dragData);
LocalFrame* mainFrame = m_page->deprecatedLocalMainFrame();
- if (RefPtr<FrameView> v = mainFrame->view()) {
+ if (RefPtrWillBeRawPtr<FrameView> v ALLOW_UNUSED = mainFrame->view()) {
haraken 2014/09/29 14:16:36 How about writing like this? RefPtrWillBeRawPtr<F
sof 2014/10/02 14:03:54 Sure, that will work - I just didn't want to accid
DataTransferAccessPolicy policy = (!m_documentUnderMouse || m_documentUnderMouse->securityOrigin()->isLocal()) ? DataTransferReadable : DataTransferTypesReadable;
RefPtrWillBeRawPtr<DataTransfer> dataTransfer = createDraggingDataTransfer(policy, dragData);
dataTransfer->setSourceOperation(dragData->draggingSourceOperationMask());
@@ -353,7 +353,7 @@ bool DragController::tryDocumentDrag(DragData* dragData, DragDestinationAction a
// It's unclear why this check is after tryDHTMLDrag.
// We send drag events in tryDHTMLDrag and that may be the reason.
- RefPtr<FrameView> frameView = m_documentUnderMouse->view();
+ RefPtrWillBeRawPtr<FrameView> frameView = m_documentUnderMouse->view();
if (!frameView)
return false;
@@ -594,7 +594,7 @@ bool DragController::tryDHTMLDrag(DragData* dragData, DragOperation& operation)
if (!mainFrame->view())
return false;
- RefPtr<FrameView> viewProtector(mainFrame->view());
+ RefPtrWillBeRawPtr<FrameView> viewProtector(mainFrame->view());
DataTransferAccessPolicy policy = m_documentUnderMouse->securityOrigin()->isLocal() ? DataTransferReadable : DataTransferTypesReadable;
RefPtrWillBeRawPtr<DataTransfer> dataTransfer = createDraggingDataTransfer(policy, dragData);
DragOperation srcOpMask = dragData->draggingSourceOperationMask();
@@ -929,7 +929,7 @@ void DragController::doSystemDrag(DragImage* image, const IntPoint& dragLocation
m_dragInitiator = frame->document();
// Protect this frame and view, as a load may occur mid drag and attempt to unload this frame
RefPtrWillBeRawPtr<LocalFrame> mainFrame = m_page->deprecatedLocalMainFrame();
- RefPtr<FrameView> mainFrameView = mainFrame->view();
+ RefPtrWillBeRawPtr<FrameView> mainFrameView = mainFrame->view();
m_client->startDrag(image, mainFrameView->rootViewToContents(frame->view()->contentsToRootView(dragLocation)),
mainFrameView->rootViewToContents(frame->view()->contentsToRootView(eventPos)), dataTransfer, frame, forLink);

Powered by Google App Engine
This is Rietveld 408576698