Changeset 610 for trunk/LocalPlayer
- Timestamp:
- Sep 13, 2024, 8:12:07 PM (2 months ago)
- Location:
- trunk/LocalPlayer
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LocalPlayer/PVSB.pas
r508 r610 54 54 Self.Max := Max; 55 55 ScrollBar.Position := 0; 56 ScrollBar.Visible := Max > =ScrollBar.PageSize;56 ScrollBar.Visible := Max > ScrollBar.PageSize; 57 57 end; 58 58 -
trunk/LocalPlayer/Term.pas
r592 r610 12 12 {$ENDIF} 13 13 Protocol, Tribes, PVSB, ClientTools, ScreenTools, BaseWin, Messg, ButtonBase, 14 LCLIntf, LCLType, SysUtils, Classes, DrawDlg, Types, 14 LCLIntf, LCLType, SysUtils, Classes, DrawDlg, Types, Math, 15 15 DateUtils, Platform, ButtonB, ButtonC, EOTButton, Area, 16 16 GraphicSet, MiniMap, IsoEngine, Wonders, TechTree, Enhance, Nego, CityType, … … 315 315 Panel: TBitmap; 316 316 TopBar: TBitmap; 317 VerticalScrollBar: TPVScroll bar;317 VerticalScrollBar: TPVScrollBar; 318 318 Closable: Boolean; 319 319 RepaintOnResize: Boolean; … … 5085 5085 with MyUn^[UnFocus] do 5086 5086 with MyModel^[mix] do 5087 if (Me >= 0) and (Me < nPl) then 5087 5088 begin { display info about selected unit } 5088 5089 if Job = jCity then … … 5168 5169 begin 5169 5170 if (Count >= TrRow * VerticalScrollBar.Position) and 5170 (Count < TrRow * (VerticalScrollBar.Position + 1)) then 5171 (Count < TrRow * (VerticalScrollBar.Position + 1)) and 5172 (Me >= 0) and (Me < nPl) then 5171 5173 begin 5172 5174 trix[Count - TrRow * VerticalScrollBar.Position] := uix; … … 6886 6888 else 6887 6889 begin 6888 VerticalScrollBar.Init( (TrCnt + TrRow - 1) div TrRow - 1, 1);6890 VerticalScrollBar.Init(Ceil(TrCnt / TrRow), 1); 6889 6891 if (VerticalScrollBar.Max >= VerticalScrollBar.PageSize) and (trixFocus >= 0) then 6890 6892 VerticalScrollBar.Position := trixFocus div TrRow; … … 8415 8417 procedure TMainScreen.ScrollBarUpdate(Sender: TObject); 8416 8418 begin 8419 {$IFDEF UNIX} 8420 // Do not scroll with mouse wheel to and above max value 8421 if VerticalScrollBar.Position > VerticalScrollBar.Max - 1 then 8422 VerticalScrollBar.Position := VerticalScrollBar.Max - 1; 8423 {$ENDIF} 8417 8424 PanelPaint; 8418 8425 Update;
Note:
See TracChangeset
for help on using the changeset viewer.