comparison Frames.lua @ 119:dc6f405c1a5d

Now resizing the mover frame based on text size. addon.Locations table now uses location names as value, rather than random numbers. Added proper Merchant restocking support. Please note this currently doesn?t take the bonus queue nor the min crafting queue options into account.
author Zerotorescue
date Sat, 15 Jan 2011 17:03:05 +0100
parents 9765bc3b3d6b
children 8460855e3d90
comparison
equal deleted inserted replaced
118:de18ef96983b 119:dc6f405c1a5d
87 titleBackground:SetTexture("Interface\\DialogFrame\\UI-DialogBox-Header"); 87 titleBackground:SetTexture("Interface\\DialogFrame\\UI-DialogBox-Header");
88 titleBackground:SetTexCoord(0.31, 0.67, 0, 0.63); 88 titleBackground:SetTexCoord(0.31, 0.67, 0, 0.63);
89 titleBackground:SetPoint("TOP", 0, 12); 89 titleBackground:SetPoint("TOP", 0, 12);
90 titleBackground:SetWidth(150); 90 titleBackground:SetWidth(150);
91 titleBackground:SetHeight(40); 91 titleBackground:SetHeight(40);
92 92
93 frame.titleBackground = titleBackground;
94
93 local titleBackgroundLeft = frame:CreateTexture(nil, "OVERLAY"); 95 local titleBackgroundLeft = frame:CreateTexture(nil, "OVERLAY");
94 titleBackgroundLeft:SetTexture("Interface\\DialogFrame\\UI-DialogBox-Header"); 96 titleBackgroundLeft:SetTexture("Interface\\DialogFrame\\UI-DialogBox-Header");
95 titleBackgroundLeft:SetTexCoord(0.21, 0.31, 0, 0.63); 97 titleBackgroundLeft:SetTexCoord(0.21, 0.31, 0, 0.63);
96 titleBackgroundLeft:SetPoint("RIGHT", titleBackground, "LEFT"); 98 titleBackgroundLeft:SetPoint("RIGHT", titleBackground, "LEFT");
97 titleBackgroundLeft:SetWidth(30); 99 titleBackgroundLeft:SetWidth(30);
223 225
224 function addon:SetFrameSettings(title, description, proceed, cancel, headers) 226 function addon:SetFrameSettings(title, description, proceed, cancel, headers)
225 local frame = InventoriumItemMover; 227 local frame = InventoriumItemMover;
226 228
227 frame.lblTitle:SetText(title); 229 frame.lblTitle:SetText(title);
230 -- Adjust size for the title background
231 frame.titleBackground:SetWidth((frame.lblTitle:GetWidth() or 0) + 10); -- 10 pixels margin
228 232
229 frame.lblDescription:SetText(description); 233 frame.lblDescription:SetText(description);
230 234
231 frame.btnMove:SetText(proceed.text); 235 frame.btnMove:SetText(proceed.text);
232 frame.btnMove.tooltipTitle = proceed.tooltipTitle; 236 frame.btnMove.tooltipTitle = proceed.tooltipTitle;