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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? optiondialogtreecellrenderer.java

?? WAP ide 代碼
?? JAVA
字號:
package wapide;import javax.swing.*;import javax.swing.plaf.ColorUIResource;import javax.swing.plaf.FontUIResource;import java.awt.*;import java.awt.event.*;import java.beans.*;import java.io.*;import java.util.*;import javax.swing.tree.*;/** * This class was taken from the source code of Java, provided by Sun Microsystems. * It was distributed as part of the Java 1.3 SDK.  It has been slightly modified * by Mark Busman for use with the WAP.CardLevelTagsDesigner class so that * it will display the appropriate icon based on the control type of any * given item.  The only procedure modified was getTreeCellRendererComponent() and the * constructor. */public class OptionDialogTreeCellRenderer extends JLabel implements TreeCellRenderer{    /** Is the value currently selected. */    protected boolean selected;    /** True if has focus. */    protected boolean hasFocus;    /** True if draws focus border around icon as well. */    private boolean drawsFocusBorderAroundIcon;    // Icons    /** Icon used to show non-leaf nodes that aren't expanded. */    transient protected Icon closedIcon;    /** Icon used to show leaf nodes. */    transient protected Icon leafIcon;    /** Icon used to show non-leaf nodes that are expanded. */    transient protected Icon openIcon;    // Colors    /** Color to use for the foreground for selected nodes. */    protected Color textSelectionColor;    /** Color to use for the foreground for non-selected nodes. */    protected Color textNonSelectionColor;    /** Color to use for the background when a node is selected. */    protected Color backgroundSelectionColor;    /** Color to use for the background when the node isn't selected. */    protected Color backgroundNonSelectionColor;    /** Color to use for the background when the node isn't selected. */    protected Color borderSelectionColor;    /**      * Returns a new instance of DefaultTreeCellRenderer.  Alignment is      * set to left aligned. Icons and text color are determined from the      * UIManager.      */    public OptionDialogTreeCellRenderer() {	setHorizontalAlignment(JLabel.LEFT);	setLeafIcon(new ImageIcon(wapide.IDEFrame.class.getResource("optionTag.gif")));	setClosedIcon(new ImageIcon(wapide.IDEFrame.class.getResource("optgroupTag.gif")));	setOpenIcon(new ImageIcon(wapide.IDEFrame.class.getResource("optgroupColorTag.gif")));	setTextSelectionColor(UIManager.getColor("Tree.selectionForeground"));	setTextNonSelectionColor(UIManager.getColor("Tree.textForeground"));	setBackgroundSelectionColor(UIManager.getColor("Tree.selectionBackground"));	setBackgroundNonSelectionColor(UIManager.getColor("Tree.textBackground"));	setBorderSelectionColor(UIManager.getColor("Tree.selectionBorderColor"));	Object value = UIManager.get("Tree.drawsFocusBorderAroundIcon");	drawsFocusBorderAroundIcon = (value != null && ((Boolean)value).				      booleanValue());    }    /**      * Returns the default icon, for the current laf, that is used to      * represent non-leaf nodes that are expanded.      */    private Icon getDefaultOpenIcon() {	return UIManager.getIcon("Tree.openIcon");    }    /**      * Returns the default icon, for the current laf, that is used to      * represent non-leaf nodes that are not expanded.      */    private Icon getDefaultClosedIcon() {	return UIManager.getIcon("Tree.closedIcon");    }    /**      * Returns the default icon, for the current laf, that is used to      * represent leaf nodes.      */    private Icon getDefaultLeafIcon() {	return UIManager.getIcon("Tree.leafIcon");    }    /**      * Sets the icon used to represent non-leaf nodes that are expanded.      */    private void setOpenIcon(Icon newIcon) {	openIcon = newIcon;    }    /**      * Returns the icon used to represent non-leaf nodes that are expanded.      */    private Icon getOpenIcon() {	return openIcon;    }    /**      * Sets the icon used to represent non-leaf nodes that are not expanded.      */    private void setClosedIcon(Icon newIcon) {	closedIcon = newIcon;    }    /**      * Returns the icon used to represent non-leaf nodes that are not      * expanded.      */    private Icon getClosedIcon() {	return closedIcon;    }    /**      * Sets the icon used to represent leaf nodes.      */    private void setLeafIcon(Icon newIcon) {	leafIcon = newIcon;    }    /**      * Returns the icon used to represent leaf nodes.      */    private Icon getLeafIcon() {	return leafIcon;    }    /**      * Sets the color the text is drawn with when the node is selected.      */    public void setTextSelectionColor(Color newColor) {	textSelectionColor = newColor;    }    /**      * Returns the color the text is drawn with when the node is selected.      */    public Color getTextSelectionColor() {	return textSelectionColor;    }    /**      * Sets the color the text is drawn with when the node isn't selected.      */    public void setTextNonSelectionColor(Color newColor) {	textNonSelectionColor = newColor;    }    /**      * Returns the color the text is drawn with when the node isn't selected.      */    public Color getTextNonSelectionColor() {	return textNonSelectionColor;    }    /**      * Sets the color to use for the background if node is selected.      */    public void setBackgroundSelectionColor(Color newColor) {	backgroundSelectionColor = newColor;    }    /**      * Returns the color to use for the background if node is selected.      */    public Color getBackgroundSelectionColor() {	return backgroundSelectionColor;    }    /**      * Sets the background color to be used for non selected nodes.      */    public void setBackgroundNonSelectionColor(Color newColor) {	backgroundNonSelectionColor = newColor;    }    /**      * Returns the background color to be used for non selected nodes.      */    public Color getBackgroundNonSelectionColor() {	return backgroundNonSelectionColor;    }    /**      * Sets the color to use for the border.      */    public void setBorderSelectionColor(Color newColor) {	borderSelectionColor = newColor;    }    /**      * Returns the color the border is drawn.      */    public Color getBorderSelectionColor() {	return borderSelectionColor;    }    /**     * Subclassed to map <code>FontUIResource</code>s to null. If     * <code>font</code> is null, or a <code>FontUIResource</code>, this     * has the effect of letting the font of the JTree show     * through. On the other hand, if <code>font</code> is non-null, and not     * a <code>FontUIResource</code>, the font becomes <code>font</code>.     */    public void setFont(Font font) {	if(font instanceof FontUIResource)	    font = null;	super.setFont(font);    }    /**     * Subclassed to map <code>ColorUIResource</code>s to null. If     * <code>color</code> is null, or a <code>ColorUIResource</code>, this     * has the effect of letting the background color of the JTree show     * through. On the other hand, if <code>color</code> is non-null, and not     * a <code>ColorUIResource</code>, the background becomes     * <code>color</code>.     */    public void setBackground(Color color) {	if(color instanceof ColorUIResource)	    color = null;	super.setBackground(color);    }    /**      * Configures the renderer based on the passed in components.      * The value is set from messaging the tree with      * <code>convertValueToText</code>, which ultimately invokes      * <code>toString</code> on <code>value</code>.      * The foreground color is set based on the selection and the icon      * is set based on on leaf and expanded.      */    public Component getTreeCellRendererComponent(JTree tree, Object value,						  boolean sel,						  boolean expanded,						  boolean leaf, int row,						  boolean hasFocus) {	String         stringValue = tree.convertValueToText(value, sel,        				  expanded, leaf, row, hasFocus);        try {          //boolean allowschildren = true;          DefaultMutableTreeNode node = (DefaultMutableTreeNode) value;	  boolean allowschildren = node.getAllowsChildren();          this.hasFocus = hasFocus;	  setText(stringValue);	  if(sel)	    setForeground(getTextSelectionColor());	  else	    setForeground(getTextNonSelectionColor());          setEnabled(true);	  if (allowschildren)	    setIcon(getOpenIcon());          else            setIcon(getLeafIcon());          if (expanded) {	    if (allowschildren)	      setIcon(getOpenIcon());            else              setIcon(getLeafIcon());          } else {	    if (allowschildren)              setIcon(getClosedIcon());            else              setIcon(getLeafIcon());          }          setComponentOrientation(tree.getComponentOrientation());	  selected = sel;        }        catch (NullPointerException nullerr) {}	return this;    }    /**      * Paints the value.  The background is filled based on selected.      */    public void paint(Graphics g) {	Color bColor;	if(selected) {	    bColor = getBackgroundSelectionColor();	} else {	    bColor = getBackgroundNonSelectionColor();	    if(bColor == null)		bColor = getBackground();	}	int imageOffset = -1;	if(bColor != null) {	    Icon currentI = getIcon();	    imageOffset = getLabelStart();	    g.setColor(bColor);	    if(getComponentOrientation().isLeftToRight()) {	        g.fillRect(imageOffset, 0, getWidth() - 1 - imageOffset,			   getHeight());	    } else {	        g.fillRect(0, 0, getWidth() - 1 - imageOffset,			   getHeight());	    }	}	if (hasFocus) {	    if (drawsFocusBorderAroundIcon) {		imageOffset = 0;	    }	    else if (imageOffset == -1) {		imageOffset = getLabelStart();	    }	    Color       bsColor = getBorderSelectionColor();	    if (bsColor != null) {		g.setColor(bsColor);		if(getComponentOrientation().isLeftToRight()) {		    g.drawRect(imageOffset, 0, getWidth() - 1 - imageOffset,			       getHeight() - 1);		} else {		    g.drawRect(0, 0, getWidth() - 1 - imageOffset,			       getHeight() - 1);		}	    }	}	super.paint(g);    }    private int getLabelStart() {	Icon currentI = getIcon();	if(currentI != null && getText() != null) {	    return currentI.getIconWidth() + Math.max(0, getIconTextGap() - 1);	}	return 0;    }    /**     * Overrides <code>JComponent.getPreferredSize</code> to     * return slightly wider preferred size value.     */    public Dimension getPreferredSize() {	Dimension        retDimension = super.getPreferredSize();	if(retDimension != null)	    retDimension = new Dimension(retDimension.width + 3,					 retDimension.height);	return retDimension;    }   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void validate() {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void revalidate() {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void repaint(long tm, int x, int y, int width, int height) {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void repaint(Rectangle r) {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    protected void firePropertyChange(String propertyName, Object oldValue, Object newValue) {	// Strings get interned...	if (propertyName=="text")	    super.firePropertyChange(propertyName, oldValue, newValue);    }   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void firePropertyChange(String propertyName, byte oldValue, byte newValue) {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void firePropertyChange(String propertyName, char oldValue, char newValue) {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void firePropertyChange(String propertyName, short oldValue, short newValue) {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void firePropertyChange(String propertyName, int oldValue, int newValue) {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void firePropertyChange(String propertyName, long oldValue, long newValue) {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void firePropertyChange(String propertyName, float oldValue, float newValue) {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void firePropertyChange(String propertyName, double oldValue, double newValue) {}   /**    * Overridden for performance reasons.    * See the <a href="#override">Implementation Note</a>    * for more information.    */    public void firePropertyChange(String propertyName, boolean oldValue, boolean newValue) {}}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
精品国产一区二区在线观看| 欧美日韩一区三区| 91精品国产品国语在线不卡| 日韩美女视频一区二区| 精品一区二区三区在线播放| 欧美日韩一区 二区 三区 久久精品| 久久精品视频在线免费观看| 精一区二区三区| 国产亚洲精品aa午夜观看| 国产精品一区二区三区网站| 日韩精品一区二区三区在线| 香蕉av福利精品导航| 欧美丝袜自拍制服另类| 日韩影院精彩在线| 精品久久久三级丝袜| 国产福利一区二区三区视频| 国产午夜亚洲精品午夜鲁丝片| 韩国成人在线视频| 亚洲视频一区二区在线| 韩国一区二区视频| 中文乱码免费一区二区| 99视频国产精品| 日韩电影在线观看一区| 久久综合色鬼综合色| eeuss鲁一区二区三区| 亚洲成av人综合在线观看| 91麻豆精品国产91久久久更新时间 | 亚洲另类色综合网站| 欧美高清精品3d| 国产电影精品久久禁18| 国产日韩欧美高清| 国产精品18久久久久久久久久久久| 国产在线日韩欧美| 亚洲日本一区二区三区| 欧美高清视频www夜色资源网| 国产综合色在线视频区| 中文字幕在线一区二区三区| 欧美喷潮久久久xxxxx| 成人精品在线视频观看| 精品亚洲免费视频| 日韩二区在线观看| 亚洲午夜电影在线观看| 国产一区二区三区四| 欧美无人高清视频在线观看| 成人免费毛片a| 黄色日韩网站视频| 日本麻豆一区二区三区视频| 一区二区欧美国产| 亚洲一区二区三区四区的| 国产日韩高清在线| 国产亚洲成年网址在线观看| 日韩欧美国产综合| 日韩一卡二卡三卡四卡| 欧美日韩高清一区| 日韩一区二区三区视频在线观看 | 在线免费观看一区| av资源网一区| 91麻豆免费观看| 成人黄动漫网站免费app| 国产不卡视频在线观看| 蜜臀av性久久久久av蜜臀妖精 | 国产亚洲自拍一区| 欧美激情在线一区二区三区| 国产清纯白嫩初高生在线观看91 | 日韩美一区二区三区| 欧美一区二区美女| 国产欧美综合在线| 亚洲乱码日产精品bd| 午夜精品成人在线| 国产一级精品在线| 在线精品亚洲一区二区不卡| 91精品国产日韩91久久久久久| 91精品国产综合久久香蕉的特点 | a在线欧美一区| 日韩一区二区在线观看视频播放| 精品成人一区二区| 一二三区精品视频| 国内精品嫩模私拍在线| 在线精品视频小说1| 欧美成人福利视频| 亚洲国产精品一区二区久久| 国产剧情一区二区| 日韩一级免费观看| 欧美电影一区二区| 精品视频123区在线观看| 欧美精品日韩精品| 国产精品高潮久久久久无| 卡一卡二国产精品| 欧美影院午夜播放| 1024成人网色www| 成人免费黄色大片| 国产网站一区二区三区| 五月天亚洲婷婷| 欧美视频中文字幕| 欧美激情中文不卡| av电影在线观看不卡| 久久天天做天天爱综合色| 日韩电影一区二区三区四区| 色婷婷av一区二区三区大白胸| 国产精品视频你懂的| 国产成人免费视频一区| 国产喂奶挤奶一区二区三区| 国产美女久久久久| 2019国产精品| 不卡av在线免费观看| 国产精品色呦呦| 色综合中文综合网| 日韩vs国产vs欧美| 日韩精品一区二区三区视频在线观看 | 欧美精品vⅰdeose4hd| 亚洲成人av福利| 制服丝袜激情欧洲亚洲| 韩国三级在线一区| 国产精品网站在线观看| 欧美日韩专区在线| 国产一级精品在线| 亚洲欧美aⅴ...| 欧美v亚洲v综合ⅴ国产v| 国产91精品一区二区麻豆亚洲| 国产精品三级久久久久三级| 91麻豆精品秘密| 免费在线看成人av| 国产免费观看久久| 在线综合视频播放| 成人性生交大片免费看中文网站| 亚洲最新视频在线观看| 精品88久久久久88久久久| 一本一本大道香蕉久在线精品| 视频一区二区欧美| 亚洲人精品午夜| 2021中文字幕一区亚洲| 欧美日韩在线综合| 色婷婷精品大在线视频| 国产在线一区观看| 日本麻豆一区二区三区视频| 国产精品乱人伦一区二区| 日韩欧美一级精品久久| 在线免费观看视频一区| 丁香婷婷综合五月| 国产米奇在线777精品观看| 天堂蜜桃一区二区三区| 一级日本不卡的影视| 国产精品午夜在线| 精品久久久久久久一区二区蜜臀| 日韩一区二区中文字幕| 制服丝袜在线91| 欧美一级高清片在线观看| 成人免费av资源| 国产成人综合亚洲91猫咪| 激情文学综合网| 久久国产精品露脸对白| 肉色丝袜一区二区| 蜜臀久久久久久久| 欧美精品 日韩| 国产成人av一区二区三区在线| 精品在线播放免费| 国产高清不卡一区二区| 国产精品小仙女| 国产三级一区二区三区| 欧美一区二区三区四区在线观看| 91精品国产美女浴室洗澡无遮挡| 欧美日韩一区二区电影| 欧洲一区二区三区免费视频| 欧美日韩视频在线一区二区| 91精品综合久久久久久| 欧美一级国产精品| 2022国产精品视频| 亚洲视频免费观看| 日本大胆欧美人术艺术动态| 久久99久久99小草精品免视看| 久久99在线观看| 91丨九色丨黑人外教| 91精品国产综合久久香蕉麻豆 | 亚洲人吸女人奶水| 日本不卡的三区四区五区| 国产一区在线看| 欧美日韩第一区日日骚| 这里只有精品99re| 日韩精品一区二区三区四区视频| 国产日韩v精品一区二区| 夜色激情一区二区| 大美女一区二区三区| 日韩亚洲欧美成人一区| 日本在线不卡视频| 国产精品亚洲第一| 精品国产sm最大网站免费看| 亚洲永久免费av| 91麻豆蜜桃一区二区三区| 久久久久久影视| 国产一区高清在线| 日韩一区二区三区高清免费看看 | 日韩免费电影网站| 五月综合激情网| 欧美日韩国产一级二级| 亚洲一区二区三区四区五区黄| www.av精品| 亚洲精品国产品国语在线app| 成人免费的视频| 亚洲精品国产一区二区三区四区在线| 成人免费的视频|