From 1d27c000f0d35bc34b180725b990c0bd56a6e658 Mon Sep 17 00:00:00 2001 From: k-m_schindler Date: Thu, 22 May 2008 22:24:58 +0000 Subject: removal of TMenu.InRegion and InStaticRegion. no actual use, at best speculative for mouse git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@1124 b956fd51-792f-4845-bead-9b4dfca2ff2c --- Game/Code/Menu/UMenu.pas | 22 ---------------------- 1 file changed, 22 deletions(-) (limited to 'Game/Code') diff --git a/Game/Code/Menu/UMenu.pas b/Game/Code/Menu/UMenu.pas index 5fe7d317..9c467e7d 100644 --- a/Game/Code/Menu/UMenu.pas +++ b/Game/Code/Menu/UMenu.pas @@ -113,7 +113,6 @@ type procedure AddSelectSlideOption(SelectNo: Cardinal; const AddText: string); overload; procedure UpdateSelectSlideOptions(ThemeSelectSlide: TThemeSelectSlide; SelectNum: integer; Values: array of string; var Data: integer); - // function AddWidget(X, Y : UInt16; WidgetSrc : PSDL_Surface): Int16; // procedure ClearWidgets(MinNumber : Int16); procedure FadeTo(Screen: PMenu); overload; @@ -128,8 +127,6 @@ type // FIXME: ParseMouse is not implemented in any subclass and not even used anywhere in the code // -> do this before activation of this method //function ParseMouse(Typ: integer; X: integer; Y: integer): Boolean; virtual; abstract; - function InRegion(X1, Y1, X2, Y2, X, Y: real): Boolean; - function InStaticRegion(StaticNr: integer; X, Y: integer): Boolean; procedure onShow; virtual; procedure onShowFinish; virtual; procedure onHide; virtual; @@ -1418,25 +1415,6 @@ begin SelectsS[SelectNum].SelectedOption := Data; end; -function TMenu.InRegion(X1, Y1, X2, Y2, X, Y: real): boolean; -var - scaled_x, scaled_y : real; -begin - { RenderW and RenderH are defined in Classes/UGraphic.pas } - scaled_x := x*640.0/RenderW; - scaled_y := x*480.0/RenderH; - Result := (X1 <= scaled_x) and (scaled_x <= X2) and (Y1 <= scaled_y) and (scaled_y <= Y2); -end; - -function TMenu.InStaticRegion(StaticNr: integer; X, Y: integer): boolean; -begin - Result := InRegion(Static[StaticNr].Texture.X, - Static[StaticNr].Texture.Y, - Static[StaticNr].Texture.X + Static[StaticNr].Texture.W - 1, - Static[StaticNr].Texture.Y + Static[StaticNr].Texture.H - 1, - X, Y); -end; - procedure TMenu.InteractInc; var Num: integer; -- cgit v1.2.3