Skip to content

Commit

Permalink
Merge pull request #225 from unoplatform/mergify/bp/unorel/winui/7.1.…
Browse files Browse the repository at this point in the history
…200/pr-224

fix(DataGrid): not displaying cells from last columns when resized from scrolled state (backport #224)
  • Loading branch information
jeromelaban authored Nov 18, 2024
2 parents 7b3d97d + c90b056 commit c51a04f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1245,6 +1245,14 @@ private bool ComputeDisplayedColumns()
_horizontalOffset -= GetEdgedColumnWidth(dataGridColumn);
dataGridColumn = this.ColumnsInternal.GetPreviousVisibleScrollingColumn(dataGridColumn);
}

if (_horizontalOffset == 0 && cx < displayWidth)
{
// if the columns have been scrolled, and all visible columns are fully rendered in the available space,
// then HorizontalAdjustment needs to be updated so that DataGridCellsPresenter.ShouldDisplayCell
// don't hide columns based on the old value.
HorizontalAdjustment = displayWidth - cx;
}
}

// third try to partially scroll in first scrolled off column
Expand Down
1 change: 0 additions & 1 deletion nuget.config
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
<clear />
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" />
<add key="AzureLatest" value="https://pkgs.dev.azure.com/dotnet/CommunityToolkit/_packaging/CommunityToolkit-MainLatest/nuget/v3/index.json" protocolVersion="3" />
<add key="MUX-Shared" value="https://pkgs.dev.azure.com/ms/microsoft-ui-xaml/_packaging/MUX-Shared/nuget/v3/index.json" />
<add key="unoplatformdev" value="https://pkgs.dev.azure.com/uno-platform/1dd81cbd-cb35-41de-a570-b0df3571a196/_packaging/unoplatformdev/nuget/v3/index.json" />
</packageSources>
<disabledPackageSources>
Expand Down

0 comments on commit c51a04f

Please sign in to comment.