Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions default.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
useOwnProfile = addon.getSetting("useOwnProfile") == "true"
useCustomPath = addon.getSetting("useCustomPath") == "true"
customPath = xbmc.translatePath(addon.getSetting("customPath"))
disableKodiLIRC = addon.getSetting("disableKodiLIRC") == "true"

userDataFolder = xbmc.translatePath("special://profile/addon_data/"+addonID)
profileFolder = os.path.join(userDataFolder, 'profile')
Expand Down Expand Up @@ -147,11 +148,21 @@ def showSite(url, stopPlayback, kiosk, userAgent):
elif osLinux:
path = "/usr/bin/google-chrome"
if useCustomPath and os.path.exists(customPath):
if disableKodiLIRC:
xbmc.executebuiltin('LIRC.Stop', wait=True)
fullUrl = getFullPath(customPath, url, kiosk, userAgent)
subprocess.Popen(fullUrl, shell=True)
proc = subprocess.Popen(fullUrl, shell=True)
if disableKodiLIRC:
proc.communicate()
xbmc.executebuiltin('LIRC.Start')
elif os.path.exists(path):
if disableKodiLIRC:
xbmc.executebuiltin('LIRC.Stop', wait=True)
fullUrl = getFullPath(path, url, kiosk, userAgent)
subprocess.Popen(fullUrl, shell=True)
proc = subprocess.Popen(fullUrl, shell=True)
if disableKodiLIRC:
proc.communicate()
xbmc.executebuiltin('LIRC.Start')
else:
xbmc.executebuiltin('XBMC.Notification(Info:,'+str(translation(30005))+'!,5000)')
addon.openSettings()
Expand Down
1 change: 1 addition & 0 deletions resources/language/English/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@
<string id="30010">Use custom Chrome/script path</string>
<string id="30011">Chrome/script path</string>
<string id="30012">Use own user profile (Could take some time on first start)</string>
<string id="30013">Disable LIRC in Kodi (Linux Only)</string>
<string id="30016">Use kiosk mode?</string>
</strings>
1 change: 1 addition & 0 deletions resources/language/German/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,6 @@
<string id="30009">XBMC Wiedergabe stoppen?</string>
<string id="30010">Benutzerdefinierten Chrome/Skript Pfad nutzen</string>
<string id="30011">Chrome/Skript Pfad</string>
<string id="30013">Deaktivieren Sie LIRC in Kodi (nur Linux)</string>
<string id="30012">Eigenes Nutzerprofil nutzen (Kann beim ersten Start etwas dauern)</string>
</strings>
1 change: 1 addition & 0 deletions resources/settings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
<setting id="useCustomPath" type="bool" label="30010" default="false"/>
<setting id="customPath" type="file" label="30011" enable="eq(-1,true)" default="special://home/addons/plugin.program.chrome.launcher/script.sh"/>
<setting id="useOwnProfile" type="bool" label="30012" default="false"/>
<setting id="disableKodiLIRC" type="bool" label="30013" default="false"/>
</settings>