Merge branch 'master' into gh-pages

This commit is contained in:
BigEd 2010-11-08 09:17:38 +00:00
commit 60b4ecab22
2 changed files with 6 additions and 10 deletions

View File

@ -52,7 +52,7 @@ var drawlayers = [true, true, true, true, true, true];
// some modes and parameters which can be passed in from the URL query // some modes and parameters which can be passed in from the URL query
var moveHereFirst; var moveHereFirst;
var expertMode=false var expertMode=true;
var animateChipLayout = true; var animateChipLayout = true;
var userCode=[]; var userCode=[];
var userResetLow; var userResetLow;
@ -82,7 +82,7 @@ function setup_part2(){
setupNodes(); setupNodes();
setupTransistors(); setupTransistors();
setupParams(); setupParams();
updateExpertMode(expertMode); setupExpertMode();
detectOldBrowser(); detectOldBrowser();
setStatus('loading graphics...'); setStatus('loading graphics...');
setTimeout(setup_part3, 0); setTimeout(setup_part3, 0);
@ -154,8 +154,6 @@ function setupParams(){
updateLoglevel(value); updateLoglevel(value);
} else if(name=="logmore" && value!=""){ } else if(name=="logmore" && value!=""){
updateLogList(value); updateLogList(value);
} else if(name=="expert" && value.indexOf("t")==0){
updateExpertMode(true);
} else if(name=="headlesssteps" && parseInt(value)!=NaN){ } else if(name=="headlesssteps" && parseInt(value)!=NaN){
headlessSteps=parseInt(value); headlessSteps=parseInt(value);
} else if(name=="graphics" && value.indexOf("f")==0){ } else if(name=="graphics" && value.indexOf("f")==0){
@ -346,8 +344,7 @@ function updateLoglevel(value){
initLogbox(logThese); initLogbox(logThese);
} }
function updateExpertMode(isOn){ function setupExpertMode(isOn){
expertMode=true
document.getElementById('expertControlPanel').style.display = 'block'; document.getElementById('expertControlPanel').style.display = 'block';
if(loglevel==0) if(loglevel==0)
updateLoglevel(1); updateLoglevel(1);
@ -367,8 +364,7 @@ function updateChipLayoutVisibility(isOn){
// replace the Show Chip button with the chip graphics // replace the Show Chip button with the chip graphics
chipsurround=document.getElementById('chipsurround'); chipsurround=document.getElementById('chipsurround');
chipsurround.style.display = 'block'; chipsurround.style.display = 'block';
if(expertMode) document.getElementById('layoutControlPanel').style.display = 'block';
document.getElementById('layoutControlPanel').style.display = 'block';
document.getElementById('nochip').style.display = 'none'; document.getElementById('nochip').style.display = 'none';
// allow the browser to respond while we load the graphics // allow the browser to respond while we load the graphics
setStatus('loading graphics...'); setStatus('loading graphics...');

View File

@ -157,7 +157,8 @@ function initChip(){
refresh(); refresh();
cycle = 0; cycle = 0;
trace = Array(); trace = Array();
updateLogList(); if(typeof expertMode != "undefined")
updateLogList();
chipStatus(); chipStatus();
if(ctrace)console.log('initChip done after', now()-start); if(ctrace)console.log('initChip done after', now()-start);
} }
@ -187,7 +188,6 @@ function updateLogList(names){
if(typeof busToString(names[i]) != "undefined") if(typeof busToString(names[i]) != "undefined")
logThese.push(names[i]); logThese.push(names[i]);
} }
console.log(logThese);
initLogbox(logThese); initLogbox(logThese);
} }