michael@0: /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ michael@0: /* vim:set ts=2 sw=2 sts=2 et cindent: */ michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: /** michael@0: * This interface is supported by command events, which are dispatched to michael@0: * XUL elements as a result of mouse or keyboard activation. michael@0: */ michael@0: michael@0: #include "nsIDOMUIEvent.idl" michael@0: michael@0: [scriptable, builtinclass, uuid(2d5b6e19-74bb-40af-9aac-59a1e53e3fcc)] michael@0: interface nsIDOMXULCommandEvent : nsIDOMUIEvent michael@0: { michael@0: /** michael@0: * Command events support the same set of modifier keys as mouse and key michael@0: * events. michael@0: */ michael@0: readonly attribute boolean ctrlKey; michael@0: readonly attribute boolean shiftKey; michael@0: readonly attribute boolean altKey; michael@0: readonly attribute boolean metaKey; michael@0: michael@0: /** michael@0: * If the command event was redispatched because of a command= attribute michael@0: * on the original target, sourceEvent will be set to the original DOM Event. michael@0: * Otherwise, sourceEvent is null. michael@0: */ michael@0: readonly attribute nsIDOMEvent sourceEvent; michael@0: michael@0: /** michael@0: * Creates a new command event with the given attributes. michael@0: */ michael@0: void initCommandEvent(in DOMString typeArg, michael@0: in boolean canBubbleArg, michael@0: in boolean cancelableArg, michael@0: in nsIDOMWindow viewArg, michael@0: in long detailArg, michael@0: in boolean ctrlKeyArg, michael@0: in boolean altKeyArg, michael@0: in boolean shiftKeyArg, michael@0: in boolean metaKeyArg, michael@0: in nsIDOMEvent sourceEvent); michael@0: };