MCPcopy Create free account
hub / github.com/apache/cloudstack / move

Method move

systemvm/agent/noVNC/core/util/cursor.js:120–137  ·  view source on GitHub ↗
(clientX, clientY)

Source from the content-addressed store, hash-verified

118 // Mouse events might be emulated, this allows
119 // moving the cursor in such cases
120 move(clientX, clientY) {
121 if (!useFallback) {
122 return;
123 }
124 // clientX/clientY are relative the _visual viewport_,
125 // but our position is relative the _layout viewport_,
126 // so try to compensate when we can
127 if (window.visualViewport) {
128 this._position.x = clientX + window.visualViewport.offsetLeft;
129 this._position.y = clientY + window.visualViewport.offsetTop;
130 } else {
131 this._position.x = clientX;
132 this._position.y = clientY;
133 }
134 this._updatePosition();
135 let target = document.elementFromPoint(clientX, clientY);
136 this._updateVisibility(target);
137 }
138
139 _handleMouseOver(event) {
140 // This event could be because we're entering the target, or

Callers 6

_fakeMouseMoveMethod · 0.45
executeMethod · 0.45
installTemplateMethod · 0.45
writehbMethod · 0.45

Calls 2

_updatePositionMethod · 0.95
_updateVisibilityMethod · 0.95

Tested by

no test coverage detected