Java Standard Edition (SE)
- Enclosing class:
public class AsyncBoxView.ChildLocator
A class to manage the effective position of the
child views in a localized area while changes are
being made around the localized area. The AsyncBoxView
may be continuously changing, but the visible area
needs to remain fairly stable until the layout thread
decides to publish an update to the parent.
|Constructor and Description
construct a child locator.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public void childChanged(AsyncBoxView.ChildState cs)
Notification that a child changed. This can effect
whether or not new offset calculations are needed.
This is called by a ChildState object that has
changed it's major span. This can therefore be
called by multiple threads.
public Shape getChildAllocation(int index,
Fetch the allocation to use for a child view.
This will update the offsets for all children
not yet updated before the given index.
public int getViewIndexAtPoint(float x,
Fetches the child view index at the given point.
This is called by the various View methods that
need to calculate which child to forward a message
to. This should be called by a block synchronized
on this object, and would typically be followed
with one or more calls to getChildAllocation that
should also be in the synchronized block.
x - the X coordinate >= 0
y - the Y coordinate >= 0
a - the allocation to the View
- the nearest child index
protected void setAllocation(Shape a)
Copy the currently allocated shape into the Rectangle
used to store the current allocation. This would be
a floating point rectangle in a Java2D-specific implementation.
protected int getViewIndexAtVisualOffset(float targetOffset)
Locate the view responsible for an offset into the box
along the major axis. Make sure that offsets are set
on the ChildState objects up to the given target span
past the desired offset.
- index of the view representing the given visual
location (targetOffset), or -1 if no view represents
Java Enterprise Edition (EE)
Java Standard Edition (SE)
RFC (standard status)
RFC (proposed standard status)
RFC (draft standard status)
RFC (informational status)
RFC (experimental status)
RFC (best current practice status)
RFC (historic status)
RFC (unknown status)
All information of this service is derived from the free sources and is provided solely in the form of quotations.
This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 79 / 159134829. Delta: 0.04248 с