javaquery/api/src/main/java/org/apidesign/bck2brwsr/htmlpage/HTML5GraphicsEnvironment.java
1.1 --- a/javaquery/api/src/main/java/org/apidesign/bck2brwsr/htmlpage/HTML5GraphicsEnvironment.java Mon Sep 23 07:09:13 2013 -0700
1.2 +++ b/javaquery/api/src/main/java/org/apidesign/bck2brwsr/htmlpage/HTML5GraphicsEnvironment.java Fri Sep 27 00:41:07 2013 +0200
1.3 @@ -257,7 +257,7 @@
1.4
1.5 @JavaScriptBody(args = {"context", "obj"}, body = "context.strokeStyle=obj;")
1.6 private native void setStrokeStyleImpl(Object context, Object obj);
1.7 -
1.8 +/*
1.9 @JavaScriptBody(args = {"color"}, body = "this._context().shadowColor=color.valueOf();")
1.10 @Override
1.11 public native void setShadowColor(String color);
1.12 @@ -292,7 +292,7 @@
1.13 @JavaScriptBody(args = {}, body = "return this._context().shadowOffsetY;")
1.14 @Override
1.15 public native double getShadowOffsetY();
1.16 -
1.17 +*/
1.18 @JavaScriptBody(args = {}, body = "return this._context().lineCap;")
1.19 @Override
1.20 public native String getLineCap();
1.21 @@ -376,16 +376,16 @@
1.22 @JavaScriptBody(args = {"text", "x", "y", "maxWidth"}, body = "this._context().strokeText(text,x,y,maxWidth);")
1.23 @Override
1.24 public native void strokeText(String text, double x, double y, double maxWidth);
1.25 -
1.26 +/*
1.27 @Override
1.28 public ImageData createPixelMap(double x, double y) {
1.29 return new ImageDataWrapper(createPixelMapImpl(x, y));
1.30 }
1.31 -
1.32 +*/
1.33 @JavaScriptBody(args = {"x", "y"},
1.34 body = "return this._context().createImageData(x,y);")
1.35 private native Object createPixelMapImpl(double x, double y);
1.36 -
1.37 +/*
1.38 @Override
1.39 public ImageData createPixelMap(ImageData imageData) {
1.40 return new ImageDataWrapper(createPixelMapImpl(imageData.getWidth(), imageData.getHeight()));
1.41 @@ -395,25 +395,25 @@
1.42 public ImageData getPixelMap(double x, double y, double width, double height) {
1.43 return new ImageDataWrapper(getPixelMapImpl(x, y, width, height));
1.44 }
1.45 -
1.46 +*/
1.47 @JavaScriptBody(args = {"x", "y", "width", "height"},
1.48 body = "return this._context().getImageData(x,y,width,height);")
1.49 private native Object getPixelMapImpl(double x, double y, double width, double height);
1.50 -
1.51 +/*
1.52 @Override
1.53 public void putPixelMap(ImageData imageData, double x, double y) {
1.54 putPixelMapImpl(((ImageDataWrapper) imageData).object(), x, y);
1.55 }
1.56 -
1.57 +*/
1.58 @JavaScriptBody(args = {"imageData", "x", "y"},
1.59 body = "this._context().putImageData(imageData,x,y);")
1.60 private native void putPixelMapImpl(Object imageData, double x, double y);
1.61 -
1.62 +/*
1.63 @Override
1.64 public void putPixelMap(ImageData imageData, double x, double y, double dirtyx, double dirtyy, double dirtywidth, double dirtyheight) {
1.65 putPixelMapImpl(((ImageDataWrapper) imageData).object(), x, y, dirtyx, dirtyy, dirtywidth, dirtyheight);
1.66 }
1.67 -
1.68 +*/
1.69 @JavaScriptBody(args = {"imageData", "x", "y", "dirtyx", "dirtyy", "dirtywidth", "dirtyheight"},
1.70 body = "this._context().putImageData(imageData,x,y, dirtyx, dirtyy, dirtywidth,dirtyheight);")
1.71 private native void putPixelMapImpl(Object imageData, double x, double y, double dirtyx, double dirtyy, double dirtywidth, double dirtyheight);
1.72 @@ -466,7 +466,7 @@
1.73 public int getWidth() {
1.74 return canvas.getWidth();
1.75 }
1.76 -
1.77 +/*
1.78 @Override
1.79 public void setHeight(int height) {
1.80 canvas.setHeight(height);
1.81 @@ -476,7 +476,7 @@
1.82 public void setWidth(int width) {
1.83 canvas.setWidth(width);
1.84 }
1.85 -
1.86 +*/
1.87 // @JavaScriptBody(args = {"src"}, body = "var image = new Image();console.log('image complete '+image.complete);image.src = './'+ src; return image;")
1.88 @JavaScriptBody(args = {"src"}, body = "console.log ('looking up image by id '+src);return document.getElementById(src);")
1.89 private static native Object createImage(String src);