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

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

?? optionlistmodel.java

?? JAVA的一些源碼 JAVA2 STANDARD EDITION DEVELOPMENT KIT 5.0
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
/* * @(#)OptionListModel.java	1.11 03/12/19 * * Copyright 2004 Sun Microsystems, Inc. All rights reserved. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. */package javax.swing.text.html;import javax.swing.*;import javax.swing.event.*;import java.util.EventListener;import java.util.BitSet;import java.io.Serializable;/** * This class extends DefaultListModel, and also implements * the ListSelectionModel interface, allowing for it to store state * relevant to a SELECT form element which is implemented as a List. * If SELECT has a size attribute whose value is greater than 1, * or if allows multiple selection then a JList is used to  * represent it and the OptionListModel is used as its model. * It also stores the initial state of the JList, to ensure an * accurate reset, if the user requests a reset of the form. *  @author Sunita Mani  @version 1.11 12/19/03 */class OptionListModel extends DefaultListModel implements ListSelectionModel, Serializable {      private static final int MIN = -1;    private static final int MAX = Integer.MAX_VALUE;    private int selectionMode = SINGLE_SELECTION;    private int minIndex = MAX;    private int maxIndex = MIN;    private int anchorIndex = -1;    private int leadIndex = -1;    private int firstChangedIndex = MAX;    private int lastChangedIndex = MIN;    private boolean isAdjusting = false;    private BitSet value = new BitSet(32);    private BitSet initialValue = new BitSet(32);    protected EventListenerList listenerList = new EventListenerList();    protected boolean leadAnchorNotificationEnabled = true;    public int getMinSelectionIndex() { return isSelectionEmpty() ? -1 : minIndex; }    public int getMaxSelectionIndex() { return maxIndex; }    public boolean getValueIsAdjusting() { return isAdjusting; }    public int getSelectionMode() { return selectionMode; }    public void setSelectionMode(int selectionMode) {	switch (selectionMode) {	case SINGLE_SELECTION:	case SINGLE_INTERVAL_SELECTION:	case MULTIPLE_INTERVAL_SELECTION:	    this.selectionMode = selectionMode;	    break;	default:	    throw new IllegalArgumentException("invalid selectionMode");	}    }    public boolean isSelectedIndex(int index) {	return ((index < minIndex) || (index > maxIndex)) ? false : value.get(index);    }    public boolean isSelectionEmpty() {	return (minIndex > maxIndex);    }    public void addListSelectionListener(ListSelectionListener l) { 	listenerList.add(ListSelectionListener.class, l);    }    public void removeListSelectionListener(ListSelectionListener l) { 	listenerList.remove(ListSelectionListener.class, l);    }    /**     * Returns an array of all the <code>ListSelectionListener</code>s added     * to this OptionListModel with addListSelectionListener().     *     * @return all of the <code>ListSelectionListener</code>s added or an empty     *         array if no listeners have been added     * @since 1.4     */    public ListSelectionListener[] getListSelectionListeners() {        return (ListSelectionListener[])listenerList.getListeners(                ListSelectionListener.class);    }    /**     * Notify listeners that we are beginning or ending a     * series of value changes     */    protected void fireValueChanged(boolean isAdjusting) {	fireValueChanged(getMinSelectionIndex(), getMaxSelectionIndex(), isAdjusting);    }    /**     * Notify ListSelectionListeners that the value of the selection,     * in the closed interval firstIndex,lastIndex, has changed.     */    protected void fireValueChanged(int firstIndex, int lastIndex) {	fireValueChanged(firstIndex, lastIndex, getValueIsAdjusting());    }    /**     * @param firstIndex The first index in the interval.     * @param index1 The last index in the interval.     * @param isAdjusting True if this is the final change in a series of them.     * @see EventListenerList     */    protected void fireValueChanged(int firstIndex, int lastIndex, boolean isAdjusting)    {	Object[] listeners = listenerList.getListenerList();	ListSelectionEvent e = null;	for (int i = listeners.length - 2; i >= 0; i -= 2) {	    if (listeners[i] == ListSelectionListener.class) {		if (e == null) {		    e = new ListSelectionEvent(this, firstIndex, lastIndex, isAdjusting);		}		((ListSelectionListener)listeners[i+1]).valueChanged(e);	    }	}    }    private void fireValueChanged() {	if (lastChangedIndex == MIN) {	    return;	}	/* Change the values before sending the event to the	 * listeners in case the event causes a listener to make	 * another change to the selection.	 */	int oldFirstChangedIndex = firstChangedIndex;	int oldLastChangedIndex = lastChangedIndex;	firstChangedIndex = MAX;	lastChangedIndex = MIN;        fireValueChanged(oldFirstChangedIndex, oldLastChangedIndex);    }    // Update first and last change indices    private void markAsDirty(int r) {        firstChangedIndex = Math.min(firstChangedIndex, r);	lastChangedIndex =  Math.max(lastChangedIndex, r);    }    // Set the state at this index and update all relevant state.    private void set(int r) {	if (value.get(r)) {	    return;	}	value.set(r);	Option option = (Option)get(r);	option.setSelection(true);        markAsDirty(r);        // Update minimum and maximum indices        minIndex = Math.min(minIndex, r);        maxIndex = Math.max(maxIndex, r);    }    // Clear the state at this index and update all relevant state.    private void clear(int r) {	if (!value.get(r)) {	    return;	}	value.clear(r);	Option option = (Option)get(r);	option.setSelection(false);        markAsDirty(r);        // Update minimum and maximum indices        /*           If (r > minIndex) the minimum has not changed.           The case (r < minIndex) is not possible because r'th value was set.           We only need to check for the case when lowest entry has been cleared,           and in this case we need to search for the first value set above it.	*/	if (r == minIndex) {	    for(minIndex = minIndex + 1; minIndex <= maxIndex; minIndex++) {	        if (value.get(minIndex)) {	            break;	        }	    }	}        /*           If (r < maxIndex) the maximum has not changed.           The case (r > maxIndex) is not possible because r'th value was set.           We only need to check for the case when highest entry has been cleared,           and in this case we need to search for the first value set below it.	*/	if (r == maxIndex) {	    for(maxIndex = maxIndex - 1; minIndex <= maxIndex; maxIndex--) {	        if (value.get(maxIndex)) {	            break;	        }	    }	}	/* Performance note: This method is called from inside a loop in	   changeSelection() but we will only iterate in the loops	   above on the basis of one iteration per deselected cell - in total.	   Ie. the next time this method is called the work of the previous	   deselection will not be repeated.	   We also don't need to worry about the case when the min and max	   values are in their unassigned states. This cannot happen because	   this method's initial check ensures that the selection was not empty	   and therefore that the minIndex and maxIndex had 'real' values.	   If we have cleared the whole selection, set the minIndex and maxIndex	   to their cannonical values so that the next set command always works	   just by using Math.min and Math.max.	*/        if (isSelectionEmpty()) {            minIndex = MAX;            maxIndex = MIN;        }    }    /**     * Sets the value of the leadAnchorNotificationEnabled flag.     * @see		#isLeadAnchorNotificationEnabled()     */    public void setLeadAnchorNotificationEnabled(boolean flag) {        leadAnchorNotificationEnabled = flag;    }    /**     * Returns the value of the leadAnchorNotificationEnabled flag.     * When leadAnchorNotificationEnabled is true the model     * generates notification events with bounds that cover all the changes to     * the selection plus the changes to the lead and anchor indices.     * Setting the flag to false causes a norrowing of the event's bounds to     * include only the elements that have been selected or deselected since     * the last change. Either way, the model continues to maintain the lead     * and anchor variables internally. The default is true.     * @return 		the value of the leadAnchorNotificationEnabled flag     * @see		#setLeadAnchorNotificationEnabled(boolean)     */    public boolean isLeadAnchorNotificationEnabled() {        return leadAnchorNotificationEnabled;    }    private void updateLeadAnchorIndices(int anchorIndex, int leadIndex) {        if (leadAnchorNotificationEnabled) {            if (this.anchorIndex != anchorIndex) {                if (this.anchorIndex != -1) { // The unassigned state.                    markAsDirty(this.anchorIndex);                }                markAsDirty(anchorIndex);            }            if (this.leadIndex != leadIndex) {                if (this.leadIndex != -1) { // The unassigned state.                    markAsDirty(this.leadIndex);                }                markAsDirty(leadIndex);            }        }        this.anchorIndex = anchorIndex;        this.leadIndex = leadIndex;    }    private boolean contains(int a, int b, int i) {        return (i >= a) && (i <= b);    }    private void changeSelection(int clearMin, int clearMax,

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
成a人片亚洲日本久久| 亚洲欧洲一区二区三区| 欧美日韩激情一区| 色综合夜色一区| 高清成人免费视频| 岛国精品一区二区| 成人午夜又粗又硬又大| 国产一区二区三区美女| 精品系列免费在线观看| 久国产精品韩国三级视频| 激情久久五月天| 精品亚洲porn| 成人黄色国产精品网站大全在线免费观看 | 9人人澡人人爽人人精品| 国产成人8x视频一区二区| 暴力调教一区二区三区| 99re热视频精品| 在线免费观看成人短视频| 欧美军同video69gay| 欧美人动与zoxxxx乱| 日韩欧美国产精品一区| 精品粉嫩aⅴ一区二区三区四区| 欧美不卡一区二区三区四区| 久久一二三国产| 亚洲天堂久久久久久久| 亚洲女爱视频在线| 午夜av电影一区| 日韩av电影天堂| 国产激情一区二区三区| 色噜噜狠狠色综合中国| 欧美精品丝袜中出| 国产亚洲欧美日韩日本| 一区二区三区欧美激情| 热久久一区二区| 成人免费不卡视频| 666欧美在线视频| 国产亚洲人成网站| 亚洲香肠在线观看| 国产一区二区三区在线观看精品| 99视频超级精品| 欧美色偷偷大香| 欧美激情综合五月色丁香小说| 一区二区三区在线观看视频| 麻豆精品一二三| 色婷婷久久久亚洲一区二区三区| 555www色欧美视频| ...xxx性欧美| 国产一区二区中文字幕| 欧美三级中文字幕在线观看| 国产午夜精品一区二区三区视频 | 日本aⅴ免费视频一区二区三区| 国产酒店精品激情| 欧美日韩国产精品成人| 国产精品久久毛片av大全日韩| 奇米影视在线99精品| 91网址在线看| 国产色一区二区| 九九热在线视频观看这里只有精品| 91在线免费播放| 国产偷国产偷亚洲高清人白洁 | 精品少妇一区二区三区在线播放| 亚洲老妇xxxxxx| 成人免费高清在线| 久久久国际精品| 久久电影网站中文字幕| 欧美日韩久久久| 亚洲伦在线观看| av在线不卡电影| 欧美韩国一区二区| 国产一区二区三区观看| 日韩精品一区二区三区蜜臀| 午夜精品一区二区三区三上悠亚 | 丝袜a∨在线一区二区三区不卡| 99久久久免费精品国产一区二区| 久久精品一区八戒影视| 韩国欧美国产1区| 日韩精品一区二区三区蜜臀| 日韩av一区二区在线影视| 欧美午夜理伦三级在线观看| 亚洲欧洲成人精品av97| 本田岬高潮一区二区三区| 国产精品成人免费| 99久久国产综合色|国产精品| 国产欧美日韩三区| 成人免费观看av| 亚洲免费在线播放| 欧美中文字幕一区二区三区| 一区二区三区在线观看国产| 在线日韩av片| 日韩在线卡一卡二| 日韩精品一区二区三区视频 | 99精品久久久久久| 亚洲私人影院在线观看| 欧洲精品在线观看| 亚洲成人免费在线观看| 欧美一级国产精品| 国产精品一区在线观看你懂的| 国产欧美一区二区三区沐欲| 99精品久久只有精品| 亚洲午夜久久久久久久久电影院| 欧美日韩一级片在线观看| 日本麻豆一区二区三区视频| 久久网站热最新地址| 99re成人精品视频| 午夜电影久久久| 久久久亚洲午夜电影| 91久久国产最好的精华液| 偷窥少妇高潮呻吟av久久免费| 日韩视频一区在线观看| 国产精品99久久久久久久vr| 亚洲欧美另类综合偷拍| 88在线观看91蜜桃国自产| 国内不卡的二区三区中文字幕| 中文字幕精品综合| 欧美偷拍一区二区| 国产精品自拍网站| 伊人婷婷欧美激情| 精品免费国产一区二区三区四区| 丁香亚洲综合激情啪啪综合| 亚洲成人av一区二区三区| 久久久精品人体av艺术| 欧美日韩一区二区三区高清| 国产精品亚洲一区二区三区在线 | 视频在线观看91| 中文字幕在线观看不卡视频| 欧美日韩精品系列| 成人性色生活片| 日韩成人伦理电影在线观看| 综合久久一区二区三区| 精品国产三级电影在线观看| 在线视频国内一区二区| 成人av资源站| 经典一区二区三区| 日韩中文字幕麻豆| 亚洲第一精品在线| 一区二区三区四区国产精品| 久久精品一区二区三区av| 日韩欧美国产wwwww| 91国模大尺度私拍在线视频| 国产成人激情av| 免费观看成人av| 天天综合日日夜夜精品| 亚洲自拍另类综合| 日韩伦理av电影| 中文字幕一区在线观看视频| 久久午夜免费电影| 精品国产不卡一区二区三区| 欧美午夜片在线看| 欧美日韩一区国产| 欧美日韩亚洲综合一区二区三区| 不卡免费追剧大全电视剧网站| 国产黄色成人av| 国产精品正在播放| 国产伦理精品不卡| 国产精品中文字幕一区二区三区| 久久国产精品第一页| 蜜臀久久99精品久久久画质超高清 | 欧美中文字幕一二三区视频| 91毛片在线观看| 91亚洲精品久久久蜜桃| 国产ts人妖一区二区| 久久97超碰色| 国产一区二区三区国产| 成人美女视频在线观看18| 成人激情黄色小说| 99久久久精品| 日本道免费精品一区二区三区| 色琪琪一区二区三区亚洲区| 欧美亚洲尤物久久| 欧美一区二区二区| 精品国产精品网麻豆系列| 国产日韩欧美精品在线| 国产精品电影一区二区| 综合久久久久综合| 婷婷中文字幕综合| 精油按摩中文字幕久久| 懂色av一区二区三区蜜臀 | 欧美日韩精品综合在线| 欧美欧美欧美欧美| 精品福利二区三区| 中文字幕欧美一| 亚洲一区二区三区激情| 蜜桃91丨九色丨蝌蚪91桃色| 国产精品羞羞答答xxdd| 91视视频在线观看入口直接观看www | 国产精品久久看| 亚洲伊人色欲综合网| 美女尤物国产一区| 成人黄色小视频| 欧美日韩成人综合在线一区二区 | 99亚偷拍自图区亚洲| 欧美福利视频导航| 日本一区二区三区电影| 亚洲综合在线电影| 国内成人免费视频| 欧美日韩视频在线观看一区二区三区| 日韩精品一区二| 亚洲乱码日产精品bd| 激情文学综合丁香| 欧美视频自拍偷拍|