Package org.eclipse.swt.events

Examples of org.eclipse.swt.events.FocusAdapter


   
    /**
     * Attaches listeners to the internal table to track editing requests.
     */
    @Override protected void applyEditActionListeners() {
        activeTableFocusListener = new FocusAdapter() {
            @Override public void focusGained(FocusEvent focusEvent) {
                deactivateActiveControl();
            }
        };

View Full Code Here


  /**
   * Defines the functionality of focus and unfocus events. Manages
   * color changes and clearing search buffer.
   */
  private void createFocusUnfocusListeners() {
    this.addFocusListener(new FocusAdapter() {
      public void focusLost(FocusEvent arg0) {
        setForeground(getDisplay().getSystemColor(SWT.COLOR_WIDGET_DARK_SHADOW));
        setBackground(getDisplay().getSystemColor(SWT.COLOR_WIDGET_LIGHT_SHADOW));
        search = "";
      }
View Full Code Here

        label.setLayoutData(gridData);
        label.setText(getLabelText(paramDef));

        Text textInput = new Text(clientArea, SWT.BORDER);
        textInput.setData(paramDef.name);
        textInput.addFocusListener(new FocusAdapter() {
          @Override
      public void focusGained(FocusEvent e) {
        setErrorMessage(null);
        setMessage(paramDef.help != null ? paramDef.help : "");
      }
View Full Code Here

        combo.setData(paramDef.name);
        combo.setVisibleItemCount(10);
        for (String item : variableNames) {
            combo.add(item);
    }
        combo.addFocusListener(new FocusAdapter() {
          @Override
      public void focusGained(FocusEvent e) {
        setErrorMessage(null);
        setMessage(paramDef.help != null ? paramDef.help : "");
      }
View Full Code Here

        if (SyncResources.PASSWORD.equals(propertyName)) {
          textStyle |= SWT.PASSWORD;
        }
        Text textInput = new Text(clientArea, textStyle);
        textInput.setData(propertyName);
        textInput.addFocusListener(new FocusAdapter() {
          @Override
      public void focusGained(FocusEvent e) {
        setErrorMessage(null);
        setMessage(hintText);
      }
View Full Code Here

        Combo combo = new Combo(clientArea, SWT.BORDER | SWT.READ_ONLY);
        combo.setData(propertyName);
        for (String item : items) {
            combo.add(Messages.getString(item));
    }
        combo.addFocusListener(new FocusAdapter() {
          @Override
      public void focusGained(FocusEvent e) {
        setErrorMessage(null);
        setMessage("");
      }
View Full Code Here

            label.setLayoutData(gridData);
            label.setText(getLabelText(paramDef));

            Text textInput = new Text(clientArea, SWT.BORDER);
            textInput.setData(paramDef.name);
            textInput.addFocusListener(new FocusAdapter() {
                @Override
                public void focusGained(FocusEvent e) {
                    setErrorMessage(null);
                    setMessage(paramDef.help != null ? paramDef.help : "");
                }
View Full Code Here

            combo.setData(paramDef.name);
            combo.setVisibleItemCount(10);
            for (String item : variableNames) {
                combo.add(item);
            }
            combo.addFocusListener(new FocusAdapter() {
                @Override
                public void focusGained(FocusEvent e) {
                    setErrorMessage(null);
                    setMessage(paramDef.help != null ? paramDef.help : "");
                }
View Full Code Here

          checkSelection();
          checkDeleteable();
          checkSelectable();
        }
      });
      text.addFocusListener(new FocusAdapter() {
        public void focusLost(FocusEvent e) {
          Object newValue = text.getText();
          updateValue(newValue);
        }
      });
View Full Code Here

   
    Label lblType = new Label(container, SWT.NONE);
    lblType.setText("Type");
   
    typeText = new Text(container, SWT.BORDER);
    typeText.addFocusListener(new FocusAdapter() {
      @Override
      public void focusLost(FocusEvent e) {
        List<ToolClass> results = ToolClass.find(project, typeName);
        treeViewer.setInput(results);
      }
View Full Code Here

TOP

Related Classes of org.eclipse.swt.events.FocusAdapter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.