aboutsummaryrefslogtreecommitdiffstats
path: root/src/classes/share
diff options
context:
space:
mode:
authorHarvey Harrison <[email protected]>2012-03-03 13:21:08 -0800
committerHarvey Harrison <[email protected]>2012-03-03 13:21:08 -0800
commit49e5df194fc268c9e5e4fdeb214db8c5cab89fae (patch)
tree6ba3ef65503cf081e76c722387e05cdeff67ccaa /src/classes/share
parent2949a666c94bc735a55aff29935d30533d701a1a (diff)
j3dcore: annotate list of Views in ViewPlatformRetained
Signed-off-by: Harvey Harrison <[email protected]>
Diffstat (limited to 'src/classes/share')
-rw-r--r--src/classes/share/javax/media/j3d/ViewPlatformRetained.java60
1 files changed, 30 insertions, 30 deletions
diff --git a/src/classes/share/javax/media/j3d/ViewPlatformRetained.java b/src/classes/share/javax/media/j3d/ViewPlatformRetained.java
index b0833cf..a34df45 100644
--- a/src/classes/share/javax/media/j3d/ViewPlatformRetained.java
+++ b/src/classes/share/javax/media/j3d/ViewPlatformRetained.java
@@ -54,11 +54,11 @@ class ViewPlatformRetained extends LeafRetained {
*/
int viewAttachPolicy = View.NOMINAL_HEAD;
- /**
- * The list of views associated with this view platform.
- * Use getViewList() to access this variable.
- */
- private ArrayList viewList = new ArrayList();
+/**
+ * The list of views associated with this view platform.
+ * Use getViewList() to access this variable.
+ */
+private ArrayList<View> viewList = new ArrayList<View>();
/**
* Cached list of viewList for synchronization
@@ -179,26 +179,26 @@ class ViewPlatformRetained extends LeafRetained {
return (float) sphere.getRadius();
}
- /**
- * This sets the view that is associated with this view platform.
- */
- void setView(View v) {
+/**
+ * This sets the view that is associated with this view platform.
+ */
+void setView(View v) {
synchronized (viewList) {
- if (!viewList.contains(v)) {
- viewList.add(v);
- }
- viewListDirty = true;
+ if (!viewList.contains(v)) {
+ viewList.add(v);
+ }
+ viewListDirty = true;
}
- }
+}
- void removeView(View v) {
+void removeView(View v) {
synchronized (viewList) {
- if (viewList.contains(v)) {
- viewList.remove(viewList.indexOf(v));
- }
- viewListDirty = true;
+ if (viewList.contains(v)) {
+ viewList.remove(viewList.indexOf(v));
+ }
+ viewListDirty = true;
}
- }
+}
Transform3D getVworldToVpc() {
if (vworldToVpc == null)
@@ -378,18 +378,18 @@ class ViewPlatformRetained extends LeafRetained {
}
}
- /**
- * Get a copy of cached view list
- */
- View[] getViewList() {
+/**
+ * Get a copy of cached view list
+ */
+View[] getViewList() {
synchronized (viewList) {
- if (viewListDirty) {
- views = (View []) viewList.toArray(new View[viewList.size()]);
- viewListDirty = false;
- }
- return views;
+ if (viewListDirty) {
+ views = viewList.toArray(new View[viewList.size()]);
+ viewListDirty = false;
+ }
+ return views;
}
- }
+}
/**
* Use by BehaviorStructure to determine whether current