pereira-a / MBB

A Retail WoW addon that gathers all minimap addon buttons into one button
The Unlicense
7 stars 6 forks source link

MBB Blocks MiddleButton Clicks #26

Open ynazar1 opened 1 year ago

ynazar1 commented 1 year ago

Addon buttons that utilize middle click functionality for OnClick function from LDB are not able to use any buttons other than Left and Right Clicks since MBB overloads RegisterForClicks function with

Line: 348 MBB.lua:

    if( buttonframe ) then
        if( buttonframe.RegisterForClicks ) then
            buttonframe:RegisterForClicks("LeftButtonDown","RightButtonDown");
        end

Please modify to either AnyDown or at least for MiddleButtonDown which should cover most of the button cases for pretty much any addon.

ynazar1 commented 1 year ago

Proposed change:

    if( buttonframe ) then
        if( buttonframe.RegisterForClicks ) then
            buttonframe:RegisterForClicks("LeftButtonDown","RightButtonDown","MiddleButtonDown");
        end
ynazar1 commented 1 year ago

There's an edge-case that if someone doesn't have cvar ActionButtonUseKeyDown enabled, then no clicks will get passed to their addon minimap buttons as their 'action' is done on ButtonUp and MBB only has ButtonDown events handled... https://wowpedia.fandom.com/wiki/CVar_ActionButtonUseKeyDown Though considering that it's always been ButtonDown... and folks don't complain... I don't have a strong opinion on including ButtonUp variations.