Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2003-09

Win32: parent form and taskbar button

10 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Micha Nelissen
to Micha Nelissen: Remember my patch to consolidate taskbar buttons by using the owner of a form? In the IDE…
Karl Brandt wrote 12 lines
Micha Nelissen wrote: > Question #2 (related): Because the environment options dialog (and the > others too i presume) have their own button but are shown modal a > strange thing happens. When the dialog is shown, you can click the > main lazarus ide window, it gets focus, but it won't respond to any > clicks. This is very annoying as one would think the ide has hung itself. This is how ShowModal works in Win32. To see, make a test example with Delphi.

In delphi when a form is shown modal and you click another form, the form show modal flashes, and the other form doesn't get focus. Am I missing something here?

Regards,

Micha.

Reply by email

Mattias Gaertner
to Micha Nelissen: Remember my patch to consolidate taskbar buttons by using the owner of a form? In the IDE…
Show quoted text 22 lines
Mattias Gaertner wrote: > On Sun, 31 Aug 2003 20:23:20 +0200 > Micha Nelissen wrote: > > >>Hi, >> >>Remember my patch to consolidate taskbar buttons by using the owner of a > >>form? >> >>In the IDE the designer form, 'Form1' so to say, is not under parental >>control, > > > Designer forms should be as separate from the IDE as possible, because > they contain designer components, which can be buggy. And it splits > TComponent notifications, between IDE and each designer form. OK, this is a good point. Can you make the owner of the source editor something else as the mainide then?

If you want, you can set the owner of the source editor to the "open file" speedbutton. The MainIDE just seems more appropriate.

Mattias

Reply by email

Karl Brandt
to Micha Nelissen: Remember my patch to consolidate taskbar buttons by using the owner of a form? In the IDE…
Micha Nelissen wrote 5 lines
Question #2 (related): Because the environment options dialog (and the others too i presume) have their own button but are shown modal a strange thing happens. When the dialog is shown, you can click the main lazarus ide window, it gets focus, but it won't respond to any clicks. This is very annoying as one would think the ide has hung itself.

This is how ShowModal works in Win32. To see, make a test example with Delphi.

BTW: compiling CVS today :GetClientBounds: just a
typo. Changing Rect to ARect fix it.
Can you fix it Mattias?

karl

Reply by email

Micha Nelissen
to Micha Nelissen: Remember my patch to consolidate taskbar buttons by using the owner of a form? In the IDE…
Mattias Gaertner wrote 16 lines
On Sun, 31 Aug 2003 20:23:20 +0200 Micha Nelissen wrote: >Hi, > >Remember my patch to consolidate taskbar buttons by using the owner of a >form? > >In the IDE the designer form, 'Form1' so to say, is not under parental >control, Designer forms should be as separate from the IDE as possible, because they contain designer components, which can be buggy. And it splits TComponent notifications, between IDE and each designer form.

OK, this is a good point. Can you make the owner of the source editor something else as the mainide then?

Regards,

Micha.

Reply by email

Micha Nelissen

Hi,

Remember my patch to consolidate taskbar buttons by using the owner of a form?

In the IDE the designer form, 'Form1' so to say, is not under parental control, so it has it's own button. This has the effect that when you click the MainIDE window, it focuses the source editor on top of the designer form. This is annoying because if you want to drop components, you will have to focus form1 again each time.

Actual question: could the designer code be easily modified to make the owner of a designer form the mainide too? And the environment options window and such too? Then this problem will disappear and everything will be under one button.

Question #2 (related): Because the environment options dialog (and the others too i presume) have their own button but are shown modal a strange thing happens. When the dialog is shown, you can click the main lazarus ide window, it gets focus, but it won't respond to any clicks. This is very annoying as one would think the ide has hung itself.

Regards,

Micha.

Reply by email

