function switchLayer()

in gui.js [177:182]


    function switchLayer(index) {
      return function(on) {
        if (on) funcs.turnOn(index);
        else funcs.turnOff(index);
      }
    }