diff --git a/jso/apis/src/main/java/org/teavm/jso/browser/Window.java b/jso/apis/src/main/java/org/teavm/jso/browser/Window.java index a111a998f..ba4c8c629 100644 --- a/jso/apis/src/main/java/org/teavm/jso/browser/Window.java +++ b/jso/apis/src/main/java/org/teavm/jso/browser/Window.java @@ -48,16 +48,16 @@ public abstract class Window implements JSObject, EventTarget, StorageProvider { public static native int setTimeout(TimerHandler handler, double delay); @JSBody(params = { "timeoutId" }, script = "clearTimeout(timeoutId);") - public abstract void clearTimeout(int timeoutId); + public static native void clearTimeout(int timeoutId); @JSBody(params = { "handler", "delay" }, script = "return setInverval(handler, delay);") - public abstract int setInterval(TimerHandler handler, int delay); + public static native int setInterval(TimerHandler handler, int delay); @JSBody(params = { "handler", "delay" }, script = "return setInverval(handler, delay);") - public abstract int setInterval(TimerHandler handler, double delay); + public static native int setInterval(TimerHandler handler, double delay); @JSBody(params = { "timeoutId" }, script = "clearInverval(timeoutId);") - public abstract void clearInterval(int timeoutId); + public static native void clearInterval(int timeoutId); @JSBody(params = {}, script = "return window;") public static native Window current(); diff --git a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Float32Array.java b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Float32Array.java index 73d2c6013..6199ebe8d 100644 --- a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Float32Array.java +++ b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Float32Array.java @@ -30,11 +30,11 @@ public abstract class Float32Array extends ArrayBufferView { public abstract void set(int index, float value); @JSBody(params = "length", script = "return new Float32Array(length);") - public static native ArrayBuffer create(int length); + public static native Float32Array create(int length); @JSBody(params = "buffer", script = "return new Float32Array(buffer);") - public static native ArrayBuffer create(ArrayBuffer buffer); + public static native Float32Array create(ArrayBuffer buffer); @JSBody(params = { "buffer", "offset", "length" }, script = "return new Float32Array(buffer, offset, length);") - public static native ArrayBuffer create(ArrayBuffer buffer, int offset, int length); + public static native Float32Array create(ArrayBuffer buffer, int offset, int length); } diff --git a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Float64Array.java b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Float64Array.java index ce2d5eeee..833ed1f80 100644 --- a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Float64Array.java +++ b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Float64Array.java @@ -30,11 +30,11 @@ public abstract class Float64Array extends ArrayBufferView { public abstract void set(int index, double value); @JSBody(params = "length", script = "return new Float64Array(length);") - public static native ArrayBuffer create(int length); + public static native Float64Array create(int length); @JSBody(params = "buffer", script = "return new Float64Array(buffer);") - public static native ArrayBuffer create(ArrayBuffer buffer); + public static native Float64Array create(ArrayBuffer buffer); @JSBody(params = { "buffer", "offset", "length" }, script = "return new Float64Array(buffer, offset, length);") - public static native ArrayBuffer create(ArrayBuffer buffer, int offset, int length); + public static native Float64Array create(ArrayBuffer buffer, int offset, int length); } diff --git a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int16Array.java b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int16Array.java index 33a969bfb..8a8d88c0f 100644 --- a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int16Array.java +++ b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int16Array.java @@ -30,11 +30,11 @@ public abstract class Int16Array extends ArrayBufferView { public abstract void set(int index, short value); @JSBody(params = "length", script = "return new Int16Array(length);") - public static native ArrayBuffer create(int length); + public static native Int16Array create(int length); @JSBody(params = "buffer", script = "return new Int16Array(buffer);") - public static native ArrayBuffer create(ArrayBuffer buffer); + public static native Int16Array create(ArrayBuffer buffer); @JSBody(params = { "buffer", "offset", "length" }, script = "return new Int16Array(buffer, offset, length);") - public static native ArrayBuffer create(ArrayBuffer buffer, int offset, int length); + public static native Int16Array create(ArrayBuffer buffer, int offset, int length); } diff --git a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int32Array.java b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int32Array.java index 5cf8ad59a..bf6f53e0a 100644 --- a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int32Array.java +++ b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int32Array.java @@ -30,11 +30,11 @@ public abstract class Int32Array extends ArrayBufferView { public abstract void set(int index, int value); @JSBody(params = "length", script = "return new Int32Array(length);") - public static native ArrayBuffer create(int length); + public static native Int32Array create(int length); @JSBody(params = "buffer", script = "return new Int32Array(buffer);") - public static native ArrayBuffer create(ArrayBuffer buffer); + public static native Int32Array create(ArrayBuffer buffer); @JSBody(params = { "buffer", "offset", "length" }, script = "return new Int32Array(buffer, offset, length);") - public static native ArrayBuffer create(ArrayBuffer buffer, int offset, int length); + public static native Int32Array create(ArrayBuffer buffer, int offset, int length); } diff --git a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int8Array.java b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int8Array.java index 38874fa7b..363acac0d 100644 --- a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int8Array.java +++ b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Int8Array.java @@ -30,11 +30,11 @@ public abstract class Int8Array extends ArrayBufferView { public abstract void set(int index, byte value); @JSBody(params = "length", script = "return new Int8Array(length);") - public static native ArrayBuffer create(int length); + public static native Int8Array create(int length); @JSBody(params = "buffer", script = "return new Int8Array(buffer);") - public static native ArrayBuffer create(ArrayBuffer buffer); + public static native Int8Array create(ArrayBuffer buffer); @JSBody(params = { "buffer", "offset", "length" }, script = "return new Int8Array(buffer, offset, length);") - public static native ArrayBuffer create(ArrayBuffer buffer, int offset, int length); + public static native Int8Array create(ArrayBuffer buffer, int offset, int length); } diff --git a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint16Array.java b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint16Array.java index c631b818e..cf19f33a2 100644 --- a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint16Array.java +++ b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint16Array.java @@ -30,11 +30,11 @@ public abstract class Uint16Array extends ArrayBufferView { public abstract void set(int index, int value); @JSBody(params = "length", script = "return new Uint8Array(length);") - public static native ArrayBuffer create(int length); + public static native Uint16Array create(int length); @JSBody(params = "buffer", script = "return new Uint8Array(buffer);") - public static native ArrayBuffer create(ArrayBuffer buffer); + public static native Uint16Array create(ArrayBuffer buffer); @JSBody(params = { "buffer", "offset", "length" }, script = "return new Uint8Array(buffer, offset, length);") - public static native ArrayBuffer create(ArrayBuffer buffer, int offset, int length); + public static native Uint16Array create(ArrayBuffer buffer, int offset, int length); } diff --git a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint8Array.java b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint8Array.java index d393f02af..efdb0658d 100644 --- a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint8Array.java +++ b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint8Array.java @@ -30,11 +30,11 @@ public abstract class Uint8Array extends ArrayBufferView { public abstract void set(int index, short value); @JSBody(params = "length", script = "return new Uint8Array(length);") - public static native ArrayBuffer create(int length); + public static native Uint8Array create(int length); @JSBody(params = "buffer", script = "return new Uint8Array(buffer);") - public static native ArrayBuffer create(ArrayBuffer buffer); + public static native Uint8Array create(ArrayBuffer buffer); @JSBody(params = { "buffer", "offset", "length" }, script = "return new Uint8Array(buffer, offset, length);") - public static native ArrayBuffer create(ArrayBuffer buffer, int offset, int length); + public static native Uint8Array create(ArrayBuffer buffer, int offset, int length); } diff --git a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint8ClampedArray.java b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint8ClampedArray.java index b373cc1c2..26aac42a5 100644 --- a/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint8ClampedArray.java +++ b/jso/apis/src/main/java/org/teavm/jso/typedarrays/Uint8ClampedArray.java @@ -30,12 +30,12 @@ public abstract class Uint8ClampedArray extends ArrayBufferView { public abstract void set(int index, int value); @JSBody(params = "length", script = "return new Uint8ClampedArray(length);") - public static native ArrayBuffer create(int length); + public static native Uint8ClampedArray create(int length); @JSBody(params = "buffer", script = "return new Uint8ClampedArray(buffer);") - public static native ArrayBuffer create(ArrayBuffer buffer); + public static native Uint8ClampedArray create(ArrayBuffer buffer); @JSBody(params = { "buffer", "offset", "length" }, script = "return new " + "Uint8ClampedArray(buffer, offset, length);") - public static native ArrayBuffer create(ArrayBuffer buffer, int offset, int length); + public static native Uint8ClampedArray create(ArrayBuffer buffer, int offset, int length); }