本文整理汇总了Java中org.eclipse.swt.widgets.Composite.isDisposed方法的典型用法代码示例。如果您正苦于以下问题:Java Composite.isDisposed方法的具体用法?Java Composite.isDisposed怎么用?Java Composite.isDisposed使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.eclipse.swt.widgets.Composite
的用法示例。
在下文中一共展示了Composite.isDisposed方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getBoundsOnDisplay
import org.eclipse.swt.widgets.Composite; //导入方法依赖的package包/类
@Override
public Rectangle getBoundsOnDisplay() {
if (isDisposed() || tableRow == null) {
return null;
}
Rectangle bounds = getBoundsRaw();
if (bounds == null) {
return null;
}
TableViewPainted tv = ((TableViewPainted) tableRow.getView());
if (tv == null) {
return null;
}
Composite c = tv.getTableComposite();
if (c == null || c.isDisposed()) {
return null;
}
Point pt = c.toDisplay(bounds.x, bounds.y);
bounds.x = pt.x;
bounds.y = pt.y;
bounds.height = getHeight();
bounds.width = getWidthRaw();
return bounds;
}
示例2: build
import org.eclipse.swt.widgets.Composite; //导入方法依赖的package包/类
protected void
build()
{
Composite parent = (Composite)instance.getProperty( UpdateCheckInstance.PT_UI_PARENT_SWT_COMPOSITE );
if ( parent != null ){
if (parent.isDisposed()) {
throw( new RuntimeException( "cancelled" ));
}
build( parent );
}else{
throw( new RuntimeException( "borkeroo" ));
}
}
示例3: obfuscatedImage
import org.eclipse.swt.widgets.Composite; //导入方法依赖的package包/类
private void obfuscatedImage(Composite c, Image image) {
if (c == null || c.isDisposed() || !c.isVisible()) {
return;
}
Control[] children = c.getChildren();
for (Control childControl : children) {
if (!childControl.isVisible()) {
continue;
}
ObfuscateImage oi = (ObfuscateImage) childControl.getData("ObfuscateImage");
if (oi != null) {
oi.obfuscatedImage(image);
continue;
}
if (childControl instanceof Composite) {
obfuscatedImage((Composite) childControl, image);
}
}
}
示例4: disposeComposite
import org.eclipse.swt.widgets.Composite; //导入方法依赖的package包/类
private void disposeComposite(Composite composite){
if(composite !=null && !composite.isDisposed()){
composite.dispose();
}
}