亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? menuitem.java

?? 源碼為Eclipse開源開發平臺桌面開發工具SWT的源代碼,
?? JAVA
?? 第 1 頁 / 共 3 頁
字號:
/******************************************************************************* * Copyright (c) 2000, 2004 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html *  * Contributors: *     IBM Corporation - initial API and implementation *******************************************************************************/package org.eclipse.swt.widgets; import org.eclipse.swt.internal.win32.*;import org.eclipse.swt.*;import org.eclipse.swt.graphics.*;import org.eclipse.swt.events.*;/** * Instances of this class represent a selectable user interface object * that issues notification when pressed and released.  * <dl> * <dt><b>Styles:</b></dt> * <dd>CHECK, CASCADE, PUSH, RADIO, SEPARATOR</dd> * <dt><b>Events:</b></dt> * <dd>Arm, Help, Selection</dd> * </dl> * <p> * Note: Only one of the styles CHECK, CASCADE, PUSH, RADIO and SEPARATOR * may be specified. * </p><p> * IMPORTANT: This class is <em>not</em> intended to be subclassed. * </p> */public class MenuItem extends Item {	Menu parent, menu;	int id, accelerator;/** * Constructs a new instance of this class given its parent * (which must be a <code>Menu</code>) and a style value * describing its behavior and appearance. The item is added * to the end of the items maintained by its parent. * <p> * The style value is either one of the style constants defined in * class <code>SWT</code> which is applicable to instances of this * class, or must be built by <em>bitwise OR</em>'ing together  * (that is, using the <code>int</code> "|" operator) two or more * of those <code>SWT</code> style constants. The class description * lists the style constants that are applicable to the class. * Style bits are also inherited from superclasses. * </p> * * @param parent a menu control which will be the parent of the new instance (cannot be null) * @param style the style of control to construct * * @exception IllegalArgumentException <ul> *    <li>ERROR_NULL_ARGUMENT - if the parent is null</li> * </ul> * @exception SWTException <ul> *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the parent</li> *    <li>ERROR_INVALID_SUBCLASS - if this class is not an allowed subclass</li> * </ul> * * @see SWT#CHECK * @see SWT#CASCADE * @see SWT#PUSH * @see SWT#RADIO * @see SWT#SEPARATOR * @see Widget#checkSubclass * @see Widget#getStyle */public MenuItem (Menu parent, int style) {	super (parent, checkStyle (style));	this.parent = parent;	parent.createItem (this, parent.getItemCount ());}/** * Constructs a new instance of this class given its parent * (which must be a <code>Menu</code>), a style value * describing its behavior and appearance, and the index * at which to place it in the items maintained by its parent. * <p> * The style value is either one of the style constants defined in * class <code>SWT</code> which is applicable to instances of this * class, or must be built by <em>bitwise OR</em>'ing together  * (that is, using the <code>int</code> "|" operator) two or more * of those <code>SWT</code> style constants. The class description * lists the style constants that are applicable to the class. * Style bits are also inherited from superclasses. * </p> * * @param parent a menu control which will be the parent of the new instance (cannot be null) * @param style the style of control to construct * @param index the index to store the receiver in its parent * * @exception IllegalArgumentException <ul> *    <li>ERROR_NULL_ARGUMENT - if the parent is null</li> * </ul> * @exception SWTException <ul> *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the parent</li> *    <li>ERROR_INVALID_SUBCLASS - if this class is not an allowed subclass</li> * </ul> * * @see SWT#CHECK * @see SWT#CASCADE * @see SWT#PUSH * @see SWT#RADIO * @see SWT#SEPARATOR * @see Widget#checkSubclass * @see Widget#getStyle */public MenuItem (Menu parent, int style, int index) {	super (parent, checkStyle (style));	this.parent = parent;	parent.createItem (this, index);}MenuItem (Menu parent, Menu menu, int style, int index) {	super (parent, checkStyle (style));	this.parent = parent;	this.menu = menu;		if (menu != null) menu.cascade = this;	display.addMenuItem (this);}/** * Adds the listener to the collection of listeners who will * be notified when the arm events are generated for the control, by sending * it one of the messages defined in the <code>ArmListener</code> * interface. * * @param listener the listener which should be notified * * @exception IllegalArgumentException <ul> *    <li>ERROR_NULL_ARGUMENT - if the listener is null</li> * </ul> * @exception SWTException <ul> *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> * </ul> * * @see ArmListener * @see #removeArmListener */public void addArmListener (ArmListener listener) {	checkWidget ();	if (listener == null) error (SWT.ERROR_NULL_ARGUMENT);	TypedListener typedListener = new TypedListener (listener);	addListener (SWT.Arm, typedListener);}/** * Adds the listener to the collection of listeners who will * be notified when the help events are generated for the control, by sending * it one of the messages defined in the <code>HelpListener</code> * interface. * * @param listener the listener which should be notified * * @exception IllegalArgumentException <ul> *    <li>ERROR_NULL_ARGUMENT - if the listener is null</li> * </ul> * @exception SWTException <ul> *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> * </ul> * * @see HelpListener * @see #removeHelpListener */public void addHelpListener (HelpListener listener) {	checkWidget ();	if (listener == null) error (SWT.ERROR_NULL_ARGUMENT);	TypedListener typedListener = new TypedListener (listener);	addListener (SWT.Help, typedListener);}/** * Adds the listener to the collection of listeners who will * be notified when the control is selected, by sending * it one of the messages defined in the <code>SelectionListener</code> * interface. * <p> * When <code>widgetSelected</code> is called, the stateMask field of the event object is valid. * <code>widgetDefaultSelected</code> is not called. * </p> * * @param listener the listener which should be notified * * @exception IllegalArgumentException <ul> *    <li>ERROR_NULL_ARGUMENT - if the listener is null</li> * </ul> * @exception SWTException <ul> *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> * </ul> * * @see SelectionListener * @see #removeSelectionListener * @see SelectionEvent */public void addSelectionListener (SelectionListener listener) {	checkWidget ();	if (listener == null) error (SWT.ERROR_NULL_ARGUMENT);	TypedListener typedListener = new TypedListener(listener);	addListener (SWT.Selection,typedListener);	addListener (SWT.DefaultSelection,typedListener);}protected void checkSubclass () {	if (!isValidSubclass ()) error (SWT.ERROR_INVALID_SUBCLASS);}static int checkStyle (int style) {	return checkBits (style, SWT.PUSH, SWT.CHECK, SWT.RADIO, SWT.SEPARATOR, SWT.CASCADE, 0);}void fillAccel (ACCEL accel) {	accel.fVirt = 0;	accel.cmd = accel.key = 0;	if (accelerator == 0 || !getEnabled ()) return;	int fVirt = OS.FVIRTKEY;	int key = accelerator & SWT.KEY_MASK;	int vKey = Display.untranslateKey (key);	if (vKey != 0) {		key = vKey;		} else {		switch (key) {			/*			* Bug in Windows.  For some reason, VkKeyScan			* fails to map ESC to VK_ESCAPE and DEL to			* VK_DELETE.  The fix is to map these keys			* as a special case.			*/			case 27: key = OS.VK_ESCAPE; break;			case 127: key = OS.VK_DELETE; break;			default: {				key = Display.wcsToMbcs ((char) key);				if (key == 0) return;				if (OS.IsWinCE) {					key = OS.CharUpper ((short) key);				} else {					vKey = OS.VkKeyScan ((short) key) & 0xFF;					if (vKey == -1) {						fVirt = 0;					} else {						key = vKey;					}				}			}		}	}	accel.key = (short) key;	accel.cmd = (short) id;	accel.fVirt = (byte) fVirt;	if ((accelerator & SWT.ALT) != 0) accel.fVirt |= OS.FALT;	if ((accelerator & SWT.SHIFT) != 0) accel.fVirt |= OS.FSHIFT;	if ((accelerator & SWT.CONTROL) != 0) accel.fVirt |= OS.FCONTROL;}void fixMenus (Decorations newParent) {	if (menu != null) menu.fixMenus (newParent);}/** * Return the widget accelerator.  An accelerator is the bit-wise * OR of zero or more modifier masks and a key. Examples: * <code>SWT.CONTROL | SWT.SHIFT | 'T', SWT.ALT | SWT.F2</code>. * * @return the accelerator * * </ul> * @exception SWTException <ul> *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> * </ul> */public int getAccelerator () {	checkWidget ();	return accelerator;}/** * Returns <code>true</code> if the receiver is enabled, and * <code>false</code> otherwise. A disabled control is typically * not selectable from the user interface and draws with an * inactive or "grayed" look. * * @return the receiver's enabled state * * @exception SWTException <ul> *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> * </ul> *  * @see #isEnabled */public boolean getEnabled () {	checkWidget ();	if ((OS.IsPPC || OS.IsSP) && parent.hwndCB != 0) {		int hwndCB = parent.hwndCB;		TBBUTTONINFO info = new TBBUTTONINFO ();		info.cbSize = TBBUTTONINFO.sizeof;		info.dwMask = OS.TBIF_STATE;		OS.SendMessage (hwndCB, OS.TB_GETBUTTONINFO, id, info);		return (info.fsState & OS.TBSTATE_ENABLED) != 0;	}	int hMenu = parent.handle;	MENUITEMINFO info = new MENUITEMINFO ();	info.cbSize = MENUITEMINFO.sizeof;	info.fMask = OS.MIIM_STATE;	boolean success;	if (OS.IsWinCE) {		int index = parent.indexOf (this);		if (index == -1) error (SWT.ERROR_CANNOT_GET_ENABLED);		success = OS.GetMenuItemInfo (hMenu, index, true, info);	} else {		success = OS.GetMenuItemInfo (hMenu, id, false, info);	}	if (!success) error (SWT.ERROR_CANNOT_GET_ENABLED);	return (info.fState & (OS.MFS_DISABLED | OS.MFS_GRAYED)) == 0;}/** * Returns the receiver's cascade menu if it has one or null * if it does not. Only <code>CASCADE</code> menu items can have * a pull down menu. The sequence of key strokes, button presses  * and/or button releases that are used to request a pull down * menu is platform specific. * * @return the receiver's menu * * @exception SWTException <ul> *    <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> *    <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> * </ul> */public Menu getMenu () {	checkWidget ();	return menu;}String getNameText () {	if ((style & SWT.SEPARATOR) != 0) return "|";	return super.getNameText ();}/** * Returns the receiver's parent, which must be a <code>Menu</code>.

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩女优av电影在线观看| 欧美性xxxxxxxx| 免费看日韩a级影片| 一区二区三区欧美日韩| 亚洲视频一区二区在线观看| 国产精品美女久久久久久久久久久 | 精品国精品国产| 91精品国产综合久久精品图片| 在线视频中文字幕一区二区| 在线观看欧美精品| 欧美日韩国产另类一区| 91精品国产欧美日韩| 日韩写真欧美这视频| 久久综合成人精品亚洲另类欧美| 国产网红主播福利一区二区| 亚洲丝袜自拍清纯另类| 一区二区在线观看不卡| 亚洲成人黄色小说| 精彩视频一区二区三区| 不卡的av中国片| 91论坛在线播放| 777xxx欧美| www欧美成人18+| 国产精品美女久久久久高潮| 亚洲影视在线播放| 久久精品久久综合| jlzzjlzz亚洲女人18| 欧美视频一区在线观看| 2024国产精品| 亚洲愉拍自拍另类高清精品| 麻豆一区二区三区| 成人美女视频在线看| 欧美日韩日日骚| 久久久不卡影院| 天涯成人国产亚洲精品一区av| 精品一区二区在线观看| 色综合天天综合网国产成人综合天 | 亚洲欧洲av一区二区三区久久| 亚洲成在人线免费| 波多野结衣精品在线| 欧美一区二区高清| 最新中文字幕一区二区三区| 婷婷一区二区三区| 成人福利电影精品一区二区在线观看 | 亚洲视频一区二区在线| 久久爱另类一区二区小说| 91麻豆.com| 国产日韩欧美激情| 久久国内精品视频| 欧美日韩国产美女| 亚洲影院久久精品| 91污在线观看| 国产精品久久久久永久免费观看| 久久99国产精品免费| 在线不卡a资源高清| 亚洲免费伊人电影| 成人av在线网站| 久久奇米777| 久久99热狠狠色一区二区| 5月丁香婷婷综合| 亚洲影视在线播放| 色老汉一区二区三区| 中文字幕视频一区二区三区久| 久久99久久久久| 日韩欧美区一区二| 精品一区免费av| 精品国产a毛片| 麻豆极品一区二区三区| 欧美一卡二卡在线| 奇米影视一区二区三区小说| 欧美高清一级片在线| 午夜视频在线观看一区二区| 欧美羞羞免费网站| 亚洲成人激情av| 91精品免费在线| 日韩综合一区二区| 欧美精品一二三区| 视频一区二区三区中文字幕| 在线电影欧美成精品| 欧美aⅴ一区二区三区视频| 日韩精品专区在线影院重磅| 久久99精品久久久久久国产越南 | 国产精品亚洲午夜一区二区三区| 日韩午夜小视频| 久久69国产一区二区蜜臀| 日韩精品一区二区三区swag| 精品一区二区av| 国产日韩精品一区| 99久久精品国产精品久久| 亚洲精品国产一区二区三区四区在线 | 在线日韩av片| 日本成人超碰在线观看| 日韩精品一区二区三区在线| 国产一区二区三区在线看麻豆| 中文在线一区二区| 欧美图片一区二区三区| 麻豆成人91精品二区三区| 久久久亚洲精品石原莉奈| 不卡的av网站| 日韩影院精彩在线| 精品国产一区二区三区久久影院| 国产在线精品国自产拍免费| 亚洲免费av在线| 制服丝袜在线91| 国产91精品精华液一区二区三区| 亚洲最大成人网4388xx| 日韩欧美国产综合| 成人一区在线观看| 日韩主播视频在线| 国产欧美日韩精品在线| 在线不卡免费av| 91麻豆.com| 国产精品亚洲成人| 午夜电影一区二区| 国产精品国产精品国产专区不蜜 | 亚洲综合在线免费观看| 日韩欧美一区二区免费| 一本大道久久a久久综合婷婷| 日本sm残虐另类| 亚洲欧美日韩国产成人精品影院| 日韩午夜电影av| 欧美亚洲尤物久久| 成人激情视频网站| 国产一区二区三区日韩| 日韩精品一二三四| 樱桃视频在线观看一区| 欧美极品另类videosde| 亚洲精品在线观看网站| 欧美日韩一区高清| 99精品热视频| 成人午夜av影视| 国产一区二区精品在线观看| 日本成人在线不卡视频| 亚洲午夜精品在线| 一级女性全黄久久生活片免费| 中文字幕av免费专区久久| 精品剧情v国产在线观看在线| 6080午夜不卡| 欧美老人xxxx18| 欧美日韩情趣电影| 欧美午夜一区二区| 欧美主播一区二区三区美女| 91啪亚洲精品| 91视频国产资源| 91日韩一区二区三区| 99v久久综合狠狠综合久久| 高清成人在线观看| 成人不卡免费av| 99久久精品国产网站| 色婷婷久久综合| 色婷婷久久综合| 欧美日韩久久不卡| 91精品中文字幕一区二区三区| 欧美日韩aaaaaa| 日韩色在线观看| 精品国产91乱码一区二区三区 | 麻豆国产精品官网| 久久国产综合精品| 国内不卡的二区三区中文字幕| 美日韩黄色大片| 国产老女人精品毛片久久| 国产老女人精品毛片久久| 粉嫩av一区二区三区| 91首页免费视频| 欧美日韩久久久| 精品国产免费久久| 国产精品国产成人国产三级 | 伦理电影国产精品| 国产揄拍国内精品对白| 丁香婷婷综合激情五月色| 91免费国产在线| 欧美一区二区私人影院日本| 久久综合av免费| 一区二区在线免费观看| 天天综合天天综合色| 国产一区日韩二区欧美三区| thepron国产精品| 欧美精品 国产精品| 久久久.com| 亚洲成人三级小说| 国产高清久久久| 欧美在线视频日韩| 久久综合色之久久综合| 亚洲精品日日夜夜| 极品销魂美女一区二区三区| 99精品欧美一区二区蜜桃免费| 欧美一区二区视频在线观看| 国产人成一区二区三区影院| 亚洲激情自拍视频| 国内精品在线播放| 欧美午夜影院一区| 中文字幕乱码亚洲精品一区| 性做久久久久久久免费看| 国产宾馆实践打屁股91| 欧美男人的天堂一二区| 亚洲视频狠狠干| 国产综合一区二区| 欧美日韩中字一区| 亚洲素人一区二区| 国产91综合网|