本文整理了Java中org.eclipse.swt.widgets.Button.dispose()
方法的一些代码示例,展示了Button.dispose()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Button.dispose()
方法的具体详情如下:
包路径:org.eclipse.swt.widgets.Button
类名称:Button
方法名:dispose
暂无
代码示例来源:origin: pentaho/pentaho-kettle
public void closeActiveButton() {
if ( button != null && !button.isDisposed() ) {
button.dispose();
}
}
代码示例来源:origin: com.eclipsesource.tabris/tabris
@Override
public void destroy() {
if( control != null ) {
control.dispose();
control = null;
}
}
代码示例来源:origin: net.sf.okapi.steps/okapi-step-tokenization-ui
public TokenSelectorPePage(Composite parent, int style) {
super(parent, style);
add.dispose();
modify.dispose();
remove.dispose();
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples
/**
* Creates the "Other" group. This is typically
* a child of the "Control" group.
*/
@Override
void createOtherGroup () {
super.createOtherGroup ();
backgroundImageButton.dispose ();
}
代码示例来源:origin: org.eclipse.pde/org.eclipse.pde.ui
private void updateMoreState(boolean needMore) {
if (needMore && moreButton == null) {
createMoreButton();
} else if (!needMore && moreButton != null) {
moreButton.dispose();
moreButton = null;
}
}
代码示例来源:origin: eclipse-jetty/eclipse-jetty-plugin
/**
* Deletes the item from the table
*
* @param table the table
*/
public void deleteItem(Table table)
{
if (item != null)
{
item.dispose();
button.dispose();
item = null;
button = null;
}
}
代码示例来源:origin: org.eclipse/org.eclipse.jst.ws.consumption.ui
public void dispose()
{
internalDispose();
if (editor_ != null)
editor_.dispose();
if (table_ != null)
table_.dispose();
if (add_ != null)
add_.dispose();
if (remove_ != null)
remove_.dispose();
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples
/**
* Disposes the editors without placing their contents
* into the table.
*/
@Override
void disposeEditors () {
comboEditor.setEditor (null, null, -1);
combo.dispose ();
nameText.dispose ();
widthText.dispose ();
heightText.dispose ();
leftAttach.dispose ();
rightAttach.dispose ();
topAttach.dispose ();
bottomAttach.dispose ();
}
代码示例来源:origin: org.apache.directory.studio/ldapbrowser.common
/**
* Delets a modification spec.
*
* @param index the index
*/
private void deleteModSpec( int index )
{
ModSpec modSpec = modSpecList.remove( index );
if ( modSpec != null )
{
modSpec.modGroup.dispose();
modSpec.modAddButton.dispose();
modSpec.modDeleteButton.dispose();
composite.setSize( composite.computeSize( SWT.DEFAULT, SWT.DEFAULT ) );
}
}
代码示例来源:origin: org.apache.directory.studio/ldapbrowser.common
/**
* Deletes the option line at the given index.
*
* @param optionComposite the option composite
* @param index the index
*/
private void deleteOptionLine( Composite optionComposite, int index )
{
OptionLine optionLine = optionLineList.remove( index );
if ( optionLine != null )
{
optionLine.optionText.dispose();
optionLine.optionAddButton.dispose();
optionLine.optionDeleteButton.dispose();
if ( !optionComposite.isDisposed() )
{
shell.layout( true, true );
}
}
}
代码示例来源:origin: org.eclipse/org.eclipse.jst.ws.consumption.ui
public void dispose()
{
super.dispose();
internalDispose();
if (editor_ != null)
editor_.dispose();
if (table_ != null)
table_.dispose();
if (add_ != null)
add_.dispose();
if (remove_ != null)
remove_.dispose();
}
代码示例来源:origin: eclipse-jetty/eclipse-jetty-plugin
/**
* Deletes the item
*
* @param table the table
*/
public void deleteItem(Table table)
{
if (item != null)
{
int indexOf = table.indexOf(item);
item.dispose();
includeButton.dispose();
globalButton.dispose();
if (indexOf > 0)
{
table.clearAll();
}
item = null;
includeButton = null;
globalButton = null;
}
}
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.ide
/**
* Creates the working set filter selection widgets.
*
* @param parent the parent composite of the working set widgets
*/
WorkingSetGroup(Composite parent) {
// radio button has to be part of main radio button group
button = createRadioButton(parent, TaskListMessages.TaskList_noWorkingSet);
GridData data = new GridData(GridData.FILL_HORIZONTAL);
button.setLayoutData(data);
Composite composite = new Composite(parent, SWT.NONE);
composite.setFont(parent.getFont());
GridLayout layout = new GridLayout();
Button radio = new Button(parent, SWT.RADIO);
layout.marginWidth = radio.computeSize(SWT.DEFAULT, SWT.DEFAULT).x;
layout.marginHeight = 0;
radio.dispose();
composite.setLayout(layout);
createButton(composite, SELECT_ID, TaskListMessages.TaskList_workingSetSelect, false);
}
代码示例来源:origin: org.apache.directory.studio/ldapbrowser.common
/**
* Delete the Rdn line on the given index.
*
* @param rdnComposite the Rdn composite
* @param index the index
*/
private void deleteRdnLine( Composite rdnComposite, int index )
{
RdnLine rdnLine = rdnLineList.remove( index );
if ( rdnLine != null )
{
rdnLine.rdnTypeCombo.dispose();
rdnLine.rdnEqualsLabel.dispose();
rdnLine.rdnValueText.dispose();
rdnLine.rdnAddButton.dispose();
rdnLine.rdnDeleteButton.dispose();
if ( !rdnComposite.isDisposed() )
{
shell.layout( true, true );
}
}
}
代码示例来源:origin: org.apache.directory.studio/ldapbrowser.common
/**
* Deletes the language line at the given index.
*
* @param langComposite the language composite
* @param index the index
*/
private void deleteLangLine( Composite langComposite, int index )
{
LangLine langLine = langLineList.remove( index );
if ( langLine != null )
{
langLine.langLabel.dispose();
langLine.languageCombo.dispose();
langLine.minusLabel.dispose();
langLine.countryCombo.dispose();
langLine.addButton.dispose();
langLine.deleteButton.dispose();
if ( !langComposite.isDisposed() )
{
shell.layout( true, true );
}
}
}
代码示例来源:origin: org.eclipse/org.eclipse.jdt.debug.ui
/**
* Disposes of the text viewer and associated widgets.
*/
protected void disposeTextViewer() {
if (fTextGroup != null) {
fTextGroup.dispose();
fTextGroup= null;
}
if (fTextViewer != null) {
StyledText textWidget = fTextViewer.getTextWidget();
if (textWidget != null) {
textWidget.dispose();
}
fTextViewer= null;
}
if (fWrapText != null) {
fWrapText.dispose();
fWrapText= null;
}
}
代码示例来源:origin: cbeust/testng-eclipse
public void dispose() {
m_outputdir.dispose();
m_disabledDefaultListeners.dispose();
m_xmlTemplateFile.dispose();
m_preDefinedListeners.dispose();
super.dispose();
}
代码示例来源:origin: org.xworker/xworker_swt
public static void keyDown(ActionContext actionContext){
Event event = (Event) actionContext.get("event");
Button button = (Button) actionContext.get("button");
Control control = (Control) event.widget;
Composite cursor = (Composite) button.getData("cursor");
Thing cursorThing = (Thing) cursor.getData("thing");
Object tableItem = button.getData("item");
Object column = button.getData("column");
switch(event.character){
case SWT.CR:
Thing thing = (Thing) control.getData();
Object value = null;
if(button.getSelection()){
value = thing.get("trueText");
}else{
value = thing.get("falseText");
}
cursorThing.doAction("setValue", (ActionContext) actionContext.get("parentContext"),
UtilMap.toParams(new Object[]{"item", tableItem, "column", column, "value", value}));
button.dispose();
break;
case SWT.ESC:
button.dispose();
break;
}
}
}
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.ui.ide
@Override
public void dispose() {
intervalField.setPropertyChangeListener(null);
noteMessage.dispose();
noteLabel.dispose();
resetMessage.dispose();
intervalField.dispose();
intervalComposite.dispose();
autoSaveGroup.dispose();
autoSaveButton.dispose();
super.dispose();
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.ui.workbench
closeButton.dispose();
else {
control.setVisible(false);
内容来源于网络,如有侵权,请联系作者删除!