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

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

?? cbanner.java

?? 源碼為Eclipse開源開發平臺桌面開發工具SWT的源代碼,
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
/******************************************************************************* * 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.custom;import org.eclipse.swt.graphics.*;import org.eclipse.swt.widgets.*;import org.eclipse.swt.*;/** * Instances of this class implement a Composite that lays out its * children and allows programmatic control of the layout. It draws * a separator between the left and right children which can be dragged * to resize the right control. * CBanner is used in the workbench to layout the toolbar area and * perspective switching toolbar at the top of the workbench. * <p> * Note that although this class is a subclass of <code>Composite</code>, * it does not make sense to set a layout on it. * </p><p> * <dl> * <dt><b>Styles:</b></dt> * <dd>NONE</dd> * <dt><b>Events:</b></dt> * <dd>(None)</dd> * </dl> * <p> * IMPORTANT: This class is <em>not</em> intended to be subclassed. * </p> *  * @since 3.0 */public class CBanner extends Composite {		Control left;	Control right;	Control bottom;		boolean simple = true;		int[] curve;	int curveStart = 0;	Rectangle curveRect = new Rectangle(0, 0, 0, 0);	int curve_width = 5;	int curve_indent = -2;		int rightWidth = SWT.DEFAULT;	Cursor resizeCursor;	boolean dragging = false;	int rightDragDisplacement = 0;		static final int OFFSCREEN = -200;	static final int BORDER_BOTTOM = 2;	static final int BORDER_TOP = 3;	static final int BORDER_STRIPE = 1;	static final int CURVE_TAIL = 200;	static final int BEZIER_RIGHT = 30;	static final int BEZIER_LEFT = 30;	static final int MIN_LEFT = 10;	static final int MIN_RIGHT = 160;		static int BORDER1 = SWT.COLOR_WIDGET_HIGHLIGHT_SHADOW;			/** * Constructs a new instance of this class given its parent * and a style value describing its behavior and appearance. * <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 widget which will be the parent of the new instance (cannot be null) * @param style the style of widget 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> * </ul> * */public CBanner(Composite parent, int style) {	super(parent, checkStyle(style));	resizeCursor = new Cursor(getDisplay(), SWT.CURSOR_SIZEWE);		Listener listener = new Listener() {		public void handleEvent(Event e) {			switch (e.type) {				case SWT.Dispose:					onDispose(); break;				case SWT.MouseDown:					onMouseDown (e.x, e.y); break;				case SWT.MouseExit:					onMouseExit(); break;				case SWT.MouseMove:					onMouseMove(e.x, e.y); break;				case SWT.MouseUp:					onMouseUp(); break;				case SWT.Paint:					onPaint(e.gc); break;				case SWT.Resize:					onResize(); break;			}		}	};	int[] events = new int[] {SWT.Dispose, SWT.MouseDown, SWT.MouseExit, SWT.MouseMove, SWT.MouseUp, SWT.Paint, SWT.Resize};	for (int i = 0; i < events.length; i++) {		addListener(events[i], listener);	}}static int[] bezier(int x0, int y0, int x1, int y1, int x2, int y2, int x3, int y3, int count) {	// The parametric equations for a Bezier curve for x[t] and y[t] where  0 <= t <=1 are:	// x[t] = x0+3(x1-x0)t+3(x0+x2-2x1)t^3+(x3-x0+3x1-3x2)t^3	// y[t] = y0+3(y1-y0)t+3(y0+y2-2y1)t^2+(y3-y0+3y1-3y2)t^3	double a0 = x0;	double a1 = 3*(x1 - x0);	double a2 = 3*(x0 + x2 - 2*x1);	double a3 = x3 - x0 + 3*x1 - 3*x2;	double b0 = y0;	double b1 = 3*(y1 - y0);	double b2 = 3*(y0 + y2 - 2*y1);	double b3 = y3 - y0 + 3*y1 - 3*y2;	int[] polygon = new int[2*count + 2];	for (int i = 0; i <= count; i++) {		double t = (double)i / (double)count;		polygon[2*i] = (int)(a0 + a1*t + a2*t*t + a3*t*t*t);		polygon[2*i + 1] = (int)(b0 + b1*t + b2*t*t + b3*t*t*t);	}	return polygon;}static int checkStyle (int style) {	return SWT.NONE;}public Point computeSize(int wHint, int hHint, boolean changed) {	checkWidget();	boolean showCurve = left != null && right != null;	int height = hHint;	int width = wHint;		Point bottomSize = new Point(0, 0);	if (bottom != null) {		Point trim = bottom.computeSize(width, SWT.DEFAULT);		trim.x = trim.x - width;		bottomSize = bottom.computeSize(width == SWT.DEFAULT ? SWT.DEFAULT : width - trim.x, SWT.DEFAULT);		if (height != SWT.DEFAULT) {			bottomSize.y = Math.min(bottomSize.y, height);			height -= bottomSize.y + BORDER_TOP + BORDER_STRIPE + BORDER_BOTTOM;		}	}	if (showCurve && height != SWT.DEFAULT ) height -= BORDER_TOP + BORDER_BOTTOM + 2*BORDER_STRIPE;	Point rightSize = new Point(0, 0);	if (right != null) {		Point trim = right.computeSize(rightWidth, height);		trim.x = trim.x - rightWidth;		rightSize = right.computeSize(rightWidth == SWT.DEFAULT ? SWT.DEFAULT : rightWidth - trim.x, rightWidth == SWT.DEFAULT ? SWT.DEFAULT : height);		if (width != SWT.DEFAULT) {			rightSize.x = Math.min(rightSize.x, width);			width -= rightSize.x + curve_width - 2* curve_indent;			width = Math.max(width, MIN_LEFT);		}	}	Point leftSize = new Point(0, 0);	if (left != null) {		Point trim = left.computeSize(width, SWT.DEFAULT);		trim.x = trim.x - width;		leftSize = left.computeSize(width == SWT.DEFAULT ? SWT.DEFAULT : width - trim.x, SWT.DEFAULT);	}	int w = 0, h = 0;	h += bottomSize.y;	if (bottom != null && (left != null || right != null)) h += BORDER_TOP + BORDER_BOTTOM + BORDER_STRIPE;	w += leftSize.x + rightSize.x;	if (showCurve) {		w += curve_width - 2*curve_indent;		h +=  BORDER_TOP + BORDER_BOTTOM + 2*BORDER_STRIPE;	}	h += left != null ? leftSize.y : rightSize.y;		if (wHint != SWT.DEFAULT) w = wHint;	if (hHint != SWT.DEFAULT) h = hHint;		return new Point(w, h);}public Rectangle computeTrim (int x, int y, int width, int height) {	checkWidget ();	return new Rectangle(x, y, width, height);}/*** Returns the Control that appears on the bottom side of the banner.* * @return the control that appears on the bottom side of the banner or null* * @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>* * @since 3.0*/public Control getBottom() {	checkWidget();	return bottom;}public Rectangle getClientArea() {	return new Rectangle(0, 0, 0, 0);}/*** Returns the Control that appears on the left side of the banner.* * @return the control that appears on the left side of the banner or null* * @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>* * @since 3.0*/public Control getLeft() {	checkWidget();	return left;}/*** Returns the Control that appears on the right side of the banner.* * @return the control that appears on the right side of the banner or null* * @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>* * @since 3.0*/public Control getRight() {	checkWidget();	return right;}/** * Returns the width of the control that appears on the right of the banner. *  * @return the width of the control that appears on the right of the banner *  * @since 3.0 */public int getRightWidth() {	checkWidget();	if (right == null) return 0;	if (rightWidth == SWT.DEFAULT) return right.computeSize(SWT.DEFAULT, getSize().y).x;	return rightWidth;}/** * Returns <code>true</code> if the CBanner is rendered * with a simple, traditional shape. *  * @return <code>true</code> if the Cbanner is rendered with a simple shape *  * @since 3.0 */public boolean getSimple() {	checkWidget();	return simple;}public void layout (boolean changed) {	checkWidget();	Point size = getSize();	boolean showCurve = left != null && right != null;	int width = size.x;	int height = size.y;		Point bottomSize = new Point(0, 0);	if (bottom != null) {		Point trim = bottom.computeSize(width, SWT.DEFAULT);		trim.x = trim.x - width;		bottomSize = bottom.computeSize(width - trim.x, SWT.DEFAULT);		bottomSize.y = Math.min(bottomSize.y, height);		height -= bottomSize.y + BORDER_TOP + BORDER_BOTTOM + BORDER_STRIPE;	}		if (showCurve) height -=  BORDER_TOP + BORDER_BOTTOM + 2*BORDER_STRIPE;	height = Math.max(0, height);	Point rightSize = new Point(0,0);	if (right != null) {		Point trim = right.computeSize(rightWidth, height);		trim.x = trim.x - rightWidth;		rightSize = right.computeSize(rightWidth == SWT.DEFAULT ? SWT.DEFAULT : rightWidth - trim.x, rightWidth == SWT.DEFAULT ? SWT.DEFAULT : height);		rightSize.x = Math.min(rightSize.x, width);		width -= rightSize.x + curve_width - 2*curve_indent;		width = Math.max(width, MIN_LEFT); 	}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久99久久99小草精品免视看| 一区二区免费在线| 91 com成人网| 欧美视频精品在线观看| 色婷婷久久99综合精品jk白丝| 99久久久无码国产精品| 成人免费视频caoporn| 国产成人精品影院| 成人av综合在线| 一本久久精品一区二区| 欧美中文字幕一区| 欧美精品丝袜久久久中文字幕| 欧美欧美欧美欧美| 欧美一级免费大片| 国产日韩欧美精品在线| 亚洲欧美怡红院| 亚洲大片免费看| 久久国产精品免费| 国产99久久久精品| 99久久精品99国产精品| 欧美四级电影网| 91精品欧美综合在线观看最新| 日韩欧美中文字幕制服| 国产日产欧美一区二区视频| 亚洲欧美另类久久久精品2019| 亚洲成av人**亚洲成av**| 久久精工是国产品牌吗| 在线观看一区日韩| 日韩三级视频在线看| 久久久精品tv| 亚洲欧美激情小说另类| 五月婷婷久久综合| 国产69精品久久久久777| 欧美日韩精品欧美日韩精品| 日韩午夜精品视频| 亚洲精品免费看| 卡一卡二国产精品| 97aⅴ精品视频一二三区| 欧美一区二区三区播放老司机| 久久亚洲欧美国产精品乐播| 亚洲视频资源在线| 国产主播一区二区三区| 欧美最猛黑人xxxxx猛交| 久久综合狠狠综合久久激情| 亚洲精品日韩一| 国产精品18久久久久久久久久久久| 91国偷自产一区二区使用方法| 日韩情涩欧美日韩视频| 一区二区三区精品| 成人毛片老司机大片| 欧美日韩国产在线观看| 中文字幕制服丝袜一区二区三区| 婷婷国产在线综合| 欧美亚洲国产bt| 亚洲欧洲色图综合| 成人免费高清在线观看| 精品国一区二区三区| 五月婷婷综合网| 欧洲视频一区二区| 自拍偷拍亚洲综合| 成人小视频免费观看| 亚洲视频在线观看一区| 成人精品免费网站| 2024国产精品| 久久91精品久久久久久秒播| 欧美日韩一区二区不卡| 日韩美女视频一区二区| 成人中文字幕在线| 欧美激情一区二区| 成人一区二区三区在线观看| 欧美zozo另类异族| 久久国产麻豆精品| 久久夜色精品一区| 国产在线观看一区二区| 久久精品视频一区二区| 国产麻豆精品在线| 久久日一线二线三线suv| 国产麻豆9l精品三级站| 久久综合久久综合久久| 国产一区二区三区高清播放| 久久这里只有精品6| 国产在线播放一区三区四| 久久久三级国产网站| 国产精品亚洲专一区二区三区| 精品免费一区二区三区| 国产精品影视网| 欧美激情在线观看视频免费| 99视频国产精品| 一区二区欧美在线观看| 欧美高清激情brazzers| 韩国成人在线视频| 中文字幕精品一区| 在线免费观看一区| 午夜视频一区二区| 久久久噜噜噜久久中文字幕色伊伊 | 天堂成人免费av电影一区| 欧美日韩精品一区二区三区蜜桃| 免费在线看成人av| 中文字幕国产一区二区| 91精彩视频在线观看| 日本不卡一区二区| 国产欧美一区二区精品性| 色成人在线视频| 日产精品久久久久久久性色| 国产日产精品1区| 欧美日韩精品综合在线| 国产精品一区二区免费不卡 | 亚洲国产一区二区a毛片| 欧美一区二区黄色| 欧美视频一区二区三区四区| 午夜精品视频在线观看| 2024国产精品| 欧美性猛片xxxx免费看久爱| 韩国在线一区二区| 亚洲综合丁香婷婷六月香| 欧美va在线播放| 色成年激情久久综合| 国产福利精品导航| 午夜影视日本亚洲欧洲精品| 国产欧美日韩在线| 欧美一区二区三区不卡| 色婷婷av一区二区三区之一色屋| 美女高潮久久久| 一区二区久久久久久| 国产精品视频看| 日韩欧美激情四射| 欧美揉bbbbb揉bbbbb| 成人午夜看片网址| 激情综合五月婷婷| 亚洲制服丝袜一区| 国产精品伦理一区二区| 欧美精品一区二区三区四区| 精品视频色一区| 色综合久久天天| 成人性生交大片免费看在线播放| 日本三级韩国三级欧美三级| 亚洲高清免费视频| 亚洲精品美国一| 亚洲精品视频在线观看网站| 国产欧美一区二区精品婷婷| 久久综合九色综合欧美98| 欧美一区日韩一区| 欧美肥胖老妇做爰| 欧美精选一区二区| 欧美亚洲动漫精品| 在线观看国产日韩| 91久久线看在观草草青青| 91免费看`日韩一区二区| 成人avav影音| 99国产精品一区| 色诱视频网站一区| 91国偷自产一区二区三区成为亚洲经典| www.欧美精品一二区| 成人激情免费视频| 91免费观看视频在线| 99精品桃花视频在线观看| 99久久99久久免费精品蜜臀| 99re这里都是精品| 色综合激情五月| 欧美日韩高清一区| 51精品秘密在线观看| 精品久久国产老人久久综合| www久久久久| 中文字幕日韩一区| 亚洲成人动漫av| 毛片av中文字幕一区二区| 国产成人99久久亚洲综合精品| 国产91丝袜在线播放| 91一区二区三区在线观看| 91国产精品成人| 日韩欧美中文字幕精品| 国产欧美日韩中文久久| 亚洲精品一二三区| 免费观看日韩av| 成人深夜福利app| 97se狠狠狠综合亚洲狠狠| 欧美亚洲禁片免费| 欧美精品一区二区久久久| 欧美国产1区2区| 亚洲va国产va欧美va观看| 国产伦理精品不卡| 欧美性受xxxx黑人xyx性爽| 日韩欧美一二三| 亚洲人成小说网站色在线| 日本不卡视频在线| 97久久精品人人澡人人爽| 91精品蜜臀在线一区尤物| 中文字幕av不卡| 香港成人在线视频| www.成人网.com| 欧美一卡在线观看| 中文字幕日本乱码精品影院| 日韩精品高清不卡| 91污在线观看| 久久久精品免费网站| 亚洲超丰满肉感bbw| 9色porny自拍视频一区二区| 日韩欧美的一区二区| 一区二区三区国产精华| 成人性视频免费网站|