|
| MAS ETH ARCH/CAAD - 2005/06 - STUDENT PAGES Master of Advanced Studies in Architecture, Specialization in Computer Aided Architectural Design | 065-0005/6 Supervision: Prof. Dr. Ludger Hovestadt, Philipp Schaerer Chair of CAAD, ETH Zurich -- NDSDongYounShin - 24 Feb 2006 var sutja=""; var gap = 0; var gap2 = 0; var mok; trace (sutja); btn_1.onRelease= function(){ sutja=sutja+"1"; trace (sutja); pan.text = sutja; } btn_2.onRelease= function(){ sutja=sutja+"2"; trace (sutja); pan.text = sutja; } btn_3.onRelease= function(){ sutja=sutja+"3"; trace (sutja); pan.text = sutja; } btn_4.onRelease= function(){ sutja=sutja+"4"; trace (sutja); pan.text = sutja; } btn_5.onRelease= function(){ sutja=sutja+"5"; trace (sutja); pan.text = sutja; } btn_6.onRelease= function(){ sutja=sutja+"6"; trace (sutja); pan.text = sutja; } btn_7.onRelease= function(){ sutja=sutja+"7"; trace (sutja); pan.text = sutja; } btn_8.onRelease= function(){ sutja=sutja+"8"; trace (sutja); pan.text = sutja; } btn_9.onRelease= function(){ sutja=sutja+"9"; trace (sutja); pan.text = sutja; } btn_0.onRelease= function(){ sutja=sutja+"0"; trace (sutja); pan.text = sutja; } btn_00.onRelease= function(){ sutja=sutja+"."; trace (sutja); pan.text = sutja; } btn_11.onRelease= function(){ sutja=sutja+"-"; trace (sutja); pan.text = sutja; } btn_plus.onRelease= function(){ gap=Number(sutja); sutja=""; sign.text = "+"; giho="+"} btn_minus.onRelease= function(){ gap=Number(sutja); sutja=""; sign.text = "-"; giho="-"} btn_multi.onRelease= function(){ gap=Number(sutja); sutja=""; sign.text = "*"; giho="*"} btn_div.onRelease= function(){ gap=Number(sutja); sutja=""; sign.text = "/"; giho="/"} btn_clear.onRelease= function(){ gap=""; sutja=""; sign.text = ""; pan.text="***SUPER CUTE CALCULATOR***"; giho=""} btn_e.onRelease= function(){ if (giho=="+"){ var mok; var gap2=Number(sutja); trace("gap2 --> " + gap2 + " : " + isNaN(gap2)); trace("gap --> " + gap + " : " + isNaN(gap)); mok=gap+Number(gap2); trace("mok: "+mok); pan.text = mok; sutja=""; } if (giho=="-"){ var mok; var gap2=Number(sutja); mok=gap-Number(gap2); pan.text = mok; sutja=""; } if (giho=="*"){ var mok; var gap2=Number(sutja); mok=gap*Number(gap2); pan.text = mok; sutja=""; } if (giho=="/"){ var mok; var gap2=Number(sutja); mok=gap/Number(gap2); pan.text = mok; sutja=""; } }
|
This website has been archived and is no longer maintained.