WoWInterface SVN PocketPlot

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /branches
    from Rev 31 to Rev 33
    Reverse comparison

Rev 31 → Rev 33

PocketPlot/pocketplot.lua
23,6 → 23,7
local coordframe = CreateFrame("Frame", nil, Minimap)
coordframe:SetHeight(28) --height of clock button
coordframe:SetWidth(60) --width of clock button
coordframe:EnableMouse(true)
local coords = coordframe:CreateFontString(nil, "OVERLAY")
coords:SetParent(coordframe)
local frames = { "Minimap",
144,7 → 145,8
 
--LFG ICON
MiniMapMeetingStoneBorder:Hide()
MiniMapMeetingStoneFrame:SetPoint("BOTTOMLEFT", Minimap, "BOTTOMLEFT", 55, 30)
MiniMapMeetingStoneFrame:ClearAllPoints()
MiniMapMeetingStoneFrame:SetPoint("BOTTOMLEFT", Minimap, "BOTTOMLEFT", 27, -3)
 
--MISC. THINGS TO HIDE
MiniMapWorldMapButton:Hide() --default keybinding for world map is M
168,13 → 170,11
local function CoordPosition()
local clockshown = TimeManagerClockButton:IsShown()
local coordshown = coordframe:IsShown()
clockTime:ClearAllPoints()
TimeManagerClockButton:ClearAllPoints()
coords:ClearAllPoints()
coordframe:ClearAllPoints()
if not PocketPlotDB.top then
if clockshown and not coordshown then
clockTime:SetPoint("CENTER")
TimeManagerClockButton:SetPoint("TOP", Minimap, "BOTTOM", 0, 0)
end
if coordshown and not clockshown then
182,14 → 182,12
coordframe:SetPoint("TOP", Minimap, "BOTTOM", 0, 0)
end
if clockshown and coordshown then
clockTime:SetPoint("LEFT")
TimeManagerClockButton:SetPoint("TOPLEFT", Minimap, "BOTTOMLEFT", 0, 0)
TimeManagerClockButton:SetPoint("TOPLEFT", Minimap, "BOTTOMLEFT", -10, 0)
coords:SetPoint("RIGHT")
coordframe:SetPoint("TOPRIGHT", Minimap, "BOTTOMRIGHT", 0, 0)
end
else
if clockshown and not coordshown then
clockTime:SetPoint("CENTER")
TimeManagerClockButton:SetPoint("BOTTOM", Minimap, "TOP", 0, 0)
end
if coordshown and not clockshown then
197,8 → 195,7
coordframe:SetPoint("BOTTOM", Minimap, "TOP", 0, 0)
end
if clockshown and coordshown then
clockTime:SetPoint("LEFT")
TimeManagerClockButton:SetPoint("BOTTOMLEFT", Minimap, "TOPLEFT", 0, 0)
TimeManagerClockButton:SetPoint("BOTTOMLEFT", Minimap, "TOPLEFT", -10, 0)
coords:SetPoint("RIGHT")
coordframe:SetPoint("BOTTOMRIGHT", Minimap, "TOPRIGHT", 0, 0)
end
233,11 → 230,13
end
_G[frame]:ClearAllPoints()
_G[frame]:SetPoint(PocketPlotDB[frame].r, UIParent, PocketPlotDB[frame].a, PocketPlotDB[frame].x, PocketPlotDB[frame].y)
_G["PP_old"..frame] = _G[frame].SetPoint
_G[frame].SetPoint = function(self, a,b,c,d,e, ...)
local a,b,c,d,e = PocketPlotDB[frame].r, UIParent, PocketPlotDB[frame].a, PocketPlotDB[frame].x, PocketPlotDB[frame].y
return _G["PP_old"..frame](self, a,b,c,d,e, ...)
end
if not _G["PP_old"..frame] then
_G["PP_old"..frame] = _G[frame].SetPoint
_G[frame].SetPoint = function(self, a,b,c,d,e, ...)
local a,b,c,d,e = PocketPlotDB[frame].r, UIParent, PocketPlotDB[frame].a, PocketPlotDB[frame].x, PocketPlotDB[frame].y
return _G["PP_old"..frame](self, a,b,c,d,e, ...)
end
end
end
 
local options = {
466,6 → 465,9
 
mover:SetScript("OnMouseDown", function() mover:StartMoving() end)
mover:SetScript("OnMouseUp", function() mover:StopMovingOrSizing() SetPosition(movershown) end)
coordframe:SetScript("OnEnter", function(self) GameTooltip:SetOwner(self, "ANCHOR_LEFT") GameTooltip:AddLine("Click to display the world map.") GameTooltip:Show() end)
coordframe:SetScript("OnLeave", function() GameTooltip:Hide() end)
coordframe:SetScript("OnMouseUp", function() WorldMapFrame:Show() end)
coordframe:SetScript("OnUpdate", function()
local coordx,coordy = GetPlayerMapPosition("player")
coords:SetFormattedText("%.1f/%.1f", coordx*100, coordy*100)