nsIMenuBoxObject 编辑
layout/xul/base/public/nsIMenuBoxObject.idl
Scriptable Represents the box object for a XUL menu. Inherits from: nsISupports
Last changed in Gecko 1.8 (Firefox 1.5 / Thunderbird 1.5 / SeaMonkey 1.0)To get access to the box object for a given menu, use code like this:
var boxObject = xulMenu.boxObject.QueryInterface(Components.interfaces.nsIMenuBoxObject);
Method overview
boolean handleKeyPress(in nsIDOMKeyEvent keyEvent); |
void openMenu(in boolean openFlag); |
Attributes
Attribute | Type | Description |
activeChild |
| The currently active menu or menuitem child of the menu box. |
openedWithKey | boolean | true if the menubar was opened using the keyboard; otherwise false . |
openedWithKey
attribute exists on the nsIMenuBoxObject_MOZILLA_2_0_BRANCH
interface. Subsequent Gecko versions will have the attribute on the nsIMenuBoxObject
interface.Methods
handleKeyPress()
boolean handleKeyPress( in nsIDOMKeyEvent keyEvent );
Parameters
keyEvent
- The key event to handle for the menu.
Return value
true
if the event was handled, false
if not.
openMenu()
void openMenu( in boolean openFlag );
Parameters
openFlag
true
to open the menu orfalse
to close it.
See also
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论