本文整理了Java中org.eclipse.swt.widgets.Tree.isDisposed()
方法的一些代码示例,展示了Tree.isDisposed()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Tree.isDisposed()
方法的具体详情如下:
包路径:org.eclipse.swt.widgets.Tree
类名称:Tree
方法名:isDisposed
暂无
代码示例来源:origin: pentaho/pentaho-kettle
public void changeLooks() {
if ( !selectionTree.isDisposed() ) {
props.setLook( selectionTree );
}
props.setLook( tabfolder.getSwtTabset(), Props.WIDGET_STYLE_TAB );
refreshTree();
refreshGraph();
}
代码示例来源:origin: pentaho/pentaho-kettle
List<TreeSelection> objects = new ArrayList<TreeSelection>();
if ( selectionTree != null && !selectionTree.isDisposed() && tree.equals( selectionTree ) ) {
TreeItem[] selection = selectionTree.getSelection();
for ( int s = 0; s < selection.length; s++ ) {
代码示例来源:origin: pentaho/pentaho-kettle
if ( coreObjectsTree == null || coreObjectsTree.isDisposed() ) {
addCoreObjectsTree();
代码示例来源:origin: pentaho/pentaho-kettle
designTreeToolbar.setSearchPlaceholder( BaseMessages.getString( PKG, "Spoon.SelectionFilter.Placeholder" ) );
designTreeToolbar.addSearchModifyListener( modifyEvent -> {
if ( coreObjectsTree != null && !coreObjectsTree.isDisposed() ) {
previousShowTrans = false;
previousShowJob = false;
代码示例来源:origin: pentaho/pentaho-kettle
private synchronized void refreshView() {
if ( wTree.isDisposed() ) {
return;
代码示例来源:origin: inspectIT/inspectIT
/**
* Returns true if the tree in the sub-view is disposed. False otherwise.
*
* @return Returns true if the tree in the sub-view is disposed. False otherwise.
*/
private boolean checkDisposed() {
return treeViewer.getTree().isDisposed();
}
代码示例来源:origin: org.eclipse.xtext/ui
public void run() {
if (!treeViewer.getTree().isDisposed()) {
Object[] expandedElements = treeViewer.getExpandedElements();
for (Object expandedElement : expandedElements) {
if (!(expandedElement instanceof IOutlineNode))
LOG.error("Content outline contains illegal node " + expandedElement);
else
expandedNodes.add((IOutlineNode) expandedElement);
}
}
}
});
代码示例来源:origin: org.eclipse.xtext/ui
@Override
protected void stateChanged(boolean newState) {
if(treeViewer != null && !treeViewer.getTree().isDisposed())
treeViewer.refresh();
}
代码示例来源:origin: org.eclipse.xtext/ui
@Override
protected void stateChanged(boolean newState) {
if(treeViewer != null && !treeViewer.getTree().isDisposed())
treeViewer.refresh();
}
代码示例来源:origin: org.eclipse.pde/org.eclipse.pde.ui
@Override
public void done(IJobChangeEvent event) {
getDisplay().asyncExec(() -> {
if (checkboxViewer.getTree().isDisposed())
return;
checkboxViewer.restoreLeafCheckState();
});
}
});
代码示例来源:origin: org.eclipse.pde/org.eclipse.pde.ui
@Override
public void stateChanged(final State newState) {
if (!this.equals(fView.getCurrentPage()) || fTreeViewer == null || fTreeViewer.getTree().isDisposed())
// if this page is not active, then wait until we call refresh on next activation
return;
fTreeViewer.getTree().getDisplay().asyncExec(() -> fTreeViewer.setInput(newState));
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.gtk.aix.ppc
@Override
public void layout () {
if (tree == null || tree.isDisposed()) return;
if (item == null || item.isDisposed()) return;
int columnCount = tree.getColumnCount();
if (columnCount == 0 && column != 0) return;
if (columnCount > 0 && (column < 0 || column >= columnCount)) return;
super.layout();
}
}
代码示例来源:origin: BiglySoftware/BiglyBT
private void updateLanguage() {
if (tree == null || tree.isDisposed()) {
return;
}
TreeItem[] selection = tree.getSelection();
if (selection != null && selection.length > 0) {
updateHeader(selection[0]);
}
if (swtView != null) {
swtView.setTitle(getFullTitle());
}
}
代码示例来源:origin: org.eclipse.xtext/ui
public void register(OutlinePage outlinePage) {
for(IOutlineContribution contribution: contributions)
contribution.register(outlinePage);
TreeViewer treeViewer = outlinePage.getTreeViewer();
if(!treeViewer.getTree().isDisposed())
treeViewer.refresh();
}
代码示例来源:origin: org.eclipse.pde/org.eclipse.pde.ui
@Override
public void modelsChanged(PluginModelDelta delta) {
if (fTreeViewer == null || fTreeViewer.getTree().isDisposed())
return;
if (delta.getAddedEntries().length > 0 || delta.getChangedEntries().length > 0 || delta.getRemovedEntries().length > 0)
fTreeViewer.getTree().getDisplay().asyncExec(() -> fTreeViewer.refresh());
}
代码示例来源:origin: org.eclipse.swt.cocoa.macosx/x86_64
void collapseItem_collapseChildren (long /*int*/ id, long /*int*/ sel, long /*int*/ itemID, boolean children) {
TreeItem item = (TreeItem)display.getWidget(itemID);
if (item == null) return;
if (!ignoreExpand) item.sendExpand (false, children);
ignoreExpand = true;
super.collapseItem_collapseChildren (id, sel, itemID, children);
ignoreExpand = false;
if (isDisposed() || item.isDisposed()) return;
setScrollWidth ();
}
代码示例来源:origin: org.eclipse.pde/org.eclipse.pde.runtime
void refresh(Object[] objects) {
if (fTreeViewer.getTree().isDisposed())
return;
if (filtersEnabled()) {
deferredRefresh();
} else {
for (Object object : objects) {
fTreeViewer.refresh(object);
}
}
updateTitle();
}
代码示例来源:origin: org.eclipse.mylyn.commons/workbench
@Override
public void done(IJobChangeEvent event) {
if (event.getResult() != null && event.getResult().isOK() && !getViewer().getTree().isDisposed()) {
getViewer().setCheckedElements(selectedValues.toArray());
}
}
});
代码示例来源:origin: org.eclipse.equinox.p2/ui
protected void refreshViewer() {
final TreeViewer treeViewer = filteredTree.getViewer();
final Tree tree = treeViewer.getTree();
IWorkbench workbench = PlatformUI.getWorkbench();
if (workbench.isClosing())
return;
if (tree != null && !tree.isDisposed()) {
updateAvailableViewState();
}
}
};
代码示例来源:origin: org.eclipse.pde/org.eclipse.pde.runtime
void refresh(Object object) {
if (fTreeViewer.getTree().isDisposed())
return;
if (filtersEnabled()) {
deferredRefresh();
} else {
fTreeViewer.refresh(object);
updateTitle();
}
}
内容来源于网络,如有侵权,请联系作者删除!