vanilla-wow-addons – Blame information for rev 1

Subversion Repositories:
Rev:
Rev Author Line No. Line
1 office 1 <Ui>
2 <Script file="tradeDispenser_OSD.lua"/>
3 <Frame name="tradeDispenserOSD" parent="UIParent" hidden="false" enableMouse="true" movable="true"> <!-- SHOWs some BUTTONS on the screen -->
4 <Size> <AbsDimension x="42" y="116"/> </Size>
5 <Anchors>
6 <Anchor point="CENTER">
7 <Offset><AbsDimension x="0" y="0"/></Offset>
8 </Anchor>
9 </Anchors>
10 <Backdrop name="$parentBackdrop" bgFile="Interface\Tooltips\UI-Tooltip-Background" edgeFile="Interface\Tooltips\UI-Tooltip-Border" tile="true">
11 <EdgeSize> <AbsValue val="16"/> </EdgeSize>
12 <TileSize> <AbsValue val="0"/> </TileSize>
13 <BackgroundInsets>
14 <AbsInset left="4" right="4" top="4" bottom="4"/>
15 </BackgroundInsets>
16 </Backdrop>
17 <Frames>
18  
19 <Button name="$parentActivateBtn" inherits="UIPanelButtonTemplate" text="">
20 <Size> <AbsDimension x="32" y="32"/> </Size>
21 <Anchors>
22 <Anchor point="CENTER" relativeTo="$parent" relativePoint="CENTER">
23 <Offset> <AbsDimension x="0" y="0"/> </Offset>
24 </Anchor>
25 </Anchors>
26 <NormalTexture file=""/> <PushedTexture file=""/>
27 <HighlightTexture file="Interface\Buttons\UI-Common-MouseHilight" alphaMode="ADD"/>
28 <Scripts>
29 <OnLoad>
30 tradeDispenser_OSD_OnLoad(this);
31 </OnLoad>
32 <OnClick>
33 tradeDispenserPlaySound(this)
34 if (arg1=="LeftButton") then
35 tD_Temp.isEnabled = not tD_Temp.isEnabled;
36 tradeDispenser_Eventhandler()
37 tradeDispenserUpdate();
38 tradeDispenserOSD_OnUpdate();
39 else
40 tradeDispenser_ResetRegistratedChars(); <!-- reset the chars... function found in TradeControl.lua -->
41 end
42 </OnClick>
43 <OnEnter>
44 tradeDispenserSetTooltipPosition(this:GetParent(),0,0);
45 if (tD_Temp.isEnabled) then
46 GameTooltip:AddLine("|cFFFFFFFF"..tD_Loc.OSD.actbutton.deactivate);
47 else
48 GameTooltip:AddLine("|cFFFFFFFF"..tD_Loc.OSD.actbutton.activate);
49 end
50 GameTooltip:AddLine(tD_Loc.OSD.actbutton.left);
51 if (tD_CharDatas.RegisterCheck) then
52 GameTooltip:AddLine(tD_Loc.OSD.actbutton.right)
53 else
54 GameTooltip:AddLine(tD_Loc.OSD.actbutton.noright)
55 end
56 GameTooltip:Show();
57 </OnEnter>
58 <OnLeave> GameTooltip:Hide(); </OnLeave>
59 </Scripts>
60 </Button>
61  
62 <Button name="$parentBroadcastBtn" inherits="UIPanelButtonTemplate" text="">
63 <Size> <AbsDimension x="32" y="32"/> </Size>
64 <NormalTexture file=""/> <PushedTexture file=""/>
65 <HighlightTexture file="Interface\Buttons\UI-Common-MouseHilight" alphaMode="ADD"/>
66 <Scripts>
67 <OnLoad>
68 tradeDispenser_OSD_OnLoad(this);
69 </OnLoad>
70 <OnClick>
71 tradeDispenserPlaySound(this)
72 if (not tD_Temp.isEnabled) then
73 DEFAULT_CHAT_FRAME:AddMessage(tD_Loc.OSD.notenabled);
74 else
75 if (arg1=="RightButton") then
76 tD_CharDatas.AutoBroadcast = not tD_CharDatas.AutoBroadcast;
77 tradeDispenserUpdate();
78 tradeDispenser.broadcastSlice=0.2;
79 tradeDispenserOSD_OnUpdate();
80 else
81 tradeDispenserBroadcastItems()
82 end
83 end
84 </OnClick>
85 <OnEnter>
86 local temp, tradeDispenserChannel = tradeDispenserGetChannel();
87  
88 tradeDispenserSetTooltipPosition(this:GetParent(),0,0);
89 GameTooltip:AddLine("|cFFFFFFFF"..tD_Loc.OSD.broadcasttip.title);
90 GameTooltip:AddLine(tD_Loc.OSD.broadcasttip.channel..tradeDispenserChannel);
91 GameTooltip:AddLine(tD_Loc.OSD.broadcasttip.left);
92 GameTooltip:AddLine(tD_Loc.OSD.broadcasttip.right);
93 GameTooltip:Show();
94 </OnEnter>
95 <OnLeave> GameTooltip:Hide(); </OnLeave>
96 </Scripts>
97 </Button>
98  
99  
100 <Button name="$parentConfigBtn" inherits="UIPanelButtonTemplate" text="">
101 <Size> <AbsDimension x="32" y="32"/> </Size>
102 <Anchors>
103 <Anchor point="TOP" relativeTo="$parentActivateBtn" relativePoint="BOTTOM">
104 <Offset> <AbsDimension x="0" y="-5"/> </Offset>
105 </Anchor>
106 </Anchors>
107 <NormalTexture file=""/> <PushedTexture file=""/>
108 <HighlightTexture file="Interface\Buttons\UI-Common-MouseHilight" alphaMode="ADD"/>
109 <Scripts>
110 <OnLoad>
111 tradeDispenser_OSD_OnLoad(this);
112 </OnLoad>
113 <OnClick>
114 tradeDispenserPlaySound(this)
115 if (arg1=="RightButton") then
116 tradeDispenserSettings:Show();
117 tradeDispenserSettingsBtn:LockHighlight();
118 tradeDispenserTradeControl:Show();
119 tradeDispenserTradeControlBtn:LockHighlight();
120 end
121 tradeDispenserMessages:Hide();
122 tD_Temp.isVisible = not tD_Temp.isVisible;
123 tradeDispenserUpdate();
124 tradeDispenser_EditBoxUpdate();
125 tradeDispenserSettings_OnUpdate();
126 tradeDispenserOSD_OnUpdate();
127 </OnClick>
128 <OnEnter>
129 tradeDispenserSetTooltipPosition(this:GetParent(),0,0);
130 if (tD_Temp.isVisible) then
131 GameTooltip:AddLine("|cFFFFFFFF"..tD_Loc.OSD.configbtn.hide)
132 else
133 GameTooltip:AddLine("|cFFFFFFFF"..tD_Loc.OSD.configbtn.show)
134 end
135 GameTooltip:AddLine(tD_Loc.OSD.configbtn.left)
136 GameTooltip:AddLine(tD_Loc.OSD.configbtn.right)
137 GameTooltip:Show()
138 </OnEnter>
139 <OnLeave> GameTooltip:Hide() </OnLeave>
140 </Scripts>
141 </Button>
142 </Frames>
143 <Scripts>
144 <OnLoad> this:Raise(); this:Raise(); this:Raise(); </OnLoad>
145 <OnMouseDown> if (not tD_CharDatas.OSD.locked) then this:StartMoving() end </OnMouseDown>
146 <OnMouseUp> if (not tD_CharDatas.OSD.locked) then this:StopMovingOrSizing() end</OnMouseUp>
147 <OnDragStop> if (not tD_CharDatas.OSD.locked) then this:StopMovingOrSizing() end</OnDragStop>
148 </Scripts>
149 </Frame>
150 </Ui>