# Namespace hcap.mouse

hcap.mouse

- Defined in: hcap-1.24.6.5901.js

Namespace Summary
Constructor Attributes | Constructor Name and Description
--- | ---
| hcap.mouse

## Method Summary

## Namespace Detail

hcap.mouse

## Method Detail

- <static> hcap.mouse.clickPointer(param)
  Clicks the pointer of pointing devices (MMR) in the current position.

      hcap.mouse.clickPointer({
           "onSuccess" : function() {
               console.log("onSuccess");
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function() {
                // No Parameter.
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.20.0
  See:
    hcap.mouse.isPointerOn() hcap.mouse.setPointerOn() hcap.mouse.getPointerPosition() hcap.mouse.setPointerPosition()
- <static> hcap.mouse.getPointerPosition(param)
  Gets the pointer position of pointing devices (MMR).
  The position is the coordinate in the HCAP OSD resolution (Property "display_resolution").

      hcap.mouse.getPointerPosition({
           "onSuccess" : function(s) {
               console.log("onSuccess : pointer position (" + s.x + "," + s.y + ")");
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function (param) {
                // {Number} param.x - X coordiate of the pointer.
                // {Number} param.y - Y coordiate of the pointer.
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.20.0
  See:
    hcap.mouse.isPointerOn() hcap.mouse.setPointerOn() hcap.mouse.setPointerPosition() hcap.mouse.clickPointer()
- <static> hcap.mouse.isMouseVisible(param)
  Checks whether the mouse pointer is visible or not.

      hcap.mouse.isMouseVisible({
           "onSuccess" : function(s) {
               console.log("onSuccess : mouse visible = " + s.isVisible);
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function (param) {
                // {Boolean} param.isVisible - true if the mouse pointer is visible, else false.
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.3.1
  See:
    hcap.mouse.setMouseVisible()
- <static> hcap.mouse.isPointerOn(param)
  Checks whether the pointer of pointing devices (MMR) is on or off.
  Mouse visibility APIs (hcap.mouse.isMouseVisible, hcap.mouse.setMouseVisible) are for virtual arrow cursor of HCAP browser handled by RCU in the environment physical pointing devices are not support.
  But pointer APIs (hcap.mouse.isPointerOn, hcap.mouse.setPointerOn) are for real mouse pointer of physical pointing devices.

      hcap.mouse.isPointerOn({
           "onSuccess" : function(s) {
               console.log("onSuccess : pointer on = " + s.isOn);
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function (param) {
                // {Boolean} param.isOn - true if the pointer is on, else false.
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.19.0
  See:
    hcap.mouse.setPointerOn() hcap.mouse.getPointerPosition() hcap.mouse.setPointerPosition() hcap.mouse.clickPointer()
- <static> hcap.mouse.setMouseVisible(param)
  Sets the mouse visibility.

      hcap.mouse.setMouseVisible({
          "isVisible" : true,
           "onSuccess" : function() {
               console.log("onSuccess");
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {Boolean} param.isVisible [Required] - true for mouse to be visible, else false.
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function() {
                // No Parameter.
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.3.1
  See:
    hcap.mouse.isMouseVisible()
- <static> hcap.mouse.setPointerOn(param)
  Switches on the pointer of pointing devices (MMR) or off.

      hcap.mouse.setPointerOn({
          "isOn" : true,
           "onSuccess" : function() {
               console.log("onSuccess");
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {Boolean} param.isOn [Required] - true for the pointer to be on, else false.
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function() {
                // No Parameter.
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.19.0
  See:
    hcap.mouse.isPointerOn() hcap.mouse.getPointerPosition() hcap.mouse.setPointerPosition() hcap.mouse.clickPointer()
- <static> hcap.mouse.setPointerPosition(param)
  Sets the pointer position of pointing devices (MMR).
  The position is the coordinate in the HCAP OSD resolution (Property "display_resolution").

      hcap.mouse.setPointerPosition({
           "x" : 200,
           "y" : 100,
           "onSuccess" : function() {
               console.log("onSuccess");
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {Number} param.x [Required] - X coordiate of the pointer.
    - {Number} param.y [Required] - Y coordiate of the pointer.
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function() {
                // No Parameter.
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.20.0
  See:
    hcap.mouse.isPointerOn() hcap.mouse.setPointerOn() hcap.mouse.getPointerPosition() hcap.mouse.clickPointer()
- <static> hcap.mouse.setPointerSize(param)
  Sets the pointer size of pointing devices (MMR).

      hcap.mouse.setPointerSize({
          "size" : 2,
           "onSuccess" : function() {
               console.log("onSuccess");
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {Number} param.size [Required] - 1 for small size, 2 for middle size and 3 for large size.
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function() {
                // No Parameter.
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.19.0