Android: Horizontal scrolling elements do not size correctly ( LogicalDensityFactor multiplied!)
Informate opened this issue · 1 comments
Informate commented
Workaround to FIX: Divide Size by Ti.Platform.displayCaps.logicalDensityFactor to have correct size.
PSEUDO CODE:
var ldf = Ti.Platform.displayCaps.logicalDensityFactor;
horizontalScrolling.add(internalView);
if (!OS_ANDROID) {
internalView.width = internalView.size.width / ldf;
internalView.height = internalView.size.height / ldf;
}
m1ga commented
Can you provide some demo code please?
Think the workaround you are talking about is basically this:
var pw = Ti.Platform.displayCaps.platformWidth;
var ph = Ti.Platform.displayCaps.platformHeight;
var ldi = Ti.Platform.displayCaps.logicalDensityFactor;
Alloy.Globals.WIDTH = (OS_ANDROID) ? pw / ldi : pw;
Alloy.Globals.HEIGHT = (OS_ANDROID) ? ph / ldi : ph;