Ignore:
Timestamp:
Dec 8, 2023, 12:28:23 PM (11 months ago)
Author:
chronos
Message:
  • Fixed: Map scrolling with mouse to right and bottom sides in high DPI.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LocalPlayer/Term.pas

    r483 r485  
    47424742      MainMap.SetPaintBounds(0, 0, UsedOffscreenWidth, UsedOffscreenHeight);
    47434743    MapValid := False;
    4744     OffscreenUser := self;
     4744    OffscreenUser := Self;
    47454745  end;
    47464746
     
    56445644          EOT.SetButtonIndexFast(eotBlinkOn);
    56455645      end;
    5646     end
    5647     else
    5648     begin
     5646    end else begin
    56495647      if Application.Active and not mScrollOff.Checked then
    56505648      begin
     
    56535651        dx := 0;
    56545652        dy := 0;
    5655         if Mouse.CursorPos.Y < Screen.height - PanelHeight then
     5653        if Mouse.CursorPos.Y < Screen.Height - PanelHeight then
    56565654          if Mouse.CursorPos.X = 0 then
    56575655            dx := -ScrollSpeed // scroll left
    5658           else if Mouse.CursorPos.X = Screen.width - 1 then
     5656          else if Mouse.CursorPos.X >= Screen.Width - 1 then
    56595657            dx := ScrollSpeed; // scroll right
    56605658        if Mouse.CursorPos.Y = 0 then
    56615659          dy := -ScrollSpeed // scroll up
    5662         else if (Mouse.CursorPos.Y = Screen.height - 1) and
    5663           (Mouse.CursorPos.X >= TerrainBtn.Left + TerrainBtn.width) and
     5660        else if (Mouse.CursorPos.Y >= Screen.Height - 1) and
     5661          (Mouse.CursorPos.X >= TerrainBtn.Left + TerrainBtn.Width) and
    56645662          (Mouse.CursorPos.X < xRightPanel + 10 - 8) then
    56655663          dy := ScrollSpeed; // scroll down
Note: See TracChangeset for help on using the changeset viewer.