code: def RecordHistory(self):
          
          if not self.restoringHistory:
              record = self.activated_node
              if self.historyIndex < -1:
                  try:
                      del self.history[self.historyIndex+1:]
                  except AttributeError, err:
                      pass
              if (not self.history) or record != self.history[-1]:
                  self.history.append(record)
              del self.history[:-200]
              self.historyIndex = -1
docs: Add the given node to the history-set