|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.tensegrity.composite.CompositeViewOperations
The CompositeViewOperations class provides some basic
functionalities that can be used when working with a
CompositeView.
| Field Summary | |
static double |
MAXIMUM_ZOOM_LIMIT
Constants for the zoom limits |
static double |
MINIMUM_ZOOM_LIMIT
Constants for the zoom limits |
static int |
TRANSLATE_CENTERED
constant that defines a translation mode |
static int |
TRANSLATE_CENTERED_IF_NOT_VISIBLE
constant that defines a translation mode |
| Method Summary | |
static void |
gatherComposites(BaseCompositeContainer bcc,
java.util.List list)
Gathers recursively all BaseComposites of the
given BaseCompositeContainer |
static int |
getModifierMask(CompositeView view)
Creates a modifier mask from the pressed keys SHIFT, ALT and CONTROL in the given CompositeView. |
static BoundingBox |
getViewBoundingBox(CompositeView view,
int calculationFlags)
Returns the view boundaries of the given view. |
static java.util.Map |
recursiveEventDisable_SelectionChange(CompositeView compositeview)
Recursively disables selection-change events and returns a Map that is filled with Lists of the currently
selected BaseComposite objects.
|
static void |
recursiveEventEnable_SelectionChange(CompositeView compositeview,
java.util.Map mappedSelectionOld)
Recursively enables beforehand disabled selection-change events and raises those events if a corresponding List with the old
selected BaseComposite objects can be found in the
Map given by mappedSelectionOld.
|
static void |
recursiveSelection(CompositeView compositeview,
boolean selection)
Recursively sets all the BaseComposite objects that are contained
in the specified CompositeView to the desired
selection-state.
|
static void |
translateSelection(CompositeView compositview,
int mode)
Translates the current selection of the CompositeView given
by compositeview so that it becomes visible in the
CompositeViews viewport. |
static void |
translateViewport(CompositeView compositeview,
Boundary bbox,
int mode)
Translates the viewport of the CompositeView given by
compositeview with regard to the translation mode given by
mode. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final double MINIMUM_ZOOM_LIMIT
public static final double MAXIMUM_ZOOM_LIMIT
public static final int TRANSLATE_CENTERED
public static final int TRANSLATE_CENTERED_IF_NOT_VISIBLE
| Method Detail |
public static final void translateSelection(CompositeView compositview,
int mode)
CompositeView given
by compositeview so that it becomes visible in the
CompositeViews viewport. The translation is done with
regards to the tranlation mode given by mode. The possible
modes are defined through constants of this class.
compositview - the CompositeView.mode - the translation mode. Valid modes are
TRANSLATE_CENTERED and
TRANSLATE_CENTERED_IF_NOT_VISIBLE.
public static final void translateViewport(CompositeView compositeview,
Boundary bbox,
int mode)
CompositeView given by
compositeview with regard to the translation mode given by
mode. The possible modes are defined through constants of
this class.
compositeview - the CompositeViewbbox - the bounding box to translate the CompositeViews
viewport to.mode - the translation mode.public static int getModifierMask(CompositeView view)
CompositeView.
view - The view to get the pressed keys of
public static void gatherComposites(BaseCompositeContainer bcc,
java.util.List list)
BaseComposites of the
given BaseCompositeContainer
bcc - The container to gather elements fromlist - The list to add the items topublic static final java.util.Map recursiveEventDisable_SelectionChange(CompositeView compositeview)
Recursively disables selection-change events and returns a
Map that is filled with Lists of the currently
selected BaseComposite objects.
The returned Map is organized such that a certain
BaseCompositeContainer instance is the key for its
List of former selected BaseComposite objects.
If the selection-change event was disabled beforehand no entry is
created in the Map.
compositeview - the CompositeView to process.
Map filled with Lists of the
currently selected BaseComposite objects.recursiveEventEnable_SelectionChange(CompositeView, Map)
public static final void recursiveEventEnable_SelectionChange(CompositeView compositeview,
java.util.Map mappedSelectionOld)
Recursively enables beforehand disabled selection-change events and
raises those events if a corresponding List with the old
selected BaseComposite objects can be found in the
Map given by mappedSelectionOld.
The Map should be organized such that the
BaseCompositeContainer instance is the key for the
List of former selected BaseComposite objects.
compositeview - the CompositeView to process.mappedSelectionOld - used to find the List with the
former selected BaseComposite objects of a certain
BaseCompositeContainer.recursiveEventDisable_SelectionChange(CompositeView)
public static final void recursiveSelection(CompositeView compositeview,
boolean selection)
Recursively sets all the BaseComposite objects that are contained
in the specified CompositeView to the desired
selection-state.
BaseComposite objects that are nested in embedded
BaseCompositeContainer objects are processed as well.
compositeview - the CompositeView to process.recursiveEventDisable_SelectionChange(CompositeView),
recursiveEventEnable_SelectionChange(CompositeView, Map)
public static BoundingBox getViewBoundingBox(CompositeView view,
int calculationFlags)
CompositeNavigatorProvider.getCompositeBoundingBox()
to control how to compute the bounding box.
This method internally uses Composite.getBoundingBox(int)
whenever possible and passes the given calculation flags to that method.
view - The view to calculate the boundaries ofcalculationFlags - Flags to control the calculation.
Composite.getBoundingBox(int)
BoundingBox
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||