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

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

?? jsframeborder.java

?? Java自定義窗體JsFrame。簡介見:http://jason0086.spaces.live.com/Blog/cns!A797D0C5C0C13C92!518.entry
?? JAVA
字號:
package com.hfkj.jsframe.border;

import java.awt.Color;
import java.awt.Dimension;
import java.awt.Frame;
import java.awt.Shape;
import java.awt.geom.RoundRectangle2D;

import javax.swing.UIManager;
import javax.swing.plaf.metal.MetalLookAndFeel;

import com.hfkj.jsframe.component.JsComponent;
import com.hfkj.jsframe.frame.JsFrameLayout;
import com.hfkj.jsframe.layout.JsLayoutManager;

/**
 * The <code>JsFrameBorder</code> class is for the integration of the operations
 * on the eight border blocks indicated by the following constraints in the <code>JsFrame</code>:
 * <p>
 * <ul>
 * <li><code>NORTHWEST</code>(defined in <code>JsFrameBorderBlock</code>):
 * The northwest portion of the layout for the <code>JsFrame</code>.
 * <li><code>NORTH</code>(defined in <code>JsFrameBorderBlock</code>):
 * the north portion of the layout for the <code>JsFrame</code>.
 * <li><code>NORTHEAST</code>(defined in <code>JsFrameBorderBlock</code>):
 * The northeast portion of the layout for the <code>JsFrame</code>.
 * <li><code>WEST</code>(defined in <code>JsFrameBorderBlock</code>):
 * The west portion of the layout for the <code>JsFrame</code>.
 * <li><code>EAST</code>(defined in <code>JsFrameBorderBlock</code>):
 * The east portion of the layout for the <code>JsFrame</code>.
 * <li><code>SOUTHWEST</code>(defined in <code>JsFrameBorderBlock</code>):
 * The southwest portion of the layout for the <code>JsFrame</code>.
 * <li><code>SOUTH</code>(defined in <code>JsFrameBorderBlock</code>):
 * The south portion of the layout for the <code>JsFrame</code>.
 * <li><code>SOUTHEAST</code>(defined in <code>JsFrameBorderBlock</code>):
 * The southeast portion of the layout for the <code>JsFrame</code>.
 * </ul>
 * <p>
 * If you just want to operate some of the above border blocks, you should first get it 
 * from the layout of the <code>JsFrame</code> by doing the following:
 * <pre>
 * JsFrameLayout layout = (JsFrameLayout) jsframe.getLayout();
 * Component component = layout.getLayoutComponent(JsFrameLayout.NORTHWEST);
 * </pre>
 * or doing the following:
 * <pre>
 * JsFrameLayout layout = (JsFrameLayout) jsframe.getLayout();
 * JsComponent jscomponent = (JsComponent) layout.getLayoutComponent(JsFrameLayout.NORTHWEST);
 * </pre>
 * 
 * @see JsFrameBorderBlock
 * @see com.hfkj.jsframe.frame.JsFrame
 * @see com.hfkj.jsframe.component.JsComponent
 * 
 * @version 1.0 01/05/09
 * @author Jason (MSN:www.jason0086.com@hotmail.com)
 */
public class JsFrameBorder {
	
	/**
	 * The root frame.
	 */
	protected Frame rootFrm = null;
	
	/**
	 * The preferred width.
	 */
	private int preferredWidthInt = 10;
	
	/**
	 * Constructs a js frame border for the frame specified by the given frame.
	 * @param rootFrame the frame which is the host of this <code>JsFrameBorder</code>
	 */
	@SuppressWarnings("static-access")
	public JsFrameBorder(Frame rootFrame) {
		this.rootFrm = rootFrame;
		this.setupBorder();
		MetalLookAndFeel lookMlaf = (MetalLookAndFeel) UIManager.getLookAndFeel();
    	this.setColor(lookMlaf.getFocusColor(), lookMlaf.getMenuBackground());
    	this.setPreferredWidth(this.preferredWidthInt);
    	this.setResizable(true);
	}
	
	/**
	 * Change the icon and string associated with the look and feel.
	 */
	@SuppressWarnings("static-access")
	public void changeLookAndFeel() {
		MetalLookAndFeel lookMlaf = (MetalLookAndFeel) UIManager.getLookAndFeel();
    	this.setColor(lookMlaf.getFocusColor(), lookMlaf.getMenuBackground());
	}
	
