+ if (dpi > 0 && mindimension > 0)
+ {
+ scale = Math.min(dpi / hidpiThreshold,
+ mindimension / tallScreenThreshold) + 1;
+ }
+ else if (dpi == 0 && mindimension > tallScreenThreshold)
+ {
+ // dpi couldn't be found but the screen has a large vertical pixel count
+ scale = mindimension / tallScreenThreshold + 1;
+ }
+ /* do nothing if mindimension == 0 -- might be just a small HD screen (e.g. Gemini PDA)
+ else if (mindimension == 0 && dpi > hidpiThreshold)
+ {
+ }
+ */