Find more from Album Artist

To discuss development of addons / skins / customization of MediaMonkey.

Moderators: jiri, drakinite, Addon Administrators

onkel_enno
Posts: 2149
Joined: Fri Jan 14, 2005 1:45 am
Location: Germany
Contact:

Find more from Album Artist

Post by onkel_enno »

Sorry for asking such a simple question, but how can I enable "Find more from Album Artist" in the song context menu?
I searched for an hour but could'nt find something.
As a shortcut it is working but I would like to have it in the context menu.

Can it only by done using a script (window.actions.findMoreFromSameAlbumArtist)?
SansaMonkey - for SanDisk Sansa and Rockbox Users

Please no PMs for Questions which should be asked in the Forum. Thx
Lowlander
Posts: 53353
Joined: Sat Sep 06, 2003 5:53 pm
Location: MediaMonkey 5

Re: Find more from Album Artist

Post by Lowlander »

As far as I can tell this isn't available in MediaMonkey 5.
onkel_enno
Posts: 2149
Joined: Fri Jan 14, 2005 1:45 am
Location: Germany
Contact:

Re: Find more from Album Artist

Post by onkel_enno »

Ok, Thanks.

Adding this to a actions_add.js replaces the "Find more from" context menu. How can I ADD the entry to window.uitools.findMoreMenuActions?

Code: Select all

(() => {
    window.uitools.findMoreMenuActions = {
        albumartist: {
            getMenuItems: function (track, collection) {
                var type;
                if (collection)
                    type = collection.getType();

                var sA = track.albumArtist.split(';').map((a) => (a.trim()));
                var retval = [];
                sA.forEach(function (a) {
                    retval.push({
                        title: function () {
                            if (inArray(type, ['video', 'tv']))
                                return _('Director') + ': ' + a;
                            else
                                return _('Album Artist') + ': ' + a;
                        },
                        noAccessKey: true,
                        visible: function () {
                            return (!!a);
                        },
                        icon: 'artist',
                        execute: function () {
                            uitools.globalSettings.showingOnline = (track.id === -2); // online mode only for online source track                            
                            if (inArray(type, ['video', 'tv']))
                                navigationHandlers['director'].navigate(a, collection);
                            else
                                navigationHandlers['albumartist'].navigate(a, collection);
                        },
                        order: 21
                    })
                });

                return retval;
            }
        }
    };
})();
Maybe this topic can be moved to the scripts forum.
SansaMonkey - for SanDisk Sansa and Rockbox Users

Please no PMs for Questions which should be asked in the Forum. Thx
Ludek
Posts: 4666
Joined: Fri Mar 09, 2007 9:00 am

Re: Find more from Album Artist

Post by Ludek »

onkel_enno wrote: Tue Apr 05, 2022 11:24 pm How can I ADD the entry to window.uitools.findMoreMenuActions?
Instead of

Code: Select all

window.uitools.findMoreMenuActions = {
        albumartist: {
            // ...
        }
};
use

Code: Select all

window.uitools.findMoreMenuActions.albumartist = {
           // ...
}
EDIT: Added your request as https://www.ventismedia.com/mantis/view.php?id=18972 (will be added in the next build Fixed in 5.0.3.2614)
onkel_enno
Posts: 2149
Joined: Fri Jan 14, 2005 1:45 am
Location: Germany
Contact:

Re: Find more from Album Artist

Post by onkel_enno »

Thanks alot :D
SansaMonkey - for SanDisk Sansa and Rockbox Users

Please no PMs for Questions which should be asked in the Forum. Thx
Post Reply