[Libreoffice-commits] core.git: 2 commits - include/vcl vcl/source
Markus Mohrhard
markus.mohrhard at collabora.co.uk
Wed May 28 09:03:01 PDT 2014
include/vcl/openglwin.hxx | 2 +-
vcl/source/window/openglwin.cxx | 11 +++++++----
2 files changed, 8 insertions(+), 5 deletions(-)
New commits:
commit dd38578b6e785da6d74e3a40b46b778c82743082
Author: Markus Mohrhard <markus.mohrhard at collabora.co.uk>
Date: Wed May 28 17:41:14 2014 +0200
fix build error
Change-Id: I550616e1f6e63ac42103756014b1aa26cee5c21f
diff --git a/vcl/source/window/openglwin.cxx b/vcl/source/window/openglwin.cxx
index 68eac16..0300987 100644
--- a/vcl/source/window/openglwin.cxx
+++ b/vcl/source/window/openglwin.cxx
@@ -24,9 +24,9 @@ private:
OpenGLWindowImpl::OpenGLWindowImpl(Window* pWindow):
mpChildWindow(new SystemChildWindow(pWindow))
{
+ mpChildWindow->Show();
maContext.init(mpChildWindow.get());
pWindow->SetMouseTransparent(false);
- maContext.show();
}
OpenGLContext* OpenGLWindowImpl::getContext()
@@ -60,7 +60,6 @@ void OpenGLWindow::Paint(const Rectangle&)
void OpenGLWindow::MouseButtonDown( const MouseEvent& rMEvt )
{
- getContext()->show();
maStartPoint = rMEvt.GetPosPixel();
}
commit 194c6709266b5b2e146c9643f1f89072b7c57000
Author: Markus Mohrhard <markus.mohrhard at collabora.co.uk>
Date: Wed May 28 17:31:27 2014 +0200
try to fix mouse interaction on windows
Change-Id: I8662b0c20dc719401eec3e3d2d852bb3e139a641
diff --git a/include/vcl/openglwin.hxx b/include/vcl/openglwin.hxx
index 85d1940..50d564c 100644
--- a/include/vcl/openglwin.hxx
+++ b/include/vcl/openglwin.hxx
@@ -32,7 +32,7 @@ public:
};
// pImpl Pattern to avoid linking against OpenGL libs when using the class without the context
-class VCLOPENGL_DLLPUBLIC OpenGLWindow : public SystemChildWindow
+class VCLOPENGL_DLLPUBLIC OpenGLWindow : public Window
{
public:
OpenGLWindow(Window* pParent);
diff --git a/vcl/source/window/openglwin.cxx b/vcl/source/window/openglwin.cxx
index 1983376..68eac16 100644
--- a/vcl/source/window/openglwin.cxx
+++ b/vcl/source/window/openglwin.cxx
@@ -14,16 +14,19 @@
class OpenGLWindowImpl
{
public:
- OpenGLWindowImpl(SystemChildWindow* pWindow);
+ OpenGLWindowImpl(Window* pWindow);
OpenGLContext* getContext();
private:
OpenGLContext maContext;
+ boost::scoped_ptr<SystemChildWindow> mpChildWindow;
};
-OpenGLWindowImpl::OpenGLWindowImpl(SystemChildWindow* pWindow)
+OpenGLWindowImpl::OpenGLWindowImpl(Window* pWindow):
+ mpChildWindow(new SystemChildWindow(pWindow))
{
- maContext.init(pWindow);
+ maContext.init(mpChildWindow.get());
pWindow->SetMouseTransparent(false);
+ maContext.show();
}
OpenGLContext* OpenGLWindowImpl::getContext()
@@ -32,7 +35,7 @@ OpenGLContext* OpenGLWindowImpl::getContext()
}
OpenGLWindow::OpenGLWindow(Window* pParent):
- SystemChildWindow(pParent, 0),
+ Window(pParent, 0),
mpImpl(new OpenGLWindowImpl(this)),
mpRenderer(NULL)
{
@@ -57,6 +60,7 @@ void OpenGLWindow::Paint(const Rectangle&)
void OpenGLWindow::MouseButtonDown( const MouseEvent& rMEvt )
{
+ getContext()->show();
maStartPoint = rMEvt.GetPosPixel();
}
More information about the Libreoffice-commits
mailing list