@@ -149,7 +149,8 @@ const OverlayTrigger = React.createClass({
149149 componentWillUnmount ( ) {
150150 ReactDOM . unmountComponentAtNode ( this . _mountNode ) ;
151151 this . _mountNode = null ;
152- clearTimeout ( this . _hoverDelay ) ;
152+ clearTimeout ( this . _hoverShowDelay ) ;
153+ clearTimeout ( this . _hoverHideDelay ) ;
153154 } ,
154155
155156 componentDidUpdate ( ) {
@@ -226,9 +227,13 @@ const OverlayTrigger = React.createClass({
226227 } ,
227228
228229 handleDelayedShow ( ) {
229- if ( this . _hoverDelay != null ) {
230- clearTimeout ( this . _hoverDelay ) ;
231- this . _hoverDelay = null ;
230+ if ( this . _hoverHideDelay != null ) {
231+ clearTimeout ( this . _hoverHideDelay ) ;
232+ this . _hoverHideDelay = null ;
233+ return ;
234+ }
235+
236+ if ( this . state . isOverlayShown || this . _hoverShowDelay != null ) {
232237 return ;
233238 }
234239
@@ -240,16 +245,20 @@ const OverlayTrigger = React.createClass({
240245 return ;
241246 }
242247
243- this . _hoverDelay = setTimeout ( ( ) => {
244- this . _hoverDelay = null ;
248+ this . _hoverShowDelay = setTimeout ( ( ) => {
249+ this . _hoverShowDelay = null ;
245250 this . show ( ) ;
246251 } , delay ) ;
247252 } ,
248253
249254 handleDelayedHide ( ) {
250- if ( this . _hoverDelay != null ) {
251- clearTimeout ( this . _hoverDelay ) ;
252- this . _hoverDelay = null ;
255+ if ( this . _hoverShowDelay != null ) {
256+ clearTimeout ( this . _hoverShowDelay ) ;
257+ this . _hoverShowDelay = null ;
258+ return ;
259+ }
260+
261+ if ( ! this . state . isOverlayShown || this . _hoverHideDelay != null ) {
253262 return ;
254263 }
255264
@@ -261,8 +270,8 @@ const OverlayTrigger = React.createClass({
261270 return ;
262271 }
263272
264- this . _hoverDelay = setTimeout ( ( ) => {
265- this . _hoverDelay = null ;
273+ this . _hoverHideDelay = setTimeout ( ( ) => {
274+ this . _hoverHideDelay = null ;
266275 this . hide ( ) ;
267276 } , delay ) ;
268277 } ,
0 commit comments