set_visible for osx

This commit is contained in:
David Rose 2009-10-02 21:54:16 +00:00
parent 945a732411
commit d6647e3a85
2 changed files with 21 additions and 1 deletions

View File

@ -104,10 +104,29 @@ set_wparams(const P3DWindowParams &wparams) {
TransformProcessType(&psn, kProcessTransformToForegroundApplication);
SetFrontProcess(&psn);
ShowWindow(_toplevel_window);
if (_visible) {
ShowWindow(_toplevel_window);
}
}
}
}
////////////////////////////////////////////////////////////////////
// Function: P3DOsxSplashWindow::set_visible
// Access: Public, Virtual
// Description: Makes the splash window visible or invisible, so as
// not to compete with the embedded Panda window in the
// same space.
////////////////////////////////////////////////////////////////////
void P3DOsxSplashWindow::
set_visible(bool visible) {
P3DSplashWindow::set_visible(visible);
if (_visible) {
ShowWindow(_toplevel_window);
} else {
HideWindow(_toplevel_window);
}
}
////////////////////////////////////////////////////////////////////

View File

@ -34,6 +34,7 @@ public:
virtual ~P3DOsxSplashWindow();
virtual void set_wparams(const P3DWindowParams &wparams);
virtual void set_visible(bool visible);
virtual void set_image_filename(const string &image_filename,
ImagePlacement image_placement);
virtual void set_install_label(const string &install_label);