Skip to content

Commit

Permalink
Update 010725 1
Browse files Browse the repository at this point in the history
Fix database error for chd games
Update strings
Add missing functions for renaming favorites
Fix display of games as tvshows -> episodes
Fix favorites with link_queries
  • Loading branch information
zach-morris committed Jan 7, 2025
1 parent 37af1a9 commit fa2a20d
Show file tree
Hide file tree
Showing 77 changed files with 675 additions and 89 deletions.
24 changes: 16 additions & 8 deletions addon.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
dl = download.download(config=config,ia_email=cm.get_setting('ia_u'),ia_password=cm.get_setting('ia_p'),dl_path=cm.get_setting('default_dl_path'),threads=cm.get_setting('dl_threads'),auto_login=False,if_game_exists=cm.get_setting('if_game_exists'),ige_dialog={'heading':cm.get_loc(30331),'list':[cm.get_loc(30055),cm.get_loc(30056)]}) #Dont login right away for speed, only set the dl path to the current default
nt = netplay.netplay(config=config)
pp = post_process.post_process(config=config)
ln = launch.launch(config=config,user_launch_os=cm.get_setting('user_launch_os'),kodi_suspend=cm.get_setting('kodi_suspend'),kodi_media_stop=cm.get_setting('kodi_media_stop'),kodi_saa=cm.get_setting('kodi_saa'),kodi_wfr=cm.get_setting('kodi_wfr'))
ln = launch.launch(config=config,user_launch_os=cm.get_setting('user_launch_os'),kodi_suspend=cm.get_setting('kodi_suspend'),kodi_media_stop=cm.get_setting('kodi_media_stop'),kodi_saa=cm.get_setting('kodi_saa'),kodi_wfr=cm.get_setting('kodi_wfr'),ra_app_path=cm.get_setting('ra_app_path'),ra_cores_path_override=cm.get_setting('ra_cores_path_override'))
dialogs = dialogs.dialogs(config=config)

# ## Plugin Routes ##
Expand Down Expand Up @@ -163,7 +163,7 @@ def view_favorites_by(choose_id):
xbmcplugin.endOfDirectory(plugin.handle)
else: #by_fav_group
xbmcplugin.setContent(plugin.handle,cm.get_setting('media_type_game'))
xbmcplugin.addDirectoryItems(plugin.handle,[(plugin.url_for_path('{}/{}'.format('view_favorites_group',item_path)),list_item,True) for list_item,item_path in db.query_db(db.get_query('favorites_by_group')) if isinstance(list_item,xbmcgui.ListItem)])
xbmcplugin.addDirectoryItems(plugin.handle,[(plugin.url_for_path('{}/{}'.format('view_favorites_group',item_path)),cm.add_context_menu(li=list_item,ip=item_path,type_in='game_favorites_group_context_menu'),True) for list_item,item_path in db.query_db(db.get_query('favorites_by_group')) if isinstance(list_item,xbmcgui.ListItem)])
for sm in config.listitem.get('sort_methods').get('categories'):
xbmcplugin.addSortMethod(plugin.handle,sm)
xbmcplugin.endOfDirectory(plugin.handle)
Expand Down Expand Up @@ -1107,11 +1107,6 @@ def view_game_list(game_list_id,choose_id):
for sm in config.listitem.get('sort_methods').get('games'):
xbmcplugin.addSortMethod(plugin.handle,sm)
else:
# Possibly update this if I can understand art types for other media types
# if choose_id in config.settings.get('media_types').keys():
# print(config.settings.get('media_types').get(choose_id))
# xbmcplugin.setContent(plugin.handle,config.settings.get('media_types').get(choose_id))
# else:
xbmcplugin.setContent(plugin.handle,cm.get_setting('media_type_game'))
xbmcplugin.addDirectoryItems(plugin.handle,[(plugin.url_for_path('{}/{}/{}/{}'.format('game_list',game_list_id,choose_id,item_path)),list_item,True) for list_item,item_path in db.query_db(db.get_query(choose_id,game_list_id=game_list_id)) if isinstance(list_item,xbmcgui.ListItem)])
for sm in config.listitem.get('sort_methods').get('game_list_choice_by'):
Expand Down Expand Up @@ -1541,6 +1536,8 @@ def remove_link_from_favorites():
ok_ret = xbmcgui.Dialog().ok(cm.get_loc(30237),cm.get_loc(30239))
xbmc.sleep(config.defaults.get('sleep'))
xbmc.executebuiltin('Container.Refresh')
else:
xbmc.log(msg='IAGL: Error finding link_query for current listitem',level=xbmc.LOGERROR)

