code: function (newMode, noSave) {
              if (mode != newMode) {
                  mode = newMode;
                  if (!noSave) {
                      saveState();
                  }
              }
  
              if (!uaSniffed.isIE || mode != "moving") {
                  timer = setTimeout(refreshState, 1);
              }
              else {
                  inputStateObj = null;
              }
          }
docs: Set the mode for later logic steps.