Team:XMU-China/Project Application

From 2014.igem.org

(Difference between revisions)
 
Line 348: Line 348:
var sidebar_sub_hover_display = side_bar_hover_target.children(".sidebar_sub").css("display");
var sidebar_sub_hover_display = side_bar_hover_target.children(".sidebar_sub").css("display");
if(sidebar_sub_hover_display = "none"){
if(sidebar_sub_hover_display = "none"){
-
side_bar_hover_target.animate({width:"275px"},200);
+
side_bar_hover_target.stop().animate({width:"275px"},200);
-
side_bar_hover_target.children(".sidebar_sub").slideDown("normal");
+
};
};
$(".sidebar_main").mouseleave(function(){
$(".sidebar_main").mouseleave(function(){
Line 355: Line 354:
var sidebar_sub_hoveroff_display = side_bar_hoveroff_target.children(".sidebar_sub").css("display");
var sidebar_sub_hoveroff_display = side_bar_hoveroff_target.children(".sidebar_sub").css("display");
if(sidebar_sub_hover_display = "block"){
if(sidebar_sub_hover_display = "block"){
-
side_bar_hover_target.children(".sidebar_sub").slideUp(100);
+
side_bar_hover_target.stop().animate({width:"155px"},100);
-
side_bar_hover_target.animate({width:"155px"},100);
+
};
};
});
});
Line 363: Line 361:
$(".navbar_main").mouseenter(function(){
$(".navbar_main").mouseenter(function(){
var nav_bar_hover_target = $(this);
var nav_bar_hover_target = $(this);
-
nav_bar_hover_target.children(".navbar_sub").slideDown();
+
nav_bar_hover_target.children(".navbar_sub").stop().slideDown();
$(".navbar_main").mouseleave(function(){
$(".navbar_main").mouseleave(function(){
var nav_bar_hoveroff_target = $(this);
var nav_bar_hoveroff_target = $(this);
-
nav_bar_hoveroff_target.children(".navbar_sub").slideUp();
+
nav_bar_hoveroff_target.children(".navbar_sub").stop().slideUp();
});
});
});
});

Latest revision as of 16:10, 17 October 2014

side_bar