@plugin.route('/context_menu/action/rename_link_from_favorites/<link_id>')
def rename_link_from_favorites(link_id):
Expand All @@ -1556,7 +1553,18 @@ def rename_link_from_favorites(link_id):
xbmc.executebuiltin('Container.Refresh')
else:
xbmc.log(msg='IAGL: Error finding link_query for link_id {}'.format(link_id),level=xbmc.LOGERROR)


@plugin.route('/context_menu/action/rename_favorites_group/<group_name>')
def rename_favorites_group(group_name):
xbmc.log(msg='IAGL: /rename_favorites_group/{}'.format(group_name),level=xbmc.LOGDEBUG)
new_name = xbmcgui.Dialog().input(heading=cm.get_loc(30486),defaultt=group_name)
if isinstance(new_name,str) and len(new_name)>0 and isinstance(group_name,str) and len(group_name)>0:
result = db.rename_favorites_group(new_name=new_name,group_name=group_name)
if isinstance(result,int) and result>0:
ok_ret = xbmcgui.Dialog().ok(cm.get_loc(30233),cm.get_loc(30487).format(new_name))
xbmc.sleep(config.defaults.get('sleep'))
xbmc.executebuiltin('Container.Refresh')

@plugin.route('/context_menu/action/update_launcher/<game_list_id>')
def update_game_list_launcher(game_list_id):
xbmc.log(msg='IAGL: /update_game_list_launcher',level=xbmc.LOGDEBUG)
Expand Down
2 changes: 1 addition & 1 deletion 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="plugin.program.iagl" name="Internet Archive Game Launcher" version="4.0.2">
<addon id="plugin.program.iagl" name="Internet Archive Game Launcher" version="4.0.3">
<requires>
<import addon="xbmc.python" version="3.0.1"/>
<import addon="script.module.infotagger"/>
Expand Down
Binary file modified resources/data/language.xlsx
Binary file not shown.
10 changes: 9 additions & 1 deletion resources/language/resource.language.af_za/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Speletjielys vertoon"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Definieer die beginbladsy vir IAGL-speletjielyste"
msgstr "Definieer die beginbladsy vir IAGL-speletjielyste"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Hernoem gunstelinggroep"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Groep hernoem na {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.am_et/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "የጨዋታ ዝርዝር ማሳያ"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "የ IAGL ጨዋታ ዝርዝሮችን መነሻ ገጽ ይግለጹ"
msgstr "የ IAGL ጨዋታ ዝርዝሮችን መነሻ ገጽ ይግለጹ"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "ተወዳጅ ቡድን እንደገና ይሰይሙ"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "ቡድን ወደ {} ተቀይሯል"
10 changes: 9 additions & 1 deletion resources/language/resource.language.ar_sa/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "عرض قائمة الألعاب"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "تحديد صفحة البدء لقوائم ألعاب IAGL"
msgstr "تحديد صفحة البدء لقوائم ألعاب IAGL"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "إعادة تسمية المجموعة المفضلة"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "تمت إعادة تسمية المجموعة إلى {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.ast_es/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Visualización de la lista de juegos"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Definir la página de inicio para las listas de juegos de IAGL"
msgstr "Definir la página de inicio para las listas de juegos de IAGL"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Cambiar el nombre del grupo de favoritos"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Grupo renombrado a {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.az_az/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Oyun Siyahısının Ekranı"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "IAGL oyun siyahıları üçün başlanğıc səhifəsini müəyyənləşdirin"
msgstr "IAGL oyun siyahıları üçün başlanğıc səhifəsini müəyyənləşdirin"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Sevimli Qrupun adını dəyişdirin"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Qrupun adı {} olaraq dəyişdirildi"
10 changes: 9 additions & 1 deletion resources/language/resource.language.be_by/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Адлюстраванне спісу гульняў"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Вызначце стартавую старонку для спісаў гульняў IAGL"
msgstr "Вызначце стартавую старонку для спісаў гульняў IAGL"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Перайменаваць абраную групу"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Група перайменавана ў {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.bg_bg/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Показване на списък с игри"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Дефинирайте началната страница за списъците с игри на IAGL"
msgstr "Дефинирайте началната страница за списъците с игри на IAGL"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Преименуване на любима група"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Групата е преименувана на {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.bs_ba/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Prikaz liste igara"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Definirajte početnu stranicu za IAGL liste igara"
msgstr "Definirajte početnu stranicu za IAGL liste igara"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Preimenujte omiljenu grupu"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Grupa preimenovana u {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.ca_es/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Visualització de la llista de jocs"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Definiu la pàgina d'inici de les llistes de jocs IAGL"
msgstr "Definiu la pàgina d'inici de les llistes de jocs IAGL"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Canvia el nom del grup preferit"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Grup canviat de nom a {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.cs_cz/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Zobrazení seznamu her"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Definujte úvodní stránku pro seznamy her IAGL"
msgstr "Definujte úvodní stránku pro seznamy her IAGL"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Přejmenovat oblíbenou skupinu"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Skupina přejmenována na {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.cy_gb/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Arddangos Rhestr Gêm"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Diffiniwch y dudalen gychwyn ar gyfer rhestrau gemau IAGL"
msgstr "Diffiniwch y dudalen gychwyn ar gyfer rhestrau gemau IAGL"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Ail-enwi Hoff Grŵp"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Ailenwyd y grŵp yn {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.da_dk/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Visning af spilliste"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Definer startsiden for IAGL-spillister"
msgstr "Definer startsiden for IAGL-spillister"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Omdøb favoritgruppe"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Gruppe omdøbt til {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.de_de/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Anzeige der Spieleliste"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Definieren Sie die Startseite für IAGL-Spielelisten"
msgstr "Definieren Sie die Startseite für IAGL-Spielelisten"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Favoritengruppe umbenennen"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Gruppe umbenannt in {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.el_gr/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Εμφάνιση λίστας παιχνιδιών"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Καθορίστε την αρχική σελίδα για τις λίστες παιχνιδιών IAGL"
msgstr "Καθορίστε την αρχική σελίδα για τις λίστες παιχνιδιών IAGL"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Μετονομασία Αγαπημένης Ομάδας"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Η ομάδα μετονομάστηκε σε {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.en_au/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Game List Display"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Define the start page for IAGL game lists"
msgstr "Define the start page for IAGL game lists"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Rename Favorite Group"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Group renamed to {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.en_gb/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Game List Display"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Define the start page for IAGL game lists"
msgstr "Define the start page for IAGL game lists"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Rename Favorite Group"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Group renamed to {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.en_nz/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Game List Display"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Define the start page for IAGL game lists"
msgstr "Define the start page for IAGL game lists"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Rename Favorite Group"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Group renamed to {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.en_us/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Game List Display"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Define the start page for IAGL game lists"
msgstr "Define the start page for IAGL game lists"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Rename Favorite Group"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Group renamed to {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.eo/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Ludo Listo Montro"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Difinu la komencan paĝon por IAGL-ludlistoj"
msgstr "Difinu la komencan paĝon por IAGL-ludlistoj"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Alinomi Ŝatatan Grupon"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Grupo renomita al {}"
10 changes: 9 additions & 1 deletion resources/language/resource.language.es_ar/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -1949,4 +1949,12 @@ msgstr "Visualización de la lista de juegos"

msgctxt "#30485"
msgid "Define the start page for IAGL game lists"
msgstr "Definir la página de inicio para las listas de juegos de IAGL"
msgstr "Definir la página de inicio para las listas de juegos de IAGL"

msgctxt "#30486"
msgid "Rename Favorite Group"
msgstr "Cambiar el nombre del grupo de favoritos"

msgctxt "#30487"
msgid "Group renamed to {}"
msgstr "Grupo renombrado a {}"
Loading

0 comments on commit fa2a20d

Please sign in to comment.