mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-01-18 06:29:44 +08:00
Fix different grid layout shown by editor than the engine (#4758)
This commit is contained in:
parent
a935d69408
commit
11df74c292
@ -568,6 +568,7 @@ namespace FancyZonesEditor
|
||||
left += cellWidth + spacing;
|
||||
}
|
||||
|
||||
int zoneNumber = 1;
|
||||
for (int row = 0; row < rows; row++)
|
||||
{
|
||||
for (int col = 0; col < cols; col++)
|
||||
@ -582,7 +583,7 @@ namespace FancyZonesEditor
|
||||
top = _rowInfo[row].Start;
|
||||
Canvas.SetLeft(zone, left);
|
||||
Canvas.SetTop(zone, top);
|
||||
zone.LabelID.Content = i + 1;
|
||||
zone.LabelID.Content = zoneNumber++;
|
||||
|
||||
int maxRow = row;
|
||||
while (((maxRow + 1) < rows) && (model.CellChildMap[maxRow + 1, col] == i))
|
||||
|
@ -329,9 +329,9 @@ namespace FancyZonesEditor
|
||||
}
|
||||
|
||||
int index = ZoneCount - 1;
|
||||
for (int row = rows - 1; row >= 0; row--)
|
||||
for (int col = cols - 1; col >= 0; col--)
|
||||
{
|
||||
for (int col = cols - 1; col >= 0; col--)
|
||||
for (int row = rows - 1; row >= 0; row--)
|
||||
{
|
||||
_gridModel.CellChildMap[row, col] = index--;
|
||||
if (index < 0)
|
||||
|
Loading…
Reference in New Issue
Block a user