changeset 4647:b0a1b8b91e3b

Fix to RT-32202: Reduce the scope of NGShape3D's members and methods Reviewed by Kevin
author Chien Yang <chien.yang@orcale.com>
date Fri, 09 Aug 2013 14:27:08 -0700
parents 8d527964b7aa
children a05473e09c47
files modules/graphics/src/main/java/com/sun/javafx/sg/prism/NGShape3D.java
diffstat 1 files changed, 10 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/modules/graphics/src/main/java/com/sun/javafx/sg/prism/NGShape3D.java	Fri Aug 09 14:25:20 2013 -0700
+++ b/modules/graphics/src/main/java/com/sun/javafx/sg/prism/NGShape3D.java	Fri Aug 09 14:27:08 2013 -0700
@@ -40,12 +40,12 @@
  * TODO: 3D - Need documentation
  */
 public abstract class NGShape3D extends NGNode {
-    protected NGPhongMaterial material;
-    protected DrawMode drawMode;
-    protected CullFace cullFace;
-    protected boolean materialDirty = false;
-    protected boolean drawModeDirty = false;
-    protected NGTriangleMesh mesh;
+    private NGPhongMaterial material;
+    private DrawMode drawMode;
+    private CullFace cullFace;
+    private boolean materialDirty = false;
+    private boolean drawModeDirty = false;
+    NGTriangleMesh mesh;
     private MeshView meshView;
 
     public void setMaterial(NGPhongMaterial material) {
@@ -64,12 +64,12 @@
         visualsChanged();
     }
 
-    protected void invalidate() {
+    void invalidate() {
         meshView = null;
         visualsChanged();
     }
 
-    protected void renderMeshView(Graphics g) {
+    private void renderMeshView(Graphics g) {
 
         //validate state
         g.setup3DRendering();
@@ -176,16 +176,13 @@
         return value < 1.0f ? ((value < 0.0f) ? 0.0f : value) : 1.0f;
     }
 
-    protected void setMesh(NGTriangleMesh triangleMesh) {
+    public void setMesh(NGTriangleMesh triangleMesh) {
         this.mesh = triangleMesh;
         meshView = null;
         visualsChanged();
     }
 
-    protected NGTriangleMesh getMesh() {
-        return mesh;
-    }
-
+    @Override
     protected void renderContent(Graphics g) {
 
         if (!Platform.isSupported(ConditionalFeature.SCENE3D) || material == null) {