[Kimchi-devel] [PATCH] Bug #361. Network Action Dropdown does not Disappear when mouse out

huoyuxin at linux.vnet.ibm.com huoyuxin at linux.vnet.ibm.com
Wed Apr 2 09:20:01 UTC 2014


From: Yu Xin Huo <huoyuxin at linux.vnet.ibm.com>

Signed-off-by: Yu Xin Huo <huoyuxin at linux.vnet.ibm.com>
---
 ui/js/src/kimchi.network.js |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/ui/js/src/kimchi.network.js b/ui/js/src/kimchi.network.js
index 1642b99..9fa8324 100644
--- a/ui/js/src/kimchi.network.js
+++ b/ui/js/src/kimchi.network.js
@@ -149,6 +149,9 @@ kimchi.addNetworkActions = function(network) {
     }).click(function() {
         $(".menu-container", "#" + network.name).toggle();
         window.scrollBy(0, 150);
+    }).mouseleave(function() {
+        var delay = setTimeout(function(){$(".menu-container", "#"+network.name).toggle(false);}, 500);
+        $(".menu-container", "#"+network.name).mouseenter(function(){clearTimeout(delay);});
     });
     $(".menu-container", "#" + network.name).mouseleave(function() {
         $(".menu-container", "#" + network.name).toggle(false);
-- 
1.7.1




More information about the Kimchi-devel mailing list