Skip to content

Commit

Permalink
[script.service.checkpreviousepisode] 0.4.7
Browse files Browse the repository at this point in the history
  • Loading branch information
bossanova808 committed Apr 10, 2024
1 parent a629d88 commit b44d6ad
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 7 deletions.
6 changes: 2 additions & 4 deletions script.service.checkpreviousepisode/addon.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon id="script.service.checkpreviousepisode" version="0.4.6" name="Kodi Check Previous Episode" provider-name="bossanova808, Razzeee, Lucleonhart" >
<addon id="script.service.checkpreviousepisode" version="0.4.7" name="Kodi Check Previous Episode" provider-name="bossanova808, Razzeee, Lucleonhart" >
<requires>
<import addon="xbmc.python" version="3.0.0" />
<import addon="script.module.yaml" version="3.11.0" />
Expand All @@ -16,9 +16,7 @@
<forum>https://forum.kodi.tv/showthread.php?tid=355464</forum>
<website>https://kodi.wiki/view/Add-on:XBMC_Check_Previous_Episode</website>
<source>https://github.com/bossanova808/script.service.checkpreviousepisode</source>
<news>v0.4.6
- Ignore shows that have already been decided on (i.e. those with a non-zero resume point)
</news>
<news>v0.4.7 Add Window Property so skinners can dress up the dialog</news>
<assets>
<icon>icon.png</icon>
</assets>
Expand Down
3 changes: 3 additions & 0 deletions script.service.checkpreviousepisode/changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
v0.4.7
- Add Window Property so skinners can dress up the dialog

v0.4.6
- Ignore shows that have already been decided on (i.e. those with a non-zero resume point)

Expand Down
8 changes: 6 additions & 2 deletions script.service.checkpreviousepisode/resources/lib/common.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
# -*- coding: utf-8 -*-
"""
Handy utility functions for Kodi Addons
Handy utility functions & constants for Kodi Addons
By bossanova808
Free in all senses....
VERSION 0.2.4 2021-08-10
VERSION 0.2.5 2024-04-09
(For Kodi Matrix & later)
See: bossanova808 repo/latest.common/common.py for latest version & always copy back any changes there plud do a version & date bump!
"""
import sys
import traceback
Expand Down Expand Up @@ -51,6 +52,8 @@
"""

unit_testing = False

# Testing outside of Kodi
if not xbmc.getUserAgent():

xbmc = None
Expand All @@ -65,6 +68,7 @@ def log(message, exception_instance=None, level=None):
print(f'EXCPT: {traceback.format_exc(exception_instance)}')


# Running inside of Kodi
else:

def log(message, exception_instance=None, level=xbmc.LOGDEBUG):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,3 @@ def onSettingsChanged(self):

def onAbortRequested(self):
log('onAbortRequested')
log("Abort Requested")
3 changes: 3 additions & 0 deletions script.service.checkpreviousepisode/resources/lib/player.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,10 @@ def onAVStarted(self):
log("Prior episode not watched! -> pausing playback")
self.pause()

# Set a window property per Hitcher's request - https://forum.kodi.tv/showthread.php?tid=355464&pid=3191615#pid3191615
HOME_WINDOW.setProperty("CheckPreviousEpisode", "MissingPreviousEpisode")
result = xbmcgui.Dialog().select(LANGUAGE(32020), [LANGUAGE(32021), LANGUAGE(32022), LANGUAGE(32023)], preselect=0)
HOME_WINDOW.setProperty("CheckPreviousEpisode", "")

# User has requested we ignore this particular show from now on...
if result == 2:
Expand Down

0 comments on commit b44d6ad

Please sign in to comment.