From a1f9ca724834c7d1e66401f8cea8063346392770 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Scott=20Gonz=C3=A1lez?= Date: Sun, 29 May 2011 09:13:35 -0400 Subject: [PATCH] Tooltip video player demo: Close tooltip on click of popup button. --- demos/tooltip/video-player.html | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) 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 ); }); } -- 2.39.5