Mattias Gaertner
to Micha Nelissen
Show quoted text 15 lines
Micha Nelissen wrote: > Question #2 (related): Because the environment options dialog (and the > others too i presume) have their own button but are shown modal a > strange thing happens. When the dialog is shown, you can click the main > lazarus ide window, it gets focus, but it won't respond to any clicks. > This is very annoying as one would think the ide has hung itself. This is how ShowModal works in Win32. To see, make a test example with Delphi. BTW: compiling CVS today :GetClientBounds: just a typo. Changing Rect to ARect fix it. Can you fix it Mattias?

Yes.
Strange, that my compilation ran through.

Mattias

Reply by email

Mattias Gaertner
to Micha Nelissen: Remember my patch to consolidate taskbar buttons by using the owner of a form? In the IDE…
Show quoted text 19 lines
Karl Brandt wrote: > Micha Nelissen wrote: > > >> Question #2 (related): Because the environment options dialog (and the >> others too i presume) have their own button but are shown modal a >> strange thing happens. When the dialog is shown, you can click the >> main lazarus ide window, it gets focus, but it won't respond to any >> clicks. This is very annoying as one would think the ide has hung >itself. > > > This is how ShowModal works in Win32. To see, make a test example with > Delphi. In delphi when a form is shown modal and you click another form, the form show modal flashes, and the other form doesn't get focus. Am I missing something here?

Focussing does not work properly under gtk1, so it was never tested in the LCL. Maybe the LCL is not complete. Feel free to improve it.

Mattias

Reply by email

Karl Brandt
to Micha Nelissen: Remember my patch to consolidate taskbar buttons by using the owner of a form? In the IDE…
Micha Nelissen wrote 11 lines
Karl Brandt wrote: > > > This is how ShowModal works in Win32. To see, make a test example with > Delphi. In delphi when a form is shown modal and you click another form, the form show modal flashes, and the other form doesn't get focus.]

Here, when i launch EnvOptions Dialog i get this behavior

Am I missing something here?

Sometimes when the Dialog closes an Invalid Typecast message is show and the app crash or get unused.
Mybe this?

karl

Reply by email

Mattias Gaertner
to Micha Nelissen: Remember my patch to consolidate taskbar buttons by using the owner of a form? In the IDE…
Show quoted text 7 lines
Hi, Remember my patch to consolidate taskbar buttons by using the owner of a form? In the IDE the designer form, 'Form1' so to say, is not under parental control,

Designer forms should be as separate from the IDE as possible, because they contain designer components, which can be buggy. And it splits TComponent notifications, between IDE and each designer form.

Show quoted text 9 lines
so it has it's own button. This has the effect that when you click the MainIDE window, it focuses the source editor on top of the designer form. This is annoying because if you want to drop components, you will have to focus form1 again each time. Actual question: could the designer code be easily modified to make the owner of a designer form the mainide too? And the environment options window and such too? Then this problem will disappear and everything will be under one button.

The Owner should have no impact on the interface. It exists solely for streaming and destructing purposes.

Show quoted text 5 lines
Question #2 (related): Because the environment options dialog (and the others too i presume) have their own button but are shown modal a strange thing happens. When the dialog is shown, you can click the main lazarus ide window, it gets focus, but it won't respond to any clicks. This is very annoying as one would think the ide has hung itself.

See Karl's mail.

Mattias

Reply by email

Micha Nelissen
to Micha Nelissen: Remember my patch to consolidate taskbar buttons by using the owner of a form? In the IDE…
Karl Brandt wrote 12 lines
Micha Nelissen wrote: > Question #2 (related): Because the environment options dialog (and the > others too i presume) have their own button but are shown modal a > strange thing happens. When the dialog is shown, you can click the > main lazarus ide window, it gets focus, but it won't respond to any > clicks. This is very annoying as one would think the ide has hung itself. This is how ShowModal works in Win32. To see, make a test example with Delphi.

In delphi when a form is shown modal and you click another form, the form show modal flashes, and the other form doesn't get focus. Am I missing something here?

Regards,

Micha.

Reply by email