mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-11 15:56:08 +02:00
MG: improved TScreen and ShowModal
git-svn-id: trunk@2954 -
This commit is contained in:
parent
db5b578e3b
commit
9c894eee04
@ -3441,10 +3441,11 @@ begin
|
||||
inherited Create(AOwner);
|
||||
|
||||
if LazarusResources.Find(ClassName)=nil then begin
|
||||
position := poScreenCenter;
|
||||
Position := poScreenCenter;
|
||||
Width := 250;
|
||||
Height := 100;
|
||||
Caption := 'Goto';
|
||||
Caption := 'Goto line';
|
||||
BorderStyle:= bsDialog;
|
||||
|
||||
Label1 := TLabel.Create(self);
|
||||
with Label1 do
|
||||
|
@ -33,6 +33,7 @@ begin
|
||||
FHintFont.Style := [];
|
||||
FHintFont.Size := 12;
|
||||
FHintFont.Pitch := fpDefault;
|
||||
FSaveFocusedList := TList.Create;
|
||||
end;
|
||||
|
||||
{------------------------------------------------------------------------------
|
||||
@ -45,7 +46,11 @@ end;
|
||||
Destructor TScreen.Destroy;
|
||||
begin
|
||||
FHintFont.Free;
|
||||
FHintFont:=nil;
|
||||
FFormList.Free;
|
||||
FFormList:=nil;
|
||||
FSaveFocusedList.Free;
|
||||
FSaveFocusedList:=nil;
|
||||
inherited Destroy;
|
||||
end;
|
||||
{
|
||||
@ -91,11 +96,8 @@ end;
|
||||
This function is used by the Forms property.
|
||||
------------------------------------------------------------------------------}
|
||||
Function TScreen.GetForms(IIndex: Integer): TForm;
|
||||
var
|
||||
FForm: TForm;
|
||||
begin
|
||||
FForm := TForm(FFormList.Items[IIndex]);
|
||||
Result := FForm;
|
||||
Result := TForm(FFormList.Items[IIndex]);
|
||||
end;
|
||||
|
||||
|
||||
@ -108,7 +110,7 @@ end;
|
||||
------------------------------------------------------------------------------}
|
||||
Function TScreen.GetWidth : Integer;
|
||||
begin
|
||||
result := GetSystemMetrics(SM_CXSCREEN);
|
||||
Result := GetSystemMetrics(SM_CXSCREEN);
|
||||
end;
|
||||
|
||||
|
||||
@ -121,7 +123,7 @@ end;
|
||||
------------------------------------------------------------------------------}
|
||||
Function TScreen.GetHeight : Integer;
|
||||
begin
|
||||
result := GetSystemMetrics(SM_CYSCREEN);
|
||||
Result := GetSystemMetrics(SM_CYSCREEN);
|
||||
end;
|
||||
|
||||
{------------------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user