|
Posted by Grzegorz Aksamit on October 16, 2008, 9:42 am
Please log in for more thread options Well, I'm not getting any WM_LBUTTONDOWN msg because my applicaiton is
windowless, so there is nothing that could receive it. My application
is an DLL service for services.exe
show/hide quoted text
> Did you try to use this call during WM_LBUTTONDOWN processing ?
> wrote:
> > > Hi,
> > > did you try to use GetMessagePos() ?
> > >http://msdn.microsoft.com/en-us/library/aa925001.aspx
> > > DWORD ptDw =3D GetMessagePos();
> > > POINTS pts =3D MAKEPOINTS(ptDw);
> > > POINT point;
> > > point.x =3D pts.x;
> > > point.y =3D pts.y;
> > > Regards,
> > > Dmitry
> > > you could try GetMessagePos
> > > wrote:
> > > > Hi,
> > > > I'm using GetAsyncKeyState(VK_LBUTTON) to asynchronously check for
> > > > stylus tap in my C++ native windows mobile application. The problem=
is
show/hide quoted text
> > > > that I need tap position (coordinates) too. Unfortunately
> > > > GetCursorPos() doesn't seem to work. I tried something like this:
> > > > if( GetAsyncKeyState(VK_LBUTTON) < 0 ) {
> > > > POINT pos;
> > > > BOOL ret =3D GetCursorPos(&pos);
> > > > // ...
> > > > }
> > > > On my windows mobile 5 device, GetCursorPos() always returns false.
> > > > My application is completely windowless so I don't have a window th=
at
show/hide quoted text
> > > > could catch any of WM_* messages (which contain tap position in wPa=
ram
show/hide quoted text
> > > > or lParam afaik).
> > > > Any idea how I could get tap position asynchronously together with
> > > > GetAsyncKeyState() ?
> > > > Regards
> > > > Grzegorz Aksamit
> > I just tried. It returns 0 all the time.- Hide quoted text -
> > - Show quoted text -
|
> I'm using GetAsyncKeyState(VK_LBUTTON) to asynchronously check for
> stylus tap in my C++ native windows mobile application. The problem is
> that I need tap position (coordinates) too. Unfortunately
> GetCursorPos() doesn't seem to work. I tried something like this:
> if( GetAsyncKeyState(VK_LBUTTON) < 0 ) {
> POINT pos;
> BOOL ret =3D GetCursorPos(&pos);
> // ...
> }
> On my windows mobile 5 device, GetCursorPos() always returns false.
> My application is completely windowless so I don't have a window that
> could catch any of WM_* messages (which contain tap position in wParam
> or lParam afaik).
> Any idea how I could get tap position asynchronously together with
> GetAsyncKeyState() ?
> Regards
> Grzegorz Aksamit