diff options
| author | Roy <roy.mail.net@gmail.com> | 2018-01-07 09:27:42 +0200 |
|---|---|---|
| committer | Roy <roy.mail.net@gmail.com> | 2018-01-07 09:27:42 +0200 |
| commit | dd18ae0c096a34048477297ba848a089a99eece1 (patch) | |
| tree | bf036a7fac1b0d1f0439fb0e039e15c491e3881a /Software/Visual_Studio/Tango.DragAndDrop | |
| parent | 6900c4dea48adb484efc9648e081b7b3f75bd60c (diff) | |
| download | Tango-dd18ae0c096a34048477297ba848a089a99eece1.tar.gz Tango-dd18ae0c096a34048477297ba848a089a99eece1.zip | |
Progress on machine designer...
Diffstat (limited to 'Software/Visual_Studio/Tango.DragAndDrop')
| -rw-r--r-- | Software/Visual_Studio/Tango.DragAndDrop/DragAndDropService.cs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Software/Visual_Studio/Tango.DragAndDrop/DragAndDropService.cs b/Software/Visual_Studio/Tango.DragAndDrop/DragAndDropService.cs index 52cb0d954..122954de8 100644 --- a/Software/Visual_Studio/Tango.DragAndDrop/DragAndDropService.cs +++ b/Software/Visual_Studio/Tango.DragAndDrop/DragAndDropService.cs @@ -45,6 +45,13 @@ namespace Tango.DragAndDrop private static Border _dragBorder; private const int MIN_DRAG_OFFSET = 8; + #region Events + + public static event EventHandler<FrameworkElement> DragStarted; + public static event EventHandler<FrameworkElement> DragEnded; + + #endregion + #region Delegates /// <summary> @@ -421,6 +428,8 @@ namespace Tango.DragAndDrop { if (Mouse.LeftButton == MouseButtonState.Pressed && _currentDragedElement != null) { + DragStarted?.Invoke(_currentDragedElement, _currentDragedElement); + var surface = GetDraggingSurface(_currentDragedElement); var rootElement = surface.Parent as FrameworkElement; @@ -473,6 +482,7 @@ namespace Tango.DragAndDrop } else { + DragEnded?.Invoke(_currentDragedElement, _currentDragedElement); DropDraggable(); } } |
