Thread Tools Display Modes
Prev Previous Post   Next Post Next
10-16-12, 06:20 PM   #1
Animor
A Flamescale Wyrmkin
AddOn Author - Click to view addons
Join Date: Mar 2011
Posts: 136
A replacement for UIPanelButtonTemplate

Hello,

I'm looking for a replacement for UIPanelButtonTemplate, since for some strange reason the button I use causes taint issues, probably because it's blizzard UI.
My addon uses a small toggle button (used for language selection) that can be dragged around the screen. When the user click the button, the text on the button changes.
I tried to look at AceGUI-3.0, but I didn't see there a way to create a dragable button which is displayed directly on the screen. I only saw there button widget that should be a child of a frame.

If it helps, here is the current XML code I'm using to create the button:
Code:
<Button name="hebChatLangButton" parent="UIParent" inherits="UIPanelButtonTemplate"
enableMouse="true" movable="true" frameStrata="HIGH" clampedToScreen="true">
  <Anchors>
    <Anchor point="CENTER" relativePoint="BOTTOMLEFT" relativeTo="UIParent">
      <Offset x="15" y="80"/>
    </Anchor>
  </Anchors>
  <Size x="35" y="35"/>
  <Scripts>
    <OnLoad>
      hebChat:hebChatLangButton_OnLoad(self)
    </OnLoad>		
    <OnClick>
      hebChat:toggleLanguage()
     </OnClick>
    <OnDragStart>
      self:StartMoving()
    </OnDragStart>
    <OnDragStop>
      self:StopMovingOrSizing()
    </OnDragStop>
  </Scripts>
</Button>
Thanks in advance!
  Reply With Quote
 

WoWInterface » Developer Discussions » Lua/XML Help » A replacement for UIPanelButtonTemplate


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off