Cod:
Code:
#Exygo's function def timp_frumos(self, minute): #import math # modulul math se presupune a fi deja importat sus self.ore = minute / 60 if minute <= 60: return uiScriptLocale.EXYGO_TIME_FORMAT_MINUTE % (minute) else: if self.ore <= 24: return uiScriptLocale.EXYGO_TIME_FORMAT_HOURS_AND_MINUTES % (self.ore, minute - 60 * self.ore) # Ingeniozitate maa! else: self.zile = self.ore / 24 return uiScriptLocale.EXYGO_TIME_FORMAT_DAYS_AND_HOURS % (self.zile, self.ore - 24 * self.zile) # Ingeniozitate maa!
Code:
self.PlayTime.SetText(self.timp_frumos(playTime))
Code:
EXYGO_TIME_FORMAT_MINUTE %s minute(s) EXYGO_TIME_FORMAT_HOURS_AND_MINUTES %s hour(s) and %s minute(s) EXYGO_TIME_FORMAT_DAYS_AND_HOURS %s day(s) and %s hour(s)
Hint: introselect.py
* This little part of code was wrote by Exygo(me)





