mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 840916 - Back out e7d3b0866dd9 from bug 779527 as it is no longer needed. r=mbrubeck
This commit is contained in:
parent
c9b234d2c3
commit
c3e9534174
@ -260,15 +260,7 @@ GetResolution(nsPresContext* aPresContext, const nsMediaFeature*,
|
||||
{
|
||||
// Resolution measures device pixels per CSS (inch/cm/pixel). We
|
||||
// return it in device pixels per CSS inches.
|
||||
//
|
||||
// However, on platforms where the CSS viewport is not fixed to the
|
||||
// screen viewport, use the device resolution instead (bug 779527).
|
||||
nsIPresShell *shell = aPresContext->PresShell();
|
||||
float appUnitsPerInch = shell->GetIsViewportOverridden() ?
|
||||
GetDeviceContextFor(aPresContext)->AppUnitsPerPhysicalInch() :
|
||||
nsPresContext::AppUnitsPerCSSInch();
|
||||
|
||||
float dpi = appUnitsPerInch /
|
||||
float dpi = float(nsPresContext::AppUnitsPerCSSInch()) /
|
||||
float(aPresContext->AppUnitsPerDevPixel());
|
||||
aResult.SetFloatValue(dpi, eCSSUnit_Inch);
|
||||
return NS_OK;
|
||||
|
Loading…
Reference in New Issue
Block a user