@@ -63,9 +63,6 @@ Type:RegisterIconDefaults{
6363
6464 -- True if the icon should display blanks instead of the pocketwatch texture.
6565 NoPocketwatch = false ,
66-
67- -- True if the icon should only check casts of spells flagged as important.
68- OnlyImportant = false ,
6966}
7067
7168if not TMW .clientHasSecrets then
@@ -98,20 +95,13 @@ Type:RegisterConfigPanel_ConstructorFunc(150, "TellMeWhen_CastSettings", functio
9895 noPocketwatch ,
9996 })
10097 else
101- local checks = {
98+ self : BuildSimpleCheckSettingFrame ( {
10299 function (check )
103100 check :SetTexts (L [" ICONMENU_ONLYINTERRUPTIBLE" ], L [" ICONMENU_ONLYINTERRUPTIBLE_DESC" ])
104101 check :SetSetting (" Interruptible" )
105102 end ,
106103 noPocketwatch ,
107- }
108- if TMW .clientHasSecrets then
109- checks [# checks + 1 ] = function (check )
110- check :SetTexts (L [" ICONMENU_ONLYIMPORTANT" ], L [" ICONMENU_ONLYIMPORTANT_DESC" ])
111- check :SetSetting (" OnlyImportant" )
112- end
113- end
114- self :BuildSimpleCheckSettingFrame (checks )
104+ })
115105 end
116106end )
117107
154144
155145local Cast_OnUpdate
156146if TMW .clientHasSecrets then
157- local IsSpellImportant = C_Spell .IsSpellImportant
158147 function Cast_OnUpdate_Secrets (icon , time )
159148 -- Upvalue things that will be referenced a lot in our loops.
160- local Units , Interruptible , OnlyImportant = icon .Units , icon .Interruptible , icon . OnlyImportant
149+ local Units , Interruptible = icon .Units , icon .Interruptible
161150
162151 for u = 1 , # Units do
163152 local unit = Units [u ]
@@ -166,21 +155,20 @@ if TMW.clientHasSecrets then
166155 local GUID = UnitGUID (unit )
167156 if GUID then
168157
169- local name , _ , iconTexture , start , endTime , _ , _ , notInterruptible , castingSpellID = UnitCastingInfo (unit )
158+ local name , _ , iconTexture , start , endTime , _ , _ , notInterruptible = UnitCastingInfo (unit )
170159 local durObj = name and UnitCastingDuration (unit )
171160 -- Reverse is used to reverse the timer sweep masking behavior. Regular casts should have it be false.
172161 local reverse = false
173162
174163 -- There is no regular spellcast. Check for a channel.
175164 if not name then
176- name , _ , iconTexture , start , endTime , _ , notInterruptible , castingSpellID = UnitChannelInfo (unit )
165+ name , _ , iconTexture , start , endTime , _ , notInterruptible = UnitChannelInfo (unit )
177166 durObj = name and UnitChannelDuration (unit )
178167 -- Channeled casts should reverse the timer sweep behavior.
179168 reverse = true
180169 end
181170
182- local isImportant = not OnlyImportant or (castingSpellID and IsSpellImportant (castingSpellID ))
183- if name and isImportant then
171+ if name then
184172 icon .LastTexture = iconTexture
185173
186174 local state
0 commit comments