Modeless dialogs off the beaten track
-
How can I control my modeless dialogs when they are moved? They can be moved all over the place, off the main window into the wide blue yonder. How can I make sure they only stay within the bounds of the main window (which itself can be resized)?
-
How can I control my modeless dialogs when they are moved? They can be moved all over the place, off the main window into the wide blue yonder. How can I make sure they only stay within the bounds of the main window (which itself can be resized)?
Override the WM_MOVE windows message with OnMove() in your dialog class and use the parent window bounding rect to limit the movement. Steve
-
How can I control my modeless dialogs when they are moved? They can be moved all over the place, off the main window into the wide blue yonder. How can I make sure they only stay within the bounds of the main window (which itself can be resized)?
-
How can I control my modeless dialogs when they are moved? They can be moved all over the place, off the main window into the wide blue yonder. How can I make sure they only stay within the bounds of the main window (which itself can be resized)?
I did it with OnMoving. Great - I can stop the user moving the dialog off the main window. But now what if I want the user to move it off the window but make the part off the window invisible?
-
How can I control my modeless dialogs when they are moved? They can be moved all over the place, off the main window into the wide blue yonder. How can I make sure they only stay within the bounds of the main window (which itself can be resized)?
And also is there a way to get a window rect that only gives you the coords of the actual view, i.e. ignores the title bar, status bar etc?