@regor It seems you've essentially solved the issue another way. It doesn't seem worth the effort of trying to supply data through notify for what may be a few residuals - it's not even clear that lfm would have missing ones anyway compared with listings on the MusicBrainz site.
@culinko Last.fm stats for Top Albums and Similar Artists are always in the bio. The setting you refer to controls display on the drop down menu.
Nope, the problem is not solved at all. Data is only downloaded with playback and makes no sense to ask users to playback their entire library to fetch a tag, then write them and then use my plugin...
Anyway I don't understand your reticence, since the main point of getting tags from the lastfm/allmusic servers is to use them (?) Obviously since they are not available to other plugins, no one is using them outside your panel. That may change if you share the tags, just saying. (for sure I would create much more things if I could use tags like similar artist, etc. shared by your panel)
Apart from that... it's a matter of changing 3 lines to do it, and that's just a dirty edit I made to check it:
tagger().this.notifyCountry already has all the code, unused.. (at least for the country tag, the tag writing routine has code for all tags)
this.notifyCountry = (handles) => {
if (!handles) return;
let a = "", a_o = "####", aa = "", aa_o = "####", l = "", l_o = "####";
let locale = [], rem = [], sa = [], tags = [], artTags = []; // THIS
const tf_a = FbTitleFormat(p.tf.a), tf_aa = FbTitleFormat(p.tf.aa), tf_cue = FbTitleFormat("$ext(%path%)"), tf_l = FbTitleFormat(p.tf.l);
const artist = tf_a.EvalWithMetadb(handles).toUpperCase(), album = tf_l.EvalWithMetadb(handles).toUpperCase(); // THIS to metadb
if (!name.alb_strip) l = l.replace(/CD(\s*\d|\.0\d)|CD\s*(One|Two|Three)|Disc\s*\d|Disc\s*(III|II|I|One|Two|Three)\b/gi,"").replace(/\(\s*\)|\[\s*\]/g, " ").replace(/\s\s+/g, " ").replace(/-\s*$/g, " ").trim();
else l = l.replace(/CD(\s*\d|\.0\d)|CD\s*(One|Two|Three)|Disc\s*\d|Disc\s*(III|II|I|One|Two|Three)\b|(Bonus\s*Track|Collector's|(Digital\s*|Super\s*|)Deluxe|Digital|Expanded|Limited|Platinum|Reissue|Special)\s*(Edition|Version)|(Bonus\s*(CD|Disc))|\d\d\w\w\s*Anniversary\s*(Expanded\s*|Re(-|)master\s*|)(Edition|Re(-|)master|Version)|((19|20)\d\d(\s*|\s*-\s*)|)(Digital(ly|)\s*|)(Re(-|)master(ed|)|Re(-|)recorded)(\s*Edition|\s*Version|)|\(Deluxe\)|\(Mono\)|\(Reissue\)|\(Revisited\)|\(Stereo\)|\(Web\)|\[Deluxe\]|\[Mono\]|\[Reissue\]|\[Revisited\]|\[Stereo\]|\[Web\]/gi,"").replace(/\(\s*\)|\[\s*\]/g, " ").replace(/\s\s+/g, " ").replace(/-\s*$/g, " ").trim();
if (artist != a_o) {
// remove any reference to [i] changed to var
a_o = artist;
if (p.tag[6].enabled || p.tag[7].enabled || p.tag[8].enabled && p.tag[8].enabled < 7) {
const lfmBio = p.cleanPth(p.pth.lfmBio, handles, 'tag') + artist.clean() + ".txt";
if (s.file(lfmBio)) {
const lfm_a = s.open(lfmBio);
if (p.tag[6].enabled) {ix = lfm_a.lastIndexOf("Top Tags: "); if (ix != -1) {artTags = lfm_a.substring(ix + 10); artTags = lfmTidy(artTags, artist, l);}}
if (p.tag[7].enabled) {
let loc = lfm_a.match(RegExp(kww, "i")); if (loc) {
loc = loc.toString();
ix = lfm_a.lastIndexOf(loc);
if (ix != -1) {
locale = lfm_a.substring(ix + loc.length);
locale = locale.split('\n')[0].trim().split(", ");
}
}
}
}
}
}
window.NotifyOthers(window.Name + ' notifyCountry', locale);
}
Then on text()
this.draw = gr => {
tag.notifyCountry(s.handle(ppt.focus));
...
And don, country is notified to the world map