Index: Source/core/rendering/RenderFullScreen.cpp |
diff --git a/Source/core/rendering/RenderFullScreen.cpp b/Source/core/rendering/RenderFullScreen.cpp |
index 664bc0244dd79477e63a5af4046dd5ac99180ed3..34b1375570bf45a9ef0d53dbb3564fe79e77c3b1 100644 |
--- a/Source/core/rendering/RenderFullScreen.cpp |
+++ b/Source/core/rendering/RenderFullScreen.cpp |
@@ -76,9 +76,9 @@ void RenderFullScreen::willBeDestroyed() |
// RenderObjects are unretained, so notify the document (which holds a pointer to a RenderFullScreen) |
// if it's RenderFullScreen is destroyed. |
- FullscreenElementStack* controller = FullscreenElementStack::from(&document()); |
- if (controller->fullScreenRenderer() == this) |
- controller->fullScreenRendererDestroyed(); |
+ FullscreenElementStack& controller = FullscreenElementStack::from(document()); |
+ if (controller.fullScreenRenderer() == this) |
+ controller.fullScreenRendererDestroyed(); |
RenderFlexibleBox::willBeDestroyed(); |
} |
@@ -140,7 +140,8 @@ RenderObject* RenderFullScreen::wrapRenderer(RenderObject* object, RenderObject* |
fullscreenRenderer->setNeedsLayoutAndPrefWidthsRecalc(); |
} |
- FullscreenElementStack::from(document)->setFullScreenRenderer(fullscreenRenderer); |
+ ASSERT(document); |
+ FullscreenElementStack::from(*document).setFullScreenRenderer(fullscreenRenderer); |
return fullscreenRenderer; |
} |
@@ -162,7 +163,7 @@ void RenderFullScreen::unwrapRenderer() |
if (placeholder()) |
placeholder()->remove(); |
remove(); |
- FullscreenElementStack::from(&document())->setFullScreenRenderer(0); |
+ FullscreenElementStack::from(document()).setFullScreenRenderer(0); |
} |
void RenderFullScreen::setPlaceholder(RenderBlock* placeholder) |