Marker tweaks

This commit is contained in:
Matthew Stratford 2021-04-26 01:01:58 +01:00
parent ff2c8f0b8e
commit e39a9b73a4
2 changed files with 6 additions and 1 deletions

View file

@ -200,7 +200,9 @@ class PlanItem:
new_markers = []
for marker in self._markers:
if marker.same_type(new_marker):
new_markers.append(new_marker)
# Only add new marker if the marker is > 0 (to delete markers otherwise)
if new_marker.time != 0:
new_markers.append(new_marker)
# Replace marker
replaced = True
else:

View file

@ -466,6 +466,9 @@ class Player:
if not self.isLoaded:
return False
timeslotitemid = self.state.get()["loaded_item"].timeslotitemid
elif self.isLoaded and self.state.get()["loaded_item"].timeslotitemid == timeslotitemid:
set_loaded = True
plan_copy: List[PlanItem] = copy.copy(self.state.get()["show_plan"])
for i in range(len(self.state.get()["show_plan"])):