Release plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32) +--- Forum: Skinning (https://forum.kodi.tv/forumdisplay.php?fid=12) +---- Forum: Skin helper addons (https://forum.kodi.tv/forumdisplay.php?fid=300) +---- Thread: Release plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners (/showthread.php?tid=345847) |
RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - nessus - 2020-01-07 (2020-01-06, 15:23)jurialmunkey Wrote: If you're setting focus to another control first, I honestly don't understand how you have enough time to click twice (let alone three times!). I tried to double click as fast as I possible could and my second click always hits the control I sent focus to onclick rather than my list.I am not setting the focus in any other control. I am just running the call_auto= method with the add_query= from the <onright /> tag of Kodi's standard cast list container. And yes, there is enough time to press right 2-3 even 4 times since the script delays about 4-5 seconds to start by closing the video info dialog.Anyway, if it's not something that can be handle/fixed by the script then no problem. Not a biggie. I was just reporting it as a not proper behavior. (2020-01-06, 15:23)jurialmunkey Wrote: Try latest. You should now get some window propertiesThanks a lot for this. It's working fine. The info is available the same as all the others. No performance issues. Only one question about this... Shouldn't the number of $INFO[ListItem.Property(NumItems.TMDB.Movies.Total)] be the same as the total number of the two plugin:// paths from info=stars_in_movies & info=crew_in_movies ?... or it's a different thing?. The same question of course applies for tv shows.Thanks Nessus RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - jurialmunkey - 2020-01-08 (2020-01-07, 13:21)nessus Wrote: I am not setting the focus in any other control. I am just running theYeah, it's difficult to manage as there isn't really anyway to talk *between* separate script instances other than setting a window property, which can sometimes lag and so doesn't help for multiple runscripts in quick succession. With that said, can you test latest version? I've added some additional checks which, from my testing, seems to alleviate the issue -- With the new checks, I actually wasn't able to recreate the issue anymore (but theoretically it is still possible and my laptop might just be beating me for processing speed). (2020-01-07, 13:21)nessus Wrote: Only one question about this... No, because with the plugin:// paths numitems.tmdb = container.numitems - numitems.dbid It's done this way since you can already get the total for a plugin:// path by using $INFO[Container(ID).NumItems] I don't use this method for detailed item because it requires individually checking if each item is in the library (which adds overhead). For plugin paths, I'm already checking DBID anyway, so no additional overhead there. RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - nessus - 2020-01-08 Aha... you nailed!!. Even with 4-5 clicks the actor info closes fine and only once. I think i am done with this. Everything work flawlessly and i am very happy with the result. Great work man. Thank you very much for all your work with this great addon and for your patience so far. Cheers Nessus RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - jurialmunkey - 2020-01-08 (2020-01-08, 01:28)nessus Wrote: Aha... you nailed!!. Even with 4-5 clicks the actor info closes fine and only once. Excellent! The additional check seems to have worked far better than I expected -- particularly as I initially thought it wouldn't help at all! (2020-01-08, 01:28)nessus Wrote: I think i am done with this. Everything work flawlessly and i am very happy with the result. No worries at all! Glad to have helped and a lot of great improvements came out of the process too. Thanks for taking the time to test things out. I should have these latest changes up on the official repo sometime in the coming week. RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - bsoriano - 2020-01-08 @jurialmunkey , I am in the process of changing my code to use the call_auto and close_dialog calls. In my video info dialog, I use a custom Play button. If I press I on a movie, and just want to play it (I have not clicked on any widget lists or anything yet), do I need to use the close_dialog call before sending a click to button 8? Or should it be after, or not at all? I am finding that the dialog is closed, but the movie does not start playing full screen, but in the background. Please confirm what the sequence of events should be, or if I need to ensure that tmdbhelper.path.current is not empty before doing any close_dialog call. Thanks. Also, for a few of the detail fields in video info (Director, Writer, Genre, Country, Studio, etc.) I use script.embuary.helper to show the user a select dialog and allow them to choose to search online in tmdb (via a tmdb helper call) or locally in the db, and sometimes a second select dialog to separate multiple items in the field so the user can select one to do the search with. First, calling embuary helper should not interfere with your plugin's new window management, correct? And second, in all of the actions that I have for these select dialogs where I close the video info dialog, do I need to replace them with a tmdb helper close_dialog call? Are there any conditions I would need to check before doing that? Thanks again for all of your help. Regards, Bart RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - jurialmunkey - 2020-01-08 (2020-01-08, 02:05)bsoriano Wrote: @jurialmunkey , I am in the process of changing my code to use the call_auto and close_dialog calls. In my video info dialog, I use a custom Play button. If I press I on a movie, and just want to play it (I have not clicked on any widget lists or anything yet), do I need to use the close_dialog call before sending a click to button 8? Or should it be after, or not at all? I am finding that the dialog is closed, but the movie does not start playing full screen, but in the background. Please confirm what the sequence of events should be, or if I need to ensure that tmdbhelper.path.current is not empty before doing any close_dialog call. Thanks.Generally, you should run close_dialog anywhere that you would normally use Dialog.Close() to close dialogvideoinfo. It should be placed before any other onclick actions. However, for SendClick(8) (and probably trailer button too) we will need a special action as the script closing the dialog at the same time interferes with the toggle fullscreen action. On the latest, I've added an additional "sendclick=" param for the close_dialog method which will let the script handle when to call SendClick(ID) (make sure you remove <onclick>SendClick(8)</onclick> because otherwise it will get called twice!) Code: <onclick>RunScript(plugin.video.themoviedb.helper,close_dialog=1190,sendclick=8)</onclick> This works for me. Please test and confirm. (2020-01-08, 02:05)bsoriano Wrote: Also, for a few of the detail fields in video info (Director, Writer, Genre, Country, Studio, etc.) I use script.embuary.helper to show the user a select dialog and allow them to choose to search online in tmdb (via a tmdb helper call) or locally in the db, and sometimes a second select dialog to separate multiple items in the field so the user can select one to do the search with. First, calling embuary helper should not interfere with your plugin's new window management, correct? And second, in all of the actions that I have for these select dialogs where I close the video info dialog, do I need to replace them with a tmdb helper close_dialog call? Are there any conditions I would need to check before doing that? Yep, just replace Dialog.Close with the close_dialog call. It should work fine -- just make sure you are only calling close_dialog when you are going to the search window and NOT themoviedb info window (i.e. don't do close_dialog when doing add_path/call_auto). Close_dialog is basically just a way to nuke the tmdbhelper process and reset all its Path properties. In order, close_dialog does the following: 1. Clears all the TMDbHelper.Path properties. 2. Closes dialogvideoinfo 3. Closes the Window ID as specified in close_dialog= 4. SendClick(ID) as specified in sendclick= RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - bsoriano - 2020-01-08 (2020-01-08, 05:27)jurialmunkey Wrote: <onclick>RunScript(plugin.video.themoviedb.helper,close_dialog=1190,sendclick=8)</onclick> @jurialmunkey , this is not working for me. Latest version of the plugin from Git, Kodi 18.5 under Windows 10. This is what I have for the custom "Play/Browse/Close" button right now (I commented out every action that is not for a local movie):
And this is the content of Window 1134:
The info dialog closes, but the movie does not play. What am I doing incorrectly? Thanks for your help. Regards, Bart RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - jurialmunkey - 2020-01-09 @bsoriano - Hmm, yes you're right, sometimes it doesn't work - I've got an alternate approach that seems to work though. On latest version I've added a playmedia param for close_dialog: Code: RunScript(plugin.video.themoviedb.helper,close_dialog=1134,playmedia=$INFO[ListItem.FileNameAndFolder]) Can you test and confirm? RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - bsoriano - 2020-01-09 (2020-01-09, 00:10)jurialmunkey Wrote: @bsoriano - Hmm, yes you're right, sometimes it doesn't work - I've got an alternate approach that seems to work though.@jurialmunkey , thanks! This works for the custom Play/Browse/Close button (with ListItem.FileNameAndPath). I will test with all of the other instances where I am closing the dialog to see how it goes. Regards, Bart RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - jurialmunkey - 2020-01-09 @bsoriano - No worries! Glad it works. If you hit any other roadblocks, let me know and I'll see if I can find a solution. RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - nessus - 2020-01-09 @bsoriano The following code it works fine for me for a custom Play button in all cases.... "Play" button in video info dialog...
... and the variables....
The <variable name="CustomClickForMoreLists"> works fine too for the widgets lists inside the video info dialog.Cheers Nessus RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - bsoriano - 2020-01-09 (2020-01-09, 12:45)nessus Wrote: @bsoriano @nessus, thank you! Regards, Bart RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - nessus - 2020-01-11 @jurialmunkey I am using the bellow plugin path as widget from skin shortcuts.... plugin://plugin.video.themoviedb.helper?info=popular&type=person&widget=True and i would like <oninfo/> to show the info for each person. I've try the call_auto method with add_path= param (since this is a TMDB Helper list) but the Window(Home).Property(TMDbHelper.Path.Current) its empty. Also tried the add_query= param but also not working.Is there a way to show the actor info dialog from outside the video info dialog?. This would be useful so it can be called also from actors section in videos windows. Thanks Nessus RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - jurialmunkey - 2020-01-11 (2020-01-11, 12:16)nessus Wrote: @jurialmunkey Kodi doesn't allow you to override <oninfo> for containers filled with dynamic content paths. It's not just my script -- you won't be able to do any <oninfo> command from a widget (e.g. try <oninfo>ActivateWindow(settings)</oninfo> and it won't work).You can only control the <onclick> action for widgets. Both add_query= and add_path= work for me as onclickCode: <onclick>RunScript(plugin.video.themoviedb.helper,add_query=$INFO[ListItem.Label],type=person,call_auto=1190)</onclick> Code: <onclick>RunScript(plugin.video.themoviedb.helper,add_path=$INFO[ListItem.FolderPath],call_auto=1190)</onclick> RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - jurialmunkey - 2020-01-11 @nessus - You should still be able to open the info dialog for the person, you just won't have detailed info. HOWEVER, note that the service monitor also works for people, so you can get the info using window properties such as Window(Home).Property(TMDBHelper.ListItem.Biography) . Use a variable to check if the listitem infolabel is empty and fallback to the service monitor info (EDIT: I just realised there is a bug in service monitor where it is checking person info anymore... fixing now EDIT2: Okay should be fixed now).
|