mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-11 00:28:18 +02:00
Removes the resource for TViewUnits and it compiles and runs now.
Shane git-svn-id: trunk@125 -
This commit is contained in:
parent
b86d3c39a1
commit
c0ca68ed97
@ -52,9 +52,9 @@ begin
|
||||
end;
|
||||
|
||||
Application.CreateForm(TMainIDE, MainIDE);
|
||||
Application.CreateForm(TViewUnits1, ViewUnits1);
|
||||
Application.CreateForm(TViewForms1, ViewForms1);
|
||||
Application.CreateForm(TMessageDlg, MessageDlg);
|
||||
Application.CreateForm(TViewForms1, ViewForms1);
|
||||
Application.CreateForm(TViewUnits1, ViewUnits1);
|
||||
Application.CreateForm(TfrmCompilerOptions, frmCompilerOptions);
|
||||
SplashForm.StartTimer;
|
||||
Application.Run;
|
||||
@ -63,6 +63,11 @@ end.
|
||||
|
||||
{
|
||||
$Log$
|
||||
Revision 1.10 2001/01/16 22:04:26 lazarus
|
||||
Removes the resource for TViewUnits and it compiles and runs now.
|
||||
|
||||
Shane
|
||||
|
||||
Revision 1.9 2001/01/15 18:25:51 lazarus
|
||||
Fixed a stupid error I caused by using a variable as an index in main.pp and this variable sometimes caused an exception because the index was out of range.
|
||||
Shane
|
||||
|
43
ide/main.pp
43
ide/main.pp
@ -161,6 +161,7 @@ type
|
||||
Function CreateSeperator : TMenuItem;
|
||||
Function ReturnActiveUnitList : TUnitInfo;
|
||||
Procedure UpdateViewDialogs;
|
||||
Procedure SetDefaultsForForm(aForm : TCustomForm);
|
||||
protected
|
||||
procedure DoFind(Sender : TObject);
|
||||
|
||||
@ -1437,7 +1438,7 @@ var
|
||||
TempName : String;
|
||||
TempFormName : String;
|
||||
Found : Boolean;
|
||||
TempForm : TForm;
|
||||
TempForm : TCustomForm;
|
||||
CInterface : TComponentInterface;
|
||||
begin
|
||||
//TempForm := TForm.Create(Self);
|
||||
@ -1452,21 +1453,8 @@ begin
|
||||
400,300));
|
||||
|
||||
TempForm:=TForm(CInterface.Control);
|
||||
|
||||
TempForm.Designer :=
|
||||
TDesigner.Create(TCustomForm(CInterface.Control));
|
||||
|
||||
TDesigner(TempForm.Designer).MainIDE := Self;
|
||||
|
||||
TDesigner(TempForm.Designer).FormEditor := FormEditor1;
|
||||
|
||||
TDesigner(tempForm.Designer).SourceEditor := SourceNotebook.CreateUnitFromForm(TempForm);
|
||||
|
||||
// TempForm.OnMouseDown := @TDesigner(TempForm.Designer).MouseDownOnForm;
|
||||
// TempForm.OnMouseUp := @TDesigner(TempForm.Designer).MouseUpOnForm;
|
||||
// TempForm.OnMouseMove := @TDesigner(TempForm.Designer).MouseMoveOnForm;
|
||||
|
||||
TempForm.OnActivate := @CodeOrFormActivated;
|
||||
SetDefaultsForForm(TempForm);
|
||||
TDesigner(tempForm.Designer).SourceEditor := SourceNotebook.CreateUnitFromForm(TForm(TempForm));
|
||||
TempForm.Show;
|
||||
|
||||
SetDesigning(TempForm,True);
|
||||
@ -1558,6 +1546,14 @@ Begin
|
||||
|
||||
end;
|
||||
|
||||
Procedure TMainIDE.SetDefaultsforForm(aForm : TCustomForm);
|
||||
Begin
|
||||
aForm.Designer := TDesigner.Create(aForm);
|
||||
TDesigner(aForm.Designer).MainIDE := Self;
|
||||
TDesigner(aForm.Designer).FormEditor := FormEditor1;
|
||||
aForm.OnActivate := @CodeOrFormActivated;
|
||||
end;
|
||||
|
||||
Procedure TMainIDE.FileOpenedEvent(Sender : TObject; Filename : String);
|
||||
var
|
||||
MenuItem : TMenuItem;
|
||||
@ -1583,12 +1579,10 @@ Begin
|
||||
TempForm := FormEditor1.NewFormFromLFM(Texts);
|
||||
|
||||
CInterface := TComponentInterface(FormEditor1.CreateControlComponentInterface(tempForm));
|
||||
TempForm.Designer := TDesigner.Create(TempForm);
|
||||
TDesigner(TempForm.Designer).MainIDE := Self;
|
||||
TDesigner(TempForm.Designer).FormEditor := FormEditor1;
|
||||
TDesigner(tempForm.Designer).SourceEditor := TSourceEditor(sender);
|
||||
SetDefaultsForForm(TempForm);
|
||||
TSourceEditor(sender).control := TempForm;
|
||||
TempForm.OnActivate := @CodeOrFormActivated;
|
||||
TDesigner(TempForm.Designer).SourceEditor := TSourceEditor(sender);
|
||||
|
||||
for I := 0 to TempForm.ComponentCount -1 do
|
||||
FormEditor1.CreateControlComponentInterface(TempForm.Components[i]);
|
||||
TempForm.Show;
|
||||
@ -1621,7 +1615,7 @@ If TSourceEditor(Sender).IsControlUnit then
|
||||
// Writeln('Result = '+Inttostr(CreateLFM(ViewForms1)));
|
||||
// Writeln('Result = '+Inttostr(CreateLFM(MessageDlg)));
|
||||
// Writeln('Result = '+Inttostr(CreateLFM(FindDialog1)));
|
||||
Writeln('Result = '+Inttostr(CreateLFM(MainIDE)));
|
||||
// Writeln('Result = '+Inttostr(CreateLFM(MainIDE)));
|
||||
end;
|
||||
end;
|
||||
|
||||
@ -1933,8 +1927,9 @@ end.
|
||||
{ =============================================================================
|
||||
|
||||
$Log$
|
||||
Revision 1.46 2001/01/16 16:21:29 lazarus
|
||||
Changed LResources to TLResources
|
||||
Revision 1.47 2001/01/16 22:04:26 lazarus
|
||||
Removes the resource for TViewUnits and it compiles and runs now.
|
||||
|
||||
Shane
|
||||
|
||||
Revision 1.45 2001/01/15 20:55:44 lazarus
|
||||
|
@ -43,7 +43,7 @@ type
|
||||
Procedure listbox1Click(Sender : TObject);
|
||||
protected
|
||||
public
|
||||
// constructor Create(AOwner: TComponent); override;
|
||||
// constructor Create(AOwner: TComponent); override;
|
||||
end;
|
||||
|
||||
var
|
||||
@ -51,11 +51,12 @@ ViewForms1 : TViewForms1;
|
||||
|
||||
implementation
|
||||
|
||||
{
|
||||
{
|
||||
constructor TViewForms1.Create(AOwner: TComponent);
|
||||
var
|
||||
Pad : Integer;
|
||||
begin
|
||||
|
||||
inherited Create(AOwner);
|
||||
Caption := 'View Project Forms';
|
||||
Left := 0;
|
||||
@ -95,7 +96,6 @@ begin
|
||||
edit1.Width := ClientWidth - (ClientWidth - btnOK.Left) - (2*pad);
|
||||
Edit1.Height := 25;
|
||||
Edit1.Visible := True;
|
||||
Edit1.Text := 'Edit1';
|
||||
Edit1.Name := 'Edit1';
|
||||
|
||||
|
||||
@ -107,7 +107,6 @@ begin
|
||||
Width:= ClientWidth - (ClientWidth - btnOK.Left) - (2*pad);
|
||||
Height:= Self.Height - Top - pad;
|
||||
Visible:= true;
|
||||
BorderStyle:= bsNone;
|
||||
MultiSelect:= false;
|
||||
Listbox1.Name := 'Listbox1';
|
||||
OnClick :=@listbox1Click;
|
||||
@ -117,7 +116,7 @@ begin
|
||||
end;
|
||||
|
||||
end;
|
||||
}
|
||||
}
|
||||
|
||||
Procedure TViewForms1.btnOKClick(Sender : TOBject);
|
||||
Begin
|
||||
@ -169,6 +168,11 @@ initialization
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.5 2001/01/16 22:04:26 lazarus
|
||||
Removes the resource for TViewUnits and it compiles and runs now.
|
||||
|
||||
Shane
|
||||
|
||||
Revision 1.4 2001/01/14 03:56:57 lazarus
|
||||
Shane
|
||||
|
||||
|
@ -43,7 +43,7 @@ type
|
||||
Procedure Listbox1Click(Sender : TObject);
|
||||
protected
|
||||
public
|
||||
// constructor Create(AOwner: TComponent); override;
|
||||
constructor Create(AOwner: TComponent); override;
|
||||
end;
|
||||
|
||||
var
|
||||
@ -51,7 +51,7 @@ ViewUnits1 : TViewUnits1;
|
||||
|
||||
implementation
|
||||
|
||||
{
|
||||
|
||||
constructor TViewUnits1.Create(AOwner: TComponent);
|
||||
var
|
||||
Pad : Integer;
|
||||
@ -106,7 +106,6 @@ begin
|
||||
Width:= ClientWidth - (ClientWidth - btnOK.Left) - (2*pad);
|
||||
Height:= Self.Height - Top - pad;
|
||||
Visible:= true;
|
||||
BorderStyle:= bsNone;
|
||||
MultiSelect:= false;
|
||||
Name := 'Listbox1';
|
||||
OnClick := @ListBox1Click;
|
||||
@ -116,7 +115,7 @@ begin
|
||||
|
||||
|
||||
end;
|
||||
}
|
||||
|
||||
|
||||
Procedure TViewUnits1.btnOKClick(Sender : TOBject);
|
||||
Begin
|
||||
@ -157,7 +156,7 @@ end;
|
||||
initialization
|
||||
{Do not change the following}
|
||||
{<LAZARUSFORMDEF>}
|
||||
{$I viewunits1.lrs}
|
||||
{ $I viewunits1.lrs}
|
||||
{<LAZARUSFORMDEFEND>}
|
||||
{}
|
||||
|
||||
@ -165,6 +164,11 @@ initialization
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.5 2001/01/16 22:04:26 lazarus
|
||||
Removes the resource for TViewUnits and it compiles and runs now.
|
||||
|
||||
Shane
|
||||
|
||||
Revision 1.4 2001/01/14 03:56:57 lazarus
|
||||
Shane
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user