WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   Lua/XML Help (https://www.wowinterface.com/forums/forumdisplay.php?f=16)
-   -   Replace Shop Button with Friendlist Button (https://www.wowinterface.com/forums/showthread.php?t=55959)

Syiana 01-08-18 09:23 AM

Replace Shop Button with Friendlist Button
 
Hey i want to replace the shop button with the friendlist button from the chatwindow
https://i.imgur.com/pflUkaO.png
but when i setpoint it to the mainbar the texture from the friendlist button is under the mainbar texture like this
https://i.imgur.com/4a1tYtF.png

Code:
StoreMicroButton:Hide()
QuickJoinToastButton:ClearAllPoints()
QuickJoinToastButton:SetPoint('CENTER', MainMenuBarArtFrame, 'CENTER', 280, 25)

any help pls? :)

Ammako 01-08-18 09:43 AM

FrameStrata

https://wow.gamepedia.com/FrameStrata

Also it might be worth setting parent as MainMenuBarArtFrame, anchoring onto shop button, and hiding shop button with :Hide(). Might be a simpler way to do this than putting it in the center of MainMenuBar and moving it all the way over. :p

lua Code:
  1. StoreMicroButton:Hide()
  2. QuickJoinToastButton:ClearAllPoints()
  3. QuickJoinToastButton:SetParent(MainMenuBarArtFrame)
  4. QuickJoinToastButton:SetPoint("CENTER", StoreMicroButton, "CENTER", 0, -10)
  5. QuickJoinToastButton:SetFrameStrata(StoreMicroButton:GetFrameStrata())

The social button is 1 pixel smaller in height than the other buttons, though. So it looks a little bit off compared to everything else, but I imagine that won't really bother you.

Syiana 01-08-18 10:34 AM

thanks for help

my code:

StoreMicroButton:Hide()
QuickJoinToastButton:ClearAllPoints()
QuickJoinToastButton:SetParent(MainMenuBarArtFrame)
QuickJoinToastButton:SetPoint("CENTER", MainMenuMicroButton, "CENTER", 26, -10)
QuickJoinToastButton:SetFrameStrata(MainMenuMicroButton:GetFrameStrata())
QuickJoinToastButton:SetHeight(33)

MainMenuMicroButton:ClearAllPoints()
MainMenuMicroButton:SetPoint('CENTER', StoreMicroButton, 'CENTER', 0, 0)

looks good:

https://i.imgur.com/H3aXoca.png

but now i have the problem when someone makes a grp in the finder tool its looks like this:

https://i.imgur.com/MMEp4uc.png

QuickJoinToastButton.Toast:SetPoint("CENTER", MainMenuMicroButton, "CENTER", 26, 50) doesnt work

Ammako 01-08-18 05:04 PM

Maybe you also need to set higher strata on QuickJoinToastButton.Toast (I can't test right now.)

It would cover your bag icons, though, which could be a problem depending on whether you ever click those at all. In which case you could move it elsewhere where it wouldn't be in the way.


All times are GMT -6. The time now is 02:26 PM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI