What Changed
Starting with v20.2, the DiagramControl uses the IListSource.GetList method to obtain data from all sources that implement the IListSource interface.
Reasons for Change
In previous versions, the DiagramControl's data binding engine prioritized the IEnumerable interface over the IListSource. This issue prevented data update notifications for data sources that implement both interfaces (for instance, TypedTableBase).
Impact on Existing Apps
This change affects the data type of a diagram item when the DiagramControl is bound to a DataTable source. The code snippet below illustrates this scenario.
C#void DataController_GenerateItem(object sender, DiagramGenerateItemEventArgs e) {
DataRow row = (DataRow)e.DataObject;
///code
}
In this scenario, convert the DataObject type to the DataRowView instead.
C#void DataController_GenerateItem(object sender, DiagramGenerateItemEventArgs e) {
DataRowView row = (DataRowView)e.DataObject;
///code
}
How to Revert to Previous Behavior
Set the DevExpress.Xpf.Core.CompatibilitySettings.PrioritizeIListSourceInDiagramDataBinding static property to false to revert to the previous behavior.