View Issue Details

IDProjectCategoryView StatusLast Update
0004032JEDI VCL00 JVCL Componentspublic2007-06-19 06:21
Reporterivan_raAssigned Toobones 
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product VersionDaily / GIT 
Target VersionFixed in Version3.34 
Summary0004032: Bug in TJvForm
Descriptionwhen TJvForm has parent, it can be shown on another form:

Let Form1 is main application form and Form2 is target form. This is code demonstrating bug:

procedure TForm1.Button1Click(Sender: TObject);
begin
  with TJvForm.Create(Application) do
  try
    Parent:=Form2;
    SetBounds(0,50,100,100);
    Color:=Random($FFFFFF);
    visible:=true;
  except
    Free;
  end;
end;

New TJvForm has Parent:=Form2 but shown on Form1
(look at JvForm.zip)
Additional InformationSuggestion:
The cause of bug is procedure TJvForm.CMShowingChanged from JvComponent unit. It fixes some "Window Ghosting "bug"", but introduces own bug
TagsNo tags attached.

Activities

2007-01-05 02:42

 

JvForm.zip (2,191 bytes)

obones

2007-01-08 03:36

administrator   ~0010554

The code for the window ghosting must stay. It must be adjusted to cope with this, considering that setting a parent to a form is not something very commonly encountered by the majority of users.

ivan_ra

2007-01-08 23:59

developer   ~0010555

Last edited: 2007-01-10 10:06

I not understand, for what cases the window ghosting code is necessary, but probably we need to check Form.Parent property before run it?
I have got this bug in project where I use TJvInterpreterFm to customize part of my form in runtime. Now I use SetWindowLong command to restore my interpreted forms appearance, but maybe there is need to more accurately write code of TJvForm.CMShowingChanged?

obones

2007-06-19 06:21

administrator   ~0013425

The ghosting bug is happening on Windows XP only and is when a dialog form pops up behind its calling form.
I have changed the code in TJvForm to only do it when the Parent property is not assigned.

Issue History

Date Modified Username Field Change
2007-01-05 02:42 ivan_ra New Issue
2007-01-05 02:42 ivan_ra File Added: JvForm.zip
2007-01-08 03:36 obones Note Added: 0010554
2007-01-08 03:36 obones Status new => acknowledged
2007-01-08 23:59 ivan_ra Note Added: 0010555
2007-01-10 10:06 ivan_ra Note Edited: 0010555
2007-06-19 06:21 obones Status acknowledged => resolved
2007-06-19 06:21 obones Fixed in Version => Daily / SVN
2007-06-19 06:21 obones Resolution open => fixed
2007-06-19 06:21 obones Assigned To => obones
2007-06-19 06:21 obones Note Added: 0013425