(2024-12-26, 17:17)Oversized Wrote: How big of a UI job would be to bring yt comments in a few less clicks ?
I don't know if you've done this before, but you can change the plugin yourself, as all add-ons are open source.
Note that any changes will only last until you update the add-on to a new version, as the new version will overwrite your changes and you'd have to do them again.
If you're interested in doing the changes yourself, the steps are these:
- Using a desktop PC, download the latest add-on zip and unpack it somewhere.
- Replace or change the relevant script file in the unpacked files.
- Repack the add-on folder back to a zip as it was.
- Transfer the modified zip to your Kodi device (you can transfer it to your device via some file hosting site that you uploaded to temporarily and accessed with the browser app in the device, or using a USB flash drive with the zip inside).
- Finally, with the Unknown Sources setting enabled, install it within Kodi.
As for the actual changes:
As of this writing (2024-12-29), the code to be changed is in this quoted part here, inside function
update_video_items
:
https://github.com/anxdpanic/plugin.vide...#L893-L908
As you can see from that link, the file to be changed is
/resources/lib/youtube_plugin/youtube/helper/utils.py
.
The code in that quoted part creates the
context_menu
variable as either a list that's pre-filled with a "remove from Playlist" item (when you're logged in and own the playlist) or as an empty list, and it looks like this:
Python:
# provide 'remove' in my playlists that have a real playlist_id
if (playlist_id
and logged_in
and playlist_channel_id == 'mine'
and playlist_id.strip().lower() not in {'wl', 'hl'}):
context_menu = [
menu_items.remove_video_from_playlist(
context,
playlist_id=playlist_id,
video_id=media_item.playlist_item_id,
video_name=title,
),
menu_items.separator(),
]
else:
context_menu = []
The changed version would be this:
Python:
# provide 'remove' in my playlists that have a real playlist_id
if (playlist_id
and logged_in
and playlist_channel_id == 'mine'
and playlist_id.strip().lower() not in {'wl', 'hl'}):
context_menu = [
menu_items.video_comments(context, video_id, video_name=title),
menu_items.remove_video_from_playlist(
context,
playlist_id=playlist_id,
video_id=media_item.playlist_item_id,
video_name=title,
),
menu_items.separator(),
]
else:
context_menu = [menu_items.video_comments(context, video_id, video_name=title)]
To both cases, it added this new menu item:
menu_items.video_comments(context, video_id, video_name=title)
(Notice the comma at the end of the added line in the playlist case, as it's one item among others inside the list.)
With these changes, when you bring up the context menu, the "Comments" item will be at the top. I use this a lot, it's just two clicks to get to them.
If you've done something wrong, it'll probably fail when you try to run the plugin. You can install the latest version again (no need to uninstall), and leave this for another day.