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

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

?? menuitem.java

?? 源碼為Eclipse開源開發(fā)平臺桌面開發(fā)工具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一区二区| 亚洲电影你懂得| 丁香另类激情小说| 在线看国产一区| 欧美国产日韩亚洲一区| 蜜桃视频一区二区| 欧美综合在线视频| 中文字幕欧美激情一区| 久久99九九99精品| 欧美一区二区在线视频| 一区二区三区在线看| 另类小说一区二区三区| 在线视频国内自拍亚洲视频| 日本一区二区不卡视频| 国产在线精品一区二区三区不卡| 欧美美女网站色| 亚洲午夜视频在线| 色综合欧美在线视频区| 《视频一区视频二区| 国产成人av一区二区三区在线| 日韩美女视频一区二区在线观看| 午夜精品福利在线| 精品视频一区二区三区免费| 亚洲乱码日产精品bd| 北条麻妃国产九九精品视频| 国产精品美女久久久久aⅴ| 成人影视亚洲图片在线| 国产视频视频一区| 国产成人av电影在线观看| 久久视频一区二区| 国模娜娜一区二区三区| 欧美成人精品1314www| 久久国产精品免费| 欧美va天堂va视频va在线| 麻豆国产欧美日韩综合精品二区 | 在线一区二区三区四区五区| 中文字幕制服丝袜成人av | 久久av老司机精品网站导航| 91精品国产乱| 黑人巨大精品欧美黑白配亚洲| 2021中文字幕一区亚洲| 国产一区二区三区香蕉| 国产精品―色哟哟| 色综合久久久久久久久久久| 亚洲乱码国产乱码精品精小说| 欧美亚洲综合一区| 蜜臀a∨国产成人精品| 亚洲精品一区二区三区蜜桃下载| 国产一区二区女| 亚洲免费伊人电影| 欧美年轻男男videosbes| 日日夜夜一区二区| 久久久久久97三级| 一本到一区二区三区| 天堂在线一区二区| 国产精品美女久久久久久久| 欧美在线色视频| 国内精品国产成人国产三级粉色| 国产精品久久久久久久第一福利| 欧美亚洲国产一区二区三区| 狂野欧美性猛交blacked| 欧美激情在线看| 欧美三区在线视频| 国产黄色精品视频| 爽爽淫人综合网网站| 久久美女艺术照精彩视频福利播放| 99精品视频在线免费观看| 午夜电影久久久| 国产精品视频观看| 777奇米四色成人影色区| 成人免费看片app下载| 亚洲va欧美va天堂v国产综合| 26uuu亚洲| 欧美日韩亚洲不卡| 大白屁股一区二区视频| 亚洲成人手机在线| 国产精品乱码一区二三区小蝌蚪| 欧美精品九九99久久| 成人av免费观看| 蜜桃av噜噜一区| 亚洲欧美日韩国产另类专区| 精品国产乱码久久久久久图片| 白白色 亚洲乱淫| 激情文学综合丁香| 日日夜夜免费精品视频| 亚洲欧美日韩系列| 国产精品视频第一区| 精品国产成人系列| 69成人精品免费视频| 色域天天综合网| 成人激情动漫在线观看| 精品写真视频在线观看| 日韩av网站免费在线| 亚洲已满18点击进入久久| 国产精品乱人伦| 国产亚洲欧美一级| 精品国产伦理网| 欧美成人性战久久| 日韩一区二区三区视频在线| 欧美日韩在线三区| 欧美系列一区二区| 91丨porny丨首页| 岛国av在线一区| 成人黄色777网| 国产成都精品91一区二区三| 韩国理伦片一区二区三区在线播放| 亚洲丝袜另类动漫二区| 国产精品国产自产拍高清av| 国产亚洲成年网址在线观看| 久久影院电视剧免费观看| 日韩精品专区在线| 精品久久一二三区| 日韩精品中文字幕一区 | 国模套图日韩精品一区二区 | 午夜精品免费在线| 亚洲最大成人综合| 夜夜精品视频一区二区| 亚洲二区在线视频| 性久久久久久久| 日韩激情在线观看| 久久99久久99小草精品免视看| 黄网站免费久久| 国产精品888| 成人av网在线| 欧美偷拍一区二区| 9191成人精品久久| 欧美videos中文字幕| 久久久综合精品| 亚洲欧洲制服丝袜| 日韩精品成人一区二区三区| 久久国产精品99久久人人澡| 国产精品一卡二卡| 色视频一区二区| 欧美一区午夜视频在线观看| 久久久久九九视频| 亚洲美女在线一区| 免费日韩伦理电影| 国产91精品露脸国语对白| 91毛片在线观看| 欧美一区二区在线看| 久久女同性恋中文字幕| 亚洲欧洲精品一区二区三区不卡| 亚洲另类春色国产| 久久国产精品第一页| 成人av影院在线| 3751色影院一区二区三区| 久久亚洲捆绑美女| 亚洲永久免费av| 国产 欧美在线| 欧美日韩视频在线第一区| 日韩三区在线观看| 亚洲日本一区二区三区| 午夜电影网亚洲视频| 国产成人精品www牛牛影视| 欧美日韩免费一区二区三区| 久久精品一区四区| 亚洲妇女屁股眼交7| 成人a级免费电影| 欧美一区二区二区| 亚洲欧美电影院| 国产精品1区2区3区在线观看| 欧美丝袜丝交足nylons| 国产日产亚洲精品系列| 丝袜美腿亚洲综合| 色婷婷精品久久二区二区蜜臀av | 欧美情侣在线播放| 欧美国产一区二区在线观看| 免费观看日韩av| 精品视频在线免费观看| 国产精品白丝在线| 久久97超碰国产精品超碰| 欧洲国产伦久久久久久久| 国产精品动漫网站| 国产一区二区三区在线观看免费视频 | 一本色道亚洲精品aⅴ| 久久麻豆一区二区| 麻豆一区二区99久久久久| 欧美在线制服丝袜| 亚洲欧美区自拍先锋| 国产精品一区免费视频| 欧美变态凌虐bdsm| 午夜精品福利在线| 欧美日韩国产一二三| 亚洲日本欧美天堂| aaa欧美色吧激情视频| 亚洲国产成人午夜在线一区| 精品亚洲porn| 久久综合九色综合97婷婷女人| 蜜臀久久99精品久久久画质超高清| 欧美日韩一区久久| 亚洲最色的网站| 在线视频欧美精品| 亚洲综合清纯丝袜自拍| 一本大道久久a久久综合| 亚洲精品国产一区二区三区四区在线| av中文字幕一区| 中文字幕在线不卡一区二区三区| 成人国产精品免费观看动漫| 国产清纯美女被跳蛋高潮一区二区久久w|