Skip to content

Commit

Permalink
V1.0.2
Browse files Browse the repository at this point in the history
 - Fix 10sec latency on subs display and possible few lines lost - at video start or when switching audio.
- Forced sub tracks : check also subtitle field "isforced" in case field "name" is empty or misspelled.
  • Loading branch information
rockrider69 committed Oct 19, 2023
1 parent a591c1b commit cde9b04
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
4 changes: 2 additions & 2 deletions addon.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@
0.1.7BETA : New Keywords Blacklist to ignore chosen subtitles tracks based on name content.
1.0.0 : Mandatory clean-up to propose as candidate version for Kodi.tv addons repository.
1.0.1 : Initial version for main Kodi.tv addons repository
1.0.2 : Forced sub tracks : check subtitle stream field "isforced" in addition to just field "name" which can be empty
Fix to avoid 10-15sec delay and few lines lost on subtitles at the very begining of a video
1.0.2 : Fix 10sec latency on subs display and possible few lines lost - at video start or when switching audio.
Forced sub tracks : check also subtitle field "isforced" in case field "name" is empty or misspelled.

</news>
<assets>
Expand Down
4 changes: 2 additions & 2 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
--- Version 1.0.2

- To identify forced sub tracks : check subtitle stream field "isforced" in addition to just field "name" which can be empty
- Fix to avoid 10-15sec delay and few lines lost on subtitles showing at the very begining of a video
- Fix 10sec latency on subs display and possible few lines lost - at video start or when switching audio.
- Forced sub tracks : check also subtitle field "isforced" in case field "name" is empty or misspelled.

--- Version 1.0.1

Expand Down
7 changes: 6 additions & 1 deletion resources/lib/prefutils.py
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,12 @@ def testForcedFlag(self, forced, subName, subForcedTag):
test = subName.lower()
matches = ['forced', 'forcés']
found = any(x in test for x in matches)
return ((forced == 'false') and not found) or ((forced == 'true') and found) or ((forced == 'true') and subForcedTag) or ((forced == 'false') and not subForcedTag)
# Only when looking for forced subs :
# in case the sub name is plain empty or not well documented,
# check also the sub isforced tag and consider it a match if set
if (forced and not found and subForcedTag):
found = True
return ((forced == 'false') and not found) or ((forced == 'true') and found)

def isExternalSub(self, subName):
test = subName.lower()
Expand Down

0 comments on commit cde9b04

Please sign in to comment.