Package org.eclipse.swt.widgets

Examples of org.eclipse.swt.widgets.Button.addListener()


    // Clear Button
    if(allowCancel) {
      final Button cancel = new Button(shell, SWT.PUSH);
      cancel.setText(Messages.getString("TaskProgress.cancel")); //$NON-NLS-1$
      cancel.addListener(SWT.Selection, new Listener() {
        public void handleEvent(Event event) {
        }
      });
      data = new GridData ();
      data.horizontalAlignment = GridData.CENTER;
View Full Code Here


        };

        txtJarPath.addListener(SWT.Modify, listener);
        btnJar.addListener(SWT.Selection, listener);
        txtFolderPath.addListener(SWT.Modify, listener);
        btnFolder.addListener(SWT.Selection, listener);

        btnBrowseJar.addSelectionListener(new SelectionAdapter() {
            @Override
            public void widgetSelected(SelectionEvent e) {
                FileDialog dialog = new FileDialog(getShell(), SWT.SAVE);
View Full Code Here

          setSet(true);
          shell.dispose();
        }
      });

      buttonCancel.addListener(SWT.Selection, new Listener() {
        public void handleEvent(Event event) {
          setSet(false);
          shell.dispose();
        }
      });
View Full Code Here

       
        shell.dispose();
      }
    });

      buttonCancel.addListener(SWT.Selection, new Listener() {
        public void handleEvent(Event event) {
          shell.dispose();
        }
      });
     
View Full Code Here

          }
          shell.dispose();
        }
      });

      buttonCancel.addListener(SWT.Selection, new Listener() {
        public void handleEvent(Event event) {
          shell.dispose();
        }
      });
       
View Full Code Here

    };
   
    text.addSelectionListener(lsDef);
    buttonOK.addSelectionListener(lsDef);

    buttonCancel.addListener(SWT.Selection, new Listener() {
      public void handleEvent(Event event) {
        cancel();
      }
    });
   
View Full Code Here

        }
      }

      Button b = new Button(parent, flags);
      b.setData(this);
      b.addListener(SWT.Dispose, getButtonListener());
      // Don't hook a dispose listener on the parent
      b.addListener(SWT.Selection, getButtonListener());
      if (action.getHelpListener() != null) {
        b.addHelpListener(action.getHelpListener());
      }
View Full Code Here

      Button b = new Button(parent, flags);
      b.setData(this);
      b.addListener(SWT.Dispose, getButtonListener());
      // Don't hook a dispose listener on the parent
      b.addListener(SWT.Selection, getButtonListener());
      if (action.getHelpListener() != null) {
        b.addHelpListener(action.getHelpListener());
      }
      widget = b;
View Full Code Here

            }
          }
        };

        executeButton.addListener(SWT.Selection, clickListener);
        cancelButton.addListener(SWT.Selection, clickListener);

        optionGroup.pack();

        display(shell);
    }
View Full Code Here

  private Button createModelSelectionButton(Composite groupContent,
      String text, int model) {
    final Button button = new Button(groupContent, SWT.RADIO);
    button.setText(text);

    button.addListener(SWT.Selection, new ModelSelectionLitener(button,
        model));
    return button;
  }

  private Button getBindingSwitch(Composite groupContent) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.