summaryrefslogtreecommitdiff
path: root/UMain.pas
diff options
context:
space:
mode:
authorTomas Bzatek <tbzatek@redhat.com>2024-10-08 21:23:56 +0200
committerTomas Bzatek <tbzatek@redhat.com>2024-10-08 21:26:21 +0200
commit81c8cd22e61701c1145dc267b0925add6cc0e78a (patch)
tree3ffeb2559f408091c858391a03285219d0ddf2c9 /UMain.pas
parent4c77a4ae178e207446312a273d2bf7fedf7fb7ff (diff)
downloadtuxcmd-0.6.80.tar.xz
Fix list view column reorderingv0.6.80
This causes a little bit of flicker, but avoids race condition somewhere.
Diffstat (limited to 'UMain.pas')
-rw-r--r--UMain.pas10
1 files changed, 7 insertions, 3 deletions
diff --git a/UMain.pas b/UMain.pas
index 9f624ad..bce9d75 100644
--- a/UMain.pas
+++ b/UMain.pas
@@ -1087,6 +1087,10 @@ begin
ListView.SelectionMode := smBrowse;
GetFirstLastPanelColumn(FirstColumn, LastColumn);
+ // Temporarily disable the fixed height mode to be able to add columns the Pascal way
+ if Application.GTKVersion_2_12_0_Up then
+ g_object_set(ListView.FWidget, 'fixed_height_mode', 0, nil);
+
for i := 1 to ConstNumPanelColumns do
if ConfColumnVisible[i] then begin
@@ -5199,9 +5203,8 @@ begin
end;
Application.ProcessMessages;
-{ RebuildListViewsTimer.Interval := 100;
- RebuildListViewsTimer.Enabled := True; }
- RebuildListViewsTimerTimer(Self);
+ RebuildListViewsTimer.Interval := 1;
+ RebuildListViewsTimer.Enabled := True;
gtk_tree_view_set_headers_visible(PGtkTreeView(SourceListView.FWidget), False);
gtk_tree_view_set_headers_visible(PGtkTreeView(SourceListView.FWidget), True);
end;
@@ -5222,6 +5225,7 @@ begin
ConstructColumns(RightListView);
InactiveItemsTimer.Enabled := False;
if DoRefresh then begin
+ Application.ProcessMessages;
FMain.DoRefresh(True, True, True);
FMain.DoRefresh(False, True, True);
LeftListView.SetSortInfo(ConfMainWindowLeftSortColumn, TGTKTreeViewSortOrder(ConfMainWindowLeftSortType));