	/**
	 * Returns the mask shape.
	 * @return the mask shape
	 */
	public Shape getMaskShape() {
		int widthInt = 0;
		int heightInt = 0;
		if (this.rootFrm.getExtendedState() == Frame.MAXIMIZED_BOTH) {
			widthInt = this.rootFrm.getMaximizedBounds().width;
			heightInt = this.rootFrm.getMaximizedBounds().height;
		}
		else {
			widthInt = this.rootFrm.getWidth();
			heightInt = this.rootFrm.getHeight();
		}
		return new RoundRectangle2D.Float(0, 
											0, 
											widthInt, 
											heightInt, 
											this.preferredWidthInt + (this.preferredWidthInt >> 1), 
											this.preferredWidthInt + (this.preferredWidthInt >> 1));
	}

	/**
	 * Sets the color for the border.
	 * @param outsideColor the outside color
	 * @param insideColor the inside color
	 */
    public void setColor(Color outsideColor, Color insideColor) {
    	JsLayoutManager xJlm = (JsLayoutManager) this.rootFrm.getLayout();
    	// set the UI for northwest portion of this frame
    	((JsComponent) xJlm.getLayoutComponent(JsFrameLayout.NORTHWEST)).setUI(
	    		new JsFrameBorderBlockUI(outsideColor, insideColor, JsFrameBorderBlock.NORTHWEST)
	    	);
    	// set the UI for north portion of this frame
    	((JsComponent) xJlm.getLayoutComponent(JsFrameLayout.NORTH)).setUI(
	    		new JsFrameBorderBlockUI(outsideColor, insideColor, JsFrameBorderBlock.NORTH)
	    	);
    	// set the UI for northeast portion of this frame
    	((JsComponent) xJlm.getLayoutComponent(JsFrameLayout.NORTHEAST)).setUI(
	    		new JsFrameBorderBlockUI(outsideColor, insideColor, JsFrameBorderBlock.NORTHEAST)
	    	);
    	// set the UI for west portion of this frame
    	((JsComponent) xJlm.getLayoutComponent(JsFrameLayout.WEST)).setUI(
	    		new JsFrameBorderBlockUI(outsideColor, insideColor, JsFrameBorderBlock.WEST)
	    	);
    	// set the UI for east portion of this frame
    	((JsComponent) xJlm.getLayoutComponent(JsFrameLayout.EAST)).setUI(
	    		new JsFrameBorderBlockUI(outsideColor, insideColor, JsFrameBorderBlock.EAST)
	    	);
    	// set the UI for southwest portion of this frame
    	((JsComponent) xJlm.getLayoutComponent(JsFrameLayout.SOUTHWEST)).setUI(
	    		new JsFrameBorderBlockUI(outsideColor, insideColor, JsFrameBorderBlock.SOUTHWEST)
	    	);
    	// set the UI for south portion of this frame
    	((JsComponent) xJlm.getLayoutComponent(JsFrameLayout.SOUTH)).setUI(
	    		new JsFrameBorderBlockUI(outsideColor, insideColor, JsFrameBorderBlock.SOUTH)
	    	);
    	// set the UI for southeast portion of this frame
    	((JsComponent) xJlm.getLayoutComponent(JsFrameLayout.SOUTHEAST)).setUI(
	    		new JsFrameBorderBlockUI(outsideColor, insideColor, JsFrameBorderBlock.SOUTHEAST)
	    	);
    }

	/**
	 * Sets the preferred width for the border.
	 * @param width the preferred width for the border
	 */
    public void setPreferredWidth(int width) {
    	JsLayoutManager xJlm = (JsLayoutManager) this.rootFrm.getLayout();
    	xJlm.getLayoutComponent(JsFrameLayout.NORTHWEST).setPreferredSize(new Dimension(width, width));
    	xJlm.getLayoutComponent(JsFrameLayout.NORTH).setPreferredSize(new Dimension(0, width));
    	xJlm.getLayoutComponent(JsFrameLayout.NORTHEAST).setPreferredSize(new Dimension(width, width));
    	xJlm.getLayoutComponent(JsFrameLayout.WEST).setPreferredSize(new Dimension(width, 0));
    	xJlm.getLayoutComponent(JsFrameLayout.EAST).setPreferredSize(new Dimension(width, 0));
    	xJlm.getLayoutComponent(JsFrameLayout.SOUTHWEST).setPreferredSize(new Dimension(width, width));
    	xJlm.getLayoutComponent(JsFrameLayout.SOUTH).setPreferredSize(new Dimension(0, width));
    	xJlm.getLayoutComponent(JsFrameLayout.SOUTHEAST).setPreferredSize(new Dimension(width, width));
    }
    
