Exemplo n.º 1
0
  /** When the login button is clicked blabla happens */
  @UiHandler("loginButton")
  void onClick(ClickEvent e) {

    if (loginButton.getText().equals("Login")) {
      login();
    } else if (loginButton.getText().equals("Logout")) logout();
  }
  @Override
  public void onClick(ClickEvent event) {
    if (activated_btn.getText().equals("Deactivate")) med.deregisterIndicator(name_lbl.getText());
    else med.registerIndicator(name_lbl.getText());

    med.addExistingIndicators();
  }
Exemplo n.º 3
0
  public String getButtonText(Object obj) {
    for (int i = 0; i < panel.getWidgetCount(); i++) {
      Button b = (Button) panel.getWidget(i);
      if (b.getElement().getPropertyObject("object") == obj) return b.getText();
    }

    return null;
  }
Exemplo n.º 4
0
  @Override
  public void onClick(ClickEvent event) {
    Button source = (Button) event.getSource();
    if (buttons.contains(source)) {
      // 文字ボタン
      String letter = source.getText();
      addLetterToAnswer(letter);

    } else if (source == buttonDelete) {
      // 消すボタン
      onErase();

    } else if (source == buttonOk) {
      // OKボタン
      onOk();

    } else {
      throw new AssertionError();
    }
  }
Exemplo n.º 5
0
 /** Returns the text of the Button */
 public String getText() {
   return loginButton.getText();
 }
Exemplo n.º 6
0
 public String getText() {
   return button.getText();
 }
Exemplo n.º 7
0
 ActionMessageBox(Button button) {
   this.activatingButton = button;
   initWidget(uiBinder.createAndBindUi(this));
   send.setText(button.getText());
 }