Mercurial > wow > worldplan
diff QuestPOI.lua @ 56:0749e38081e7
- More fixes for map updates from non-Legion zones.
author | Nenue |
---|---|
date | Tue, 03 Jan 2017 20:04:16 -0500 |
parents | 6a2e85836219 |
children | 54aa7f8ebca8 |
line wrap: on
line diff
--- a/QuestPOI.lua Sat Dec 31 17:48:25 2016 -0500 +++ b/QuestPOI.lua Tue Jan 03 20:04:16 2017 -0500 @@ -28,6 +28,9 @@ local dprint = DEVIAN_WORKSPACE and function(...) _G.print('WQData', ...) end or function() end local QuestPOI = WorldPlanPOIMixin +local pinBaseIndex = 1300 +local overlayBaseIndex = 1350 +local previousHighlight local PIN_REFRESH_DELAY = .5 local PIN_REQUEST_DELAY = .1 @@ -188,11 +191,21 @@ local GetFactionInfoByID, GetQuestObjectiveInfo = GetFactionInfoByID, GetQuestObjectiveInfo function QuestPOI:OnEnter() - if not WorldMapFrame:IsVisible() then - end + WorldMap_HijackTooltip(self.owningFrame); if self.filtered then return end + self:SetFrameLevel(pinBaseIndex+100) + self.Overlay:SetFrameLevel(pinBaseIndex+101) + + if previousHighlight then + previousHighlight:SetFrameLevel(pinBaseIndex+previousHighlight:GetID()) + previousHighlight.Overlay:SetFrameLevel(overlayBaseIndex+previousHighlight:GetID()) + end + + previousHighlight = self + + WorldMapTooltip:SetOwner(self, "ANCHOR_RIGHT"); --print('doing tooltip stuff') @@ -422,12 +435,11 @@ self.Overlay:SetShown(false) end -local overlayBaseIndex = 1300 function QuestPOI:SetAnchor(owner, dX, dY, mapWidth, mapHeight) wqprint(self:GetName()..':SetAnchor', self.filtered, self.used) self:SetParent(owner) self:ClearAllPoints() - self:SetFrameLevel(overlayBaseIndex + self:GetID()) + self:SetFrameLevel(pinBaseIndex + self:GetID()) self.Overlay:SetParent(owner) self.Overlay:SetFrameLevel(overlayBaseIndex + self:GetID()) if (dX and dY) then @@ -694,6 +706,7 @@ local iconTexture = self.itemTexture + self:SetSize(highlightWidth, highlightWidth) if self.questID == GetSuperTrackedQuestID() then highlightWidth = highlightWidth + 2 end @@ -702,7 +715,6 @@ highlightWidth = highlightWidth + self.rarity end self.tagIcon:SetSize(self.tagSize, self.tagSize) - self:SetSize(iconWidth, iconWidth) icon:SetSize(iconWidth, iconWidth) iconBorder:SetSize(borderWidth, borderWidth) trackingBorder:SetSize(highlightWidth, highlightWidth)