Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 10b6290c authored by Jeff Brown's avatar Jeff Brown
Browse files

Only handle onHoverEvent in actionable views.

Modified onHoverEvent so that a view only has its state changed to
hovered when the view is clickable.  The intent is to prevent labels
from taking hover focus away from their containing view group despite
not being actionable in any way.  The child will still receive
a hover event but, if it does not handle the event (returns false),
the hover event will bubble up to its parent and ancestors allowing
them a chance to handle the event instead.

The new onHoverEvent semantics are better because now they closely
mirror those of onTouchEvent.  This makes it straightforward to
implement views that respond to hover by changing their visual
appearance (such as by making buttons glow when hovered).

Added onInterceptHoverEvent to enable ViewGroups to explicitly
intercept hover events within their bounds.

Exposed the new hover event API for real.

Change-Id: I63195c8f5c74b859f6047487f9a0f703e8f40ffe
parent 738e7e43
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment