vanilla-wow-addons – Blame information for rev 1

Subversion Repositories:
Rev:
Rev Author Line No. Line
1 office 1 function IMBA_Options_OnLoad()
2 this:SetBackdropBorderColor(1, 1, 1, 1);
3 this:SetBackdropColor(0.0,0.0,0.0,0.6);
4 IMBA_Options_Update();
5 this:RegisterEvent("VARIABLES_LOADED");
6  
7 IMBA_Options_Title:SetText("IMBA Options "..IMBA_Version);
8 this:SetScale(0.9);
9 end
10  
11 --Taken from CTRA
12 function IMBA_SortTable(t1, t2)
13 local locs = { };
14 for k, v in IMBA_Locations do
15 locs[v[1]] = k;
16 end
17 if ( t1[2] and t2[2] ) then
18 return locs[t1[1]] < locs[t2[1]];
19 else
20 local loc1, loc2;
21 if ( t1[2] ) then
22 loc1 = locs[t1[1]];
23 else
24 loc1 = locs[t1[4]];
25 end
26 if ( t2[2] ) then
27 loc2 = locs[t2[1]];
28 else
29 loc2 = locs[t2[4]];
30 end
31 if ( loc1 == loc2 ) then
32 if ( t1[2] or t2[2] ) then
33 return (t1[2]);
34 else
35 return t1[1] < t2[1];
36 end
37 else
38 return loc1 < loc2;
39 end
40 end
41 end
42  
43 function IMBA_CalculateEntries()
44 local locIndexes = { };
45 local tbl = { };
46 local numPerLoc = { };
47  
48 -- Calculate number of mods per location
49 for k, v in IMBA_Addons do
50 local loc = v.Location;
51 if ( not loc ) then
52 loc = "Other";
53 end
54 if ( not numPerLoc[loc] ) then
55 numPerLoc[loc] = 1;
56 else
57 numPerLoc[loc] = numPerLoc[loc] + 1;
58 end
59 end
60 -- Populate the locIndexes table with the locations we have
61 for k, v in IMBA_Locations do
62 -- Only add if there are mods for it
63 if ( numPerLoc[v[1]] ) then
64 locIndexes[v[1]] = v[2];
65 tinsert(tbl, { v[1], 1, v[2] });
66 end
67 end
68  
69 -- Calculate which records to add
70 for k, v in IMBA_Addons do
71 if ( not v.Location ) then
72 v.Location = "Other";
73 end
74 if ( locIndexes[v.Location] and locIndexes[v.Location] == 1 ) then
75 tinsert(tbl, { k, nil, v, v.Location });
76 end
77 end
78  
79 -- Sort the table
80 table.sort(tbl, IMBA_SortTable);
81  
82 return tbl, numPerLoc;
83 end
84  
85  
86 function IMBA_Options_Update()
87 local tbl, numPerLoc = IMBA_CalculateEntries();
88 local numEntries = getn(tbl);
89 -- ScrollFrame update
90 FauxScrollFrame_Update(IMBA_Options_BossFrame_ScrollFrame, numEntries, 8, 25 );
91  
92 for i=1, 8, 1 do
93 local obj = getglobal("IMBA_Options_BossFrame_BossMod" .. i);
94 local nameText = getglobal("IMBA_Options_BossFrame_BossMod" .. i .. "Name");
95 local descriptText = getglobal("IMBA_Options_BossFrame_BossMod" .. i .. "Descript");
96 local statusText = getglobal("IMBA_Options_BossFrame_BossMod" .. i .. "Status");
97 local line = getglobal("IMBA_Options_BossFrame_BossMod" .. i .. "Line");
98 local dropdown = getglobal("IMBA_Options_BossFrame_BossMod" .. i .. "Menu");
99 local plusMinus = getglobal("IMBA_Options_BossFrame_BossMod" .. i .. "ShowHide");
100 local prevLine = getglobal("IMBA_Options_BossFrame_BossMod" .. i-1 .. "Line");
101  
102 local index = i + FauxScrollFrame_GetOffset(IMBA_Options_BossFrame_ScrollFrame);
103  
104 if ( index <= numEntries ) then
105 obj:Show();
106 line:Hide();
107 if ( not tbl[index][2] ) then
108 -- Not a header
109 obj.header = nil;
110 nameText:SetText(tbl[index][1]);
111 nameText:SetTextColor(0.5, 0.5, 0.5);
112 nameText:ClearAllPoints();
113 nameText:SetPoint("TOPLEFT", obj:GetName(), "TOPLEFT", 45, 0);
114 plusMinus:Hide();
115 if ( tbl[index][3].Active ) then
116 statusText:SetText("On");
117 statusText:SetTextColor(0, 1, 0);
118 else
119 statusText:SetText("Off");
120 statusText:SetTextColor(1, 0, 0);
121 end
122  
123 if IMBA_CheckIfCanActivate(tbl[index][1]) then
124 statusText:Show();
125 else
126 statusText:Hide();
127 end
128  
129 if ( tbl[index][3].Description ) then
130 descriptText:SetText(tbl[index][3].Description);
131 else
132 descriptText:SetText("");
133 end
134 obj.index = tbl[index][1];
135 if ( not obj.hasBeenInitialized ) then
136 UIDropDownMenu_Initialize(dropdown, IMBA_InitDropDown, "MENU");
137 obj.hasBeenInitialized = 1;
138 end
139 else
140 if ( prevLine ) then
141 prevLine:Show();
142 end
143 -- Header
144 obj.header = 1;
145 obj.headername = tbl[index][1];
146 local num = numPerLoc[tbl[index][1]];
147 if ( not num ) then
148 num = 0;
149 end
150 plusMinus:Show();
151 if ( tbl[index][3] == 1 ) then
152 if ( obj.mouseIsOver ) then
153 GameTooltip:SetText("Click to contract");
154 end
155 plusMinus:SetText("-");
156 obj.expanded = 1;
157 else
158 if ( obj.mouseIsOver ) then
159 GameTooltip:SetText("Click to expand");
160 end
161 plusMinus:SetText("+");
162 obj.expanded = nil;
163 end
164 nameText:SetText(tbl[index][1] .. " (" .. num .. ")");
165 nameText:SetTextColor(1, 1, 1);
166 nameText:ClearAllPoints();
167 nameText:SetPoint("LEFT", obj:GetName(), "LEFT", 12, 0);
168 statusText:SetText("");
169 descriptText:SetText("");
170 end
171 else
172 obj:Hide();
173 end
174 end
175 end
176  
177 function IMBA_AddonVarClicked()
178 if IMBA_SavedVariables.Mods[this.value[1]]==nil then
179 IMBA_SavedVariables.Mods[this.value[1]]={};
180 end
181 if IMBA_SavedVariables.Mods[this.value[1]].Var==nil then
182 IMBA_SavedVariables.Mods[this.value[1]].Var={};
183 end
184 if IMBA_SavedVariables.Mods[this.value[1]].Var[this.value[2]] then
185 IMBA_SavedVariables.Mods[this.value[1]].Var[this.value[2]]=false;
186 else
187 IMBA_SavedVariables.Mods[this.value[1]].Var[this.value[2]]=true;
188 end
189 end
190  
191 function IMBA_InitDropDown()
192 local modName = getglobal(UIDROPDOWNMENU_INIT_MENU):GetParent().index;
193 local info = {};
194  
195 info.text = modName;
196 info.isTitle = 1;
197 info.justifyH = "CENTER";
198 info.notCheckable = 1;
199 UIDropDownMenu_AddButton(info);
200  
201 if IMBA_CheckIfCanActivate(modName) then
202 info = { };
203 info.text = "Enable mod";
204 info.tooltipTitle = "Enable mod";
205 info.tooltipText = "Enables the mod, turning on all enabled options.";
206 info.checked = IMBA_Addons[modName].Active;
207 info.func = IMBA_EnableMod;
208 info.keepShownOnClick = 1;
209 info.value = modName;
210 UIDropDownMenu_AddButton(info);
211 end
212  
213 if IMBA_Addons[modName].MainFrame then
214 info = { };
215 info.text = "Visible";
216 info.tooltipTitle = "Visible";
217 info.tooltipText = "Toggles Visibility on the Addon. (If the addon is enabled it will auto become visible at the beginning of the boss fight)";
218 info.checked = IMBA_SavedVariables.Mods[modName].Visible;
219 info.func = IMBA_ToggleModVisibility;
220 info.keepShownOnClick = 1;
221 info.value = modName;
222 UIDropDownMenu_AddButton(info);
223 end
224  
225 --if IMBA_CheckIfCanActivate(modName) then
226 -- info = { };
227 -- info.text = "Test mod";
228 -- info.tooltipTitle = "Test mod";
229 -- info.tooltipText = "Tests the mod, initializing it";
230 -- info.keepShownOnClick = 1;
231 -- info.checked = 0;
232 -- info.func = IMBA_TestMod;
233 -- info.value = modName;
234 -- UIDropDownMenu_AddButton(info);
235 --end
236  
237 if IMBA_Addons[modName].Options then
238 for k, v in IMBA_Addons[modName].OptionsOrder do
239 option=IMBA_Addons[modName].Options[v];
240 info = { };
241 info.text = option.text;
242 info.keepShownOnClick = 1;
243 info.checked = option.valuefunc();
244 info.func = option.func;
245 UIDropDownMenu_AddButton(info);
246 end
247 end
248 if IMBA_Addons[modName].VarText then
249 for k, option in IMBA_Addons[modName].OptionsOrder2 do
250 info = { };
251 info.text = IMBA_Addons[modName].VarText[option];
252 info.keepShownOnClick = 1;
253 if IMBA_SavedVariables.Mods[modName].Var==nil then
254 IMBA_SavedVariables.Mods[modName].Var={};
255 end
256 info.checked = IMBA_SavedVariables.Mods[modName].Var[option];
257  
258 info.func = IMBA_AddonVarClicked;
259 info.value = {modName,option};
260 UIDropDownMenu_AddButton(info);
261 end
262 end
263 end
264  
265 -- Enable/Disable mod
266 function IMBA_EnableMod()
267 IMBA_Addons[this.value].Active = not IMBA_Addons[this.value].Active;
268 IMBA_SavedVariables.Mods[this.value].Active = IMBA_Addons[this.value].Active;
269 IMBA_Options_Update();
270 end
271  
272 -- Tests the Mod
273 function IMBA_TestMod()
274 if IMBA_Addons[this.value].RegenActivator then
275 getglobal(IMBA_Addons[this.value].RegenActivator)();
276 elseif IMBA_Addons[this.value].YellActivator then
277 getglobal(IMBA_Addons[this.value].YellActivator)(IMBA_Addons[this.value].TestYell);
278 end
279 end
280  
281 function IMBA_ToggleModVisibility()
282 IMBA_SavedVariables.Mods[this.value].Visible = not IMBA_SavedVariables.Mods[this.value].Visible;
283 if IMBA_SavedVariables.Mods[this.value].Visible then
284 getglobal(IMBA_Addons[this.value].MainFrame):Show();
285 else
286 getglobal(IMBA_Addons[this.value].MainFrame):Hide();
287 end
288 end
289  
290  
291 function IMBA_ToggleHeader(name)
292 for k, v in IMBA_Locations do
293 if ( v[1] == name ) then
294 if ( v[2] == 1 ) then
295 IMBA_Locations[k][2] = 0;
296 else
297 IMBA_Locations[k][2] = 1;
298 end
299 break;
300 end
301 end
302 IMBA_Options_Update();
303 end
304  
305 function IMBA_Options_OnEvent(event)
306 if event=="VARIABLES_LOADED" then
307 IMBA_Options_Update();
308 end
309 end
310  
311 function IMBA_FrameSettingsDropDown_OnLoad()
312 UIDropDownMenu_Initialize(this, IMBA_FrameSettingsDropDown_Initialize);
313 end
314  
315 function IMBA_FrameSettingsDropDown_Initialize()
316  
317 for i=1,2,1 do
318 info = {};
319 info.text = IMBA_BG[i].name;
320 info.value = i;
321 info.func = IMBA_FrameSettingsDropDown_OnClick;
322 UIDropDownMenu_AddButton(info);
323 end
324  
325 if IMBA_SavedVariables.FrameType==nil then
326 IMBA_SavedVariables.FrameType=1;
327 end
328  
329 UIDropDownMenu_SetSelectedID(IMBA_Options_GraphicsFrame_FrameSettings_DropDown,IMBA_SavedVariables.FrameType);
330 end
331  
332 function IMBA_FrameSettingsDropDown_OnClick()
333 UIDropDownMenu_SetSelectedValue(IMBA_Options_GraphicsFrame_FrameSettings_DropDown, this.value);
334 IMBA_SavedVariables.FrameType=this.value;
335 IMBA_SetBackdrops(this.value);
336 end
337  
338 function IMBA_BarSettingsDropDown_OnLoad()
339 UIDropDownMenu_Initialize(this, IMBA_BarSettingsDropDown_Initialize);
340 end
341  
342  
343 function IMBA_BarSettingsDropDown_Initialize()
344  
345 for i=1,5,1 do
346 info = {};
347 info.text = IMBA_BarTextures[i].name;
348 info.value = i;
349 info.func = IMBA_BarSettingsDropDown_OnClick;
350 UIDropDownMenu_AddButton(info);
351 end
352  
353 if IMBA_SavedVariables.BarTextureNum==nil then
354 IMBA_SavedVariables.BarTextureNum=1;
355 end
356  
357 UIDropDownMenu_SetSelectedID(IMBA_Options_GraphicsFrame_BarSettings_DropDown,IMBA_SavedVariables.BarTextureNum);
358 end
359  
360 function IMBA_BarSettingsDropDown_OnClick()
361 UIDropDownMenu_SetSelectedValue(IMBA_Options_GraphicsFrame_BarSettings_DropDown, this.value);
362 IMBA_SavedVariables.BarTextureNum=this.value;
363 end
364  
365 function IMBA_ShowModOptions()
366 IMBA_Options_BossFrame:Show();
367 IMBA_Options_GraphicsFrame:Hide();
368 end
369  
370 function IMBA_ShowGraphicsOptions()
371 IMBA_SetupOptionColors();
372 IMBA_Options_BossFrame:Hide();
373 IMBA_Options_GraphicsFrame:Show();
374 end
375  
376 function IMBA_SetupOptionColors()
377 if IMBA_SavedVariables.Colors["FrameBG"]==nil then
378 IMBA_SavedVariables.Colors["FrameBG"]={r=0,g=0,b=0,a=0.6};
379 end
380 if IMBA_SavedVariables.Colors["FrameBorder"]==nil then
381 IMBA_SavedVariables.Colors["FrameBorder"]={r=1,g=1,b=1,a=1};
382 end
383 if IMBA_SavedVariables.Colors["BarStart"]==nil then
384 IMBA_SavedVariables.Colors["BarStart"]={r=1,g=1,b=1};
385 end
386 if IMBA_SavedVariables.Colors["BarEnd"]==nil then
387 IMBA_SavedVariables.Colors["BarEnd"]={r=1,g=1,b=1};
388 end
389 IMBA_Options_GraphicsFrame_FrameSettings_BGColor.color=IMBA_SavedVariables.Colors["FrameBG"];
390 IMBA_Options_GraphicsFrame_FrameSettings_BGColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["FrameBG"].r,IMBA_SavedVariables.Colors["FrameBG"].g,IMBA_SavedVariables.Colors["FrameBG"].b);
391 IMBA_Options_GraphicsFrame_FrameSettings_BorderColor.color=IMBA_SavedVariables.Colors["FrameBorder"];
392 IMBA_Options_GraphicsFrame_FrameSettings_BorderColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["FrameBorder"].r,IMBA_SavedVariables.Colors["FrameBorder"].g,IMBA_SavedVariables.Colors["FrameBorder"].b);
393 IMBA_Options_GraphicsFrame_BarSettings_StartColor.color=IMBA_SavedVariables.Colors["BarStart"];
394 IMBA_Options_GraphicsFrame_BarSettings_StartColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["BarStart"].r,IMBA_SavedVariables.Colors["BarStart"].g,IMBA_SavedVariables.Colors["BarStart"].b);
395 IMBA_Options_GraphicsFrame_BarSettings_EndColor.color=IMBA_SavedVariables.Colors["BarEnd"]
396 IMBA_Options_GraphicsFrame_BarSettings_EndColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["BarEnd"].r,IMBA_SavedVariables.Colors["BarEnd"].g,IMBA_SavedVariables.Colors["BarEnd"].b);
397 IMBA_Options_GraphicsFrame_BarSettings_InnerColor.color=IMBA_SavedVariables.Colors["BarInner"];
398 IMBA_Options_GraphicsFrame_BarSettings_InnerColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["BarInner"].r,IMBA_SavedVariables.Colors["BarInner"].g,IMBA_SavedVariables.Colors["BarInner"].b);
399 IMBA_Options_GraphicsFrame_BarSettings_BorderColor.color=IMBA_SavedVariables.Colors["BarBorder"]
400 IMBA_Options_GraphicsFrame_BarSettings_BorderColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["BarBorder"].r,IMBA_SavedVariables.Colors["BarBorder"].g,IMBA_SavedVariables.Colors["BarBorder"].b);
401  
402 IMBA_Options_GraphicsFrame_BarSettings_CustomColors:SetChecked(IMBA_SavedVariables.CustomBarColors)
403 IMBA_Options_GraphicsFrame_FrameSettings_CloseButtons:SetChecked(IMBA_SavedVariables.HideClose)
404 IMBA_Options_GraphicsFrame_HideMinimapIcon:SetChecked(IMBA_SavedVariables.HideMinimapIcon)
405 IMBA_Options_GraphicsFrame_ShowAlertWindow:SetChecked(IMBA_SavedVariables.ShowAlertWindow)
406 end
407  
408 function IMBA_LoadDefault_FrameSettings()
409 IMBA_SavedVariables.FrameType=1;
410 IMBA_SavedVariables.Colors["FrameBG"]={r=0,g=0,b=0,a=0.6};
411 IMBA_SavedVariables.Colors["FrameBorder"]={r=1,g=1,b=1,a=1};
412 IMBA_Options_GraphicsFrame_FrameSettings_BGColor.color=IMBA_SavedVariables.Colors["FrameBG"];
413 IMBA_Options_GraphicsFrame_FrameSettings_BGColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["FrameBG"].r,IMBA_SavedVariables.Colors["FrameBG"].g,IMBA_SavedVariables.Colors["FrameBG"].b);
414 IMBA_Options_GraphicsFrame_FrameSettings_BorderColor.color=IMBA_SavedVariables.Colors["FrameBorder"];
415 IMBA_Options_GraphicsFrame_FrameSettings_BorderColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["FrameBorder"].r,IMBA_SavedVariables.Colors["FrameBorder"].g,IMBA_SavedVariables.Colors["FrameBorder"].b);
416 IMBA_SetBackdrops(IMBA_SavedVariables.FrameType);
417 IMBA_SavedVariables.HideClose=false;
418 IMBA_ShowCloseButtons();
419 IMBA_Options_GraphicsFrame_FrameSettings_CloseButtons:SetChecked(false)
420 end
421  
422 function IMBA_FrameColorsChanged()
423 IMBA_SetBackdrops(IMBA_SavedVariables.FrameType);
424 end
425  
426 function IMBA_BarColorsChanged()
427 IMBA_SavedVariables.Colors["BarStart"]=IMBA_Options_GraphicsFrame_BarSettings_StartColor.color;
428 IMBA_SavedVariables.Colors["BarEnd"]=IMBA_Options_GraphicsFrame_BarSettings_EndColor.color;
429 end
430  
431 function IMBA_BarColors2Changed()
432 IMBA_SavedVariables.Colors["BarInner"]=IMBA_Options_GraphicsFrame_BarSettings_InnerColor.color;
433 IMBA_SavedVariables.Colors["BarBorder"]=IMBA_Options_GraphicsFrame_BarSettings_BorderColor.color;
434 IMBA_BarColorNumber=IMBA_BarColorNumber+1;
435 end
436  
437 function IMBA_CustomColors_Clicked()
438 IMBA_SavedVariables.CustomBarColors=IMBA_Options_GraphicsFrame_BarSettings_CustomColors:GetChecked()
439 IMBA_BarColorNumber=IMBA_BarColorNumber+1;
440 end
441  
442 function IMBA_LoadDefault_BarSettings()
443 IMBA_SavedVariables.Colors["BarStart"]={r=1,g=1,b=1};
444 IMBA_SavedVariables.Colors["BarEnd"]={r=1,g=1,b=1};
445 IMBA_SavedVariables.Colors["BarInner"]={r=0.4,g=0.4,b=0.4,a=0.6};
446 IMBA_SavedVariables.Colors["BarBorder"]={r=0.9,g=0.9,b=0.9,a=0.6};
447 IMBA_SavedVariables.CustomBarColors=nil;
448 IMBA_BarColorNumber=IMBA_BarColorNumber+1;
449  
450  
451 IMBA_Options_GraphicsFrame_BarSettings_StartColor.color=IMBA_SavedVariables.Colors["BarStart"]
452 IMBA_Options_GraphicsFrame_BarSettings_StartColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["BarStart"].r,IMBA_SavedVariables.Colors["BarStart"].g,IMBA_SavedVariables.Colors["BarStart"].b);
453 IMBA_Options_GraphicsFrame_BarSettings_EndColor.color=IMBA_SavedVariables.Colors["BarEnd"]
454 IMBA_Options_GraphicsFrame_BarSettings_EndColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["BarEnd"].r,IMBA_SavedVariables.Colors["BarEnd"].g,IMBA_SavedVariables.Colors["BarEnd"].b);
455 IMBA_Options_GraphicsFrame_BarSettings_InnerColor.color=IMBA_SavedVariables.Colors["BarInner"];
456 IMBA_Options_GraphicsFrame_BarSettings_InnerColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["BarInner"].r,IMBA_SavedVariables.Colors["BarInner"].g,IMBA_SavedVariables.Colors["BarInner"].b);
457 IMBA_Options_GraphicsFrame_BarSettings_BorderColor.color=IMBA_SavedVariables.Colors["BarBorder"]
458 IMBA_Options_GraphicsFrame_BarSettings_BorderColor_BG:SetVertexColor(IMBA_SavedVariables.Colors["BarBorder"].r,IMBA_SavedVariables.Colors["BarBorder"].g,IMBA_SavedVariables.Colors["BarBorder"].b);
459  
460 IMBA_Options_GraphicsFrame_BarSettings_CustomColors:SetChecked(IMBA_SavedVariables.CustomBarColors)
461  
462 end
463  
464 function IMBA_HideCloseButtons_Clicked()
465 IMBA_SavedVariables.HideClose=IMBA_Options_GraphicsFrame_FrameSettings_CloseButtons:GetChecked()
466 if IMBA_SavedVariables.HideClose then
467 IMBA_HideCloseButtons()
468 else
469 IMBA_ShowCloseButtons()
470 end
471 end
472  
473 function IMBA_HideMinimapIcon_Clicked()
474 IMBA_SavedVariables.HideMinimapIcon=IMBA_Options_GraphicsFrame_HideMinimapIcon:GetChecked()
475 if IMBA_SavedVariables.HideMinimapIcon then
476 IMBA_OptionsButton:Hide();
477 else
478 IMBA_OptionsButton:Show();
479 end
480 end
481  
482 function IMBA_ShowAlertWindow_Clicked()
483 IMBA_SavedVariables.ShowAlertWindow=IMBA_Options_GraphicsFrame_ShowAlertWindow:GetChecked()
484 if IMBA_SavedVariables.ShowAlertWindow then
485 IMBA_Alerts.isLocked=false;
486 IMBA_Alerts:EnableMouse(true);
487 IMBA_Alerts:SetMovable(true);
488 IMBA_Alerts:SetBackdropBorderColor(IMBA_SavedVariables.Colors["FrameBorder"].r,IMBA_SavedVariables.Colors["FrameBorder"].g,IMBA_SavedVariables.Colors["FrameBorder"].b,IMBA_SavedVariables.Colors["FrameBorder"].a);
489 IMBA_Alerts:SetBackdropColor(IMBA_SavedVariables.Colors["FrameBG"].r,IMBA_SavedVariables.Colors["FrameBG"].g,IMBA_SavedVariables.Colors["FrameBG"].b,IMBA_SavedVariables.Colors["FrameBG"].a);
490 else
491 IMBA_Alerts.isLocked=true;
492 IMBA_Alerts:EnableMouse(false);
493 IMBA_Alerts:SetMovable(false);
494 IMBA_Alerts:SetBackdropBorderColor(IMBA_SavedVariables.Colors["FrameBorder"].r,IMBA_SavedVariables.Colors["FrameBorder"].g,IMBA_SavedVariables.Colors["FrameBorder"].b,0);
495 IMBA_Alerts:SetBackdropColor(IMBA_SavedVariables.Colors["FrameBG"].r,IMBA_SavedVariables.Colors["FrameBG"].g,IMBA_SavedVariables.Colors["FrameBG"].b,0);
496 end
497 end
498  
499 function IMBA_DontRaidBroadcast_Clicked()
500 IMBA_SavedVariables.DontRaidBroadcast=IMBA_Options_GraphicsFrame_DontRaidBroadcast:GetChecked()
501 end
502  
503  
504 function IMBA_UseSCTForAlerts_Clicked()
505 IMBA_SavedVariables.UseSCTForAlerts=IMBA_Options_GraphicsFrame_UseSCTForAlerts:GetChecked()
506 end