diff options
Diffstat (limited to 'chart2/source')
-rw-r--r-- | chart2/source/view/main/DummyXShape.cxx | 29 |
1 files changed, 13 insertions, 16 deletions
diff --git a/chart2/source/view/main/DummyXShape.cxx b/chart2/source/view/main/DummyXShape.cxx index 8eb97e37f94b..4ed9622617b5 100644 --- a/chart2/source/view/main/DummyXShape.cxx +++ b/chart2/source/view/main/DummyXShape.cxx @@ -1119,26 +1119,23 @@ bool DummyChart::initWindow() winData.pVisual = (void*)(vi->visual); pWindow.reset(new SystemChildWindow(mpWindow.get(), 0, &winData, sal_False)); pChildSysData = pWindow->GetSystemData(); - - if( !pChildSysData ) - return false; } + if (!pWindow || !pChildSysData) + return false; - if( pWindow ) - { - pWindow->SetMouseTransparent( sal_True ); - pWindow->SetParentClipMode( PARENTCLIPMODE_NOCLIP ); - pWindow->EnableEraseBackground( sal_False ); - pWindow->SetControlForeground(); - pWindow->SetControlBackground(); + pWindow->SetMouseTransparent( sal_True ); + pWindow->SetParentClipMode( PARENTCLIPMODE_NOCLIP ); + pWindow->EnableEraseBackground( sal_False ); + pWindow->SetControlForeground(); + pWindow->SetControlBackground(); + + GLWin.dpy = reinterpret_cast<Display*>(pChildSysData->pDisplay); + GLWin.win = pChildSysData->aWindow; + GLWin.vi = vi; + GLWin.GLXExtensions = glXQueryExtensionsString( GLWin.dpy, GLWin.screen ); + OSL_TRACE("available GLX extensions: %s", GLWin.GLXExtensions); - GLWin.dpy = reinterpret_cast<Display*>(pChildSysData->pDisplay); - GLWin.win = pChildSysData->aWindow; - GLWin.vi = vi; - GLWin.GLXExtensions = glXQueryExtensionsString( GLWin.dpy, GLWin.screen ); - OSL_TRACE("available GLX extensions: %s", GLWin.GLXExtensions); - } return true; } |