Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'intern/ghost/intern/GHOST_SystemWin32.cpp')
-rw-r--r--intern/ghost/intern/GHOST_SystemWin32.cpp60
1 files changed, 26 insertions, 34 deletions
diff --git a/intern/ghost/intern/GHOST_SystemWin32.cpp b/intern/ghost/intern/GHOST_SystemWin32.cpp
index 3b95373f800..0767ad5a8f9 100644
--- a/intern/ghost/intern/GHOST_SystemWin32.cpp
+++ b/intern/ghost/intern/GHOST_SystemWin32.cpp
@@ -231,44 +231,36 @@ GHOST_IWindow *GHOST_SystemWin32::createWindow(
GHOST_TInt32 left, GHOST_TInt32 top,
GHOST_TUns32 width, GHOST_TUns32 height,
GHOST_TWindowState state, GHOST_TDrawingContextType type,
- bool stereoVisual,
+ bool wantStereoVisual,
const bool exclusive,
- const GHOST_TUns16 numOfAASamples,
+ const GHOST_TUns16 wantNumOfAASamples,
const GHOST_TEmbedderWindowID parentWindow)
{
- GHOST_Window *window = 0;
- window = new GHOST_WindowWin32(this, title, left, top, width, height, state, type, stereoVisual, numOfAASamples, parentWindow);
- if (window) {
- if (window->getValid()) {
- // Store the pointer to the window
-// if (state != GHOST_kWindowStateFullScreen) {
- m_windowManager->addWindow(window);
- m_windowManager->setActiveWindow(window);
-// }
- }
- else {
-
- // Invalid parent window hwnd
- if (((GHOST_WindowWin32 *)window)->getNextWindow() == NULL) {
- delete window;
- window = 0;
- return window;
- }
-
- // An invalid window could be one that was used to test for AA
- window = ((GHOST_WindowWin32 *)window)->getNextWindow();
-
- // If another window is found, let the wm know about that one, but not the old one
- if (window->getValid()) {
- m_windowManager->addWindow(window);
- }
- else {
- delete window;
- window = 0;
- }
-
- }
+ GHOST_Window *window =
+ new GHOST_WindowWin32(
+ this,
+ title,
+ left,
+ top,
+ width,
+ height,
+ state,
+ type,
+ wantStereoVisual,
+ wantNumOfAASamples,
+ parentWindow);
+
+ if (window->getValid()) {
+ // Store the pointer to the window
+ m_windowManager->addWindow(window);
+ m_windowManager->setActiveWindow(window);
}
+ else {
+ GHOST_PRINT("GHOST_SystemWin32::createWindow(): window invalid\n");
+ delete window;
+ window = 0;
+ }
+
return window;
}