Kaydet (Commit) c02e393c authored tarafından Markus Mohrhard's avatar Markus Mohrhard

Revert "Fix OpenGL chart reinitializing"

This reverts commit cbc50c90.
üst d5fb4b73
......@@ -64,7 +64,6 @@ ChartWindow::ChartWindow( ChartController* pController, Window* pParent, WinBits
uno::Reference< chart2::X3DChartWindowProvider > x3DWindowProvider(pController->getModel(), uno::UNO_QUERY_THROW);
sal_uInt64 nWindowPtr = reinterpret_cast<sal_uInt64>(m_pOpenGLWindow);
x3DWindowProvider->setWindow(nWindowPtr);
x3DWindowProvider->update();
}
ChartWindow::~ChartWindow()
......@@ -73,7 +72,6 @@ ChartWindow::~ChartWindow()
{
uno::Reference< chart2::X3DChartWindowProvider > x3DWindowProvider(m_pWindowController->getModel(), uno::UNO_QUERY_THROW);
x3DWindowProvider->setWindow(0);
x3DWindowProvider->update();
}
delete m_pOpenGLWindow;
}
......
......@@ -238,7 +238,7 @@ public:
/**
* Only necessary for stateless implementations
*/
virtual void render(com::sun::star::uno::Reference< com::sun::star::drawing::XShapes > xRootShape, bool bInitOpenGL = true) = 0;
virtual void render(com::sun::star::uno::Reference< com::sun::star::drawing::XShapes > xRootShape) = 0;
virtual bool preRender(OpenGLWindow* pWindow) = 0;
virtual void postRender(OpenGLWindow* pWindow) = 0;
......
......@@ -184,7 +184,7 @@ public:
virtual void setPageSize( com::sun::star::uno::Reference < com::sun::star::drawing::XShapes > xChartShapes, const com::sun::star::awt::Size& rSize ) SAL_OVERRIDE;
virtual void render(com::sun::star::uno::Reference< com::sun::star::drawing::XShapes > xDrawPage, bool bInitOpenGL = true) SAL_OVERRIDE;
virtual void render(com::sun::star::uno::Reference< com::sun::star::drawing::XShapes > xDrawPage) SAL_OVERRIDE;
virtual bool preRender(OpenGLWindow* pWindow) SAL_OVERRIDE;
virtual void postRender(OpenGLWindow* pWindow) SAL_OVERRIDE;
......
......@@ -197,7 +197,7 @@ public:
/**
* not necessary right now
*/
virtual void render(com::sun::star::uno::Reference< com::sun::star::drawing::XShapes >, bool ) SAL_OVERRIDE {}
virtual void render(com::sun::star::uno::Reference< com::sun::star::drawing::XShapes > ) SAL_OVERRIDE {}
virtual bool preRender(OpenGLWindow*) SAL_OVERRIDE { return true; }
virtual void postRender(OpenGLWindow*) SAL_OVERRIDE {}
......
......@@ -166,7 +166,6 @@ public:
virtual void scroll(long nDelta) SAL_OVERRIDE;
virtual void contextDestroyed() SAL_OVERRIDE;
const OpenGLWindow* getOpenGLWindow() const;
void updateOpenGLWindow();
private:
ChartView* mpView;
......@@ -209,11 +208,6 @@ void GL2DRenderer::contextDestroyed()
mbContextDestroyed = true;
}
const OpenGLWindow* GL2DRenderer::getOpenGLWindow() const
{
return mpWindow;
}
void GL2DRenderer::updateOpenGLWindow()
{
if(mbContextDestroyed)
......@@ -2771,7 +2765,7 @@ void ChartView::render()
bool bRender = pShapeFactory->preRender(pWindow);
if(bRender)
{
pShapeFactory->render(mxRootShape, pWindow != mp2DRenderer->getOpenGLWindow());
pShapeFactory->render(mxRootShape);
pShapeFactory->postRender(pWindow);
}
}
......
......@@ -395,7 +395,6 @@ public:
virtual void render() SAL_OVERRIDE;
void clear();
void invalidateInit() { mbNotInit = true; }
TextCache& getTextCache() { return maTextCache;}
private:
......
......@@ -446,13 +446,9 @@ uno::Reference< drawing::XShape >
return pText;
}
void OpenglShapeFactory::render(uno::Reference< drawing::XShapes > xRootShape, bool bInitOpenGL)
void OpenglShapeFactory::render(uno::Reference< drawing::XShapes > xRootShape)
{
dummy::DummyChart& rChart = dynamic_cast<dummy::DummyChart&>(*xRootShape.get());
if(bInitOpenGL)
{
rChart.invalidateInit();
}
rChart.render();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment