本文整理了Java中org.eclipse.swt.widgets.Text.setFocus()
方法的一些代码示例,展示了Text.setFocus()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Text.setFocus()
方法的具体详情如下:
包路径:org.eclipse.swt.widgets.Text
类名称:Text
方法名:setFocus
暂无
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
wStepname.selectAll();
wStepname.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
private void getData() {
wStep.setSelection( searchingSteps );
wDB.setSelection( searchingDatabases );
wNote.setSelection( searchingNotes );
wFilter.setText( Const.NVL( filterString, "" ) );
wFilter.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
public void getData() {
if ( text != null ) {
wDesc.setText( text );
}
if ( readonly ) {
wOK.setFocus();
} else {
wDesc.setFocus();
}
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
if ( jobEntry.getName() != null ) {
wName.setText( jobEntry.getName() );
}
if ( jobEntry.arguments != null ) {
for ( int i = 0; i < jobEntry.arguments.length; i++ ) {
TableItem ti = wFields.table.getItem( i );
if ( jobEntry.arguments[i] != null ) {
ti.setText( 1, jobEntry.arguments[i] );
}
if ( jobEntry.filemasks[i] != null ) {
ti.setText( 2, jobEntry.filemasks[i] );
}
}
wFields.setRowNums();
wFields.optWidth( true );
}
wPrevious.setSelection( jobEntry.argFromPrevious );
wIncludeSubfolders.setSelection( jobEntry.includeSubfolders );
wDeleteAllBefore.setSelection( jobEntry.deleteallbefore );
wName.selectAll();
wName.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
wName.setText( Const.nullToEmpty( jobEntry.getName() ) );
wName.selectAll();
wName.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
if ( input.getFilename() != null ) {
wFilename.setText( input.getFilename() );
}
wDoNotOpenNewFileInit.setSelection( input.isDoNotOpenNewFileInit() );
wAddToResult.setSelection( input.isAddToResultFiles() );
wStepname.selectAll();
wStepname.setFocus();
}
代码示例来源:origin: caoxinyu/RedisClient
@Override
public void widgetSelected(SelectionEvent e) {
if(channel.getText().length() > 0 && message.getText().length() > 0){
publish.publish(id, channel.getText(), message.getText());
TableItem item = new TableItem(table, SWT.None);
SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss:SSS", Locale.getDefault());
String time = df.format(new Date());
String[] str = new String[]{time, channel.getText(), message.getText()};
item.setText(str);
table.setSelection(item);
channel.selectAll();
message.selectAll();
channel.setFocus();
}
}
});
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
if ( jobEntry.getName() != null ) {
wName.setText( jobEntry.getName() );
}
if ( jobEntry.arguments != null ) {
for ( int i = 0; i < jobEntry.arguments.length; i++ ) {
TableItem ti = wFields.table.getItem( i );
if ( jobEntry.arguments[i] != null ) {
ti.setText( 1, jobEntry.arguments[i] );
}
if ( jobEntry.filemasks[i] != null ) {
ti.setText( 2, jobEntry.filemasks[i] );
}
}
wFields.setRowNums();
wFields.optWidth( true );
}
wPrevious.setSelection( jobEntry.argFromPrevious );
wIncludeSubfolders.setSelection( jobEntry.includeSubfolders );
wName.selectAll();
wName.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
if ( jobEntry.getName() != null ) {
wName.setText( jobEntry.getName() );
}
if ( jobEntry.getFilename() != null ) {
wFilename.setText( jobEntry.getFilename() );
}
wName.selectAll();
wName.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
public void getData() {
wName.setText( Const.NVL( partitionSchema.getName(), "" ) );
refreshPartitions();
wDynamic.setSelection( partitionSchema.isDynamicallyDefined() );
wNumber.setText( Const.NVL( partitionSchema.getNumberOfPartitionsPerSlave(), "" ) );
wName.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
if ( input.getRowcountField() != null ) {
wRowcountField.setText( input.getRowcountField() );
}
if ( input.isOutputRowcount() ) {
wRowcountField.setEnabled( true );
}
wOutputRowcount.setSelection( input.isOutputRowcount() );
wStepname.selectAll();
wStepname.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
wStepname.selectAll();
wStepname.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
private void setSearchText() {
if ( this.text != null && !Utils.isEmpty( this.text.getSelectionText() ) ) {
searchText.setText( this.text.getSelectionText() );
}
searchText.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
Table table = wFields.table;
if ( input.getFieldName().length > 0 ) {
table.removeAll();
}
for ( int i = 0; i < input.getFieldName().length; i++ ) {
TableItem ti = new TableItem( table, SWT.NONE );
ti.setText( 0, "" + ( i + 1 ) );
ti.setText( 1, input.getFieldName()[i] );
ti.setText( 2, input.getAscending()[i] ? BaseMessages.getString( PKG, "System.Combo.Yes" ) : BaseMessages
.getString( PKG, "System.Combo.No" ) );
}
wFields.setRowNums();
wFields.optWidth( true );
wStepname.selectAll();
wStepname.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
for ( int i = 0; i < input.getFieldname().length; i++ ) {
TableItem item = wFields.table.getItem( i );
item.setText( 1, input.getFieldname()[i] );
item.setText( 2, ValueMetaFactory.getValueMetaName( input.getType()[i] ) );
int len = input.getLength()[i];
int prc = input.getPrecision()[i];
item.setText( 3, len >= 0 ? "" + len : "" );
item.setText( 4, prc >= 0 ? "" + prc : "" );
}
wStepname.selectAll();
wStepname.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
if ( jobEntry.getName() != null ) {
wName.setText( jobEntry.getName() );
}
if ( jobEntry.getMessageabort() != null ) {
wMessageAbort.setText( jobEntry.getMessageabort() );
}
wName.selectAll();
wName.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
public void getData() {
wName.setText( Const.NVL( clusterSchema.getName(), "" ) );
wPort.setText( Const.NVL( clusterSchema.getBasePort(), "" ) );
wBufferSize.setText( Const.NVL( clusterSchema.getSocketsBufferSize(), "" ) );
wFlushInterval.setText( Const.NVL( clusterSchema.getSocketsFlushInterval(), "" ) );
wCompressed.setSelection( clusterSchema.isSocketsCompressed() );
wDynamic.setSelection( clusterSchema.isDynamic() );
refreshSlaveServers();
wName.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
if ( input.getRowThreshold() != null ) {
wRowThreshold.setText( input.getRowThreshold() );
}
if ( input.getMessage() != null ) {
wMessage.setText( input.getMessage() );
}
wAlwaysLogRows.setSelection( input.isAlwaysLogRows() );
wAbortButton.setSelection( input.isAbort() );
wAbortWithErrorButton.setSelection( input.isAbortWithError() );
wSafeStopButton.setSelection( input.isSafeStop() );
wStepname.selectAll();
wStepname.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
/**
* Copy information from the meta-data input to the dialog fields.
*/
public void getData() {
wStepname.selectAll();
wStepname.setFocus();
}
代码示例来源:origin: pentaho/pentaho-kettle
private void setSearchText() {
if ( this.text != null && !Utils.isEmpty( this.text.getSelectionText() ) ) {
searchText.setText( this.text.getSelectionText() );
}
searchText.setFocus();
}
内容来源于网络,如有侵权,请联系作者删除!