File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -1011,16 +1011,16 @@ export class AppiumDriver {
1011
1011
public getScreenViewPort ( ) : IRectangle {
1012
1012
const rect = this . getScreenActualViewPort ( ) ;
1013
1013
if ( rect
1014
+ && this . isIOS
1014
1015
&& Object . getOwnPropertyNames ( rect ) . length > 0
1015
- && this . _args . appiumCaps . device . deviceScreenDensity ) {
1016
+ && this . _args . device . deviceScreenDensity ) {
1016
1017
return < IRectangle > {
1017
- x : rect . x / this . _args . appiumCaps . device . deviceScreenDensity ,
1018
- y : rect . y / this . _args . appiumCaps . device . deviceScreenDensity ,
1019
- width : rect . width / this . _args . appiumCaps . device . deviceScreenDensity ,
1020
- height : rect . height / this . _args . appiumCaps . device . deviceScreenDensity ,
1018
+ x : rect . x / this . _args . device . deviceScreenDensity ,
1019
+ y : rect . y / this . _args . device . deviceScreenDensity ,
1020
+ width : rect . width / this . _args . device . deviceScreenDensity ,
1021
+ height : rect . height / this . _args . device . deviceScreenDensity ,
1021
1022
}
1022
1023
} else {
1023
- logError ( "Device's density is undefined!" ) ;
1024
1024
return rect ;
1025
1025
}
1026
1026
}
You can’t perform that action at this time.
0 commit comments