Beispiel #1
0
 public static Value evaluate(
     DOMObjects nativeObject, FunctionCalls.CallInfo call, State s, Solver.SolverInterface c) {
   switch (nativeObject) {
     case MOUSE_EVENT_INIT_MOUSE_EVENT:
       {
         NativeFunctions.expectParameters(nativeObject, call, c, 15, 15);
         /* Value typeArg =*/ Conversion.toString(NativeFunctions.readParameter(call, s, 0), c);
         /* Value canBubbleArg =*/ Conversion.toBoolean(NativeFunctions.readParameter(call, s, 1));
         /* Value cancelableArg =*/ Conversion.toBoolean(
             NativeFunctions.readParameter(call, s, 2));
         // View arg not checked
         /* Value detailArg =*/ Conversion.toNumber(NativeFunctions.readParameter(call, s, 4), c);
         /* Value screenXArg =*/ Conversion.toNumber(NativeFunctions.readParameter(call, s, 5), c);
         /* Value screenYArg =*/ Conversion.toNumber(NativeFunctions.readParameter(call, s, 6), c);
         /* Value clientXArg =*/ Conversion.toNumber(NativeFunctions.readParameter(call, s, 7), c);
         /* Value clientYArg =*/ Conversion.toNumber(NativeFunctions.readParameter(call, s, 8), c);
         /* Value ctrlKeyArg =*/ Conversion.toBoolean(NativeFunctions.readParameter(call, s, 9));
         /* Value altKeyArg =*/ Conversion.toBoolean(NativeFunctions.readParameter(call, s, 10));
         /* Value shiftKeyArg =*/ Conversion.toBoolean(NativeFunctions.readParameter(call, s, 11));
         /* Value metaKeyArg =*/ Conversion.toBoolean(NativeFunctions.readParameter(call, s, 12));
         /* Value buttonArg =*/ Conversion.toNumber(NativeFunctions.readParameter(call, s, 13), c);
         /* Value relatedTargetArg =*/ DOMConversion.toEventTarget(
             NativeFunctions.readParameter(call, s, 14), c);
         return Value.makeUndef();
       }
     default:
       throw new UnsupportedOperationException("Unsupported Native Object: " + nativeObject);
   }
 }
 public static String getValidConversions() {
   StringBuilder sb = new StringBuilder();
   for (int i = 0; i < Conversion.list.length; i++) {
     Conversion c = Conversion.list[i];
     if (c.validate()) {
       sb.append(c.toString());
       if (i < Conversion.list.length - 1) sb.append("\n");
     }
   }
   return sb.toString();
 }