    /**
     * Sets the resizabled state of the border.
     * @param resizabled the resizabled state of the border
     */
    public void setResizable(boolean resizabled) {
    	JsLayoutManager xJlm = (JsLayoutManager) this.rootFrm.getLayout();
    	xJlm.getLayoutComponent(JsFrameLayout.NORTHWEST).setEnabled(resizabled);
    	xJlm.getLayoutComponent(JsFrameLayout.NORTH).setEnabled(resizabled);
    	xJlm.getLayoutComponent(JsFrameLayout.NORTHEAST).setEnabled(resizabled);
    	xJlm.getLayoutComponent(JsFrameLayout.WEST).setEnabled(resizabled);
    	xJlm.getLayoutComponent(JsFrameLayout.EAST).setEnabled(resizabled);
    	xJlm.getLayoutComponent(JsFrameLayout.SOUTHWEST).setEnabled(resizabled);
    	xJlm.getLayoutComponent(JsFrameLayout.SOUTH).setEnabled(resizabled);
    	xJlm.getLayoutComponent(JsFrameLayout.SOUTHEAST).setEnabled(resizabled);
    }
    
    private void setupBorder() {
    	this.rootFrm.add(new JsFrameBorderBlock(JsFrameBorderBlock.NORTHWEST, this.rootFrm), JsFrameLayout.NORTHWEST);
    	this.rootFrm.add(new JsFrameBorderBlock(JsFrameBorderBlock.NORTH, this.rootFrm), JsFrameLayout.NORTH);
    	this.rootFrm.add(new JsFrameBorderBlock(JsFrameBorderBlock.NORTHEAST, this.rootFrm), JsFrameLayout.NORTHEAST);
    	this.rootFrm.add(new JsFrameBorderBlock(JsFrameBorderBlock.WEST, this.rootFrm), JsFrameLayout.WEST);
    	this.rootFrm.add(new JsFrameBorderBlock(JsFrameBorderBlock.EAST, this.rootFrm), JsFrameLayout.EAST);
    	this.rootFrm.add(new JsFrameBorderBlock(JsFrameBorderBlock.SOUTHWEST, this.rootFrm), JsFrameLayout.SOUTHWEST);
    	this.rootFrm.add(new JsFrameBorderBlock(JsFrameBorderBlock.SOUTH, this.rootFrm), JsFrameLayout.SOUTH);
    	this.rootFrm.add(new JsFrameBorderBlock(JsFrameBorderBlock.SOUTHEAST, this.rootFrm), JsFrameLayout.SOUTHEAST);
    }
	

}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久精品夜色噜噜亚洲a∨| 欧美日韩电影在线播放| 中文字幕乱码日本亚洲一区二区| 黄色小说综合网站| 亚洲综合久久av| 欧美另类变人与禽xxxxx| 蜜桃一区二区三区在线观看| 久久影院视频免费| 成人综合婷婷国产精品久久| 亚洲另类一区二区| 欧美日韩美女一区二区| 精品中文字幕一区二区小辣椒| 久久久不卡影院| 色偷偷久久一区二区三区| 亚洲国产成人porn| 久久综合狠狠综合| 99精品国产热久久91蜜凸| 亚洲成人在线网站| 2020国产精品自拍| 日本黄色一区二区| 韩国三级中文字幕hd久久精品| 欧美激情在线观看视频免费| 欧美性做爰猛烈叫床潮| 精品一区免费av| 亚洲女同一区二区| 精品国产百合女同互慰| 91麻豆国产福利在线观看| 日韩精品午夜视频| ...xxx性欧美| 欧美成人欧美edvon| 91一区二区三区在线观看| 免费成人美女在线观看| 亚洲桃色在线一区| 精品剧情在线观看| 欧美性色黄大片手机版| 国产91综合一区在线观看| 午夜欧美大尺度福利影院在线看| 国产丝袜美腿一区二区三区| 欧美另类久久久品| 国产精品网曝门| 久久综合精品国产一区二区三区| 国产不卡视频一区| 日本欧美一区二区三区| 国产精品全国免费观看高清 | 亚洲丰满少妇videoshd| 2020国产精品| 欧美一区二区三区白人| 在线精品国精品国产尤物884a| 国产九色精品成人porny| 日韩电影在线一区二区三区| 亚洲丝袜制服诱惑| 国产片一区二区| 精品欧美一区二区三区精品久久| 欧美三级在线播放| 一本久道中文字幕精品亚洲嫩| 国产91丝袜在线播放九色| 免费人成网站在线观看欧美高清| 亚洲一区二区精品3399| 亚洲精品综合在线| 综合色天天鬼久久鬼色| 亚洲国产成人私人影院tom | 欧美一区二区三区视频免费播放| 色综合色综合色综合色综合色综合| 激情综合一区二区三区| 蜜桃av噜噜一区二区三区小说| 亚洲丶国产丶欧美一区二区三区| **欧美大码日韩| 亚洲欧洲精品一区二区三区不卡| 日本一区二区视频在线| 久久精品免视看| 国产欧美日产一区| 国产午夜亚洲精品午夜鲁丝片| 久久综合九色综合久久久精品综合| 日韩一级在线观看| 日韩欧美一级二级三级久久久| 日韩欧美你懂的| 欧美成人a在线| 精品少妇一区二区三区 | 欧美午夜一区二区| 欧美私人免费视频| 欧美日韩精品是欧美日韩精品| 欧美日韩一区二区三区不卡| 欧美日韩免费视频| 91精品欧美久久久久久动漫| 制服丝袜激情欧洲亚洲| 日韩欧美中文一区二区| 精品毛片乱码1区2区3区| 久久午夜老司机| 欧美国产精品劲爆| 亚洲三级免费电影| 亚洲电影你懂得| 久国产精品韩国三级视频| 激情综合一区二区三区| 高清国产一区二区三区| 日本精品视频一区二区三区| 欧美视频一区在线| 精品国产精品一区二区夜夜嗨| 欧美精品一区二区精品网| 亚洲国产精品av| 一区二区在线观看不卡| 欧美aaa在线| 国产99久久久国产精品免费看| 一本色道久久综合亚洲aⅴ蜜桃 | 国产精品911| 99久久国产综合精品麻豆 | 欧美一级电影网站| 久久久91精品国产一区二区精品| 中文字幕一区二区三区不卡在线| 亚洲成人综合视频| 国产老肥熟一区二区三区| 91丝袜美女网| 日韩视频在线永久播放| 中文字幕一区三区| 日韩国产精品大片| 成人一区二区视频| 欧美女孩性生活视频| 国产网站一区二区| 亚洲成人av一区| 懂色av一区二区在线播放| 欧美日本国产一区| 日本一区二区电影| 日本欧美一区二区| 色老综合老女人久久久| 亚洲精品一区二区三区在线观看| 最新热久久免费视频| 久久99精品国产麻豆不卡| 色成年激情久久综合| 国产亚洲精品精华液| 性欧美大战久久久久久久久| 丁香五精品蜜臀久久久久99网站| 欧美高清视频一二三区 | 精品在线播放午夜| 欧美吻胸吃奶大尺度电影| wwwwww.欧美系列| 日韩国产欧美一区二区三区| 91片黄在线观看| 国产精品你懂的在线欣赏| 日本麻豆一区二区三区视频| 色素色在线综合| 国产精品久久久久久久裸模| 久久国产精品一区二区| 欧美日韩国产区一| 亚洲三级在线播放| av在线综合网| 久久奇米777| 国内国产精品久久| 欧美一区二区三区在线观看视频| 一区二区三区高清| 99精品视频在线观看免费| 欧美大片一区二区| 日韩1区2区3区| 欧美剧情片在线观看| 亚洲精品国产第一综合99久久| 粉嫩aⅴ一区二区三区四区| 26uuu亚洲综合色| 日韩av在线播放中文字幕| 欧美色中文字幕| 亚洲制服丝袜av| 欧洲激情一区二区| 亚洲综合视频在线| 91福利国产成人精品照片| 亚洲特黄一级片| 色综合天天综合在线视频| 亚洲欧洲成人自拍| 一本久久精品一区二区| 亚洲欧美日韩精品久久久久| 91丨porny丨最新| 亚洲尤物在线视频观看| 色94色欧美sute亚洲线路一ni| 亚洲免费观看高清完整版在线观看| 成人av网址在线观看| 一色屋精品亚洲香蕉网站| 色综合天天做天天爱| 亚洲一区二区三区美女| 欧美色倩网站大全免费| 午夜精品久久久久久久久久| 91精品国产一区二区三区香蕉| 首页国产丝袜综合| 日韩欧美视频一区| 国产在线一区二区综合免费视频| 久久久久久久综合日本| 不卡影院免费观看| 亚洲精品少妇30p| 欧美日韩国产综合一区二区三区| 视频在线观看一区| 久久免费国产精品| 99久久久精品| 日韩精品亚洲一区| 久久精品视频免费观看| 成人av动漫网站| 亚洲成av人片观看| 精品国产伦理网| 99久久婷婷国产| 丝袜亚洲另类欧美| 久久久精品影视| 欧美伊人精品成人久久综合97| 奇米精品一区二区三区在线观看 | 91毛片在线观看| 免费成人av在线| 国产精品久久久久久久久免费丝袜|