Skip to content

Commit

Permalink
Fix #129: RadioMenuItem IsChecked doesn't update correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
Kinnara committed Jul 12, 2020
1 parent 313e3ca commit cb1398e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ModernWpf.Controls/RadioMenuItem/RadioMenuItem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ private void UpdateSiblings()
if (IsChecked)
{
// Since this item is checked, uncheck all siblings
if (Parent is ItemsControl parent)
if (ItemsControlFromItemContainer(this) is { } parent)
{
int childrenCount = parent.Items.Count;
for (int i = 0; i < childrenCount; i++)
Expand Down

0 comments on commit cb1398e

Please sign in to comment.