aboutsummaryrefslogtreecommitdiffstats
path: root/src/menu/UMenuButton.pas
diff options
context:
space:
mode:
Diffstat (limited to 'src/menu/UMenuButton.pas')
-rw-r--r--src/menu/UMenuButton.pas68
1 files changed, 36 insertions, 32 deletions
diff --git a/src/menu/UMenuButton.pas b/src/menu/UMenuButton.pas
index 868a86f3..509c140b 100644
--- a/src/menu/UMenuButton.pas
+++ b/src/menu/UMenuButton.pas
@@ -125,6 +125,7 @@ implementation
uses
SysUtils,
+ UDisplay,
UDrawTexture;
procedure TButton.SetX(Value: real);
@@ -534,42 +535,45 @@ end;
function TButton.GetMouseOverArea: TMouseOverRect;
begin
- if (FadeTex.TexNum = 0) then
- begin
- Result.X := Texture.X;
- Result.Y := Texture.Y;
- Result.W := Texture.W;
- Result.H := Texture.H;
- end
- else
+ if (Display.Cursor_HiddenByScreen = false) then
begin
- case FadeTexPos of
- 0: begin // fade tex on top
- Result.X := Texture.X;
- Result.Y := FadeTex.Y;
- Result.W := Texture.W;
- Result.H := FadeTex.H + Texture.H;
- end;
+ if (FadeTex.TexNum = 0) then
+ begin
+ Result.X := Texture.X;
+ Result.Y := Texture.Y;
+ Result.W := Texture.W;
+ Result.H := Texture.H;
+ end
+ else
+ begin
+ case FadeTexPos of
+ 0: begin // fade tex on top
+ Result.X := Texture.X;
+ Result.Y := FadeTex.Y;
+ Result.W := Texture.W;
+ Result.H := FadeTex.H + Texture.H;
+ end;
- 1: begin // fade tex on left side
- Result.X := FadeTex.X;
- Result.Y := Texture.Y;
- Result.W := FadeTex.W + Texture.W;
- Result.H := Texture.H;
- end;
+ 1: begin // fade tex on left side
+ Result.X := FadeTex.X;
+ Result.Y := Texture.Y;
+ Result.W := FadeTex.W + Texture.W;
+ Result.H := Texture.H;
+ end;
- 2: begin // fade tex on bottom
- Result.X := Texture.X;
- Result.Y := Texture.Y;
- Result.W := Texture.W;
- Result.H := FadeTex.H + Texture.H;
- end;
+ 2: begin // fade tex on bottom
+ Result.X := Texture.X;
+ Result.Y := Texture.Y;
+ Result.W := Texture.W;
+ Result.H := FadeTex.H + Texture.H;
+ end;
- 3: begin // fade tex on right side
- Result.X := Texture.X;
- Result.Y := Texture.Y;
- Result.W := FadeTex.W + Texture.W;
- Result.H := Texture.H;
+ 3: begin // fade tex on right side
+ Result.X := Texture.X;
+ Result.Y := Texture.Y;
+ Result.W := FadeTex.W + Texture.W;
+ Result.H := Texture.H;
+ end;
end;
end;
end;