Skip to content

Commit cc07149

Browse files
authored
[script.simkl] 3.2.3 (#2775)
1 parent 9a7b05e commit cc07149

File tree

6 files changed

+19
-19
lines changed

6 files changed

+19
-19
lines changed

script.simkl/README.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,18 +17,8 @@
1717
## TODO:
1818
- [x] Make it work on Android
1919

20-
## Help Translate:
21-
You can use Crowdin [https://crowdin.com/project/Kodi-add-on-for-Simkl](https://crowdin.com/project/Kodi-add-on-for-Simkl) to help translate this add-on into your language.
22-
23-
## Donations:
24-
It would be very nice if you invite me for a cup of coffee:
25-
26-
Bitcoin address: 1PcbSQrBddJszsTiRhqHyLntp7Lxfuyaio
27-
28-
Thanks, you can write me an e-mail to [email protected] with your receipt, and I'll send you a photo drinking the cup of coffee you invited me to.
29-
3020
## Join the conversation:
31-
- Discuss on Discord https://discord.gg/JRtwsfG
21+
- Discuss on Discord [https://discord.gg/u89XfYn](https://discord.gg/u89XfYn)
3222
- Post bugs, feature requests on Github https://github.com/SIMKL/script.simkl/issues
3323

3424
[license]: https://github.com/SIMKL/script.simkl/blob/master/LICENSE.txt

script.simkl/addon.xml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
22
<addon id="script.simkl"
33
name="Simkl TV Tracker"
4-
version="3.2.2"
4+
version="3.2.3"
55
provider-name="David Davó, Simkl">
66
<requires>
77
<import addon="xbmc.python" version="3.0.0"/>
@@ -25,8 +25,10 @@
2525
</assets>
2626
<language>en</language>
2727
<news>
28+
v3.2.3 (31-10-25)
29+
- fixed bubble popup and autoscrobble settings
2830
v3.2.2 (05-01-24)
29-
- fixed new pything isAlive fn
31+
- fixed new python isAlive function
3032
v3.2 (22-09-22)
3133
- right click, mark as watched/unwatched added
3234
v3.1 (21-07-13)

script.simkl/changelog.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
v 3.2.3
2+
- fixed bubble popup and autoscrobble settings
3+
14
v 3.2.1
25
- is_live fixed
36

script.simkl/resources/lib/api_simkl.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,11 @@ def __init__(self):
2626
self.isLoggedIn = False
2727
self.loginInProgress = False
2828

29-
self.headers = {"Content-Type": "application-json", "simkl-api-key": APIKEY}
29+
addon_version = __addon__.getAddonInfo("version")
30+
kodi_version = xbmc.getInfoLabel("System.BuildVersion")
31+
user_agent = "script.simkl/v{} / Kodi/{}".format(addon_version, kodi_version)
32+
33+
self.headers = {"Content-Type": "application-json", "simkl-api-key": APIKEY, "User-Agent": user_agent}
3034
# set_setting('token', '')
3135
token = get_setting('token')
3236
if token:

script.simkl/resources/lib/engine.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def __init__(self, api):
2121

2222
def onPlayBackStarted(self):
2323
self._stop_tracker()
24-
if self._api.isLoggedIn:
24+
if self._api.isLoggedIn and get_setting("autoscrobble").lower() in ['true', '1']:
2525
self._detect_item()
2626

2727
def onPlayBackStopped(self):
@@ -122,6 +122,9 @@ def _detect_item(self):
122122
self._run_tracker()
123123

124124
def _run_tracker(self):
125+
if get_setting("autoscrobble").lower() not in ['true', '1']:
126+
log("Auto-scrobble is disabled, skipping tracker")
127+
return
125128
self._playback_lock.set()
126129
self._tracker = threading.Thread(target=self._thread_tracker)
127130
self._tracker.start()
@@ -162,7 +165,7 @@ def _thread_tracker(self):
162165
else:
163166
log("Retrying")
164167

165-
elif success and bool(get_setting("bubble")):
168+
elif success and (get_setting("bubble").lower() in ['true', '1']):
166169
self._show_bubble(self._item)
167170
break
168171
except:

script.simkl/resources/settings.xml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,8 @@
99
</category>
1010
<setting type="sep"/>
1111
<category label="Options">
12-
<setting label="32002" type="lsep"/>
13-
<setting label="32003" type="bool" id="synclib" default="false" enable="false"/>
1412
<setting label="Scrobbler" type="lsep"/>
15-
<setting label="Auto-scrobble" type="bool" id="autoscrobble" default="true" enable="false"/>
13+
<setting label="Auto-scrobble" type="bool" id="autoscrobble" default="true" enable="true"/>
1614
<setting label="32006" type="slider" id="scr-pct" default="70" range="0,100" option="percent" enable="gt(-1,-2)" />
1715
<setting label="32007" type="slider" id="sct-w-pct" default="10" range="0,100" option="percent" visible="false"/>
1816
<setting label="32008" type="bool" id="bubble" default="true" enable="true"/>

0 commit comments

Comments
 (0)