components/blockly-src/blocks/math.js
function() {
    this.jsonInit({
      "message0": "%1 %2",
      "args0": [
        {
          "type": "field_dropdown",
          "name": "OP",
          "options": [
            [Blockly.Msg.MATH_ROUND_OPERATOR_ROUND, 'ROUND'],
            [Blockly.Msg.MATH_ROUND_OPERATOR_ROUNDUP, 'ROUNDUP'],
            [Blockly.Msg.MATH_ROUND_OPERATOR_ROUNDDOWN, 'ROUNDDOWN']
          ]
        },
        {
          "type": "input_value",
          "name": "NUM",
          "check": "Number"
        }
      ],
      "output": "Number",
      "colour": Blockly.Blocks.math.HUE,
      "tooltip": Blockly.Msg.MATH_ROUND_TOOLTIP,
      "helpUrl": Blockly.Msg.MATH_ROUND_HELPURL
    });
  }
function() {
    this.jsonInit({
      "message0": "%1 %2",
      "args0": [
        {
          "type": "field_dropdown",
          "name": "OP",
          "options": [
            [Blockly.Msg.MATH_ROUND_OPERATOR_ROUND, 'ROUND'],
            [Blockly.Msg.MATH_ROUND_OPERATOR_ROUNDUP, 'ROUNDUP'],
            [Blockly.Msg.MATH_ROUND_OPERATOR_ROUNDDOWN, 'ROUNDDOWN']
          ]
        },
        {
          "type": "input_value",
          "name": "NUM",
          "check": "Number"
        }
      ],
      "output": "Number",
      "colour": Blockly.Blocks.math.HUE,
      "tooltip": Blockly.Msg.MATH_ROUND_TOOLTIP,
      "helpUrl": Blockly.Msg.MATH_ROUND_HELPURL
    });
  }
function ( ) { this . jsonInit ( { "message0" : "%1 %2" , "args0" : [ { "type" : "field_dropdown" , "name" : "OP" , "options" : [ [ Blockly . Msg . MATH_ROUND_OPERATOR_ROUND , 'ROUND' ] , [ Blockly . Msg . MATH_ROUND_OPERATOR_ROUNDUP , 'ROUNDUP' ] , [ Blockly . Msg . MATH_ROUND_OPERATOR_ROUNDDOWN , 'ROUNDDOWN' ] ] } , { "type" : "input_value" , "name" : "NUM" , "check" : "Number" } ] , "output" : "Number" , "colour" : Blockly . Blocks . math . HUE , "tooltip" : Blockly . Msg . MATH_ROUND_TOOLTIP , "helpUrl" : Blockly . Msg . MATH_ROUND_HELPURL } ) ; }
Block for rounding functions.
@this Blockly.Block
Block for rounding functions .