Document.releaseCapture()

The releaseCapture() method releases mouse capture if it's currently enabled on an element within this document. Enabling mouse capture on an element is done by calling element.setCapture().

Syntax

document.releaseCapture();

Once mouse capture is released, mouse events will no longer all be directed to the element on which capture is enabled.

Example

See the example for element.setCapture().

Specifications

Based on Internet Explorer's implementation.

Browser compatibility

Update compatibility data on GitHub
DesktopMobile
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidFirefox for AndroidOpera for AndroidSafari on iOSSamsung Internet
releaseCapture
Non-standard
Chrome No support NoEdge No support NoFirefox Full support 4IE Full support 5Opera ? Safari No support NoWebView Android No support NoChrome Android No support NoFirefox Android Full support 4Opera Android No support NoSafari iOS No support NoSamsung Internet Android No support No

Legend

Full support  
Full support
No support  
No support
Compatibility unknown  
Compatibility unknown
Non-standard. Expect poor cross-browser support.
Non-standard. Expect poor cross-browser support.

See also