Ignore:
Timestamp:
Dec 18, 2023, 10:31:54 PM (11 months ago)
Author:
chronos
Message:
  • Modified: Code cleanup.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LocalPlayer/TechTree.pas

    r468 r496  
    9999        ClientHeight - BlackBorder, -BlackBorder - xOffset,
    100100        -BlackBorder - yOffset, Paper);
    101     if xOffset + Image.width < ClientWidth - 2 * BlackBorder then
    102       FillRectSeamless(Canvas, BlackBorder + xOffset + Image.width, BlackBorder,
     101    if xOffset + Image.Width < ClientWidth - 2 * BlackBorder then
     102      FillRectSeamless(Canvas, BlackBorder + xOffset + Image.Width, BlackBorder,
    103103        ClientWidth - BlackBorder, ClientHeight - BlackBorder,
    104104        -BlackBorder - xOffset, -BlackBorder - yOffset, Paper);
    105105    X := Max(BlackBorder, BlackBorder + xOffset);
    106     W := Min(BlackBorder + xOffset + Image.width, ClientWidth - BlackBorder);
     106    W := Min(BlackBorder + xOffset + Image.Width, ClientWidth - BlackBorder);
    107107    if yOffset > 0 then
    108108      FillRectSeamless(Canvas, X, BlackBorder, W, BlackBorder + yOffset,
    109109        -BlackBorder - xOffset, -BlackBorder - yOffset, Paper);
    110     if yOffset + Image.height < ClientHeight - 2 * BlackBorder then
    111       FillRectSeamless(Canvas, X, BlackBorder + yOffset + Image.height, W,
     110    if yOffset + Image.Height < ClientHeight - 2 * BlackBorder then
     111      FillRectSeamless(Canvas, X, BlackBorder + yOffset + Image.Height, W,
    112112        ClientHeight - BlackBorder, -BlackBorder - xOffset,
    113113        -BlackBorder - yOffset, Paper);
     
    115115  BitBltCanvas(Canvas, Max(BlackBorder, BlackBorder + xOffset),
    116116    Max(BlackBorder, BlackBorder + yOffset),
    117     Min(Image.width, Min(Image.width + xOffset,
     117    Min(Image.Width, Min(Image.Width + xOffset,
    118118    Min(ClientWidth - 2 * BlackBorder, ClientWidth - 2 * BlackBorder - xOffset))
    119     ), Min(Image.height, Min(Image.height + yOffset,
     119    ), Min(Image.Height, Min(Image.Height + yOffset,
    120120    Min(ClientHeight - 2 * BlackBorder, ClientHeight - 2 * BlackBorder -
    121121    yOffset))), Image.Canvas, Max(0, -xOffset),
     
    177177    (Screen.Height - NewHeight) div 2,
    178178    NewWidth, NewHeight);
    179   CloseBtn.Left := width - CloseBtn.width - BlackBorder - 8;
     179  CloseBtn.Left := Width - CloseBtn.Width - BlackBorder - 8;
    180180  CloseBtn.Top := BlackBorder + 8;
    181181  xOffset := (ClientWidth - Image.Width + LeftBorder - RightBorder) div 2 -
     
    213213    if xOffset > LeftBorder then
    214214      xOffset := LeftBorder;
    215     if xOffset < ClientWidth - 2 * BlackBorder - Image.width - RightBorder then
    216       xOffset := ClientWidth - 2 * BlackBorder - Image.width - RightBorder;
     215    if xOffset < ClientWidth - 2 * BlackBorder - Image.Width - RightBorder then
     216      xOffset := ClientWidth - 2 * BlackBorder - Image.Width - RightBorder;
    217217    if yOffset > TopBorder then
    218218      yOffset := TopBorder;
    219     if yOffset < ClientHeight - 2 * BlackBorder - Image.height - BottomBorder
     219    if yOffset < ClientHeight - 2 * BlackBorder - Image.Height - BottomBorder
    220220    then
    221       yOffset := ClientHeight - 2 * BlackBorder - Image.height - BottomBorder;
     221      yOffset := ClientHeight - 2 * BlackBorder - Image.Height - BottomBorder;
    222222
    223223    SmartInvalidate;
Note: See TracChangeset for help on using the changeset viewer.