Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » Newbie corner » Adjusting the Z order of a dialog window?
Adjusting the Z order of a dialog window? [message #49054] Sun, 10 December 2017 06:01 Go to next message
ptkacz is currently offline  ptkacz
Messages: 89
Registered: March 2017
Member
Hi Guys,

I've created a dialog class that gets invoked by the main application upon application launch as follows, within the application's constructor:

someDialog.open();

The dialog window's constructor is defined as follows:

SomeDialog::SomeDialog() {
    CtrlLayout(*this, "Some Dialog");
    CtrlLayout(SomePanel);
}

When the application is launched, the dialog window opens, but is hidden behind the application window.

How does one raise the dialog window above the application window?



Peter
Re: Adjusting the Z order of a dialog window? [message #49055 is a reply to message #49054] Sun, 10 December 2017 08:24 Go to previous messageGo to next message
deep is currently offline  deep
Messages: 263
Registered: July 2011
Location: Bangalore
Experienced Member
You can call "someDialog.open();" this using timercallback from constructor like,

SetTimeCallback ( 200, THISBACK ( your_function ), 0 );

With positive value it is called once after time delay ( first value is time delay in msec. )

This way you allow constructor to finish its tasks and then call Dialog.


Warm Regards

Deepak

[Updated on: Sun, 10 December 2017 08:24]

Report message to a moderator

Re: Adjusting the Z order of a dialog window? [message #49131 is a reply to message #49054] Sun, 24 December 2017 07:27 Go to previous messageGo to next message
ptkacz is currently offline  ptkacz
Messages: 89
Registered: March 2017
Member
Thanks deep! That worked!

The next question is, why does that work?

In addition, I attempted to make use of a couple of other methods in order to attempt to modify the Z order of the dialog window, but that didn't work.

Aside from the dialog window ending up in the background, the dialog window named ended listing in the task bar, which was annoying. Making use of the SetTimeCallback, this issue doesn't happen as well.

Again, thanks so much for the suggestion!


Peter
Re: Adjusting the Z order of a dialog window? [message #49137 is a reply to message #49131] Mon, 25 December 2017 09:08 Go to previous messageGo to next message
deep is currently offline  deep
Messages: 263
Registered: July 2011
Location: Bangalore
Experienced Member
Hi Peter,

Basically with this you are allowing constructor to finish its tasks of creating the objects.
Before you start using the objects


Warm Regards

Deepak
Re: Adjusting the Z order of a dialog window? [message #50401 is a reply to message #49137] Wed, 17 October 2018 04:44 Go to previous message
ptkacz is currently offline  ptkacz
Messages: 89
Registered: March 2017
Member
NonModal windows appear to do the trick!
Previous Topic: GridCtrl + rich texts
Next Topic: Linking issue...cmd line vs U++ vs Codeblocks...
Goto Forum:
  


Current Time: Fri Mar 29 11:35:50 CET 2024

Total time taken to generate the page: 0.01242 seconds