Template:Peking2012 Color Prologue
From 2012.igem.org
(Difference between revisions)
m |
m |
||
(111 intermediate revisions not shown) | |||
Line 4: | Line 4: | ||
/* | /* | ||
* Peking 2012 Header | * Peking 2012 Header | ||
- | * | + | * Copyleft (C) Sun Sibai <sun.niasw@gmail.com> |
* this = /Template:Peking2012_Color_Prologue | * this = /Template:Peking2012_Color_Prologue | ||
*/ | */ | ||
Line 28: | Line 28: | ||
background-position: 50% 0; | background-position: 50% 0; | ||
background-repeat: no-repeat; | background-repeat: no-repeat; | ||
- | background-image: url("/wiki/images/ | + | background-image: url("/wiki/images/d/d7/Peking2012_Color_Background_Large.jpg"); |
overflow: hidden; | overflow: hidden; | ||
} | } | ||
Line 56: | Line 56: | ||
overflow: hidden; | overflow: hidden; | ||
border-style: none; | border-style: none; | ||
+ | } | ||
+ | #bodyContent | ||
+ | { | ||
+ | z-index: 0; | ||
} | } | ||
#footer-box | #footer-box | ||
{ | { | ||
- | |||
- | |||
background-color: transparent; | background-color: transparent; | ||
background-image: none; | background-image: none; | ||
border-style: none; | border-style: none; | ||
- | z-index: | + | z-index: 0; |
} | } | ||
#catlinks | #catlinks | ||
Line 73: | Line 75: | ||
#content a:hover | #content a:hover | ||
{ | { | ||
- | color: # | + | color: #fff350; |
display: inline; | display: inline; | ||
} | } | ||
Line 92: | Line 94: | ||
display: inline; | display: inline; | ||
} | } | ||
- | + | ul,li | |
- | ul , li | + | |
{ | { | ||
margin: 0; | margin: 0; | ||
Line 99: | Line 100: | ||
list-style-image: none; | list-style-image: none; | ||
list-style-type: none; | list-style-type: none; | ||
+ | } | ||
+ | table | ||
+ | { | ||
+ | border-collapse:collapse; | ||
+ | background-color: transparent; | ||
+ | color: #ffffff; | ||
+ | text-align: justify; | ||
} | } | ||
h3 | h3 | ||
Line 213: | Line 221: | ||
margin: 0; | margin: 0; | ||
} | } | ||
- | # | + | #PKU_menubar li |
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
{ | { | ||
display: inline; | display: inline; | ||
Line 235: | Line 232: | ||
margin: 0 auto; | margin: 0 auto; | ||
text-align: center; | text-align: center; | ||
+ | z-index: 1; | ||
+ | position: relative; | ||
+ | top: 0; | ||
} | } | ||
#PKU_banner_image | #PKU_banner_image | ||
Line 243: | Line 243: | ||
#PKU_banner_logo | #PKU_banner_logo | ||
{ | { | ||
- | width: | + | width: 60px; |
height: 60px; | height: 60px; | ||
text-align: center; | text-align: center; | ||
- | font-family: serif; | + | color: #ffffff; |
- | font-size: | + | font-family: Georgia, serif; |
+ | font-size: 15px; | ||
font-variant: small-caps; | font-variant: small-caps; | ||
+ | letter-spacing: 2px; | ||
+ | padding-top: 10px; | ||
} | } | ||
- | #PKU_banner_menu | + | #PKU_banner_menu |
- | + | ||
{ | { | ||
width: 550px; | width: 550px; | ||
height: 30px; | height: 30px; | ||
+ | } | ||
+ | #PKU_banner_menu , | ||
+ | #PKU_banner_submenu | ||
+ | { | ||
padding: 0; | padding: 0; | ||
margin: 0; | margin: 0; | ||
text-align: center; | text-align: center; | ||
- | font-size: | + | font-size: 15px; |
- | font-family: | + | font-family: Georgia, serif; |
overflow: hidden; | overflow: hidden; | ||
- | |||
} | } | ||
#PKU_banner_menu a , | #PKU_banner_menu a , | ||
Line 268: | Line 273: | ||
{ | { | ||
color: #e3e3e3; | color: #e3e3e3; | ||
- | font-size: | + | font-size: 15px; |
text-decoration: none; | text-decoration: none; | ||
} | } | ||
Line 275: | Line 280: | ||
{ | { | ||
color: #ffffff; | color: #ffffff; | ||
- | font-size: | + | font-size: 17px; |
text-decoration: none; | text-decoration: none; | ||
} | } | ||
- | # | + | #PKU_banner_submenu > li, |
- | #PKU_banner_submenu li | + | #PKU_banner_submenu > li ul |
{ | { | ||
- | + | height: 130px; | |
- | + | ||
- | + | ||
overflow: hidden; | overflow: hidden; | ||
+ | text-align: center; | ||
} | } | ||
- | # | + | #PKU_banner_menu > li |
{ | { | ||
- | height: | + | height: 30px; |
- | + | ||
} | } | ||
- | |||
#PKU_banner_submenu > li ul > li | #PKU_banner_submenu > li ul > li | ||
{ | { | ||
- | height: | + | height: 25px; |
+ | width: 100%; | ||
+ | background-color: #3570ff; | ||
+ | opacity: 0.85; | ||
+ | } | ||
+ | #PKU_banner_submenu > li ul > li:hover | ||
+ | { | ||
+ | background-color: #80aaff; | ||
+ | opacity: 1.0; | ||
} | } | ||
#PKU_banner_submenu > li ul > li a , | #PKU_banner_submenu > li ul > li a , | ||
Line 300: | Line 310: | ||
#PKU_banner_submenu > li ul > li a:visited | #PKU_banner_submenu > li ul > li a:visited | ||
{ | { | ||
- | + | color: #f0f0f0; | |
- | + | ||
text-decoration: none; | text-decoration: none; | ||
+ | padding-top: 2px; | ||
+ | vertical-align: middle; | ||
} | } | ||
#PKU_banner_submenu > li ul > li a:hover , | #PKU_banner_submenu > li ul > li a:hover , | ||
#PKU_banner_submenu > li ul > li a:active | #PKU_banner_submenu > li ul > li a:active | ||
{ | { | ||
- | + | color: #ffffcc; | |
- | + | ||
text-decoration: none; | text-decoration: none; | ||
} | } | ||
- | # | + | |
+ | /***--- Block Style ---***/ | ||
+ | #text-body | ||
{ | { | ||
- | + | position: relative; | |
+ | top: -90px; | ||
+ | z-index: 1; | ||
} | } | ||
- | # | + | |
+ | #text-body #PKU_subsubmenu | ||
{ | { | ||
- | + | background-color: transparent; | |
+ | padding: 0; | ||
+ | margin: 0; | ||
} | } | ||
- | # | + | #text-body #PKU_subsubmenu a, |
+ | #text-body #PKU_subsubmenu a:link, | ||
+ | #text-body #PKU_subsubmenu a:visited | ||
{ | { | ||
- | + | color: #eeeeee; | |
} | } | ||
- | # | + | #text-body #PKU_subsubmenu a:hover, |
+ | #text-body #PKU_subsubmenu a:active | ||
{ | { | ||
- | + | color: #ffffff; | |
} | } | ||
- | + | #text-body ul#PKU_subsubmenu > li | |
- | + | ||
- | + | ||
- | + | ||
- | #text-body | + | |
{ | { | ||
- | position: | + | width: 184px; |
- | top: - | + | overflow: hidden; |
+ | line-height: 20px; | ||
+ | vertical-align: middle; | ||
+ | padding: 13px 18px; | ||
+ | text-align: left; | ||
+ | font-family: Eras Medium ITC, Verdana, sans-serif; | ||
+ | } | ||
+ | #text-body ul#PKU_subsubmenu > li.trunk | ||
+ | { | ||
+ | margin-top: 20px; | ||
+ | font-size: 18px; | ||
+ | background-position: 50% 50%; | ||
+ | } | ||
+ | #text-body ul#PKU_subsubmenu > li:first-child | ||
+ | { | ||
+ | margin-top: 0; | ||
+ | } | ||
+ | #text-body ul#PKU_subsubmenu > li.branch | ||
+ | { | ||
+ | padding: 7px 17px; | ||
+ | margin: 0; | ||
+ | border-style: solid; | ||
+ | border-width: 1px; | ||
+ | border-color: #70a0ff; | ||
+ | font-size: 14px; | ||
+ | height: 0; | ||
+ | } | ||
+ | #text-body ul#PKU_subsubmenu > li.branch li | ||
+ | { | ||
+ | line-height: 30px; | ||
+ | vertical-align: middle; | ||
} | } | ||
Line 340: | Line 386: | ||
{ | { | ||
background-color: transparent; | background-color: transparent; | ||
- | padding: | + | color: #ffffff; |
- | margin: 0; | + | padding: 25px; |
+ | margin: 20px 0; | ||
border-style: solid; | border-style: solid; | ||
border-width: 1px; | border-width: 1px; | ||
- | border-color: # | + | border-color: #70a0ff; |
text-align: center; | text-align: center; | ||
font-family: Arial, sans-serif; | font-family: Arial, sans-serif; | ||
} | } | ||
- | + | #text-body .PKU_context.first | |
+ | { | ||
+ | margin-top: 0; | ||
+ | } | ||
#text-body .PKU_context * | #text-body .PKU_context * | ||
{ | { | ||
margin: 0; | margin: 0; | ||
+ | } | ||
+ | #text-body .PKU_context table | ||
+ | { | ||
+ | margin: 0 auto; | ||
+ | width: 560px; | ||
+ | font-size: 15px; | ||
+ | } | ||
+ | #text-body .PKU_context table td | ||
+ | { | ||
+ | border-style: solid; | ||
+ | border-color: #ffffff; | ||
+ | border-width: 1px; | ||
} | } | ||
#text-body .PKU_context p | #text-body .PKU_context p | ||
{ | { | ||
font-size: 16px; | font-size: 16px; | ||
- | padding: | + | padding: 10px; |
text-align: justify; | text-align: justify; | ||
} | } | ||
Line 362: | Line 424: | ||
{ | { | ||
text-align: left; | text-align: left; | ||
- | font-size: | + | color: #70d0ff; |
- | padding: | + | font-size: 30px; |
+ | padding: 10px; | ||
+ | line-height: 33px; | ||
} | } | ||
- | #text-body .PKU_context. | + | #text-body .PKU_context ul, |
+ | #text-body .PKU_context li | ||
{ | { | ||
- | + | text-align: justify; | |
+ | font-size: 16px; | ||
} | } | ||
- | #text-body .PKU_context. | + | #text-body .PKU_context ul.refer li |
{ | { | ||
- | + | font-size: 15px; | |
} | } | ||
- | #text-body .PKU_context | + | #text-body .PKU_context ul.refer |
- | + | ||
{ | { | ||
- | padding: | + | padding-left: 10px; |
+ | width: 655px; | ||
} | } | ||
- | #text-body .PKU_context p.description | + | #text-body .PKU_context ul |
+ | { | ||
+ | padding-left: 20px; | ||
+ | width: 570px; | ||
+ | } | ||
+ | #text-body .PKU_context.floatC p | ||
+ | { | ||
+ | width: 887px; | ||
+ | } | ||
+ | #text-body .PKU_context.floatR p | ||
+ | { | ||
+ | width: 655px; | ||
+ | } | ||
+ | #text-body .PKU_context.floatR p.description | ||
{ | { | ||
font-style: italic; | font-style: italic; | ||
Line 385: | Line 464: | ||
padding: 10px 10px; | padding: 10px 10px; | ||
text-align: justify; | text-align: justify; | ||
- | width: | + | width: 550px; |
} | } | ||
- | + | #text-body .PKU_context img , | |
- | . | + | #text-body .PKU_context object |
{ | { | ||
- | + | padding: 0; | |
} | } | ||
Line 474: | Line 553: | ||
pkutopa[12].href = 'https://2012.igem.org/wiki/index.php?title=Special:UserLogin' + '&'.substring(0,1) + 'returnto=' + thispage; | pkutopa[12].href = 'https://2012.igem.org/wiki/index.php?title=Special:UserLogin' + '&'.substring(0,1) + 'returnto=' + thispage; | ||
- | var | + | var userbar = document.getElementById('pt-userpage'); |
var username; | var username; | ||
+ | var userstr; | ||
- | if ( | + | if (userbar!=null) |
{ | { | ||
- | username = | + | userstr = userbar.innerHTML; |
+ | username = userstr.substring(userstr.lastIndexOf('<'),userstr.indexOf('>')+1); | ||
pkutopa[17].innerHTML = username; | pkutopa[17].innerHTML = username; | ||
pkutopa[17].href = 'https://2012.igem.org/User:' + username; | pkutopa[17].href = 'https://2012.igem.org/User:' + username; | ||
Line 487: | Line 568: | ||
pkutopli[5].style.display='inline'; | pkutopli[5].style.display='inline'; | ||
pkutopli[6].style.display='none'; | pkutopli[6].style.display='none'; | ||
- | + | userstr = document.getElementById('menubar').innerHTML; | |
- | if ( | + | if (userstr.search('unwatch')!=-1) |
{ | { | ||
pkutopli[2].style.display='none'; | pkutopli[2].style.display='none'; | ||
pkutopli[3].style.display='inline'; | pkutopli[3].style.display='inline'; | ||
} | } | ||
- | else if ( | + | else if (userstr.search('watch')!=-1) |
{ | { | ||
pkutopli[2].style.display='inline'; | pkutopli[2].style.display='inline'; | ||
Line 515: | Line 596: | ||
</script> | </script> | ||
- | + | <div class="floatC"><p class="blank" style="height:20px;"> </p></div> | |
<div id="PKU_banner_container"> | <div id="PKU_banner_container"> | ||
<div class="floatL"> | <div class="floatL"> | ||
Line 521: | Line 602: | ||
</div> | </div> | ||
<div class="floatR"> | <div class="floatR"> | ||
- | <p id="PKU_banner_logo"><img style="width: | + | <p id="PKU_banner_logo"><img style="width:50px;margin-right:0;" src="/wiki/images/8/85/Peking2012_Color_Logo_128.png" alt="" /></p> |
</div> | </div> | ||
<div class="floatR"> | <div class="floatR"> | ||
- | <ul id="PKU_banner_menu" class="button"> | + | <ul id="PKU_banner_menu" class="button horizontal"> |
- | <li style="width: | + | <li style="width:60px;"> |
<a onmouseover="TriggerSubmenu(0);" href="/Team:Peking"> | <a onmouseover="TriggerSubmenu(0);" href="/Team:Peking"> | ||
Home | Home | ||
</a> | </a> | ||
</li> | </li> | ||
- | <li style="width: | + | <li style="width:60px;"> |
- | <a onmouseover="TriggerSubmenu(1);" onmouseout=" | + | <a onmouseover="TriggerSubmenu(1);" onmouseout="TriggerSubmenu(0);"> |
Team | Team | ||
</a> | </a> | ||
</li> | </li> | ||
- | <li style="width: | + | <li style="width:70px;"> |
- | <a onmouseover="TriggerSubmenu(2);" onmouseout=" | + | <a onmouseover="TriggerSubmenu(2);" onmouseout="TriggerSubmenu(0);"> |
Project | Project | ||
</a> | </a> | ||
</li> | </li> | ||
- | <li style="width: | + | <li style="width:85px;"> |
- | <a onmouseover="TriggerSubmenu( | + | <a onmouseover="TriggerSubmenu(3);" onmouseout="TriggerSubmenu(0);"> |
Data Page | Data Page | ||
</a> | </a> | ||
</li> | </li> | ||
- | <li style="width: | + | <li style="width:80px;"> |
- | <a onmouseover="TriggerSubmenu( | + | <a onmouseover="TriggerSubmenu(4);" onmouseout="TriggerSubmenu(0);"> |
Modeling | Modeling | ||
</a> | </a> | ||
</li> | </li> | ||
- | <li style="width: | + | <li style="width:130px;"> |
- | <a onmouseover="TriggerSubmenu( | + | <a onmouseover="TriggerSubmenu(5);" onmouseout="TriggerSubmenu(0);"> |
Human Practice | Human Practice | ||
</a> | </a> | ||
</li> | </li> | ||
- | <li style="width: | + | <li style="width:65px;"> |
<a onmouseover="TriggerSubmenu(0);" href="/Team:Peking/Safety"> | <a onmouseover="TriggerSubmenu(0);" href="/Team:Peking/Safety"> | ||
Safety | Safety | ||
Line 563: | Line 644: | ||
</div> | </div> | ||
<div class="floatC"> | <div class="floatC"> | ||
- | <ul id="PKU_banner_submenu" class="button"> | + | <ul id="PKU_banner_submenu" class="button horizontal"> |
- | <li | + | <li class="blank"> |
  |   | ||
</li> | </li> | ||
- | <li | + | <li> |
- | <ul onmouseover="TriggerSubmenu(1);" onmouseout="TriggerSubmenu(0);" > | + | <ul onmouseover="TriggerSubmenu(1);" onmouseout="TriggerSubmenu(0);" class="vertical" style="width:120px;display:block;"> |
<li class="submenu_team"> | <li class="submenu_team"> | ||
<a href="/Team:Peking/Team/Members"> | <a href="/Team:Peking/Team/Members"> | ||
Line 575: | Line 656: | ||
</li> | </li> | ||
<li class="submenu_team"> | <li class="submenu_team"> | ||
- | <a href="/Team:Peking/Team/ | + | <a href="/Team:Peking/Team/Protocol"> |
- | + | Protocol | |
</a> | </a> | ||
</li> | </li> | ||
<li class="submenu_team"> | <li class="submenu_team"> | ||
- | <a href="/Team:Peking/Team/ | + | <a href="/Team:Peking/Team/AA"> |
- | + | Attribution | |
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
</a> | </a> | ||
</li> | </li> | ||
</ul> | </ul> | ||
</li> | </li> | ||
- | <li | + | <li> |
- | <ul onmouseover="TriggerSubmenu(2);" onmouseout="TriggerSubmenu(0);" > | + | <ul onmouseover="TriggerSubmenu(2);" onmouseout="TriggerSubmenu(0);" class="vertical" style="width:200px;display:block;"> |
+ | <li class="submenu_project"> | ||
+ | <a href="/Team:Peking/Project"> | ||
+ | Overview | ||
+ | </a> | ||
+ | </li> | ||
<li class="submenu_project"> | <li class="submenu_project"> | ||
<a href="/Team:Peking/Project/Luminesensor"> | <a href="/Team:Peking/Project/Luminesensor"> | ||
Line 599: | Line 680: | ||
</li> | </li> | ||
<li class="submenu_project"> | <li class="submenu_project"> | ||
- | <a href="/Team:Peking/Project/ | + | <a href="/Team:Peking/Project/Communication"> |
Light Communication | Light Communication | ||
</a> | </a> | ||
</li> | </li> | ||
<li class="submenu_project"> | <li class="submenu_project"> | ||
- | <a href="/Team:Peking/Project/ | + | <a href="/Team:Peking/Project/3D"> |
- | + | Synbio in 2D & 3D | |
</a> | </a> | ||
</li> | </li> | ||
Line 615: | Line 696: | ||
</ul> | </ul> | ||
</li> | </li> | ||
- | <li | + | <li> |
- | <ul onmouseover="TriggerSubmenu(3);" onmouseout="TriggerSubmenu(0);" > | + | <ul onmouseover="TriggerSubmenu(3);" onmouseout="TriggerSubmenu(0);" class="vertical" style="width:170px;display:block;"> |
- | <li class=" | + | <li class="submenu_project"> |
- | <a href="/Team:Peking/ | + | <a href="/Team:Peking/DataPage"> |
- | + | Data Page | |
</a> | </a> | ||
</li> | </li> | ||
+ | <li class="submenu_project"> | ||
+ | <a href="/Team:Peking/DataPage/Judging"> | ||
+ | Judging Criteria | ||
+ | </a> | ||
+ | </li> | ||
+ | </ul> | ||
+ | </li> | ||
+ | <li> | ||
+ | <ul onmouseover="TriggerSubmenu(4);" onmouseout="TriggerSubmenu(0);" class="vertical" style="width:250px;display:block;"> | ||
<li class="submenu_modeling"> | <li class="submenu_modeling"> | ||
- | <a href="/Team:Peking/Modeling | + | <a href="/Team:Peking/Modeling"> |
- | + | Overview | |
</a> | </a> | ||
</li> | </li> | ||
- | + | <li class="submenu_modeling"> | |
- | <a href="/Team:Peking/Modeling/ | + | <a href="/Team:Peking/Modeling/Luminesensor"> |
- | + | Luminesensor | |
</a> | </a> | ||
- | </li | + | </li> |
<li class="submenu_modeling"> | <li class="submenu_modeling"> | ||
<a href="/Team:Peking/Modeling/Phototaxis"> | <a href="/Team:Peking/Modeling/Phototaxis"> | ||
Phototaxis Simulation | Phototaxis Simulation | ||
+ | </a> | ||
+ | </li> | ||
+ | <li class="submenu_modeling"> | ||
+ | <a href="/Team:Peking/Modeling/Ring"> | ||
+ | Ring Pattern | ||
</a> | </a> | ||
</li> | </li> | ||
</ul> | </ul> | ||
</li> | </li> | ||
- | <li | + | <li> |
- | <ul onmouseover="TriggerSubmenu( | + | <ul onmouseover="TriggerSubmenu(5);" onmouseout="TriggerSubmenu(0);" class="vertical" style="width:320px;display:block;"> |
<li class="submenu_humanpractice"> | <li class="submenu_humanpractice"> | ||
- | <a href="/Team:Peking/HumanPractice/ | + | <a href="/Team:Peking/HumanPractice/Sowing"> |
- | Sowing Tomorrow Synthetic Biologists | + | Sowing Tomorrow's Synthetic Biologists |
</a> | </a> | ||
</li> | </li> | ||
<li class="submenu_humanpractice"> | <li class="submenu_humanpractice"> | ||
- | <a href="/Team:Peking/HumanPractice/ | + | <a href="/Team:Peking/HumanPractice/Review"> |
Historic iGEM Projects Review | Historic iGEM Projects Review | ||
</a> | </a> | ||
</li> | </li> | ||
<li class="submenu_humanpractice"> | <li class="submenu_humanpractice"> | ||
- | <a href="/Team:Peking/HumanPractice/ | + | <a href="/Team:Peking/HumanPractice/Outreach/Visiting"> |
Outreach & Workshop | Outreach & Workshop | ||
</a> | </a> | ||
Line 669: | Line 764: | ||
*/ | */ | ||
- | var Submenu_Size_Cur = [0, 0, 0, 0, 0]; | + | var Submenu_Size_Cur = [130, 0, 0, 0, 0, 0]; |
- | var Submenu_Item_Num = | + | var Submenu_Item_Num = 5; |
var Submenu_Item_Des = 0; | var Submenu_Item_Des = 0; | ||
var Submenu_Item_Cur = 0; | var Submenu_Item_Cur = 0; | ||
- | var Submenu_BlankWidth = [0, | + | var Submenu_BlankWidth = [0, 445, 470, 562, 608, 640]; //Unit: Pixel |
- | var Submenu_ListHeight = [ | + | var Submenu_ListHeight = [130, 75, 125, 50, 100, 75]; //Unit: Pixel |
var Submenu_Handle_State = 0; //0:Null, 1:Growth, 2:Waiting, 3:Wither | var Submenu_Handle_State = 0; //0:Null, 1:Growth, 2:Waiting, 3:Wither | ||
var Submenu_Handle = null; | var Submenu_Handle = null; | ||
+ | var Submenu_Parent = document.getElementById('PKU_banner_container'); | ||
var Submenu = document.getElementById('PKU_banner_submenu'); | var Submenu = document.getElementById('PKU_banner_submenu'); | ||
- | var Submenu_Obj = Submenu. | + | var Submenu_Obj = Submenu.getElementsByTagName('ul'); |
+ | var Submenu_Blank = Submenu.getElementsByTagName('li')[0]; | ||
+ | for (var it=0;it<Submenu_Item_Num;++it) | ||
+ | { | ||
+ | Submenu_Obj[it].style.height=Submenu_Size_Cur[it+1]+'px'; | ||
+ | Submenu_Obj[it].style.display='none'; | ||
+ | } | ||
/* Automatic Function */ | /* Automatic Function */ | ||
function ItemGrowth() | function ItemGrowth() | ||
{ | { | ||
- | Submenu_Size_Cur[Submenu_Item_Cur] = Submenu_Size_Cur[Submenu_Item_Cur] * 0. | + | Submenu_Size_Cur[Submenu_Item_Cur] = Submenu_Size_Cur[Submenu_Item_Cur] * 0.6 + Submenu_ListHeight[Submenu_Item_Cur] * 1.2 * 0.4; |
if (Submenu_Size_Cur[Submenu_Item_Cur]>=Submenu_ListHeight[Submenu_Item_Cur]) | if (Submenu_Size_Cur[Submenu_Item_Cur]>=Submenu_ListHeight[Submenu_Item_Cur]) | ||
{ | { | ||
Submenu_Size_Cur[Submenu_Item_Cur]=Submenu_ListHeight[Submenu_Item_Cur]; | Submenu_Size_Cur[Submenu_Item_Cur]=Submenu_ListHeight[Submenu_Item_Cur]; | ||
- | |||
Submenu_Handle_State = 0; | Submenu_Handle_State = 0; | ||
+ | Submenu_Handle = null; | ||
} | } | ||
else | else | ||
Line 694: | Line 796: | ||
Submenu_Handle = setTimeout(ItemGrowth,50); | Submenu_Handle = setTimeout(ItemGrowth,50); | ||
} | } | ||
- | Submenu_Obj[Submenu_Item_Cur].style.height=Submenu_Size_Cur[Submenu_Item_Cur]+'px'; | + | Submenu_Obj[Submenu_Item_Cur-1].style.height=Submenu_Size_Cur[Submenu_Item_Cur]+'px'; |
} | } | ||
function ItemWither() | function ItemWither() | ||
{ | { | ||
- | Submenu_Size_Cur[Submenu_Item_Cur] = Submenu_Size_Cur[Submenu_Item_Cur] * 0. | + | Submenu_Size_Cur[Submenu_Item_Cur] = Submenu_Size_Cur[Submenu_Item_Cur] * 0.6 - 5 * 0.4; |
if (Submenu_Size_Cur[Submenu_Item_Cur]<=0) | if (Submenu_Size_Cur[Submenu_Item_Cur]<=0) | ||
{ | { | ||
Submenu_Size_Cur[Submenu_Item_Cur]=0; | Submenu_Size_Cur[Submenu_Item_Cur]=0; | ||
+ | Submenu_Obj[Submenu_Item_Cur-1].style.display='none'; | ||
+ | Submenu_Obj[Submenu_Item_Cur-1].style.height=0; | ||
Submenu_Item_Cur = Submenu_Item_Des; | Submenu_Item_Cur = Submenu_Item_Des; | ||
- | + | Submenu_Blank.style.width=Submenu_BlankWidth[Submenu_Item_Cur]+'px'; | |
if (Submenu_Item_Des!=0) | if (Submenu_Item_Des!=0) | ||
{ | { | ||
+ | if (Submenu_Handle) {clearTimeout(Submenu_Handle);Submenu_Handle = null;} | ||
+ | Submenu_Obj[Submenu_Item_Cur-1].style.display='block'; | ||
Submenu_Handle_State = 1; | Submenu_Handle_State = 1; | ||
ItemGrowth(); | ItemGrowth(); | ||
Line 713: | Line 819: | ||
Submenu_Handle_State = 0; | Submenu_Handle_State = 0; | ||
Submenu_Handle = null; | Submenu_Handle = null; | ||
- | + | Submenu_Parent.style.zIndex = 0; | |
} | } | ||
} | } | ||
else | else | ||
{ | { | ||
+ | Submenu_Obj[Submenu_Item_Cur-1].style.height=Submenu_Size_Cur[Submenu_Item_Cur]+'px'; | ||
Submenu_Handle = setTimeout(ItemWither,50); | Submenu_Handle = setTimeout(ItemWither,50); | ||
} | } | ||
- | |||
} | } | ||
function ToWither() | function ToWither() | ||
Line 736: | Line 842: | ||
if (i!=0) | if (i!=0) | ||
{ | { | ||
- | + | Submenu_Parent.style.zIndex = 5; | |
Submenu_Item_Des = i; | Submenu_Item_Des = i; | ||
Submenu_Item_Cur = i; | Submenu_Item_Cur = i; | ||
Submenu_Handle_State = 1; | Submenu_Handle_State = 1; | ||
- | + | Submenu_Blank.style.width=Submenu_BlankWidth[Submenu_Item_Cur]+'px'; | |
+ | Submenu_Obj[Submenu_Item_Cur-1].style.display='block'; | ||
+ | if (Submenu_Handle) {clearTimeout(Submenu_Handle);Submenu_Handle = null;} | ||
ItemGrowth(); | ItemGrowth(); | ||
} | } | ||
Line 754: | Line 862: | ||
else if (i!=Submenu_Item_Cur) | else if (i!=Submenu_Item_Cur) | ||
{ | { | ||
+ | if (Submenu_Handle) {clearTimeout(Submenu_Handle);Submenu_Handle = null;} | ||
Submenu_Handle_State = 3; | Submenu_Handle_State = 3; | ||
ItemWither(); | ItemWither(); | ||
Line 764: | Line 873: | ||
if (i!=0) | if (i!=0) | ||
{ | { | ||
+ | clearTimeout(Submenu_Handle);Submenu_Handle = null; | ||
if (i==Submenu_Item_Cur) | if (i==Submenu_Item_Cur) | ||
{ | { | ||
- | |||
Submenu_Handle_State = 0; | Submenu_Handle_State = 0; | ||
} | } | ||
Line 781: | Line 890: | ||
if (i==Submenu_Item_Cur) | if (i==Submenu_Item_Cur) | ||
{ | { | ||
- | clearTimeout(Submenu_Handle); | + | clearTimeout(Submenu_Handle);Submenu_Handle = null; |
Submenu_Handle_State = 1; | Submenu_Handle_State = 1; | ||
ItemGrowth(); | ItemGrowth(); | ||
Line 791: | Line 900: | ||
{ | { | ||
Submenu_Item_Des = i; | Submenu_Item_Des = i; | ||
+ | clearTimeout(Submenu_Handle);Submenu_Handle = null; | ||
Submenu_Handle_State = 3; | Submenu_Handle_State = 3; | ||
ItemWither(); | ItemWither(); |
Latest revision as of 05:09, 26 October 2012