From d4af394bac513bcaf693cdb94ee47e0617f14c85 Mon Sep 17 00:00:00 2001 From: rich2014 Date: Fri, 13 Oct 2023 16:13:33 +0800 Subject: [PATCH] Cocoa/TabControl: clean up --- lcl/interfaces/cocoa/cocoatabcontrols.pas | 3 --- 1 file changed, 3 deletions(-) diff --git a/lcl/interfaces/cocoa/cocoatabcontrols.pas b/lcl/interfaces/cocoa/cocoatabcontrols.pas index 210d6f06ce..48e7c40967 100644 --- a/lcl/interfaces/cocoa/cocoatabcontrols.pas +++ b/lcl/interfaces/cocoa/cocoatabcontrols.pas @@ -63,7 +63,6 @@ type { various indexes in fulltabs } currentIndex : Integer; // index of the current tab visibleLeftIndex: Integer; // index shown in TabView on the left - visibleRightIndex: Integer; // index shown in TabView on the right leftKeepAmount: Integer; // left tab amount to keep, equals currentIndex-visibleLeftIndex procedure attachAllTabs; message 'attachAllTabs'; @@ -487,11 +486,9 @@ procedure TCocoaTabControl.updateVariousIndex; begin if numberOfTabViewItems > 0 then begin visibleLeftIndex:= fulltabs.indexOfObject( tabViewItemAtIndex(0) ); - visibleRightIndex:= visibleLeftIndex + numberOfTabViewItems - 1; leftKeepAmount:= currentIndex - visibleLeftIndex; end else begin visibleLeftIndex:= -1; - visibleRightIndex:= -1; leftKeepAmount:= 0; end; end;