Skip to content
This repository was archived by the owner on Nov 28, 2024. It is now read-only.

Commit 773ddf8

Browse files
committed
Redraw the row after canceling inline editing to avoid showing stale content.
1 parent 2d310d3 commit 773ddf8

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

Controls/Grid/Grid.UWP/View/Services/Editing/EditingService.cs

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using System;
1+
using System;
22
using System.Collections.Generic;
33
using System.Linq;
44
using System.Text;
@@ -181,27 +181,30 @@ public bool CancelEdit(ActionTrigger trigger)
181181
if (trigger != ActionTrigger.ExternalEditor)
182182
{
183183
this.Owner.ExternalEditor.CancelEdit();
184+
this.Owner.CurrencyService.RefreshCurrentItem(true);
184185
}
185186
}
186187
else
187188
{
188189
this.Owner.Model.CancelEdit();
189190
this.Owner.EditRowLayer.EditorLayoutSlots.Clear();
191+
this.Owner.CurrencyService.RefreshCurrentItem(true);
190192
}
191193

192194
this.Owner.Model.CurrentDataProvider.CancelEditOperation(this.EditItem);
193195
})
194196
{
195-
Flags = UpdateFlags.AffectsContent
197+
Flags = UpdateFlags.AffectsData
196198
};
197199

198-
this.Owner.updateService.RegisterUpdate(update);
199-
200200
foreach (var pair in this.operation.OriginalValues)
201201
{
202202
pair.Key.SetValueForInstance(this.operation.EditItemInfo.Item, pair.Value);
203203
}
204204

205+
this.Owner.updateService.RegisterUpdate(update);
206+
207+
205208
if (this.operation.EditMode == DataGridUserEditMode.Inline)
206209
{
207210
this.Owner.EditRowLayer.EditorLayoutSlots.Clear();

0 commit comments

Comments
 (0)