Register
Site Login
Site Search
Forums
Advertisement
Welcome to PocketMatrix. PocketMatrix is dedicated to providing the best online community for mobile device developers and enthusiests. What's new?

Problem with MainProc function


Problem with MainProc function

Postby PointOfLight » Nov 21, 2004 @ 4:59am

I'm trying to trap the WM_LBUTTONDOWN event in the MainProc function of my application. According to MSDN, the lParam$ variable is supposed to house the X value of the mouse in the LOWORD and the Y value in the HIWORD. However, when I do:

Code: Select all


x$ = LOWORD(lParam$);
y$ = HIWORD(lParam$);
2 lines; 0 keywds; 0 nums; 8 ops; 0 strs; 0 coms    Syntactic Coloring v0.4 - Dan East  


x$ actually contains the Y value of the mouse, and y$ is always 0. This used to work just fine. This is on the latest build of PPL, and I am using the GameAPI.
Eric Pankoke
Programmer
Point Of Light Software
http://www.polsoftware.com/
PointOfLight
pm Member
 
Posts: 525
Joined: Nov 2, 2003 @ 8:39pm


Postby kornalius » Nov 21, 2004 @ 5:16am

Oups, sorry should have mentionned it somewhere. The newest version of PPL passes the X mouse location in wParam$ and the Y location in the lParam$. It use to be passed in lParam$ only but this wouldn't support negative mouse location. Check Simple.ppl to see how it works now. wParam$ is the X value and lParam$ is the Y$ value.

Sorry again.
Regards,
Kornalius
President
ArianeSoft Inc.
http://www.arianesoft.ca
User avatar
kornalius
pm Member
 
Posts: 1704
Joined: Dec 9, 2003 @ 6:04pm
Location: Montreal, Québec, Canada


Postby PointOfLight » Nov 21, 2004 @ 5:23am

Didn't wParam already house a value? Or was that value not applicable in the WinCE world?
Eric Pankoke
Programmer
Point Of Light Software
http://www.polsoftware.com/
PointOfLight
pm Member
 
Posts: 525
Joined: Nov 2, 2003 @ 8:39pm


Postby kornalius » Nov 21, 2004 @ 5:03pm

The wParam indicates whether various virtual keys are down. This is not neccessary imo with the GameAPI.
Regards,
Kornalius
President
ArianeSoft Inc.
http://www.arianesoft.ca
User avatar
kornalius
pm Member
 
Posts: 1704
Joined: Dec 9, 2003 @ 6:04pm
Location: Montreal, Québec, Canada


Postby PointOfLight » Nov 21, 2004 @ 6:50pm

Okay. I didn't realize that this was just for the GameAPI. That makes sense.
Eric Pankoke
Programmer
Point Of Light Software
http://www.polsoftware.com/
PointOfLight
pm Member
 
Posts: 525
Joined: Nov 2, 2003 @ 8:39pm


Return to Pocket Programming Language (PPL)


Sort


Forum Description

Discuss this new development tool.

Moderator:

kornalius

Forum permissions

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

cron