This commit is contained in:
恍兮惚兮 2024-06-09 22:28:03 +08:00
parent 965e4fbe11
commit deb9321cda

View File

@ -990,17 +990,14 @@ class dialog_setting_game_internal(QWidget):
return lists return lists
def refresh(self): def refresh(self):
self._timelabel.setText( __ = gobject.baseobject.querytraceplaytime_v4(self.exepath)
self.formattime(savehook_new_data[self.exepath]["statistic_playtime"]) _cnt = sum([_[1] - _[0] for _ in __])
) savehook_new_data[self.exepath]["statistic_playtime"] = _cnt
self._timelabel.setText(self.formattime(_cnt))
self._wordlabel.setText( self._wordlabel.setText(
str(savehook_new_data[self.exepath]["statistic_wordcount"]) str(savehook_new_data[self.exepath]["statistic_wordcount"])
) )
self.chart.setdata( self.chart.setdata(self.split_range_into_days(__))
self.split_range_into_days(
gobject.baseobject.querytraceplaytime_v4(self.exepath)
)
)
def formattime(self, t, usingnotstart=True): def formattime(self, t, usingnotstart=True):
t = int(t) t = int(t)