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

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

?? list.java

?? 源碼為Eclipse開源開發平臺桌面開發工具SWT的源代碼,
?? JAVA
?? 第 1 頁 / 共 4 頁
字號:
 * @exception IllegalArgumentException <ul> *    <li>ERROR_INVALID_RANGE - if the index is not between 0 and the number of elements in the list minus 1 (inclusive)</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> * @exception SWTError <ul> *    <li>ERROR_CANNOT_GET_ITEM - if the operation fails because of an operating system failure</li> * </ul> */public String getItem (int index) {	checkWidget ();	int length = OS.SendMessage (handle, OS.LB_GETTEXTLEN, index, 0);	if (length != OS.LB_ERR) {		TCHAR buffer = new TCHAR (getCodePage (), length + 1);		int result = OS.SendMessage (handle, OS.LB_GETTEXT, index, buffer);		if (result != OS.LB_ERR) return buffer.toString (0, length);	}	int count = OS.SendMessage (handle, OS.LB_GETCOUNT, 0, 0);	if (0 <= index && index < count) {		error (SWT.ERROR_CANNOT_GET_ITEM);	} else {		error (SWT.ERROR_INVALID_RANGE);	}	return null;}/** * Returns the number of items contained in the receiver. * * @return the number of items * * @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> * @exception SWTError <ul> *    <li>ERROR_CANNOT_GET_COUNT - if the operation fails because of an operating system failure</li> * </ul> */public int getItemCount () {	checkWidget ();	int result = OS.SendMessage (handle, OS.LB_GETCOUNT, 0, 0);	if (result == OS.LB_ERR) error (SWT.ERROR_CANNOT_GET_COUNT);	return result;}/** * Returns the height of the area which would be used to * display <em>one</em> of the items in the tree. * * @return the height of one item * * @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> * @exception SWTError <ul> *    <li>ERROR_CANNOT_GET_ITEM_HEIGHT - if the operation fails because of an operating system failure</li> * </ul> */public int getItemHeight () {	checkWidget ();	int result = OS.SendMessage (handle, OS.LB_GETITEMHEIGHT, 0, 0);	if (result == OS.LB_ERR) error (SWT.ERROR_CANNOT_GET_ITEM_HEIGHT);	return result;}/** * Returns an array of <code>String</code>s which are the items * in the receiver.  * <p> * Note: This is not the actual structure used by the receiver * to maintain its list of items, so modifying the array will * not affect the receiver.  * </p> * * @return the items in the receiver's list * * @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> * @exception SWTError <ul> *    <li>ERROR_CANNOT_GET_ITEM - if the operation fails because of an operating system failure while getting an item</li> *    <li>ERROR_CANNOT_GET_COUNT - if the operation fails because of an operating system failure while getting the item count</li> * </ul> */public String [] getItems () {	checkWidget ();	int count = getItemCount ();	String [] result = new String [count];	for (int i=0; i<count; i++) result [i] = getItem (i);	return result;}/** * Returns an array of <code>String</code>s that are currently * selected in the receiver. An empty array indicates that no * items are selected. * <p> * Note: This is not the actual structure used by the receiver * to maintain its selection, so modifying the array will * not affect the receiver.  * </p> * @return an array representing the selection * * @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> * @exception SWTError <ul> *    <li>ERROR_CANNOT_GET_SELECTION - if the operation fails because of an operating system failure while getting the selection</li> *    <li>ERROR_CANNOT_GET_ITEM - if the operation fails because of an operating system failure while getting an item</li> * </ul> */public String [] getSelection () {	checkWidget ();	int [] indices = getSelectionIndices ();	String [] result = new String [indices.length];	for (int i=0; i<indices.length; i++) {		result [i] = getItem (indices [i]);	}	return result;}/** * Returns the number of selected items contained in the receiver. * * @return the number of selected items * * @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> * @exception SWTError <ul> *    <li>ERROR_CANNOT_GET_COUNT - if the operation fails because of an operating system failure</li> * </ul> */public int getSelectionCount () {	checkWidget ();	if ((style & SWT.SINGLE) != 0) {		int result = OS.SendMessage (handle, OS.LB_GETCURSEL, 0, 0);		if (result == OS.LB_ERR) return 0;		return 1;	}	int result = OS.SendMessage (handle, OS.LB_GETSELCOUNT, 0, 0);	if (result == OS.LB_ERR) error (SWT.ERROR_CANNOT_GET_COUNT);	return result;}/** * Returns the zero-relative index of the item which is currently * selected in the receiver, or -1 if no item is selected. * * @return the index of the selected item * * @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> * @exception SWTError <ul> *    <li>ERROR_CANNOT_GET_SELECTION - if the operation fails because of an operating system failure</li> * </ul> */public int getSelectionIndex () {	checkWidget ();	if ((style & SWT.SINGLE) != 0) {		return OS.SendMessage (handle, OS.LB_GETCURSEL, 0, 0);	}	int count = OS.SendMessage (handle, OS.LB_GETSELCOUNT, 0, 0);	if (count == OS.LB_ERR) error (SWT.ERROR_CANNOT_GET_SELECTION);	if (count == 0) return -1;	int index = OS.SendMessage (handle, OS.LB_GETCARETINDEX, 0, 0);	int result = OS.SendMessage (handle, OS.LB_GETSEL, index, 0);	if (result == OS.LB_ERR) error (SWT.ERROR_CANNOT_GET_SELECTION);	if (result != 0) return index;	int [] buffer = new int [1];	result = OS.SendMessage (handle, OS.LB_GETSELITEMS, 1, buffer);	if (result != 1) error (SWT.ERROR_CANNOT_GET_SELECTION);	return buffer [0];}/** * Returns the zero-relative indices of the items which are currently * selected in the receiver.  The array is empty if no items are selected. * <p> * Note: This is not the actual structure used by the receiver * to maintain its selection, so modifying the array will * not affect the receiver.  * </p> * @return the array of indices of the selected items * * @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> * @exception SWTError <ul> *    <li>ERROR_CANNOT_GET_SELECTION - if the operation fails because of an operating system failure</li> * </ul> */public int [] getSelectionIndices () {	checkWidget ();	if ((style & SWT.SINGLE) != 0) {		int result = OS.SendMessage (handle, OS.LB_GETCURSEL, 0, 0);		if (result == OS.LB_ERR) return new int [0];		return new int [] {result};	}	int length = OS.SendMessage (handle, OS.LB_GETSELCOUNT, 0, 0);	if (length == OS.LB_ERR) error (SWT.ERROR_CANNOT_GET_SELECTION);	int [] indices = new int [length];	int result = OS.SendMessage (handle, OS.LB_GETSELITEMS, length, indices);	if (result != length) error (SWT.ERROR_CANNOT_GET_SELECTION);	return indices;}/** * Returns the zero-relative index of the item which is currently * at the top of the receiver. This index can change when items are * scrolled or new items are added or removed. * * @return the index of the top item * * @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 getTopIndex () {	checkWidget ();	return OS.SendMessage (handle, OS.LB_GETTOPINDEX, 0, 0);}/** * Gets the index of an item. * <p> * The list is searched starting at 0 until an * item is found that is equal to the search item. * If no item is found, -1 is returned.  Indexing * is zero based. * * @param string the search item * @return the index of the item * * @exception IllegalArgumentException <ul> *    <li>ERROR_NULL_ARGUMENT - if the string 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> */public int indexOf (String string) {	return indexOf (string, 0);}/** * Searches the receiver's list starting at the given,  * zero-relative index until an item is found that is equal * to the argument, and returns the index of that item. If * no item is found or the starting index is out of range, * returns -1. * * @param string the search item * @param start the zero-relative index at which to start the search * @return the index of the item * * @exception IllegalArgumentException <ul> *    <li>ERROR_NULL_ARGUMENT - if the string 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> * @exception SWTError <ul> *    <li>ERROR_CANNOT_GET_COUNT - if the operation fails because of an operating system failure while getting the item count</li> *    <li>ERROR_CANNOT_GET_ITEM - if the operation fails because of an operating system failure while getting an item</li> * </ul> */public int indexOf (String string, int start) {	checkWidget ();	if (string == null) error (SWT.ERROR_NULL_ARGUMENT);		/*	* Bug in Windows.  For some reason, LB_FINDSTRINGEXACT	* will not find empty strings even though it is legal	* to insert an empty string into a list.  The fix is	* to search the list, an item at a time.	*/	if (string.length () == 0) {		int count = getItemCount ();		for (int i=start; i<count; i++) {			if (string.equals (getItem (i))) return i;		}		return -1;	}	/* Use LB_FINDSTRINGEXACT to search for the item */	int count = OS.SendMessage (handle, OS.LB_GETCOUNT, 0, 0);	if (!(0 <= start && start < count)) return -1;	int index = start - 1, last;	TCHAR buffer = new TCHAR (getCodePage (), string, true);	do {		index = OS.SendMessage (handle, OS.LB_FINDSTRINGEXACT, last = index, buffer);		if (index == OS.LB_ERR || index <= last) return -1;	} while (!string.equals (getItem (index)));	return index;}/** * Returns <code>true</code> if the item is selected, * and <code>false</code> otherwise.  Indices out of * range are ignored. * * @param index the index of the item * @return the visibility state of the item at the index * * @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 boolean isSelected (int index) {	checkWidget ();	int result = OS.SendMessage (handle, OS.LB_GETSEL, index, 0);	return (result != 0) && (result != OS.LB_ERR);}/** * Removes the items from the receiver at the given * zero-relative indices. * * @param indices the array of indices of the items * * @exception IllegalArgumentException <ul> *    <li>ERROR_INVALID_RANGE - if the index is not between 0 and the number of elements in the list minus 1 (inclusive)</li> *    <li>ERROR_NULL_ARGUMENT - if the indices array 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> * @exception SWTError <ul> *    <li>ERROR_ITEM_NOT_REMOVED - if the operation fails because of an operating system failure</li> * </ul> */public void remove (int [] indices) {	checkWidget ();	if (indices == null) error (SWT.ERROR_NULL_ARGUMENT);	if (indices.length == 0) return;	int [] newIndices = new int [indices.length];	System.arraycopy (indices, 0, newIndices, 0, indices.length);	sort (newIndices);	int start = newIndices [newIndices.length - 1], end = newIndices [0];	int count = OS.SendMessage (handle, OS.LB_GETCOUNT, 0, 0);	if (!(0 <= start && start <= end && end < count)) {		error (SWT.ERROR_INVALID_RANGE);	}	int topIndex = OS.SendMessage (handle, OS.LB_GETTOPINDEX, 0, 0);	RECT rect = null;	int hDC = 0, oldFont = 0, newFont = 0, newWidth = 0;	if ((style & SWT.H_SCROLL) != 0) {		rect = new RECT ();		hDC = OS.GetDC (handle);		newFont = OS.SendMessage (handle, OS.WM_GETFONT, 0, 0);		if (newFont != 0) oldFont = OS.SelectObject (hDC, newFont);	}	int cp = getCodePage ();	int i = 0, topCount = 0, last = -1;	while (i < newIndices.length) {		int index = newIndices [i];		if (index != last) {			TCHAR buffer = null;			if ((style & SWT.H_SCROLL) != 0) {				int length = OS.SendMessage (handle, OS.LB_GETTEXTLEN, index, 0);				if (length == OS.LB_ERR) break;				buffer = new TCHAR (cp, length + 1);				int result = OS.SendMessage (handle, OS.LB_GETTEXT, index, buffer);				if (result == OS.LB_ERR) break;			}			int result = OS.SendMessage (handle, OS.LB_DELETESTRING, index, 0);			if (result == OS.LB_ERR) break;			if ((style & SWT.H_SCROLL) != 0) {				int flags = OS.DT_CALCRECT | OS.DT_SINGLELINE | OS.DT_NOPREFIX;				OS.DrawText (hDC, buffer, -1, rect, flags);				newWidth = Math.max (newWidth, rect.right - rect.left);			}			if (index < topIndex) topCount++;			last = index;		}		i++;	}	if ((style & SWT.H_SCROLL) != 0) {		if (newFont != 0) OS.SelectObject (hDC, oldFont);		OS.ReleaseDC (handle, hDC);

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
夜夜揉揉日日人人青青一国产精品| 色综合久久88色综合天天免费| 亚洲品质自拍视频网站| 国产拍欧美日韩视频二区| 欧美成人一区二区三区| 欧美另类久久久品| 91麻豆精品国产无毒不卡在线观看 | 视频一区在线播放| 亚洲综合视频在线| 三级欧美韩日大片在线看| 亚洲一区电影777| 日日夜夜免费精品视频| 蜜桃视频一区二区三区| 精品影院一区二区久久久| 国产一区在线精品| 高清在线成人网| 波多野结衣精品在线| 在线看一区二区| 日韩一区二区在线观看| 欧美国产一区在线| 亚洲免费在线看| 毛片av中文字幕一区二区| 国产一区二区三区在线看麻豆| 成人永久aaa| 欧美日本在线播放| 久久五月婷婷丁香社区| 中文字幕一区免费在线观看| 亚洲精品成人少妇| 蜜桃av一区二区| 91污片在线观看| 日韩精品一区二区三区四区视频| 欧美激情在线免费观看| 亚洲狠狠爱一区二区三区| 国产在线视视频有精品| 色悠悠亚洲一区二区| 精品久久久久一区二区国产| 亚洲人成精品久久久久| 麻豆精品一区二区av白丝在线| 成人网在线免费视频| 欧美久久婷婷综合色| 欧美国产激情一区二区三区蜜月| 亚洲成av人**亚洲成av**| 国产99久久久国产精品潘金网站| 欧美日韩免费观看一区二区三区| 国产午夜精品久久久久久免费视| 亚洲福中文字幕伊人影院| 成人高清伦理免费影院在线观看| 在线不卡中文字幕播放| 亚洲天堂免费在线观看视频| 麻豆成人在线观看| 色狠狠av一区二区三区| 久久综合999| 日韩一区精品字幕| 在线观看日韩国产| 国产精品久久99| 国内外精品视频| 欧美xxxx在线观看| 日韩和欧美的一区| 在线视频综合导航| 亚洲三级小视频| 成人黄色网址在线观看| 久久久久国产精品麻豆ai换脸 | 色综合中文字幕国产| 欧美成人伊人久久综合网| 韩国一区二区三区| 国产一区二区三区免费看| 久久精品国产澳门| 色婷婷av久久久久久久| 国产精品久久久久影院色老大| 久久99精品一区二区三区三区| 在线观看亚洲a| 亚洲精品国产无套在线观| 成人av集中营| 日本一区二区三区高清不卡| 国产精品自拍一区| 日本一区二区视频在线观看| 国产成人自拍高清视频在线免费播放| 欧美不卡一二三| 国产在线视频一区二区| 久久婷婷成人综合色| 国产成a人无v码亚洲福利| 亚洲国产精品t66y| 91麻豆国产福利精品| 洋洋av久久久久久久一区| 欧美三级乱人伦电影| 奇米一区二区三区av| xnxx国产精品| 成人亚洲一区二区一| 中文字幕中文字幕中文字幕亚洲无线| 99久久99久久综合| 亚洲大片免费看| 精品乱码亚洲一区二区不卡| 久久精工是国产品牌吗| 国产精品久久久久精k8| 色天天综合色天天久久| 日本亚洲电影天堂| 日本一区二区三区久久久久久久久不 | 91福利视频在线| 日本不卡免费在线视频| 久久综合av免费| 91久久精品网| 美洲天堂一区二卡三卡四卡视频 | 欧美视频日韩视频| 麻豆精品久久精品色综合| 国产午夜亚洲精品不卡| 欧美性猛交xxxxxxxx| 极品美女销魂一区二区三区免费 | 午夜精品久久久久影视| 精品999在线播放| 色综合一区二区| 久久精品国产久精国产| 国产精品美女久久久久aⅴ| 欧美日韩第一区日日骚| 国产乱子轮精品视频| 亚洲国产日韩一区二区| 精品国产青草久久久久福利| 91免费视频大全| 国产一区二区在线视频| 亚洲午夜激情av| 国产精品二区一区二区aⅴ污介绍| 欧美狂野另类xxxxoooo| 成人av第一页| 久久国产三级精品| 亚洲国产视频一区| 中文字幕巨乱亚洲| 欧美精品一区二区三| 欧美日韩精品一区二区三区蜜桃 | 欧美精品18+| 99久久国产综合色|国产精品| 久久国产精品色婷婷| 五月天精品一区二区三区| 国产精品二三区| 国产校园另类小说区| 日韩欧美成人一区二区| 欧美三级三级三级爽爽爽| 成人一区二区三区视频| 午夜精品久久久久影视| 亚洲一区视频在线| 亚洲青青青在线视频| 国产精品色哟哟| 国产精品三级视频| 久久亚洲免费视频| 日韩午夜电影av| 91精品国产黑色紧身裤美女| 欧美性受xxxx黑人xyx性爽| av在线不卡免费看| 成人激情校园春色| 高清国产一区二区| 成人亚洲一区二区一| 国产高清无密码一区二区三区| 寂寞少妇一区二区三区| 极品瑜伽女神91| 国产精品99精品久久免费| 国产一区二区剧情av在线| 国内外成人在线| 国产精品性做久久久久久| 黑人巨大精品欧美一区| 国产剧情一区二区三区| 国产精品自拍一区| 99精品欧美一区| 欧美三区在线视频| 制服丝袜在线91| 日韩免费高清视频| 2021国产精品久久精品| 国产肉丝袜一区二区| 国产精品嫩草99a| 国产精品久久久久久户外露出| 亚洲色图欧洲色图| 日韩精品视频网站| 国产麻豆91精品| 波多野结衣精品在线| 欧美三区在线视频| 欧美va日韩va| 国产精品久久久久婷婷二区次| 亚洲欧美综合网| 午夜亚洲福利老司机| 麻豆精品一区二区三区| 国产成人av福利| 欧美视频在线观看一区| 精品国产一二三区| ㊣最新国产の精品bt伙计久久| 亚洲午夜电影在线| 精品一区二区国语对白| 色综合天天综合网国产成人综合天 | 久久久久国产精品人| 亚洲激情五月婷婷| 美美哒免费高清在线观看视频一区二区| 国产一区二区三区免费看 | 欧美一区二区在线免费观看| 久久久久久久久久久久电影| 亚洲精品videosex极品| 国产美女在线精品| 欧美三级午夜理伦三级中视频| 久久亚洲精品国产精品紫薇| 亚洲男人天堂av| 国产成人午夜视频| 日韩视频免费直播| 亚洲综合色成人| 国产一区二区在线看| 欧美丝袜丝交足nylons图片|