File tree Expand file tree Collapse file tree 2 files changed +19
-6
lines changed Expand file tree Collapse file tree 2 files changed +19
-6
lines changed Original file line number Diff line number Diff line change @@ -296,9 +296,11 @@ function timer(seconds) { //counts time, takes seconds
296
296
} , 1000 ) ;
297
297
}
298
298
299
- window . onresize = function ( ) {
300
- resizeScreen ( ) ;
301
- } ;
299
+ if ( os !== "Android" ) {
300
+ window . onresize = function ( ) {
301
+ resizeScreen ( ) ;
302
+ } ;
303
+ }
302
304
303
305
function resizeScreen ( ) {
304
306
let scaleVal = window . innerHeight / 600 ;
@@ -1033,6 +1035,17 @@ txtCustom.addEventListener("keyup", function(e) {
1033
1035
hideKeyboard ( txtCustom ) ;
1034
1036
} ) ;
1035
1037
1038
+ if ( os === "Android" ) {
1039
+ txtSpeaker . addEventListener ( "onfocus" , function ( ) {
1040
+ let y = document . getElementById ( "playControl" ) . getBoundingClientRect ( ) . y ;
1041
+ document . body . marginTop = `-${ y } px` ;
1042
+ } ) ;
1043
+
1044
+ txtSpeaker . addEventListener ( "onblur" , function ( ) {
1045
+ document . body . marginTop = '0px' ;
1046
+ } ) ;
1047
+ }
1048
+
1036
1049
txtSpeaker . addEventListener ( "keyup" , function ( e ) {
1037
1050
if ( e . key === 13 )
1038
1051
hideKeyboard ( txtSpeaker ) ;
@@ -1351,8 +1364,6 @@ tickAll.addEventListener('change', (event) => {
1351
1364
} , 1000 ) ;
1352
1365
} ) ( ) ;
1353
1366
1354
- resizeScreen ( ) ;
1355
-
1356
1367
function hideKeyboard ( element ) {
1357
1368
element . readOnly = true ;
1358
1369
setTimeout ( function ( ) {
@@ -1396,4 +1407,6 @@ window.addEventListener('DOMContentLoaded', (event) => {
1396
1407
if ( window . innerHeight > window . innerWidth * 2 && window . matchMedia ( "(orientation: portrait)" ) . matches ) {
1397
1408
document . querySelector ( '#innerPlayContainer' ) . classList . add ( "longPhonePortrait" ) ;
1398
1409
}
1410
+
1411
+ resizeScreen ( ) ;
1399
1412
} ) ;
You can’t perform that action at this time.
0 commit comments