0025362: Samples - Conversion to B-Spline doesn't show bspline surface on Windows 8
authorski <ski@opencascade.com>
Wed, 23 Nov 2016 07:24:20 +0000 (10:24 +0300)
committerapn <apn@opencascade.com>
Fri, 25 Nov 2016 09:38:22 +0000 (12:38 +0300)
Added constants WM_MOUSEFIRST and WM_PAINT in WaitForInput method for correct handling of system messages.

samples/mfc/standard/10_Convert/src/OCCDemo_Presentation.cpp

index 4b3554b..9097ec2 100755 (executable)
@@ -39,7 +39,9 @@ Standard_Boolean OCCDemo_Presentation::WaitForInput (unsigned long aMilliSeconds
     MSG msg;
     if (::PeekMessage (&msg, NULL, 0, 0, PM_NOREMOVE))
     {
-      if (msg.message == WM_KEYUP)
+      if ( msg.message == WM_KEYUP ||
+           msg.message == WM_MOUSEFIRST ||
+           msg.message == WM_PAINT )
       {
         ::PeekMessage (&msg, NULL, 0, 0, PM_REMOVE);
         return WaitForInput (aMilliSeconds);