From 9486ad42e12884e2b3f40cbd76fba2cf889a416f Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Sun, 20 Mar 2016 08:12:28 +0100 Subject: Fix parent check. --- plugingui/nativewindow_win32.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'plugingui') diff --git a/plugingui/nativewindow_win32.cc b/plugingui/nativewindow_win32.cc index e4a1e73..d7e0e06 100644 --- a/plugingui/nativewindow_win32.cc +++ b/plugingui/nativewindow_win32.cc @@ -372,7 +372,7 @@ void NativeWindowWin32::hide() void NativeWindowWin32::redraw() { - if(parent_window) + if(parent_window == nullptr) { RedrawWindow(m_hwnd, nullptr, nullptr, RDW_ERASE|RDW_INVALIDATE); UpdateWindow(m_hwnd); @@ -408,7 +408,7 @@ bool NativeWindowWin32::hasEvent() } // Parented windows have their event loop somewhere else. - if(parent_window) + if(parent_window == nullptr) { MSG msg; return PeekMessage(&msg, m_hwnd, 0, 0, PM_NOREMOVE) != 0; @@ -427,7 +427,7 @@ Event* NativeWindowWin32::getNextEvent() } // Parented windows have their event loop somewhere else. - if(parent_window) + if(parent_window == nullptr) { MSG msg; if(GetMessage(&msg, m_hwnd, 0, 0)) @@ -456,7 +456,7 @@ Event* NativeWindowWin32::peekNextEvent() } // Parented windows have their event loop somewhere else. - if(parent_window) + if(parent_window == nullptr) { MSG msg; if(PeekMessage(&msg, m_hwnd, 0, 0, PM_NOREMOVE)) -- cgit v1.2.3