Permalink
Browse files

Added Panel.PaintingDragging

Added Panel.PaintingDragging to be true when we are paining a panel inside drag'n'drop.
  • Loading branch information...
1 parent f48891f commit a0cbd3d26ec4792ed46856f993fd69bde46f8d10 @robotboy655 robotboy655 committed Aug 7, 2014
Showing with 3 additions and 1 deletion.
  1. +3 −1 garrysmod/lua/includes/extensions/client/panel/dragdrop.lua
@@ -265,8 +265,10 @@ hook.Add( "DrawOverlay", "DragNDropPaint", function()
dist = dist / 512
surface.SetAlphaMultiplier( Alpha * dist )
+ v.PaintingDragging = true
v:PaintAt( ox + v.x - v:GetWide() / 2, oy + v.y - v:GetTall() / 2 ) // fill the gap between the top left corner and the mouse position
-
+ v.PaintingDragging = nil
+
end
surface.SetAlphaMultiplier( 1.0 )

0 comments on commit a0cbd3d

Please sign in to comment.