Commit 0a0b43ed authored by Clinton Stimpson's avatar Clinton Stimpson Committed by Dave DeMarle
Browse files

Fix QVTKWidget problem on Windows with Aero off.

Need to invalidate the whole region at the start of WM_PAINT so the
desktop compositor will composite the whole area.

Change-Id: Id659f35ecbac16466d7ff68603607dff2d40c50e
parent 5b50df2a
......@@ -47,6 +47,10 @@
#include "qx11info_x11.h"
#endif
#if defined(Q_WS_WIN)
# include <windows.h>
#endif
#include "vtkInteractorStyleTrackballCamera.h"
#include "vtkRenderWindow.h"
#if defined(QVTK_USE_CARBON)
......@@ -821,6 +825,17 @@ void QVTKWidget::x11_setup_window()
#endif
}
#if defined(Q_WS_WIN)
bool QVTKWidget::winEvent(MSG* msg, long*)
{
if(msg->message == WM_PAINT)
{
InvalidateRect(this->winId(), NULL, FALSE);
}
return false;
}
#endif
#if defined (QVTK_USE_CARBON)
OSStatus QVTKWidget::DirtyRegionProcessor(EventHandlerCallRef, EventRef event, void* wid)
{
......
......@@ -247,6 +247,10 @@ protected:
// that VTK chooses
void x11_setup_window();
#if defined(Q_WS_WIN)
bool winEvent(MSG* msg, long* result);
#endif
#if defined(QVTK_USE_CARBON)
EventHandlerUPP DirtyRegionHandlerUPP;
EventHandlerRef DirtyRegionHandler;
......
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