Template:Peking2012 Color Modeling
From 2012.igem.org
(Difference between revisions)
m |
m |
||
Line 10: | Line 10: | ||
<div class="floatL"> | <div class="floatL"> | ||
<ul id="PKU_subsubmenu" class="vertical"> | <ul id="PKU_subsubmenu" class="vertical"> | ||
- | <li class="trunk" style="background-image:url('/wiki/images/a/a4/Peking2012_Color_Title_FlameYellow.jpg');"> | + | <li class="trunk" style="background-image:url('/wiki/images/a/a4/Peking2012_Color_Title_FlameYellow.jpg');" onmouseover="listTrigger(0);"> |
<a href="/Team:Peking/Modeling/Luminesensor">Luminesensor Optimization</a> | <a href="/Team:Peking/Modeling/Luminesensor">Luminesensor Optimization</a> | ||
- | </li><li class="branch"> | + | </li><li class="branch" onmouseover="listTrigger(0);"> |
<ul class="vertical"> | <ul class="vertical"> | ||
<li> | <li> | ||
Line 22: | Line 22: | ||
</li> | </li> | ||
</ul> | </ul> | ||
- | </li><li class="trunk" style="background-image:url('/wiki/images/a/a2/Peking2012_Color_Title_FreshGreen.jpg');"> | + | </li><li class="trunk" style="background-image:url('/wiki/images/a/a2/Peking2012_Color_Title_FreshGreen.jpg');" onmouseover="listTrigger(1);"> |
<a href="/Team:Peking/Modeling/Channel">New Communication Channel</a> | <a href="/Team:Peking/Modeling/Channel">New Communication Channel</a> | ||
- | </li><li class="branch"> | + | </li><li class="branch" onmouseover="listTrigger(1);"> |
<ul class="vertical"> | <ul class="vertical"> | ||
</ul> | </ul> | ||
- | </li><li class="trunk" style="background-image:url('/wiki/images/f/fe/Peking2012_Color_Title_GrapePurple.jpg');"> | + | </li><li class="trunk" style="background-image:url('/wiki/images/f/fe/Peking2012_Color_Title_GrapePurple.jpg');" onmouseover="listTrigger(2);"> |
<a href="/Team:Peking/Modeling/Phototaxis">Phototaxis</a> | <a href="/Team:Peking/Modeling/Phototaxis">Phototaxis</a> | ||
- | </li><li class="branch"> | + | </li><li class="branch" onmouseover="listTrigger(2);"> |
<ul class="vertical"> | <ul class="vertical"> | ||
<li> | <li> | ||
Line 59: | Line 59: | ||
* by Sun Sibai | * by Sun Sibai | ||
*/ | */ | ||
- | var sublists_Num = | + | var sublists_Num = 3; //Total Number |
var sublists_Cur = 0; //Current Grow | var sublists_Cur = 0; //Current Grow | ||
var sublists_Now = 0; //Current Page | var sublists_Now = 0; //Current Page | ||
- | var subLhght = [120,120,120 | + | var subLhght = [120,120,120]; //Unit: Pixel |
- | var subLhght_Cur = [ | + | var subLhght_Cur = [0,0,0]; //Unit: Pixel |
var subLhand_Wither = [null,null,null,null]; | var subLhand_Wither = [null,null,null,null]; | ||
var subLhand_Growth = null; | var subLhand_Growth = null; | ||
Line 70: | Line 70: | ||
for (var it=0;it<sublists_Num;++it) | for (var it=0;it<sublists_Num;++it) | ||
{ | { | ||
- | sublists[2*it+ | + | sublists[2*it+2].style.height=subLhght_Cur[it]+'px'; |
- | sublists[2*it+ | + | sublists[2*it+2].style.display='none'; |
} | } | ||
/* Automatic Function */ | /* Automatic Function */ | ||
Line 94: | Line 94: | ||
subLhand_Growth = setTimeout(listGrowth,50); | subLhand_Growth = setTimeout(listGrowth,50); | ||
} | } | ||
- | sublists[2*sublists_Cur+ | + | sublists[2*sublists_Cur+2].style.height=subLhght_Cur[sublists_Cur]+'px'; |
} | } | ||
function listWither(i) | function listWither(i) | ||
Line 104: | Line 104: | ||
clearInterval(subLhand_Wither[i]); | clearInterval(subLhand_Wither[i]); | ||
subLhand_Wither[i] = null; | subLhand_Wither[i] = null; | ||
- | sublists[2*i+ | + | sublists[2*i+2].style.display='none'; |
} | } | ||
- | sublists[2*i+ | + | sublists[2*i+2].style.height=subLhght_Cur[sublists_Cur]+'px'; |
} | } | ||
function listReturn() | function listReturn() | ||
Line 122: | Line 122: | ||
} | } | ||
sublists_Cur = i; | sublists_Cur = i; | ||
- | if (subLhand_Wither[ | + | if (subLhand_Wither[i]!=null) |
{ | { | ||
- | clearInterval(subLhand_Wither[ | + | clearInterval(subLhand_Wither[i]); |
} | } | ||
+ | sublists[2*i+2].style.display='block'; | ||
listGrowth(); | listGrowth(); | ||
} | } |
Revision as of 09:17, 14 September 2012