WinCE device, no thumb dragging for GUI scrollbars

You discovered a bug in the engine, and you are sure that it is not a problem of your code? Just post it in here. Please read the bug posting guidelines first.
Post Reply
rvl2
Posts: 6
Joined: Sun Aug 23, 2009 10:43 am

WinCE device, no thumb dragging for GUI scrollbars

Post by rvl2 »

Scrollbar's thumb is not dragged on my PDA due forgotten updates of mouse button state. Minimal patch for current ogl-es branch:

Code: Select all

Index: CIrrDeviceWinCE.cpp
===================================================================
--- CIrrDeviceWinCE.cpp	(revision 2662)
+++ CIrrDeviceWinCE.cpp	(working copy)
@@ -140,6 +140,7 @@
 		event.MouseInput.Event = irr::EMIE_LMOUSE_PRESSED_DOWN;
 		event.MouseInput.X = (short)LOWORD(lParam);
 		event.MouseInput.Y = (short)HIWORD(lParam);
+		event.MouseInput.ButtonStates = wParam & MK_LBUTTON;
 		dev = getDeviceFromHWnd(hWnd);
 		if (dev)
 			dev->postEventFromUser(event);
@@ -222,6 +223,7 @@
 		event.MouseInput.Event = irr::EMIE_MOUSE_MOVED;
 		event.MouseInput.X = (short)LOWORD(lParam);
 		event.MouseInput.Y = (short)HIWORD(lParam);
+		event.MouseInput.ButtonStates = wParam & MK_LBUTTON;
 		dev = getDeviceFromHWnd(hWnd);
 
 		if (dev)
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Ok, I've copied some more from the win32 device and put everything into the 1.6 branch for now. But I guess we need some common subclass to save the whole copy'n'paste thing here. Will be approached for Irrlicht 1.7, together with the OpenGL synchronisation and DirectX merging.
Post Reply