Search completed in 0.93 seconds.
15 results for "oncontextmenu":
GlobalEventHandlers.oncontextmenu - Web APIs
Web › API › GlobalEventHandlers › oncontextmenu
the oncontextmenu property of the globaleventhandlers mixin is an eventhandler that processes contextmenu events.
... syntax target.oncontextmenu = functionref; value functionref is a function name or a function expression.
... only one oncontextmenu handler can be assigned to an object at a time.
...And 2 more matches
XUL accessibility guidelines - Archive of obsolete content
Archive › Mozilla › XUL › XUL accessibility guidelines
use the oncontextmenu event handler or the context attribute to create context menus.
...the oncontextmenu event and context attribute work with the correct platform-specific context menu triggers, including the keyboard button and appropriate mouse clicks.
... context menus context menus are triggered by the oncontextmenu event handler.
XRReferenceSpace.getOffsetReferenceSpace() - Web APIs
Web › API › XRReferenceSpace › getOffsetReferenceSpace
note also that we set oncontextmenu up to be ignored by calling preventdefault() on those events.
... canvas.oncontextmenu = (event) => { event.preventdefault(); }; canvas.addeventlistener("mousemove", (event) => { if (event.buttons & 2) { rotateviewby(event.movementx, event.movementy); } }); next, the rotateviewby() function, which updates the mouse look direction's yaw and pitch based on the mouse delta values from the mousemove event.
XUL Events - Archive of obsolete content
Archive › Mozilla › XUL › Events
attribute: oncontextmenu drag the drag event is sent to the source node (the node that was dragged) several times a second while the drag is occurring.
ContextMenus - Archive of obsolete content
Archive › Mozilla › XUL › PopupGuide › ContextMenus
<hbox id="container" align="center" oncontextmenu="..."> <label value="name:"/> <textbox id="name"/> </hbox> in this example, an attempt to open a context menu anywhere inside the hbox will call the event listener attached using the oncontextmenu attribute.
XUL Questions and Answers - Archive of obsolete content
Archive › Mozilla › XUL › XUL Questions and Answers
how do i close the "showpopup" which is automatically opened when the "oncontextmenu" event is called?
Document - Web APIs
Web › API › Document
globaleventhandlers.oncontextmenu is an eventhandler representing the code to be called when the contextmenu event is raised.
Element: auxclick event - Web APIs
Web › API › Element › auxclick event
; let html = document.queryselector('html'); function random(number) { return math.floor(math.random() * number); } function randomcolor() { return `rgb(${random(255)}, ${random(255)}, ${random(255)})`; } button.onclick = function() { button.style.backgroundcolor = randomcolor(); }; button.onauxclick = function(e) { e.preventdefault(); button.style.color = randomcolor(); } button.oncontextmenu = function(e) { e.preventdefault(); } notice that in addition to capturing the auxclick event using onauxclick, the contextmenu event is also captured, and preventdefault() called on that event, in order to prevent the context menu from popping up after the color change is applied.
Element: contextmenu event - Web APIs
Web › API › Element › contextmenu event
bubbles yes cancelable yes interface mouseevent event handler property oncontextmenu examples in this example, the default action of the contextmenu event is canceled using preventdefault() when the contextmenu event is fired at the first paragraph.
Element - Web APIs
Web › API › Element
also available via the oncontextmenu property.
GlobalEventHandlers - Web APIs
Web › API › GlobalEventHandlers
globaleventhandlers.oncontextmenu is an eventhandler representing the code to be called when the contextmenu event is raised.
Index - Web APIs
Web › API › Index
1489 globaleventhandlers.oncontextmenu api, event handler, globaleventhandlers, html dom, property, reference the oncontextmenu property of the globaleventhandlers mixin is an eventhandler that processes contextmenu events.
MouseEvent.button - Web APIs
Web › API › MouseEvent › button
example html <button id="button" oncontextmenu="event.preventdefault();">click here with your mouse...</button> <p id="log"></p> javascript let button = document.queryselector('#button'); let log = document.queryselector('#log'); button.addeventlistener('mouseup', logmousebutton); function logmousebutton(e) { if (typeof e === 'object') { switch (e.button) { case 0: log.textcontent = 'left button clicked.'; break...
Window - Web APIs
Web › API › Window
globaleventhandlers.onclose called after the window is closed globaleventhandlers.oncontextmenu called when the right mouse button is pressed globaleventhandlers.onerror called when a resource fails to load or when an error occurs at runtime.
Global attributes - HTML: Hypertext Markup Language
Web › HTML › Global attributes
the event handler attributes: onabort, onautocomplete, onautocompleteerror, onblur, oncancel, oncanplay, oncanplaythrough, onchange, onclick, onclose, oncontextmenu, oncuechange, ondblclick, ondrag, ondragend, ondragenter, ondragexit, ondragleave, ondragover, ondragstart, ondrop, ondurationchange, onemptied, onended, onerror, onfocus, oninput, oninvalid, onkeydown, onkeypress, onkeyup, onload, onloadeddata, onloadedmetadata, onloadstart, onmousedown, onmouseenter, onmouseleave, onmousemove, onmouseout, onmouseover, onmouseup, onmousewheel, onpause, onplay, o...