当前位置: 首页>>代码示例>>Java>>正文


Java Text.isDisposed方法代码示例

本文整理汇总了Java中org.eclipse.swt.widgets.Text.isDisposed方法的典型用法代码示例。如果您正苦于以下问题:Java Text.isDisposed方法的具体用法?Java Text.isDisposed怎么用?Java Text.isDisposed使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.eclipse.swt.widgets.Text的用法示例。


在下文中一共展示了Text.isDisposed方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: canFlipToNextPage

import org.eclipse.swt.widgets.Text; //导入方法依赖的package包/类
@Override
public boolean canFlipToNextPage() {

    ZooKeeperServerNewWizardPage2 jmxPage = (ZooKeeperServerNewWizardPage2) getNextPage();

    if (jmxPage != null) {
        GridComposite jmxPageGridComposite = jmxPage.getGridComposite();

        if (jmxPageGridComposite != null) {

            String hostPortString = getHost() + ":" + String.valueOf(ZooKeeperServerDescriptor.DEFAULT_JMX_PORT);
            String defaultJmxServiceUrlString = "service:jmx:rmi:///jndi/rmi://" + hostPortString + "/jmxrmi";

            Text jmxUrlText = (Text) jmxPageGridComposite
                    .getControl(ZooKeeperServerNewWizardPage2.CONTROL_NAME_JMX_URL_TEXT);
            
            if (jmxUrlText != null && !jmxUrlText.isDisposed()) {
                jmxUrlText.setText(defaultJmxServiceUrlString);
            }
        }
    }

    return super.canFlipToNextPage();
}
 
开发者ID:baloise,项目名称:eZooKeeper,代码行数:25,代码来源:ZooKeeperServerNewWizardPage1.java

示例2: setId

import org.eclipse.swt.widgets.Text; //导入方法依赖的package包/类
private void setId() {

        SetDigestIdDialog dialog = new SetDigestIdDialog(getShell());
        dialog.setBlockOnOpen(true);
        if (dialog.open() == SetDigestIdDialog.OK) {
            Text idEditor = (Text) _IdTableEditor.getEditor();
            if (idEditor != null && !idEditor.isDisposed()) {
                idEditor.setText(dialog.getDigestId());
                idEditor.forceFocus();
            }
        }

    }
 
开发者ID:baloise,项目名称:eZooKeeper,代码行数:14,代码来源:ZnodeAclComposite.java

示例3: addModifyListener

import org.eclipse.swt.widgets.Text; //导入方法依赖的package包/类
private void addModifyListener(Text text){
	if(text != null && !text.isDisposed()){
		text.addModifyListener(new ModifyListener() {
			@Override
			public void modifyText(ModifyEvent e) {
				Utils.INSTANCE.addMouseMoveListener(text, cursor);	
			}
		});
	}
}
 
开发者ID:capitalone,项目名称:Hydrograph,代码行数:11,代码来源:FTPProtocolWidget.java

示例4: addIdKeyComposite

import org.eclipse.swt.widgets.Text; //导入方法依赖的package包/类
/**
 * @param container
 * @return
 */
private Control addIdKeyComposite(Composite container) {
	Composite keyFileComposite = new Composite(container, SWT.BORDER);
	keyFileComposite.setLayout(new GridLayout(3, false));
	keyFileComposite.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false, 1, 1));
	
	FTPWidgetUtility ftpWidgetUtility = new FTPWidgetUtility();
	if(!StringUtils.equalsIgnoreCase(protocolText, "AWS S3 HTTPS")){
		Label userIdLbl = (Label) ftpWidgetUtility.createLabel(keyFileComposite, "User ID");
		text1 = (Text) ftpWidgetUtility.createText(keyFileComposite, "", SWT.BORDER);
		new Button(keyFileComposite, SWT.NONE).setVisible(false);
	}
	
	String label2Text = null;
	if(StringUtils.equalsIgnoreCase(protocolText, "AWS S3 HTTPS")){
		label2Text = "Porperty File";
	}else{
		label2Text = "Private Key";
	}
	
	Label privateKeyLbl = (Label) ftpWidgetUtility.createLabel(keyFileComposite, label2Text);
	setPropertyHelpText(privateKeyLbl, "Used to provide the value for authentication");
	privateKeyLbl.setCursor(new Cursor(privateKeyLbl.getDisplay(), SWT.CURSOR_HELP));
	text2 = (Text) ftpWidgetUtility.createText(keyFileComposite, "", SWT.BORDER);
	Utils.INSTANCE.addMouseMoveListener(text2, cursor);
	Button keyFileBrwsBtn = new Button(keyFileComposite, SWT.NONE);
	keyFileBrwsBtn.setText("...");
	
	selectionListener(keyFileBrwsBtn, text2);
	
	ControlDecoration text2ControlDecoration = WidgetUtility.addDecorator(text2,Messages.EMPTYFIELDMESSAGE);
	
	FTPWidgetUtility widgetUtility = new FTPWidgetUtility();
	if(text1 != null && !text1.isDisposed()){
		ControlDecoration text1ControlDecoration = WidgetUtility.addDecorator(text1,Messages.EMPTYFIELDMESSAGE);
		widgetUtility.validateWidgetText(text1, propertyDialogButtonBar, cursor, text1ControlDecoration);
	}
	widgetUtility.validateEmptyWidgetText(text2, propertyDialogButtonBar, cursor, text2ControlDecoration);
	
	if(text1!=null){
		addModifyListener(text1);
	}
	addModifyListener(text2);
	
	return keyFileComposite;
}
 
开发者ID:capitalone,项目名称:Hydrograph,代码行数:50,代码来源:FTPAuthenticEditorDialog.java


注:本文中的org.eclipse.swt.widgets.Text.isDisposed方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。