A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://webplatform.github.io/docs/dom/DataTransfer/setDragImage below:

setDragImage · WebPlatform Docs

setDragImage Summary

Uses the given element to update the drag feedback image, replacing any previously specified feedback image.

Method of dom/DataTransferdom/DataTransfer

Syntax
var result = element.setDragImage(element, x, y);
Parameters element
Data-type
Object

An “img” element, used to set the drag data store bitmap to the element’s image (at its intrinsic size). If not an “img” element, used to set the drag data store bitmap to an image generated from the given element, although the mechanism for doing so is not currently specified.

x
Data-type
unsigned long

The “x” value of the drag data store hot spot coordinate.

y
Data-type
unsigned long

The “y” value of the drag data store hot spot coordinate.

Return Value

Returns an object of type

Examples

function setDragImage(e) {
  var img = document.getElementById("dragimg");
  var oData = e.dataTransfer;
  oData.setDragImage (img, 0, 0);
}
Related specifications
HTML5
Candidate Recommendation

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4