flex-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Harbs <harbs.li...@gmail.com>
Subject Re: FlexJS hitTestPoint
Date Thu, 28 Jul 2016 06:03:09 GMT
The other piece of this is stage.getObjectsUnderPoint.

It would be nice to wrap that as well. The question is where to do that. HTMLElementWrapper
as well? What about getting global objects? There’s no “stage” is there?

On Jul 28, 2016, at 8:58 AM, Harbs <harbs.lists@gmail.com> wrote:

> Any suggestions on how to implement this?
> 
> Should we just add a hitTestPoint function to HTMLElementWrapper that behaves like the
Flash version?
> 
> I’m not sure what to do about the shape flag. I think the HTML version takes shape
into account automatically.
> 
> On Jul 28, 2016, at 8:46 AM, Alex Harui <aharui@adobe.com> wrote:
> 
>> 
>> 
>> On 7/27/16, 10:40 PM, "Harbs" <harbs.lists@gmail.com> wrote:
>> 
>>> I just found this:
>>> http://stackoverflow.com/questions/8813051/determine-which-element-the-mou
>>> se-pointer-is-on-top-of-in-javascript
>>> 
>>> Seems pretty straight-forward.
>> 
>> That points to [2], which has the following snippet:
>> 
>> "If the specified point is outside the visible bounds of the document or
>> either coordinate is negative, the result is null."
>> 
>> I think Flash supports negative coords for off-list calculations, but I
>> could be wrong.  But still it should be good enough for now.
>> 
>> -Alex
>> 
>> [2] 
>> https://developer.mozilla.org/en-US/docs/Web/API/Document/elementFromPoint
>> 
>> 
> 


Mime
View raw message