parameters: (self, deltaTime, newAmount)
docstring: This method saves item delta time and shows updated progress bar with calculated eta
docstring_summary: This method saves item delta time and shows updated progress bar with calculated eta
docstring_tokens: This method saves item delta time and shows updated progress bar with calculated eta
function: def progress(self, deltaTime, newAmount):
          """
          This method saves item delta time and shows updated progress bar with calculated eta
          """
  
          if len(self._times) <= ((self._max * 3) / 100) or newAmount > self._max:
              eta = None
          else:
              midTime = sum(self._times) / len(self._times)
              midTimeWithLatest = (midTime + deltaTime) / 2
              eta = midTimeWithLatest * (self._max - newAmount)
  
          self._times.append(deltaTime)
          self.update(newAmount)
          self.draw(eta)
function_tokens: def progress ( self , deltaTime , newAmount ) : if len ( self . _times ) <= ( ( self . _max * 3 ) / 100 ) or newAmount > self . _max : eta = None else : midTime = sum ( self . _times ) / len ( self . _times ) midTimeWithLatest = ( midTime + deltaTime ) / 2 eta = midTimeWithLatest * ( self . _max - newAmount ) self . _times . append ( deltaTime ) self . update ( newAmount ) self . draw ( eta )