I don't believe that is accurate with LibSharedMedia-3.0 and its dependency CallbackHandler-1.0.
The prototype for the RegisterCallback method is:
function(self, eventname, method, ...)
The self parameter gets LibSharedMedia-3.0, the event name is "LibSharedMedia_Registered", and the method is the handler to call.
Actually S9Th is correct. If two addons both call RegisterCallback with the LibSharedMedia-3.0 object as self and the eventname as "LibSharedMedia_Registered" then the last addon to call RegisterCallback will overwrite the previous one.
This addon registers callback incorrectly, it seems, so it conflicts with other addons like Proximo. To solve it, line 18 in its lua file must be changed to
Gadzooks, the problem with that is that your custom media in the deprecated SharedMedia-2.0 is only registered with one version of LibSharedMedia library; whereas plain SharedMedia registers your media with ALL versions, so it's available in ALL addons that use a LibSharedMedia library.
Plus, once you spend the 10 minutes or so switching your custom media over to SharedMedia's MyMedia.lua file (it's mostly copy-paste and find-replace) you'll never have to do it again, only update the core addon file if a new library version is released.
Also, ALL of the media that's included in the base SharedMedia-2.0 addon is also included in the SharedMedia addon, so all that's needed is to copy over your custom media.
Originally posted by Elkano Mikord, mind adding the following line to toc?
## OptionalDeps: LibSharedMedia-3.0
This will make it load the standalone version of the lib first in case it is installed.
@Gadzooks: Do not use SharedMedia-2.0 but SharedMedia. SM-2.0 was a bad idea of whoever had it; SM injects in all versions of LSM.
I use both. SM2.0 has a TON of fonts and textures already added. I dont feel like going an adding all of those to the silly mymedia file in order for them to work right.
Maybe I just dont know how to do it right, im open for suggestion.
Originally posted by Mikord Did you get MSBTSharedMedia 1.33? I just updated it tonight.
Make sure the zip file you download reflects the correct version. WowInterface has been serving up old files for some reason lately I've noticed. Clearing your browser's cache seems to be a workaround for it.
No amount of deleting my cookies, cache, etc, makes wowinterface let me download 1.33. It keeps servering up 1.32
edit: I see you uploaded it again. Got it fine now. Fixed the problem too
Did you get MSBTSharedMedia 1.33? I just updated it tonight.
Make sure the zip file you download reflects the correct version. WowInterface has been serving up old files for some reason lately I've noticed. Clearing your browser's cache seems to be a workaround for it.
Hmmm, i was using sharedmedia 2.0, and in the past, MSBT has had no issues using the huge assortment of fonts included with that.
However, with this update and the change to 3.0, none of those fonts are recognized in msbt anymore.
I followed the instructions with the medialib3.0 stuff and registered all the fonts i wanted with 3.0. Other mods that now use 3.0 show these fonts fine (things like Quartz, Satrina Buffs, etc), however, this mod simply wont recognize any new fonts, and I cant figure out why.
SharedMedia fonts weren't working for a lot of us so I did some digging. I think the problem is that the callback function you're registering expects the mediaType as the first argument, but that's the event name "LibSharedMedia_Registered". Changing line 19 from
Code:
function (mediaType, name)
to
Code:
function (event, mediaType, name)
seems to do the trick. Thanks again for the best combat text addon out there.