File conf/lua-check/luacheckrc.lua changed (mode: 100644) (index 2ad2e00..87bbc31) |
... |
... |
stds.cata = { |
16 |
16 |
stds.wrath = { |
stds.wrath = { |
17 |
17 |
read_globals = { |
read_globals = { |
18 |
18 |
'CreateFrame', |
'CreateFrame', |
|
19 |
|
'GetAddOnMetadata', |
19 |
20 |
'GetBuildInfo', |
'GetBuildInfo', |
20 |
21 |
'GetInstanceInfo', |
'GetInstanceInfo', |
21 |
22 |
'GetModifiedClick', |
'GetModifiedClick', |
|
... |
... |
stds.framexml = { |
156 |
157 |
'ToggleDropDownMenu', |
'ToggleDropDownMenu', |
157 |
158 |
'UIParent', |
'UIParent', |
158 |
159 |
'UnregisterUnitWatch', |
'UnregisterUnitWatch', |
|
160 |
|
'InterfaceOptions_AddCategory' |
159 |
161 |
}, |
}, |
160 |
162 |
globals = { |
globals = { |
161 |
163 |
}, |
}, |
|
... |
... |
stds.framexml = { |
165 |
167 |
|
|
166 |
168 |
stds.chorus = { |
stds.chorus = { |
167 |
169 |
read_globals = { |
read_globals = { |
|
170 |
|
'ChorusConfMovableCheckBox', |
|
171 |
|
'ChorusConfFrameTitle', |
168 |
172 |
'ChorusFocusFrame', |
'ChorusFocusFrame', |
169 |
173 |
'ChorusFrame', |
'ChorusFrame', |
170 |
174 |
'ChorusGroupFrame', |
'ChorusGroupFrame', |
|
... |
... |
stds.chorus = { |
172 |
176 |
'ChorusPartyFrame', |
'ChorusPartyFrame', |
173 |
177 |
'ChorusPlayerFrame', |
'ChorusPlayerFrame', |
174 |
178 |
'ChorusRaidFrame', |
'ChorusRaidFrame', |
|
179 |
|
'ChorusSoloFrame', |
175 |
180 |
'ChorusTargetFrame', |
'ChorusTargetFrame', |
176 |
181 |
}, |
}, |
177 |
182 |
globals = { |
globals = { |
|
... |
... |
stds.chorus = { |
180 |
185 |
--exact. ]]-- |
--exact. ]]-- |
181 |
186 |
'Chorus', |
'Chorus', |
182 |
187 |
'ChorusAuraWeightMap', |
'ChorusAuraWeightMap', |
|
188 |
|
'ChorusConf', |
|
189 |
|
'ChorusConfProfileName', |
183 |
190 |
'ChorusFocusFrameHealthFrame', |
'ChorusFocusFrameHealthFrame', |
184 |
191 |
'ChorusFocusFrameUnitNameFrame', |
'ChorusFocusFrameUnitNameFrame', |
|
192 |
|
'ChorusHugeRaidFrame', |
|
193 |
|
'ChorusLargeRaidFrame', |
185 |
194 |
'ChorusLuacheckrcDump', |
'ChorusLuacheckrcDump', |
186 |
195 |
'ChorusPlayerFrameHealthFrame', |
'ChorusPlayerFrameHealthFrame', |
187 |
196 |
'ChorusPlayerFrameUnitNameFrame', |
'ChorusPlayerFrameUnitNameFrame', |
|
197 |
|
'ChorusSmallRaidFrame', |
188 |
198 |
'ChorusTargetFrameHealthFrame', |
'ChorusTargetFrameHealthFrame', |
189 |
199 |
'ChorusTargetFrameUnitNameFrame', |
'ChorusTargetFrameUnitNameFrame', |
190 |
|
'ChorusUnitGroupRoleMap', |
|
191 |
200 |
'ChorusTinyRaidFrame', |
'ChorusTinyRaidFrame', |
192 |
|
'ChorusSmallRaidFrame', |
|
193 |
|
'ChorusLargeRaidFrame', |
|
194 |
|
'ChorusHugeRaidFrame', |
|
|
201 |
|
'ChorusUnitGroupRoleMap', |
195 |
202 |
}, |
}, |
196 |
203 |
} |
} |
197 |
204 |
|
|
File conf/make/src.mk changed (mode: 100644) (index da7fb82..0895cf2) |
... |
... |
${srcdir}src/ChorusUnitLevelFrameTemplate.lua \ |
28 |
28 |
${srcdir}src/ChorusUnitNameFrameTemplate.lua \ |
${srcdir}src/ChorusUnitNameFrameTemplate.lua \ |
29 |
29 |
${srcdir}src/ChorusPartyFrame.lua \ |
${srcdir}src/ChorusPartyFrame.lua \ |
30 |
30 |
${srcdir}src/ChorusGroupFrame.lua \ |
${srcdir}src/ChorusGroupFrame.lua \ |
|
31 |
|
${srcdir}src/ChorusConfFrame.lua \ |
31 |
32 |
${srcdir}src/ChorusFrame.lua |
${srcdir}src/ChorusFrame.lua |
32 |
33 |
|
|
33 |
34 |
XMLFILES = \ |
XMLFILES = \ |
|
... |
... |
${srcdir}src/ChorusTinyRaidFrame.xml \ |
64 |
65 |
${srcdir}src/ChorusSmallRaidFrame.xml \ |
${srcdir}src/ChorusSmallRaidFrame.xml \ |
65 |
66 |
${srcdir}src/ChorusLargeRaidFrame.xml \ |
${srcdir}src/ChorusLargeRaidFrame.xml \ |
66 |
67 |
${srcdir}src/ChorusGroupFrame.xml \ |
${srcdir}src/ChorusGroupFrame.xml \ |
|
68 |
|
${srcdir}src/ChorusConfFrame.xml \ |
67 |
69 |
${srcdir}src/ChorusFrame.xml |
${srcdir}src/ChorusFrame.xml |
File src/ChorusConfFrame.lua changed (mode: 100644) (index 1255367..3ef0737) |
... |
... |
local function savePoints(conf, profileName, frame) |
86 |
86 |
frameSettings = {} |
frameSettings = {} |
87 |
87 |
end |
end |
88 |
88 |
assert(frameSettings ~= nil) |
assert(frameSettings ~= nil) |
89 |
|
assert('table' == type(frameSettigns)) |
|
|
89 |
|
assert('table' == type(frameSettings)) |
90 |
90 |
|
|
91 |
91 |
local record = {} |
local record = {} |
92 |
92 |
local i = 0 |
local i = 0 |
93 |
93 |
while (i < 8) do |
while (i < 8) do |
94 |
94 |
i = i + 1 |
i = i + 1 |
95 |
95 |
local point = {frame:GetPoint(i)} |
local point = {frame:GetPoint(i)} |
96 |
|
record[i] = point |
|
|
96 |
|
if point[1] then |
|
97 |
|
record[i] = point |
|
98 |
|
end |
97 |
99 |
end |
end |
98 |
100 |
|
|
99 |
101 |
frameSettings.points = record |
frameSettings.points = record |
|
... |
... |
local function loadPoints(conf, profileName, frame) |
130 |
132 |
|
|
131 |
133 |
local frameSettings = confProfile[n] |
local frameSettings = confProfile[n] |
132 |
134 |
if not frameSettings then |
if not frameSettings then |
133 |
|
print('ChorusConfFrame.lua: empty settings for frame "' .. n .. '"') |
|
134 |
135 |
return |
return |
135 |
136 |
end |
end |
136 |
137 |
|
|
|
... |
... |
local function loadPoints(conf, profileName, frame) |
138 |
139 |
assert(points ~= nil, 'no frame position saved') |
assert(points ~= nil, 'no frame position saved') |
139 |
140 |
assert('table' == type(points)) |
assert('table' == type(points)) |
140 |
141 |
local i = 0 |
local i = 0 |
141 |
|
while (i < 8) do |
|
|
142 |
|
while (i < math.min(#points, 8)) do |
142 |
143 |
i = i + 1 |
i = i + 1 |
143 |
144 |
local point = points[i] |
local point = points[i] |
144 |
145 |
assert(point ~= nil) |
assert(point ~= nil) |
145 |
146 |
assert('table' == type(point)) |
assert('table' == type(point)) |
146 |
|
if point[3] and point[4] and point[5] then |
|
147 |
|
frame:SetPoint(point[3], point[4], point[5]) |
|
|
147 |
|
if point[1] then |
|
148 |
|
frame:SetPoint(unpack(point)) |
148 |
149 |
end |
end |
149 |
150 |
end |
end |
150 |
151 |
end |
end |
|
... |
... |
end |
152 |
153 |
local function confApply(confFrame) |
local function confApply(confFrame) |
153 |
154 |
assert(confFrame ~= nil) |
assert(confFrame ~= nil) |
154 |
155 |
|
|
155 |
|
local flag = ChorusConfMovableCheckBox:GetChecked() |
|
|
156 |
|
local flag = 1 == ChorusConfMovableCheckBox:GetChecked() |
156 |
157 |
|
|
157 |
|
if flag then |
|
158 |
|
local i = 0 |
|
159 |
|
while (i < #movableFrameList) do |
|
160 |
|
i = i + 1 |
|
161 |
|
local f = movableFrameList[i] |
|
162 |
|
assert(f ~= nil) |
|
|
158 |
|
local i = 0 |
|
159 |
|
while (i < #movableFrameList) do |
|
160 |
|
i = i + 1 |
|
161 |
|
local f = movableFrameList[i] |
|
162 |
|
assert(f ~= nil) |
|
163 |
|
if flag then |
163 |
164 |
movableEnable(f) |
movableEnable(f) |
164 |
|
end |
|
165 |
|
else |
|
166 |
|
local i = 0 |
|
167 |
|
while (i < #movableFrameList) do |
|
168 |
|
i = i + 1 |
|
169 |
|
local f = movableFrameList[i] |
|
170 |
|
assert(f ~= nil) |
|
|
165 |
|
else |
171 |
166 |
movableDisable(f) |
movableDisable(f) |
172 |
|
savePoints(ChorusConf, ChorusConfProfileName, f) |
|
173 |
167 |
end |
end |
|
168 |
|
savePoints(ChorusConf, ChorusConfProfileName, f) |
174 |
169 |
end |
end |
175 |
170 |
end |
end |
176 |
171 |
|
|
|
... |
... |
local function confDefault(confFrame) |
204 |
199 |
end |
end |
205 |
200 |
|
|
206 |
201 |
local function confFrameEventProcessor(confFrame) |
local function confFrameEventProcessor(confFrame) |
|
202 |
|
assert(confFrame ~= nil) |
|
203 |
|
|
207 |
204 |
ChorusConf = ChorusConf or {['main'] = {}} |
ChorusConf = ChorusConf or {['main'] = {}} |
208 |
205 |
ChorusConfProfileName = ChorusConfProfileName or 'main' |
ChorusConfProfileName = ChorusConfProfileName or 'main' |
209 |
206 |
|
|