Merge pull request #3544 from Flow-Launcher/width-issue

Fix size changed width issue
This commit is contained in:
Jack Ye 2025-05-14 14:38:14 +08:00 committed by GitHub
commit 8522d781a7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 6 deletions

View file

@ -432,6 +432,9 @@ namespace Flow.Launcher.Plugin.Program.Views
var workingWidth =
listView.ActualWidth - SystemParameters.VerticalScrollBarWidth; // take into account vertical scrollbar
if (workingWidth <= 0) return;
var col1 = 0.25;
var col2 = 0.15;
var col3 = 0.60;

View file

@ -21,16 +21,15 @@ namespace Flow.Launcher.Plugin.Sys
ListView listView = sender as ListView;
GridView gView = listView.View as GridView;
var workingWidth = listView.ActualWidth - SystemParameters.VerticalScrollBarWidth; // take into account vertical scrollbar
var workingWidth =
listView.ActualWidth - SystemParameters.VerticalScrollBarWidth; // take into account vertical scrollbar
if (workingWidth <= 0) return;
var col1 = 0.2;
var col2 = 0.6;
var col3 = 0.2;
if (workingWidth <= 0)
{
return;
}
gView.Columns[0].Width = workingWidth * col1;
gView.Columns[1].Width = workingWidth * col2;
gView.Columns[2].Width = workingWidth * col3;