mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-08-17 04:41:36 +08:00
Merge pull request #3767 from NativeScript/ios-corner-radius-dip
Fix iOS corner radiuses dip incorrectly converted
This commit is contained in:
@ -34,7 +34,7 @@ export function checkUniformNativeBorderColor(v: view.View): boolean {
|
||||
}
|
||||
|
||||
export function getUniformNativeCornerRadius(v: view.View): number {
|
||||
return (<UIView>v.ios).layer.cornerRadius;
|
||||
return utils.layout.toDevicePixels((<UIView>v.ios).layer.cornerRadius);
|
||||
}
|
||||
|
||||
export function checkNativeBackgroundColor(v: view.View): boolean {
|
||||
|
@ -37,7 +37,7 @@ export module ios {
|
||||
const borderColor = background.getUniformBorderColor();
|
||||
layer.borderColor = !borderColor ? undefined : borderColor.ios.CGColor;
|
||||
layer.borderWidth = layout.toDeviceIndependentPixels(background.getUniformBorderWidth());
|
||||
layer.cornerRadius = background.getUniformBorderRadius();
|
||||
layer.cornerRadius = layout.toDeviceIndependentPixels(background.getUniformBorderRadius());
|
||||
}
|
||||
else {
|
||||
drawNonUniformBorders(nativeView, background);
|
||||
|
Reference in New Issue
Block a user