本文整理了Java中org.eclipse.swt.graphics.Region.isDisposed
方法的一些代码示例,展示了Region.isDisposed
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Region.isDisposed
方法的具体详情如下:
包路径:org.eclipse.swt.graphics.Region
类名称:Region
方法名:isDisposed
[英]Returns true
if the region has been disposed, and false
otherwise.
This method gets the dispose state for the region. When a region has been disposed, it is an error to invoke any other method (except #dispose()) using the region.
[中]如果区域已被释放,则返回true
,否则返回false
。
此方法获取区域的dispose状态。当区域已被释放时,使用该区域调用任何其他方法(除了#dispose())都是错误的。
代码示例来源:origin: pentaho/pentaho-kettle
if ( ( (Region) object ).isDisposed() ) {
return;
代码示例来源:origin: org.eclipse.swt.cocoa.macosx/x86_64
/**
* Returns a string containing a concise, human-readable
* description of the receiver.
*
* @return a string representation of the receiver
*/
public String toString () {
if (isDisposed()) return "Region {*DISPOSED*}";
return "Region {" + handle + "}";
}
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc
/**
* Returns a string containing a concise, human-readable
* description of the receiver.
*
* @return a string representation of the receiver
*/
@Override
public String toString () {
if (isDisposed()) return "Region {*DISPOSED*}";
return "Region {" + handle + "}";
}
}
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86
/**
* Returns a string containing a concise, human-readable
* description of the receiver.
*
* @return a string representation of the receiver
*/
@Override
public String toString () {
if (isDisposed()) return "Region {*DISPOSED*}";
return "Region {" + handle + "}";
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x
/**
* Returns a string containing a concise, human-readable
* description of the receiver.
*
* @return a string representation of the receiver
*/
@Override
public String toString () {
if (isDisposed()) return "Region {*DISPOSED*}";
return "Region {" + handle + "}";
}
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc
/**
* Returns a string containing a concise, human-readable
* description of the receiver.
*
* @return a string representation of the receiver
*/
@Override
public String toString () {
if (isDisposed()) return "Region {*DISPOSED*}";
return "Region {" + handle + "}";
}
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.workbench
@Override
public void dispose() {
super.dispose();
if (!shellRegion.isDisposed())
shellRegion.dispose();
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x
/**
* Translate all of the polygons the receiver maintains to describe
* its area by the specified point.
*
* @param x the x coordinate of the point to translate
* @param y the y coordinate of the point to translate
*
* @exception SWTException <ul>
* <li>ERROR_GRAPHIC_DISPOSED - if the receiver has been disposed</li>
* </ul>
*
* @since 3.1
*/
public void translate (int x, int y) {
if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED);
translate(new Point(x, y));
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc
/**
* Translate all of the polygons the receiver maintains to describe
* its area by the specified point.
*
* @param x the x coordinate of the point to translate
* @param y the y coordinate of the point to translate
*
* @exception SWTException <ul>
* <li>ERROR_GRAPHIC_DISPOSED - if the receiver has been disposed</li>
* </ul>
*
* @since 3.1
*/
public void translate (int x, int y) {
if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED);
translate(new Point(x, y));
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc
/**
* Returns <code>true</code> if the receiver does not cover any
* area in the (x, y) coordinate plane, and <code>false</code> if
* the receiver does cover some area in the plane.
*
* @return <code>true</code> if the receiver is empty, and <code>false</code> otherwise
*
* @exception SWTException <ul>
* <li>ERROR_GRAPHIC_DISPOSED - if the receiver has been disposed</li>
* </ul>
*/
public boolean isEmpty() {
if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED);
return OS.gdk_region_empty(handle);
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.s390x
/**
* Returns <code>true</code> if the receiver does not cover any
* area in the (x, y) coordinate plane, and <code>false</code> if
* the receiver does cover some area in the plane.
*
* @return <code>true</code> if the receiver is empty, and <code>false</code> otherwise
*
* @exception SWTException <ul>
* <li>ERROR_GRAPHIC_DISPOSED - if the receiver has been disposed</li>
* </ul>
*/
public boolean isEmpty() {
if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED);
return OS.gdk_region_empty(handle);
}
代码示例来源:origin: org.eclipse.e4.ui.workbench.addons/swt
public void dispose() {
if (feedbackShell != null && !feedbackShell.isDisposed()) {
Region region = feedbackShell.getRegion();
if (region != null && !region.isDisposed())
region.dispose();
feedbackShell.dispose();
}
feedbackShell = null;
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.linux.ppc
/**
* Returns <code>true</code> if the receiver does not cover any
* area in the (x, y) coordinate plane, and <code>false</code> if
* the receiver does cover some area in the plane.
*
* @return <code>true</code> if the receiver is empty, and <code>false</code> otherwise
*
* @exception SWTException <ul>
* <li>ERROR_GRAPHIC_DISPOSED - if the receiver has been disposed</li>
* </ul>
*/
public boolean isEmpty() {
if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED);
return OS.gdk_region_empty(handle);
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.e4.ui.workbench.addons.swt
public void dispose() {
if (feedbackShell != null && !feedbackShell.isDisposed()) {
Region region = feedbackShell.getRegion();
if (region != null && !region.isDisposed()) {
region.dispose();
}
feedbackShell.dispose();
}
feedbackShell = null;
}
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui
public void close() {
if (fPopup != null) {
if (!fPopup.isDisposed()) {
fPopup.close();
}
fPopup= null;
}
releaseWidgetToken();
if (fRegion != null) {
if (! fRegion.isDisposed()) {
fRegion.dispose();
}
}
}
代码示例来源:origin: org.eclipse.jdt/org.eclipse.jdt.ui
public void close() {
if (fPopup != null) {
if (!fPopup.isDisposed()) {
fPopup.close();
}
fPopup= null;
}
releaseWidgetToken();
if (fRegion != null) {
if (! fRegion.isDisposed()) {
fRegion.dispose();
}
}
}
代码示例来源:origin: org.eclipse.xtext/ui
public void close() {
if (popup != null) {
if (!popup.isDisposed()) {
popup.close();
}
popup = null;
}
releaseWidgetToken();
if (region != null) {
if (!region.isDisposed()) {
region.dispose();
}
}
}
代码示例来源:origin: org.eclipse/org.eclipse.jdt.ui
public void close() {
if (fPopup != null) {
if (!fPopup.isDisposed()) {
fPopup.close();
}
fPopup= null;
}
releaseWidgetToken();
if (fRegion != null) {
if (! fRegion.isDisposed()) {
fRegion.dispose();
}
}
}
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.swt.win32.win32.x86
/**
* Returns a rectangle which represents the rectangular
* union of the collection of polygons the receiver
* maintains to describe its area.
*
* @return a bounding rectangle for the region
*
* @exception SWTException <ul>
* <li>ERROR_GRAPHIC_DISPOSED - if the receiver has been disposed</li>
* </ul>
*
* @see Rectangle#union
*/
public Rectangle getBounds () {
if (isDisposed()) SWT.error(SWT.ERROR_GRAPHIC_DISPOSED);
return DPIUtil.autoScaleDown(getBoundsInPixels());
}
代码示例来源:origin: org.eclipse.e4.ui.workbench.addons/swt
private void defineRegion() {
Region rgn = new Region();
for (Rectangle r : rects) {
rgn.add(r);
rgn.subtract(r.x + 2, r.y + 2, r.width - 4, r.height - 4);
}
if (feedbackShell.getRegion() != null && !feedbackShell.getRegion().isDisposed())
feedbackShell.getRegion().dispose();
feedbackShell.setRegion(rgn);
feedbackShell.redraw();
display.update();
}
内容来源于网络,如有侵权,请联系作者删除!