108 return new TraceFillRect(this); 109 } 110 111 private static class TraceFillRect extends FillRect { 112 FillRect target; 113 114 public TraceFillRect(FillRect target) { 115 super(target.getSourceType(), 116 target.getCompositeType(), 117 target.getDestType()); 118 this.target = target; 119 } 120 121 public GraphicsPrimitive traceWrap() { 122 return this; 123 } 124 125 public void FillRect(SunGraphics2D sg2d, SurfaceData dest, 126 int x, int y, int w, int h) 127 { 128 tracePrimitive(target); 129 target.FillRect(sg2d, dest, x, y, w, h); 130 } 131 } 132 } | 108 return new TraceFillRect(this); 109 } 110 111 private static class TraceFillRect extends FillRect { 112 FillRect target; 113 114 public TraceFillRect(FillRect target) { 115 super(target.getSourceType(), 116 target.getCompositeType(), 117 target.getDestType()); 118 this.target = target; 119 } 120 121 public GraphicsPrimitive traceWrap() { 122 return this; 123 } 124 125 public void FillRect(SunGraphics2D sg2d, SurfaceData dest, 126 int x, int y, int w, int h) 127 { 128 if ((traceflags & TRACEPTIME) == 0) { 129 tracePrimitive(target); 130 } 131 long time = System.nanoTime(); 132 target.FillRect(sg2d, dest, x, y, w, h); 133 tracePrimitiveTime(target, System.nanoTime() - time); 134 } 135 } 136 } |