Quantcast

Only hide the tooltip if the control key is down.

Scott Sibley [10-20-10 - 08:01]
Only hide the tooltip if the control key is down.
Filename
Modules/Nameplates/Nameplates.lua
diff --git a/Modules/Nameplates/Nameplates.lua b/Modules/Nameplates/Nameplates.lua
index 939319c..ab504c4 100644
--- a/Modules/Nameplates/Nameplates.lua
+++ b/Modules/Nameplates/Nameplates.lua
@@ -103,10 +103,19 @@ function update()
 				local x, y = GetCursorPosition()
 				anchor:ClearAllPoints()
 				anchor:SetPoint("BOTTOMLEFT", UIParent, "BOTTOMLEFT", x - size / 2, y - size / 2)
-				if PluginUtils.Intersect(anchor, frame) then
+				if PluginUtils.Intersect(anchor, frame) and IsControlKeyDown() then
 					GameTooltip:Hide()
+					break
 				end
 			end
 		end
 	end
 end
+
+function mod:OnHide()
+	self.timer:Stop()
+end
+
+function mod:SetUnit()
+	self.timer:Start()
+end