Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix DataGrid IList editing issue #13845

Merged
merged 2 commits into from
Dec 7, 2023
Merged

Fix DataGrid IList editing issue #13845

merged 2 commits into from
Dec 7, 2023

Conversation

maxkatz6
Copy link
Member

@maxkatz6 maxkatz6 commented Dec 6, 2023

What does the pull request do?

Fixes 11.0.6/master issue regressed by #13313
Personally, I would consider reverting previous PR, as DataGridCollectionView isn't really intended to be used outside of the DataGrid (...duh).
But this PR attempts to fix current behavior, hopefully without breaking anything else.

Fixed issues

Fixes #13843

@maxkatz6 maxkatz6 added bug area-datagrid backport-candidate-11.0.x Consider this PR for backporting to 11.0 branch labels Dec 6, 2023
@maxkatz6
Copy link
Member Author

maxkatz6 commented Dec 6, 2023

Specifically that issue was caused by this property always returning false:

public bool AllowEdit
{
get
{
if (List == null)
{
return true;
}
else
{
return !List.IsReadOnly;
}
}
}

@maxkatz6 maxkatz6 requested a review from grokys December 6, 2023 07:49
@avaloniaui-bot
Copy link

You can test this PR using the following package version. 11.1.999-cibuild0042686-beta. (feed url: https://nuget-feed-all.avaloniaui.net/v3/index.json) [PRBUILDID]

Copy link
Member

@grokys grokys left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm fine with reverting #13313, but if this fixes everything then even better.

@maxkatz6 maxkatz6 added this pull request to the merge queue Dec 7, 2023
Merged via the queue into master with commit 5625f54 Dec 7, 2023
6 checks passed
@maxkatz6 maxkatz6 deleted the fix-datagrid-ilist-issue branch December 7, 2023 11:16
@maxkatz6 maxkatz6 added backported-11.0.x and removed backport-candidate-11.0.x Consider this PR for backporting to 11.0 branch labels Jan 17, 2024
maxkatz6 added a commit that referenced this pull request Jan 17, 2024
* Implement basic writeable IList on DataGridCollectionView hopefully it won't break anything else

* Make preference over DataGridCollectionView in DataGridDataConnection
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unable to edit DataGrid values
3 participants