Last try: overdrived gauge timed colours change made less brutal

This commit is contained in:
HomeWorld
2010-08-30 19:48:15 +03:00
parent bb3f88f905
commit 6e4dfe2e5f
2 changed files with 5 additions and 5 deletions

2
eos

Submodule eos updated: 9575dcadd0...a08f8a11d2

View File

@@ -51,7 +51,7 @@ class PyGauge(wx.PyWindow):
self._timerOver = None self._timerOver = None
self._oldValue = 0 self._oldValue = 0
self._timerOn = 0 self._timerOn = 0
self._animDuration = 300 self._animDuration = 500
self._animStep = 0 self._animStep = 0
self._period = 25 self._period = 25
self._animValue = 0 self._animValue = 0
@@ -239,8 +239,8 @@ class PyGauge(wx.PyWindow):
c1 =wx.Colour(255,33,33) c1 =wx.Colour(255,33,33)
c2 =wx.Colour(255,33,33) c2 =wx.Colour(255,33,33)
else: else:
c1 =wx.Colour(0,0,0) c1 =wx.Colour(200,0,0)
c2 =wx.Colour(0,0,0) c2 =wx.Colour(200,0,0)
else: else:
c1,c2 = self.GetBarGradient() c1,c2 = self.GetBarGradient()
@@ -322,7 +322,7 @@ class PyGauge(wx.PyWindow):
start = 0 start = 0
end = oldValue - value end = oldValue - value
step=self.OUT_QUAD(self._animStep, start, end, self._animDuration) step=self.OUT_BOUNCE(self._animStep, start, end, self._animDuration)
self._animStep += self._period self._animStep += self._period
if self._timerId == event.GetId() and self._overdriveTimerId != event.GetId(): if self._timerId == event.GetId() and self._overdriveTimerId != event.GetId():