Closed Artur91425 closed 3 years ago
Oh, I pressed the wrong button xD. I wanted to add just a comment)
So far, do not merge this PR. I did not make the handling after clicking "Exact" checkbutton.
now it works correctly
I do not know in the WoW 2.1.5 there is a SetShown
method. As far as I know, all APIs have been moved from version 9.x (Shadowlends) so most likely there is this method. If so, then can simplify the code slightly:
Instead this
if class_dropdown:IsShown() and subclass_dropdown:GetIndex() then
subclass_dropdown:Show()
else
subclass_dropdown:Hide()
end
and this
if subclass_dropdown:IsShown() and slot_dropdown:GetIndex() then
slot_dropdown:Show()
else
slot_dropdown:Hide()
end
Can be written one line
subclass_dropdown:SetShown(class_dropdown:IsShown() and subclass_dropdown:GetIndex())
and
slot_dropdown:SetShown(subclass_dropdown:IsShown() and slot_dropdown:GetIndex())
Looks nice. Just one thing, I've been meaning to look into this for a while: In the vanilla version of aux it was possible to select a slot without selecting a subclass. I removed this when porting to classic, but I don't remember if I did that because it was not possible anymore or just because it was easier this way and I was in a hurry to get it done. Would you know by any chance? This has been requested before and I just recently found out myself that this would be quite useful, playing a healer with mail/plate and looking for boe items with healing that could also be cloth/leather/mail. If this is still possible somehow that would change the requirements for this dropdown logic.
Checked and it doesn't seem to be possible. Merging this then. Thanks!
Since the ability to select the slot depends on the selection of the subclass, and the selection of the subclass depends on the selection of the class, then there is no need to constantly display these dropdown lists. Therefore, I made their hide when they cannot be used. And to look beautifully I added changing the point for the dropdown list of quality.
Demonstration: https://youtu.be/dVb9fKFBeXY