Skip to content

Commit

Permalink
fix gui info lost (#31)
Browse files Browse the repository at this point in the history
  • Loading branch information
Juice-XIJ authored Apr 26, 2022
1 parent 860633f commit 702203e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
3 changes: 1 addition & 2 deletions forza.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,8 @@ def test_gear(self, update_car_gui_func=None):
if fdp is None:
continue

self.__update_forza_info(fdp)

if fdp.speed > 0.1:
self.__update_forza_info(fdp)
if update_car_gui_func is not None:
update_car_gui_func(fdp)
info = {
Expand Down
6 changes: 0 additions & 6 deletions gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,12 +219,6 @@ def reset_car_info(self):
self.treeview.item(self.speed_tree[key], values="-")
self.treeview.item(self.rpm_tree[key], values="-")

# reset car information
self.car_id_var.set("None")
self.car_perf_var.set(0)
self.car_class_var.set(-1)
self.car_drivetrain_var.set('')

# reset accel and brake
self.acceleration_var.set("0%")
self.brake_var.set("0%")
Expand Down

0 comments on commit 702203e

Please sign in to comment.