예제 #1
0
  private void createDescription() {
    FormToolkit toolkit = new FormToolkit(getDisplay());

    setLayout(new GridLayout());

    text = toolkit.createText(this, "", SWT.NONE);
    text.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
    text.setText(description.getDisplay() != null ? description.getDisplay() : "");
    text.addModifyListener(mListener);
  }
예제 #2
0
 private void updateText() {
   text.removeModifyListener(mListener);
   text.setText(description.getDisplay() != null ? description.getDisplay() : "");
   text.addModifyListener(mListener);
 }