The edge flags won't tell you this happened, they are just set when the down
event is at the edge of the screen.  You can do the same thing yourself just
by looking at the coordinates of the event and seeing if it is at your edge.

I don't think there is any information coming from the touch driver to help
you determine what you want.  Note that once a down happens, the platform
continues to deliver movement events to your view until an up occurs, even
if those events go out of your view or even off the visible area of the
screen but still seen by the digitizer.  You will see these as coordinates
extending outside of your view.  The point where you get the up event is
whenever as far as everyone is concerned that finger is actually no longer
touching the screen.

On Wed, Apr 6, 2011 at 9:41 AM, Paul <[email protected]> wrote:

> Hi Dianne.  My app defines the individual swipes of the user on the
> drawing canvas as 'gestures', in that each has a start on finger down,
> an end on finger up, and is in progress in between those two events.
> When the user is drawing close to the edge of the screen, and touches
> it, the break in MotionEvents to the gesture detector results in the
> end of the gesture event being fired off and when their finger is
> brought back onto the screen, still in the continuous motion, this is
> registered as an onDown and a new, second stroke is started.  So for
> example, if the user is drawing a stroke in an arc that is meant to go
> close to the edge but not touch it, but they touch it by accident,
> there will be two unique strokes that are discontinuous and would not
> represent the user's intent.
>
> If I can determine that I have an edge case while the gesture is in
> progress, I am thinking that I may be able to handle this case in a
> more intuitive or expected manor, for instance signaling my app to not
> register the second stroke.
>
> It's not the end of the world if this is 'the way it is', but was just
> going to try to play around and see what I could do with the edgeFlags
> to improve this behavior.
>
> Thanks,
>
> Paul
>
> On Mar 22, 5:06 pm, Dianne Hackborn <[email protected]> wrote:
> > Why do you want this?  It is used for some subtle event dispatching in
> the
> > view hierarchy to better select target views when touching near the edge
> of
> > the screen.  I strongly recommend you not rely on it yourself.
> >
> >
> >
> > On Tue, Mar 22, 2011 at 5:59 AM, Paul <[email protected]> wrote:
> > > Looking over older posts, I found this:
> >
> > >http://groups.google.com/group/android-developers/browse_thread/threa.
> ..
> >
> > > So it's 2011 now, and I am using the emulator and a Galaxy Tab both
> > > running 2.2, and I can't for the life of me get the MotionEvent's
> > > passed from a simple full-screen drawing app to report a
> > > getEdgeFlags() value of anything other than 0.
> >
> > > Anyone else have this issue, or a workaround for it?
> >
> > > Thanks,
> >
> > > Paul
> >
> > > --
> > > You received this message because you are subscribed to the Google
> > > Groups "Android Developers" group.
> > > To post to this group, send email to
> [email protected]
> > > To unsubscribe from this group, send email to
> > > [email protected]
> > > For more options, visit this group at
> > >http://groups.google.com/group/android-developers?hl=en
> >
> > --
> > Dianne Hackborn
> > Android framework engineer
> > [email protected]
> >
> > Note: please don't send private questions to me, as I don't have time to
> > provide private support, and so won't reply to such e-mails.  All such
> > questions should be posted on public forums, where I and others can see
> and
> > answer them.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Dianne Hackborn
Android framework engineer
[email protected]

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to