This repository was archived by the owner on Oct 8, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +14
-10
lines changed
Expand file tree Collapse file tree 1 file changed +14
-10
lines changed Original file line number Diff line number Diff line change @@ -112,14 +112,19 @@ define( [ "jquery",
112112 } ,
113113
114114 _resizeTimeout : function ( ) {
115- if ( ! this . _maybeRefreshTimeout ( ) ) {
116- // effectively rapid-open the popup while leaving the screen intact
117- this . _trigger ( "beforeposition" ) ;
118- this . _ui . container
119- . removeClass ( "ui-selectmenu-hidden" )
120- . offset ( this . _placementCoords ( this . _desiredCoords ( undefined , undefined , "window" ) ) ) ;
121-
122- this . _resizeScreen ( ) ;
115+ if ( this . _isOpen ) {
116+ if ( ! this . _maybeRefreshTimeout ( ) ) {
117+ // effectively rapid-open the popup while leaving the screen intact
118+ this . _trigger ( "beforeposition" ) ;
119+ this . _ui . container
120+ . removeClass ( "ui-selectmenu-hidden" )
121+ . offset ( this . _placementCoords ( this . _desiredCoords ( undefined , undefined , "window" ) ) ) ;
122+
123+ this . _resizeScreen ( ) ;
124+ this . _resizeData = null ;
125+ this . _orientationchangeInProgress = false ;
126+ }
127+ } else {
123128 this . _resizeData = null ;
124129 this . _orientationchangeInProgress = false ;
125130 }
@@ -132,8 +137,7 @@ define( [ "jquery",
132137 } ,
133138
134139 _handleWindowOrientationchange : function ( e ) {
135-
136- if ( ! this . _orientationchangeInProgress ) {
140+ if ( ! this . _orientationchangeInProgress && this . _isOpen ) {
137141 // effectively rapid-close the popup while leaving the screen intact
138142 this . _ui . container
139143 . addClass ( "ui-selectmenu-hidden" )
You can’t perform that action at this time.
0 commit comments