From 6897d83bf2e03b26f85d72a851df2c778b301323 Mon Sep 17 00:00:00 2001 From: lazarus Date: Tue, 16 Oct 2001 20:01:28 +0000 Subject: [PATCH] MG: removed splashform fix, because of the unpredictable side effects git-svn-id: trunk@353 - --- ide/uniteditor.pp | 4 ++-- lcl/include/control.inc | 4 +++- lcl/include/customform.inc | 6 +++++- lcl/interfaces/gtk/gtkobject.inc | 12 ++++++++++++ 4 files changed, 22 insertions(+), 4 deletions(-) diff --git a/ide/uniteditor.pp b/ide/uniteditor.pp index 352e6eaa92..0f6949d393 100644 --- a/ide/uniteditor.pp +++ b/ide/uniteditor.pp @@ -2451,11 +2451,11 @@ writeln('[TSourceNotebook.NewFile] D '); {$ENDIF} Notebook.Pages[Notebook.PageIndex] := FindUniquePageName(NewShortName,Notebook.PageIndex); - if (SplashForm.Visible) and (Notebook.Pages.Count=1) then begin +{ if (SplashForm.Visible) and (Notebook.Pages.Count=1) then begin SplashForm.Hide; SplashForm.Show; Application.ProcessMessages; - end; + end;} {$IFDEF IDE_DEBUG} writeln('[TSourceNotebook.NewFile] end'); {$ENDIF} diff --git a/lcl/include/control.inc b/lcl/include/control.inc index 4b16885673..264c50aca2 100644 --- a/lcl/include/control.inc +++ b/lcl/include/control.inc @@ -1272,7 +1272,6 @@ end; {------------------------------------------------------------------------------} procedure TControl.DestroyComponent; begin - //TODO: Does this procedure belong here CNSendMessage(LM_DESTROY, Self, nil); end; @@ -1326,6 +1325,9 @@ end; { ============================================================================= $Log$ + Revision 1.27 2001/10/16 20:01:28 lazarus + MG: removed splashform fix, because of the unpredictable side effects + Revision 1.26 2001/10/16 14:19:13 lazarus MG: added nvidia opengl support and a new opengl example from satan diff --git a/lcl/include/customform.inc b/lcl/include/customform.inc index 3d9dcdbceb..37b48e498a 100644 --- a/lcl/include/customform.inc +++ b/lcl/include/customform.inc @@ -99,7 +99,8 @@ Procedure TCustomForm.FocusControl(Control : TWinControl); Begin //Writeln('[TCustomForm.FocusControl] A ',ClassName,' ',Control.ClassName); FActiveControl := Control; - LCLLinux.SetFocus(Control.Handle); + if HandleAllocated and Visible then + LCLLinux.SetFocus(Control.Handle); //Writeln('[TCustomForm.FocusControl] END ',ClassName,' ',Control.ClassName); End; @@ -943,6 +944,9 @@ end; { ============================================================================= $Log$ + Revision 1.29 2001/10/16 20:01:28 lazarus + MG: removed splashform fix, because of the unpredictable side effects + Revision 1.28 2001/10/10 17:55:04 lazarus MG: fixed caret lost, gtk cleanup, bracket lvls, bookmark saving diff --git a/lcl/interfaces/gtk/gtkobject.inc b/lcl/interfaces/gtk/gtkobject.inc index 8c58381504..bf7fe7b940 100644 --- a/lcl/interfaces/gtk/gtkobject.inc +++ b/lcl/interfaces/gtk/gtkobject.inc @@ -452,7 +452,16 @@ begin //writeln('>>> LM_DESTROY ',Sender.Classname,' Sender=',HexStr(Cardinal(Sender),8),' Handle=',HexStr(Cardinal(Handle),8)); if Handle<>0 then begin if MCaptureHandle=Handle then MCaptureHandle:=0; +//writeln('>>> LM_DESTROY A ',Sender.Classname,' Sender=',HexStr(Cardinal(Sender),8),' Handle=',HexStr(Cardinal(Handle),8)); +{ + Important (Mattias): + + If Sender is TForm and one of its components was focused by SetFocus then + the next line will produce a gtk warning. The PGtkWidget(Handle) is also + a dirty cast. If Sender is TForm, Handle is a PGtkWindow ! +} gtk_widget_destroy(PGtkWidget(Handle)); +//writeln('>>> LM_DESTROY END ',Sender.Classname,' Sender=',HexStr(Cardinal(Sender),8),' Handle=',HexStr(Cardinal(Handle),8)); end; // remove all remaining messages to this component QueueItem:=FMessageQueue.First; @@ -3092,6 +3101,9 @@ end; { ============================================================================= $Log$ + Revision 1.63 2001/10/16 20:01:28 lazarus + MG: removed splashform fix, because of the unpredictable side effects + Revision 1.62 2001/10/16 10:51:10 lazarus MG: added clicked event to TButton, MessageDialog reacts to return key