Mercurial > wow > ouroloot
comparison gui.lua @ 111:cfbaf001fd52
Minor cleanup to player dropdown
author | Farmbuyer of US-Kilrogg <farmbuyer@gmail.com> |
---|---|
date | Wed, 08 Aug 2012 23:15:06 -0400 |
parents | f93c1a93923b |
children | 67bf97136273 |
comparison
equal
deleted
inserted
replaced
110:f93c1a93923b | 111:cfbaf001fd52 |
---|---|
1141 _d:SetUserData("DD cell", cellFrame) | 1141 _d:SetUserData("DD cell", cellFrame) |
1142 gui.dropdown.eoi_loot[1].text = e.itemlink | 1142 gui.dropdown.eoi_loot[1].text = e.itemlink |
1143 EasyMenu (gui.dropdown.eoi_loot, dropdownmenuframe, cellFrame, 0, 0, "MENU") | 1143 EasyMenu (gui.dropdown.eoi_loot, dropdownmenuframe, cellFrame, 0, 0, "MENU") |
1144 | 1144 |
1145 elseif kind == 'loot' and column == 2 then | 1145 elseif kind == 'loot' and column == 2 then |
1146 gui.dropdown.eoi_player[1].text = e.person | 1146 local ddep = gui.dropdown.eoi_player |
1147 ddep[1].text = e.person | |
1147 local raiders = {} | 1148 local raiders = {} |
1148 for i = 1, GetNumRaidMembers() do | 1149 for i = 1, GetNumRaidMembers() do |
1149 tinsert (raiders, (GetRaidRosterInfo(i))) | 1150 tinsert (raiders, (GetRaidRosterInfo(i))) |
1150 end | 1151 end |
1151 table.sort(raiders) | 1152 table.sort(raiders) |
1153 local name = raiders[i] | 1154 local name = raiders[i] |
1154 raiders[i] = gen_dd_entry (name, eoi_dropdownfuncs, 'df_REASSIGN', name) | 1155 raiders[i] = gen_dd_entry (name, eoi_dropdownfuncs, 'df_REASSIGN', name) |
1155 end | 1156 end |
1156 tinsert (raiders, gen_dd_entry ("Enter name...", eoi_dropdownfuncs)) | 1157 tinsert (raiders, gen_dd_entry ("Enter name...", eoi_dropdownfuncs)) |
1157 tinsert (raiders, gen_dd_entry (CLOSE, eoi_dropdownfuncs)) | 1158 tinsert (raiders, gen_dd_entry (CLOSE, eoi_dropdownfuncs)) |
1158 gui.dropdown.eoi_player[2].menuList = raiders | 1159 ddep[2].menuList = raiders |
1159 | 1160 |
1160 if not addon:_test_disposition (e.disposition, 'can_reassign') then | 1161 if not addon:_test_disposition (e.disposition, 'can_reassign') then |
1161 gui.dropdown.eoi_player[2].disabled = true | 1162 ddep[2].disabled = true |
1162 gui.dropdown.eoi_player[2].tooltipTitle = "Cannot Reassign" | 1163 ddep[2].tooltipTitle = "Cannot Reassign" |
1163 gui.dropdown.eoi_player[2].tooltipText = "You must first mark this item as 'normal' or 'offspec' before reassignment." | 1164 ddep[2].tooltipText = "You must first mark this item as 'normal' or 'offspec' before reassignment." |
1164 else | 1165 else |
1165 gui.dropdown.eoi_player[2].disabled = nil | 1166 ddep[2].disabled = nil |
1166 gui.dropdown.eoi_player[2].tooltipTitle = nil | 1167 ddep[2].tooltipTitle = nil |
1167 gui.dropdown.eoi_player[2].tooltipText = nil | 1168 ddep[2].tooltipText = nil |
1168 end | 1169 end |
1169 EasyMenu (gui.dropdown.eoi_player, dropdownmenuframe, cellFrame, 0, 0, "MENU") | 1170 EasyMenu (ddep, dropdownmenuframe, cellFrame, 0, 0, "MENU") |
1170 | 1171 |
1171 elseif kind == 'boss' then | 1172 elseif kind == 'boss' then |
1172 gui.dropdown.eoi_boss[1].text = e.bossname | 1173 gui.dropdown.eoi_boss[1].text = e.bossname |
1173 -- KILLWIPE: update '2' if this is not the 2nd entry in gui.dropdown.eoi_boss | 1174 -- KILLWIPE: update '2' if this is not the 2nd entry in gui.dropdown.eoi_boss |
1174 gui.dropdown.eoi_boss[2].tooltipWhileDisabled = nil | 1175 gui.dropdown.eoi_boss[2].tooltipWhileDisabled = nil |