File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -94,7 +94,9 @@ class UIImagePickerControllerDelegateImpl extends NSObject implements UIImagePic
94
94
95
95
private setImageAssetAndCallCallback ( imageAsset : imageAssetModule . ImageAsset ) {
96
96
if ( this . _keepAspectRatio ) {
97
- let isPictureLandscape = imageAsset . nativeImage . size . width > imageAsset . nativeImage . size . height ;
97
+ let pictureWidth = imageAsset . nativeImage ? imageAsset . nativeImage . size . width : imageAsset . ios . pixelWidth ;
98
+ let pictureHeight = imageAsset . nativeImage ? imageAsset . nativeImage . size . height : imageAsset . ios . pixelHeight ;
99
+ let isPictureLandscape = pictureWidth > pictureHeight ;
98
100
let areOptionsLandscape = this . _width > this . _height ;
99
101
if ( isPictureLandscape !== areOptionsLandscape ) {
100
102
let oldWidth = this . _width ;
You can’t perform that action at this time.
0 commit comments