TStatusBar's create and destroy were not set to override TWinControls so they were never called.

Shane

git-svn-id: trunk@85 -
This commit is contained in:
lazarus 2000-12-29 18:33:54 +00:00
parent 4be859d5cd
commit 0fa9bc58f7
5 changed files with 33 additions and 35 deletions

View File

@ -309,8 +309,8 @@ type
FAlignmentWidget : TAlignment;
procedure SetSimpleText(Value : String);
public
constructor Create(AOwner : TComponent);
destructor Destroy;
constructor Create(AOwner : TComponent); override;
destructor Destroy; override;
published
property SimpleText : String read FSimpleText write SetSimpleText;
property Visible;
@ -876,6 +876,10 @@ end.
{ =============================================================================
$Log$
Revision 1.2 2000/12/29 18:33:54 lazarus
TStatusBar's create and destroy were not set to override TWinControls so they were never called.
Shane
Revision 1.1 2000/07/13 10:28:23 michael
+ Initial import

View File

@ -1192,16 +1192,9 @@ end;
------------------------------------------------------------------------------}
constructor TControl.Create(AOwner : TComponent);
begin
{ if AOwner = nil
then Assert(False, Format('Trace:[TControl.Create] %s --> Create(AOwner: nil)', [ClassName]))
else Assert(False, Format('Trace:[TControl.Create] %s --> Create(AOwner: %s)', [ClassName, AOwner.ClassNAme]));
}
inherited Create(AOwner);
FControlStyle := [csCaptureMouse,
csClickEvents,
csSetCaption,
csDoubleClicks];
FControlStyle := [csCaptureMouse, csClickEvents, csSetCaption, csDoubleClicks];
FAnchors := [akLeft,akTop];
FAlign := alNone;
// initial control isn't visible (It isn't created yet)
@ -1283,6 +1276,10 @@ end;
{ =============================================================================
$Log$
Revision 1.7 2000/12/29 18:33:54 lazarus
TStatusBar's create and destroy were not set to override TWinControls so they were never called.
Shane
Revision 1.6 2000/12/29 13:14:05 lazarus
Using the lresources.pp and registering components.
This is a major change but will create much more flexibility for the IDE.

View File

@ -3,19 +3,15 @@
{------------------------------------------------------------------------------}
constructor TStatusBar.Create(AOwner : TComponent);
begin
Assert(False, 'Trace:Inside TStatusBar Constructor');
inherited Create(AOwner);
fCompStyle := csStatusBar;
Align := alBottom;
Setbounds(0,TWinControl(AOwner).Height-15,TWInControl(AOwner).Width,15);
CreateComponent(AOwner);
Height := 15;
Width := 100;
Top := 3;
Left := 1;
FContext := 0;
Align := alBottom;
FMessage := -1;
end;

View File

@ -1739,8 +1739,6 @@ begin
if (Parent <> nil)
then Parent.HandleNeeded;
end;
// MWE: moved to createwnd
// if fCompStyle <> csNone then
CreateHandle;
end;
end;
@ -1892,6 +1890,10 @@ end;
{ =============================================================================
$Log$
Revision 1.6 2000/12/29 18:33:54 lazarus
TStatusBar's create and destroy were not set to override TWinControls so they were never called.
Shane
Revision 1.5 2000/12/29 13:14:05 lazarus
Using the lresources.pp and registering components.
This is a major change but will create much more flexibility for the IDE.

View File

@ -985,22 +985,8 @@ begin
else
writeln ('STOPPOK: [TGtkObject.SetText] Possible superfluous use of SetText, use SetLabel instead!');
end;
{STOPPOK: Code seems superfluous, see SetLabel instead
var
pStr: PChar;
// Stoppok: Hmm, this cast looks quite dangerous if the code above is also valid
case TLMNotebookEvent(Data^).fCompStyle of
csNotebook :
begin
writeln ('STOPPOK: [TGtkObject.SetText] Notebook: Why the hell are we getting here?');
pStr := StrAlloc(Length(TLMNotebookEvent(Data^).Str) + 1);
StrPCopy(pStr, TLMNotebookEvent(Data^).Str);
gtk_notebook_set_tab_label_text(PGtkNotebook(TWinControl(TLMNotebookEvent(Data^).Parent).handle),
PGtkWidget(TWinControl(TLMNotebookEvent(Data^).Child).handle),
pStr);
end;
end;
}
{STOPPOK: Code seems superfluous, see SetLabel instead}
end;
{------------------------------------------------------------------------------
@ -1848,6 +1834,15 @@ begin
csSTATUSBAR :
begin
Writeln('*****************************');
Writeln('*****************************');
Writeln('*****************************');
Writeln('*****************************');
Writeln('*******gtk_status_bar********');
Writeln('*****************************');
Writeln('*****************************');
Writeln('*****************************');
Writeln('*****************************');
P := gtk_statusbar_new();
Assert(False, 'Trace:In CreateComponent --StatusBar');
end;
@ -2702,6 +2697,10 @@ end;
{ =============================================================================
$Log$
Revision 1.12 2000/12/29 18:33:54 lazarus
TStatusBar's create and destroy were not set to override TWinControls so they were never called.
Shane
Revision 1.11 2000/12/22 19:55:38 lazarus
Added the Popupmenu code to the LCL.
Now you can right click on the editor and a PopupMenu appears.