From c5cde62cecfdd413e9902b26b30b0d4dfd05a24d Mon Sep 17 00:00:00 2001 From: Roy Ben-Shabat Date: Thu, 14 Mar 2019 13:25:32 +0200 Subject: Machine Studio v4.0.10 PPC v1.0.9 --- .../Tango.Touch/Controls/LightTouchDataGrid.cs | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) (limited to 'Software/Visual_Studio/Tango.Touch/Controls') diff --git a/Software/Visual_Studio/Tango.Touch/Controls/LightTouchDataGrid.cs b/Software/Visual_Studio/Tango.Touch/Controls/LightTouchDataGrid.cs index f098af31d..552543320 100644 --- a/Software/Visual_Studio/Tango.Touch/Controls/LightTouchDataGrid.cs +++ b/Software/Visual_Studio/Tango.Touch/Controls/LightTouchDataGrid.cs @@ -555,16 +555,14 @@ namespace Tango.Touch.Controls current_top += (ordered[i].Margin.Top + ordered[i].ActualHeight + ordered[i].Margin.Bottom); - if (contentPresenter.Tag == null) - { - LightTouchDataGridRow row = contentPresenter.FindChild(); + LightTouchDataGridRow row = contentPresenter.FindChild(); - if (row != null) - { - contentPresenter.Tag = 1; - row.RegisterForPreviewMouseOrTouchUp(OnRowMouseTouchUp); - row.RegisterForPreviewMouseOrTouchDown(OnRowMouseTouchDown); - } + if (row != null) + { + row.UnRegisterMouseOrTouch(OnRowMouseTouchUp); + row.RegisterForPreviewMouseOrTouchUp(OnRowMouseTouchUp); + row.UnRegisterMouseOrTouch(OnRowMouseTouchDown); + row.RegisterForPreviewMouseOrTouchDown(OnRowMouseTouchDown); } } -- cgit v1.3.1