Release response as input for HitTest

David McFarlane mcfarla9 at msu.edu
Tue Nov 22 17:07:54 UTC 2011


Maja,

Your question entails two things:  (1) Getting a "release" response, 
and  (2) using that with HitTest.  I assume that you have a handle on 
#1 (otherwise, start with the "{key} nomenclature" topic in the 
E-Basic Help facility), and I will give you only a hint for #2.

If you look at the SlideState.HitTest topic in the E-Basic Help, then 
you will notice that HitTest will take any arbitrary x, y values for 
its arguments.  HitTest does not care where those x, y values come 
from.  So you merely need to get the mouser cursor position at the 
time of release and then feed that to HitTest.

Hmm, now that I think of it, forget about "release" responses.  If 
you already have drag & drop code working, then you probably already 
directly address the mouse (see the MouseDevice topic in the EB 
Help).  In that case, simply do what you already do to drag the 
object, and then when done dragging feed the final cursor postion in 
to HitTest.  That's how I would go.

-- David McFarlane


At 11/22/2011 04:53 AM Tuesday, you wrote:
>Hi everyone,
>
>I have been searching the support and google group posts for checking
>whether I can do a HitTest with a release response? Participants are
>going to move objects and release them at certain goal positions which
>are going to be scored either as accurate or inaccurate. I am
>attempting to modify the click and drag sample script, but would like
>to check for more elegant solutions. Do you have any suggestions how
>set the release mouse coordinates as input for the HitTest variable?
>Or any hints whether the same has been already discussed?
>
>Thanks advance!
>Maja

-- 
You received this message because you are subscribed to the Google Groups "E-Prime" group.
To post to this group, send email to e-prime at googlegroups.com.
To unsubscribe from this group, send email to e-prime+unsubscribe at googlegroups.com.
For more options, visit this group at http://groups.google.com/group/e-prime?hl=en.



More information about the Eprime mailing list