1 Clazz.declarePackage ("java.awt.event");
\r
2 Clazz.load (["java.awt.event.MouseEvent"], "java.awt.event.MouseWheelEvent", null, function () {
\r
3 c$ = Clazz.decorateAsClass (function () {
\r
5 this.scrollAmount = 0;
\r
6 this.wheelRotation = 0;
\r
7 Clazz.instantialize (this, arguments);
\r
8 }, java.awt.event, "MouseWheelEvent", java.awt.event.MouseEvent);
\r
9 Clazz.makeConstructor (c$,
\r
10 function (source, id, when, modifiers, x, y, clickCount, popupTrigger, scrollType, scrollAmount, wheelRotation) {
\r
11 this.construct (source, id, when, modifiers, x, y, 0, 0, clickCount, popupTrigger, scrollType, scrollAmount, wheelRotation);
\r
12 }, "java.awt.Component,~N,~N,~N,~N,~N,~N,~B,~N,~N,~N");
\r
13 Clazz.makeConstructor (c$,
\r
14 function (source, id, when, modifiers, x, y, xAbs, yAbs, clickCount, popupTrigger, scrollType, scrollAmount, wheelRotation) {
\r
15 Clazz.superConstructor (this, java.awt.event.MouseWheelEvent, [source, id, when, modifiers, x, y, xAbs, yAbs, clickCount, popupTrigger, 0]);
\r
16 this.scrollType = scrollType;
\r
17 this.scrollAmount = scrollAmount;
\r
18 this.wheelRotation = wheelRotation;
\r
19 }, "java.awt.Component,~N,~N,~N,~N,~N,~N,~N,~N,~B,~N,~N,~N");
\r
20 Clazz.defineMethod (c$, "getScrollType",
\r
22 return this.scrollType;
\r
24 Clazz.defineMethod (c$, "getScrollAmount",
\r
26 return this.scrollAmount;
\r
28 Clazz.defineMethod (c$, "getWheelRotation",
\r
30 return this.wheelRotation;
\r
32 Clazz.defineMethod (c$, "getUnitsToScroll",
\r
34 return this.scrollAmount * this.wheelRotation;
\r
36 Clazz.defineMethod (c$, "paramString",
\r
38 var scrollTypeStr = null;
\r
39 if (this.getScrollType () == 0) {
\r
40 scrollTypeStr = "WHEEL_UNIT_SCROLL";
\r
41 } else if (this.getScrollType () == 1) {
\r
42 scrollTypeStr = "WHEEL_BLOCK_SCROLL";
\r
44 scrollTypeStr = "unknown scroll type";
\r
45 }return Clazz.superCall (this, java.awt.event.MouseWheelEvent, "paramString", []) + ",scrollType=" + scrollTypeStr + ",scrollAmount=" + this.getScrollAmount () + ",wheelRotation=" + this.getWheelRotation ();
\r
47 Clazz.defineStatics (c$,
\r
48 "WHEEL_UNIT_SCROLL", 0,
\r
49 "WHEEL_BLOCK_SCROLL", 1);
\r