< prev index next >

src/share/classes/sun/awt/image/BufImgSurfaceData.java

Print this page

        

@@ -1,7 +1,7 @@
 /*
- * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2018, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 only, as
  * published by the Free Software Foundation.  Oracle designates this

@@ -23,11 +23,10 @@
  * questions.
  */
 
 package sun.awt.image;
 
-import java.awt.Color;
 import java.awt.Rectangle;
 import java.awt.GraphicsConfiguration;
 import java.awt.image.ColorModel;
 import java.awt.image.SampleModel;
 import java.awt.image.DirectColorModel;

@@ -36,13 +35,10 @@
 import java.awt.image.BufferedImage;
 import java.awt.image.DataBuffer;
 
 import sun.java2d.SurfaceData;
 import sun.java2d.SunGraphics2D;
-import sun.java2d.StateTrackable;
-import sun.java2d.StateTrackable.*;
-import sun.java2d.StateTracker;
 import sun.java2d.loops.SurfaceType;
 import sun.java2d.loops.CompositeType;
 import sun.java2d.loops.RenderLoops;
 
 

@@ -407,12 +403,10 @@
     protected void checkCustomComposite() {
         // BufferedImages always allow Custom Composite objects since
         // their pixels are immediately retrievable anyway.
     }
 
-    private static native void freeNativeICMData(long pData);
-
     /**
      * Returns destination Image associated with this SurfaceData.
      */
     public Object getDestination() {
         return bufImg;

@@ -422,14 +416,7 @@
         private long pData = 0L;
 
         private ICMColorData(long pData) {
             this.pData = pData;
         }
-
-        public void finalize() {
-            if (pData != 0L) {
-                BufImgSurfaceData.freeNativeICMData(pData);
-                pData = 0L;
-            }
-        }
     }
 }
< prev index next >