diff --git a/dom/plugins/base/nsPluginInstanceOwner.cpp b/dom/plugins/base/nsPluginInstanceOwner.cpp index e108c41f6af..dc856427b8e 100644 --- a/dom/plugins/base/nsPluginInstanceOwner.cpp +++ b/dom/plugins/base/nsPluginInstanceOwner.cpp @@ -173,9 +173,8 @@ nsPluginInstanceOwner::GetImageContainer() // NotifySize() causes Flash to do a bunch of stuff like ask for surfaces to render // into, set y-flip flags, etc, so we do this at the beginning. - float xResolution = mObjectFrame->PresContext()->GetRootPresContext()->PresShell()->GetXResolution(); - float yResolution = mObjectFrame->PresContext()->GetRootPresContext()->PresShell()->GetYResolution(); - ScreenSize screenSize = (r * LayoutDeviceToScreenScale(xResolution, yResolution)).Size(); + gfxSize resolution = mObjectFrame->PresContext()->PresShell()->GetCumulativeResolution(); + ScreenSize screenSize = (r * LayoutDeviceToScreenScale(resolution.width, resolution.height)).Size(); mInstance->NotifySize(nsIntSize(screenSize.width, screenSize.height)); container = LayerManager::CreateImageContainer();