Mercurial > wow > breuesk
comparison Gui.lua @ 58:615346b6ee99
Starting to use userdata
| author | John@Yosemite-PC |
|---|---|
| date | Sun, 25 Mar 2012 17:43:09 -0400 |
| parents | 94ae80d58903 |
| children | c7330bc4a9ea |
comparison
equal
deleted
inserted
replaced
| 57:93acdcd6ace5 | 58:615346b6ee99 |
|---|---|
| 71 f:SetTitle("BSK") | 71 f:SetTitle("BSK") |
| 72 f:SetLayout("Flow") | 72 f:SetLayout("Flow") |
| 73 f:SetHeight(680) | 73 f:SetHeight(680) |
| 74 f:SetWidth(580) | 74 f:SetWidth(580) |
| 75 | 75 |
| 76 | |
| 76 local left = AceGUI:Create("InlineGroup") | 77 local left = AceGUI:Create("InlineGroup") |
| 77 left:SetLayout("List") | 78 left:SetLayout("List") |
| 78 left:SetWidth(175) | 79 left:SetWidth(175) |
| 79 left:SetFullHeight(true) | 80 left:SetFullHeight(true) |
| 80 left.alignoffset=0.25 -- hack, as per http://forums.wowace.com/showthread.php?t=17114 | 81 left.alignoffset=0.25 -- hack, as per http://forums.wowace.com/showthread.php?t=17114 |
| 153 biddingZone:SetFullWidth(true) | 154 biddingZone:SetFullWidth(true) |
| 154 | 155 |
| 155 local label = AceGUI:Create("Label") | 156 local label = AceGUI:Create("Label") |
| 156 label:SetText("Bidding now open for ...") | 157 label:SetText("Bidding now open for ...") |
| 157 local biddingOn = AceGUI:Create("InteractiveLabel") | 158 local biddingOn = AceGUI:Create("InteractiveLabel") |
| 158 biddingOn:SetText( "|cffa335ee|Hitem:65003:0:0:0:0:0:0:0:85:0|h[Reclaimed Ashkandi, Greatsword of the Brotherhood]|h|r") | 159 biddingOn.userdata = { "|cffa335ee|Hitem:65003:0:0:0:0:0:0:0:85:0|h[Reclaimed Ashkandi, Greatsword of the Brotherhood]|h|r" } |
| 160 biddingOn:SetText(biddingOn.userdata[1]) | |
| 159 biddingOn:SetFullWidth(true) | 161 biddingOn:SetFullWidth(true) |
| 160 biddingOn:SetCallback("OnEnter", function(widget) _G.GameTooltip:SetOwner(widget.frame,"ANCHOR_RIGHT"); _G.GameTooltip:SetHyperlink("|cffa335ee|Hitem:65003:0:0:0:0:0:0:0:85:0|h[Reclaimed Ashkandi, Greatsword of the Brotherhood]|h|r"); _G.GameTooltip:Show() end ) | 162 biddingOn:SetCallback("OnEnter", function(widget) _G.GameTooltip:SetOwner(widget.frame,"ANCHOR_RIGHT"); _G.GameTooltip:SetHyperlink(widget.userdata[1]); _G.GameTooltip:Show() end ) |
| 161 biddingOn:SetCallback("OnLeave", function(widget) _G.GameTooltip:Hide() end ) | 163 biddingOn:SetCallback("OnLeave", function(widget) _G.GameTooltip:Hide() end ) |
| 162 local b1 = AceGUI:Create("SelectorList") | 164 local b1 = AceGUI:Create("SelectorList") |
| 163 b1:SetNumLines(6) | 165 b1:SetNumLines(6) |
| 164 b1:SetInteractive(admin) | 166 b1:SetInteractive(admin) |
| 165 local dummydata = {copy(tree[1]),copy( tree[2] ),copy( tree[3] )} | 167 local dummydata = {copy(tree[1]),copy( tree[2] ),copy( tree[3] )} |
| 167 dummydata[2].text = dummydata[2].text .. " (roll 73)" | 169 dummydata[2].text = dummydata[2].text .. " (roll 73)" |
| 168 b1:SetList(dummydata) | 170 b1:SetList(dummydata) |
| 169 local bidTitle = AceGUI:Create("Label") | 171 local bidTitle = AceGUI:Create("Label") |
| 170 bidTitle:SetText("Current bids") | 172 bidTitle:SetText("Current bids") |
| 171 bidTitle:SetFullWidth(true) | 173 bidTitle:SetFullWidth(true) |
| 172 | |
| 173 | 174 |
| 174 local bidRetractButton = AceGUI:Create("Button") | 175 local bidRetractButton = AceGUI:Create("Button") |
| 175 bidRetractButton:SetText("Place Bid") | 176 bidRetractButton:SetText("Place Bid") |
| 176 bidRetractButton:SetWidth(100) | 177 bidRetractButton:SetWidth(100) |
| 177 local rollButton = AceGUI:Create("Button") | 178 local rollButton = AceGUI:Create("Button") |
| 209 if admin then biddingZone:AddChildren(g1) end | 210 if admin then biddingZone:AddChildren(g1) end |
| 210 right:AddChildren(t2) | 211 right:AddChildren(t2) |
| 211 if admin then right:AddChildren(alb1,alb2,alb3) end | 212 if admin then right:AddChildren(alb1,alb2,alb3) end |
| 212 right:AddChildren(biddingZone) | 213 right:AddChildren(biddingZone) |
| 213 f:AddChildren(left,right) | 214 f:AddChildren(left,right) |
| 214 end | 215 |
| 216 | |
| 217 end |
