use of com.google.gwt.event.dom.client.ClickEvent in project che by eclipse.
the class MoveViewImpl method createButtons.
private void createButtons(JavaLocalizationConstant locale) {
preview = createButton(locale.moveDialogButtonPreview(), "move-preview-button", new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
delegate.onPreviewButtonClicked();
}
});
Button cancel = createButton(locale.moveDialogButtonCancel(), "move-cancel-button", new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
hide();
delegate.onCancelButtonClicked();
}
});
accept = createButton(locale.moveDialogButtonOk(), "move-accept-button", new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
delegate.onAcceptButtonClicked();
}
});
addButtonToFooter(accept);
addButtonToFooter(cancel);
addButtonToFooter(preview);
}
use of com.google.gwt.event.dom.client.ClickEvent in project che by eclipse.
the class OrganizeImportsViewImpl method createButtons.
private void createButtons(JavaLocalizationConstant locale) {
back = createButton(locale.organizeImportsButtonBack(), "imports-back-button", new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
delegate.onBackButtonClicked();
}
});
next = createButton(locale.organizeImportsButtonNext(), "imports-next-button", new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
delegate.onNextButtonClicked();
}
});
Button cancel = createButton(locale.organizeImportsButtonCancel(), "imports-cancel-button", new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
hide();
delegate.onCancelButtonClicked();
}
});
finish = createPrimaryButton(locale.organizeImportsButtonFinish(), "imports-finish-button", new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
delegate.onFinishButtonClicked();
}
});
addButtonToFooter(finish);
addButtonToFooter(cancel);
addButtonToFooter(next);
addButtonToFooter(back);
}
use of com.google.gwt.event.dom.client.ClickEvent in project che by eclipse.
the class OrganizeImportsViewImpl method show.
/** {@inheritDoc} */
@Override
public void show(ConflictImportDTO match) {
container.clear();
List<String> matches = match.getTypeMatches();
for (String fqn : matches) {
final Label label = new Label(fqn);
if (fqn.equals(selectedImport)) {
selectedLabel = label;
selectedLabel.getElement().getStyle().setBackgroundColor(getEditorSelectionColor());
}
label.getElement().getStyle().setColor(getMainFontColor());
label.getElement().getStyle().setCursor(POINTER);
label.addClickHandler(new ClickHandler() {
@Override
public void onClick(ClickEvent clickEvent) {
selectedLabel.getElement().getStyle().setBackgroundColor("initial");
selectedLabel = label;
label.getElement().getStyle().setBackgroundColor(getEditorSelectionColor());
}
});
container.add(label);
}
super.show();
}
use of com.google.gwt.event.dom.client.ClickEvent in project che by eclipse.
the class ShowSshKeyViewImpl method addButtons.
private void addButtons() {
Button cancel = createButton(locale.cancel(), "copy-machine-key-cancel-button", new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
hide();
}
});
addButtonToFooter(cancel);
}
use of com.google.gwt.event.dom.client.ClickEvent in project opentsdb by OpenTSDB.
the class MetricForm method setupDownsampleWidgets.
private void setupDownsampleWidgets() {
downsampler.setEnabled(false);
fill_policy.setEnabled(false);
interval.setEnabled(false);
interval.setMaxLength(5);
interval.setVisibleLength(5);
interval.setValue("10m");
interval.setValidationRegexp("^[1-9][0-9]*[smhdwy]$");
downsample.addClickHandler(new ClickHandler() {
public void onClick(final ClickEvent event) {
final boolean checked = ((CheckBox) event.getSource()).getValue();
downsampler.setEnabled(checked);
fill_policy.setEnabled(checked);
interval.setEnabled(checked);
if (checked) {
downsampler.setFocus(true);
}
}
});
}
Aggregations