View Single Post
07-28-14, 05:49 AM   #4
ObbleYeah
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Sep 2008
Posts: 210
Originally Posted by sezz View Post
FramePositionDelegate:UIParentManageFramePositions() resets the position anyways (the check for IsUserPlaced()) is gone - any simple workarounds yet?
does it? This is working fine for me on the beta. Simple 6.0 update to zork's rWatchFrameMover method

Lua Code:
  1. local watchframeheight = 450
  2.  
  3.     local function MMFMWF_Tooltip(self)
  4.         GameTooltip:SetOwner(self, "ANCHOR_TOP")
  5.         GameTooltip:AddLine("• Drag to move", 0, 1, 0.5, 1, 1, 1)
  6.         GameTooltip:Show()
  7.     end
  8.  
  9.     -- remove the former when 6.0 hits
  10.     local wf = WatchFrame or ObjectiveTrackerFrame
  11.     wf:SetClampedToScreen(true)
  12.     wf:SetMovable(true)
  13.     wf:SetUserPlaced(true)
  14.     wf:ClearAllPoints()
  15.     wf.ClearAllPoints = function() end
  16.     wf:SetPoint("TOP", MinimapCluster, "BOTTOM", 0, -20)
  17.     wf.SetPoint = function() end
  18.     wf:SetHeight(watchframeheight)
  19.  
  20.     local wfhmoveframe = CreateFrame("FRAME", nil, wf)
  21.     wfhmoveframe:SetHeight(16)
  22.     wfhmoveframe:SetPoint("TOPLEFT", wf, "TOPLEFT", 150, 0)
  23.     wfhmoveframe:SetPoint("TOPRIGHT", wf, "TOPRIGHT")
  24.     wfhmoveframe:EnableMouse(true)
  25.     wfhmoveframe:RegisterForDrag("LeftButton")
  26.     wfhmoveframe:SetHitRectInsets(-5, -5, -5, -5)
  27.    
  28.     wfhmoveframe:SetScript("OnDragStart", function(s)
  29.         local f = s:GetParent()
  30.         f:StartMoving()
  31.     end)
  32.    
  33.     wfhmoveframe:SetScript("OnDragStop", function(s)
  34.         local f = s:GetParent()
  35.         f:StopMovingOrSizing()
  36.     end)
  37.    
  38.     wfhmoveframe:SetScript("OnEnter", function(s)
  39.         MMFMWF_Tooltip(s)
  40.     end)