aboutsummaryrefslogtreecommitdiffstats
path: root/src/classes/share
diff options
context:
space:
mode:
authorHarvey Harrison <[email protected]>2012-03-03 13:32:05 -0800
committerHarvey Harrison <[email protected]>2012-03-03 14:53:10 -0800
commitd4a73b8d8988df086a13b6609f7ee7eeb057a335 (patch)
tree97922e79c9b905d35e846bcc2f7ee1cc158f6e83 /src/classes/share
parent49e5df194fc268c9e5e4fdeb214db8c5cab89fae (diff)
j3dcore: only mark the cached view list as dirty if we actually change it
Signed-off-by: Harvey Harrison <[email protected]>
Diffstat (limited to 'src/classes/share')
-rw-r--r--src/classes/share/javax/media/j3d/ViewPlatformRetained.java8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/classes/share/javax/media/j3d/ViewPlatformRetained.java b/src/classes/share/javax/media/j3d/ViewPlatformRetained.java
index a34df45..47cb248 100644
--- a/src/classes/share/javax/media/j3d/ViewPlatformRetained.java
+++ b/src/classes/share/javax/media/j3d/ViewPlatformRetained.java
@@ -186,17 +186,15 @@ void setView(View v) {
synchronized (viewList) {
if (!viewList.contains(v)) {
viewList.add(v);
+ viewListDirty = true;
}
- viewListDirty = true;
}
}
void removeView(View v) {
synchronized (viewList) {
- if (viewList.contains(v)) {
- viewList.remove(viewList.indexOf(v));
- }
- viewListDirty = true;
+ if (viewList.remove(v))
+ viewListDirty = true;
}
}