diff --git a/demos/tooltip/video-player.html b/demos/tooltip/video-player.html
index e0db0575d..1d8458abb 100644
--- a/demos/tooltip/video-player.html
+++ b/demos/tooltip/video-player.html
@@ -85,9 +85,12 @@
},
text: !!$( this ).attr( "title" )
});
- if ( !button.next().is( ":ui-popup" ) ) {
+ if ( button.next().is( ":ui-popup" ) ) {
+ button.click(function( event ) {
+ $( ".demo" ).tooltip( "close", event );
+ });
+ } else {
button.click(function() {
- console.log( "click" );
notify( button );
});
}