View Issue Details

IDProjectCategoryView StatusLast Update
0017951LazarusIDEpublic2010-11-18 10:53
ReporterKim PedersenAssigned ToPaul Ishenin 
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionfixed 
Product Version0.9.29 (SVN)Product Build 
Target Version1.0.0Fixed in Version0.9.29 (SVN) 
Summary0017951: TForm.ActiveControl overwritten
DescriptionWhen dropping two TEdits on a new form you can set the ActiveControl property on the form to one of them without any problem. When ActiveControl has been set you can toggle between the components and the form, and the form still remembers ActivControl correctly.
When saving the project and restarting Lazarus, the IDE will only accept one particular control as ActiveControl on the form (I think it is the upper left most). That is, if you select Edit2 as ActiveControl in the property editor and then click on the form afterwards, it will revert to Edit1. It only happens if you click on the form. If you select the form in the dropdown menu in the property editor, it will display the right control.
Additional InformationHaving compiled Lazarus with VerboseFocus this is what I get when clicking on the form:
----
GTKFocusCBAfter Widget=09972720 Event^.theIn=1 LCLObject=Form1:TForm1
     GetFocus=nil
TWinControl.WndProc LM_SetFocus Edit2:TEdit
TCustomForm.SetFocusedControl Self=Form1:TForm1 Control=Edit2:TEdit Control.HandleAllocated=True
gtkfrmactivateAfter Widget=09972720 Event^.theIn=1 LCLObject=Form1:TForm1
     GetFocus=nil
GTKFocusCBAfter Widget=09BAF840 Event^.theIn=1 LCLObject=Edit1:TEdit
     GetFocus=09BAF840 ParentLCLFocus=Edit1:TEdit
TWinControl.WndProc LM_SetFocus Edit1:TEdit
TCustomForm.SetFocusedControl Self=Form1:TForm1 Control=Edit1:TEdit Control.HandleAllocated=True
TCustomForm.SetFocusedControl Self=Form1:TForm1 SomeParent=Form1:TForm1 OldActiveControl=Edit2:TEdit New=Edit1:TEdit
----

You can see that the activecontrol is somehow changed back to Edit1 in GTKFocusCB
TagsNo tags attached.
Fixed in Revision28305
LazTarget1.0
WidgetsetGTK 2
Attached Files

Activities

Paul Ishenin

2010-11-18 03:06

manager   ~0043163

Please test and close if ok.

Kim Pedersen

2010-11-18 10:53

reporter   ~0043174

Working perfect now.
Thanks.

Issue History

Date Modified Username Field Change
2010-11-16 14:24 Kim Pedersen New Issue
2010-11-16 14:24 Kim Pedersen Widgetset => GTK 2
2010-11-16 14:30 Vincent Snijders LazTarget => 1.0
2010-11-16 14:30 Vincent Snijders Status new => acknowledged
2010-11-16 14:30 Vincent Snijders Target Version => 1.0.0
2010-11-16 14:35 Paul Ishenin Status acknowledged => assigned
2010-11-16 14:35 Paul Ishenin Assigned To => Paul Ishenin
2010-11-18 03:06 Paul Ishenin Fixed in Revision => 28305
2010-11-18 03:06 Paul Ishenin Status assigned => resolved
2010-11-18 03:06 Paul Ishenin Fixed in Version => 0.9.29 (SVN)
2010-11-18 03:06 Paul Ishenin Resolution open => fixed
2010-11-18 03:06 Paul Ishenin Note Added: 0043163
2010-11-18 10:53 Kim Pedersen Status resolved => closed
2010-11-18 10:53 Kim Pedersen Note Added: 0043174