org.jboss.errai.common.client.dom.TextInput.setAttribute()方法的使用及代码示例

x33g5p2x  于2022-01-30 转载在 其他  
字(9.0k)|赞(0)|评价(0)|浏览(122)

本文整理了Java中org.jboss.errai.common.client.dom.TextInput.setAttribute()方法的一些代码示例,展示了TextInput.setAttribute()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。TextInput.setAttribute()方法的具体详情如下:
包路径:org.jboss.errai.common.client.dom.TextInput
类名称:TextInput
方法名:setAttribute

TextInput.setAttribute介绍

暂无

代码示例

代码示例来源:origin: org.kie.workbench.screens/kie-wb-common-examples-screen-client

@Override
public void setPlaceHolder(final String placeHolder) {
  repositoryUrlInput.setAttribute("placeholder",
                  placeHolder);
}

代码示例来源:origin: org.drools/drools-wb-globals-editor-client

@Inject
public AddGlobalPopupViewImpl( final Div view,
                final TextInput aliasInput,
                final Select classNameSelect,
                final Button yesButton,
                final Button cancelButton,
                final TranslationService translationService ) {
  this.view = view;
  this.aliasInput = aliasInput;
  this.classNameSelect = classNameSelect;
  this.addButton = yesButton;
  this.cancelButton = cancelButton;
  this.translationService = translationService;
  aliasInput.setAttribute( "placeholder",
               translationService.getTranslation( GlobalsEditorConstants.AddGlobalPopupAliasInputPlaceholder ) );
}

代码示例来源:origin: kiegroup/drools-wb

@Inject
public AddGlobalPopupViewImpl( final Div view,
                final TextInput aliasInput,
                final Select classNameSelect,
                final Button yesButton,
                final Button cancelButton,
                final TranslationService translationService ) {
  this.view = view;
  this.aliasInput = aliasInput;
  this.classNameSelect = classNameSelect;
  this.addButton = yesButton;
  this.cancelButton = cancelButton;
  this.translationService = translationService;
  aliasInput.setAttribute( "placeholder",
               translationService.getTranslation( GlobalsEditorConstants.AddGlobalPopupAliasInputPlaceholder ) );
}

代码示例来源:origin: org.kie.workbench.stunner/kie-wb-common-stunner-widgets

@Override
@PostConstruct
public void initialize() {
  nameField.setAttribute("placeHolder",
              translationService.getTranslation(StunnerWidgetsConstants.NameEditBoxWidgetViewImp_name));
  super.initialize();
}

代码示例来源:origin: org.jbpm/jbpm-wb-human-tasks-client

@Override
public void setSelectedDate(final Date date) {
  if (date != null) {
    selectedDate = date;
    setupDateTimePicker();
    dateRangePicker.getElement().setAttribute("placeholder",
                         DateUtils.getDateTimeStr(selectedDate));
  }
}

代码示例来源:origin: kiegroup/jbpm-wb

@Override
public void setSelectedDate(final Date date) {
  if (date != null) {
    selectedDate = date;
    setupDateTimePicker();
    dateRangePicker.getElement().setAttribute("placeholder",
                         DateUtils.getDateTimeStr(selectedDate));
  }
}

代码示例来源:origin: org.kie.workbench.screens/kie-wb-common-datasource-mgmt-client

@PostConstruct
private void init( ) {
  nameFilterTextBox.setAttribute( "placeholder", translationService.getTranslation(
      DataSourceManagementConstants.DatabaseObjectExplorerViewImpl_namePatternHelp ) );
  dataGrid = new PagedTable<>( 20, new ProvidesKey< DatabaseObjectRow >( ) {
    @Override
    public Object getKey( DatabaseObjectRow item ) {
      return item.getName( );
    }
  } );
  initializeResultsTable( );
  resultsPanel.add( dataGrid );
}

代码示例来源:origin: org.kie.workbench.stunner/kie-wb-common-stunner-widgets

@Test
public void testInitialize() {
  tested.initialize();
  verify(nameField,
      times(1)).setAttribute(eq("placeHolder"), anyString());
}

代码示例来源:origin: org.jbpm/jbpm-wb-human-tasks-client

protected void setupDateTimePicker() {
  final DateRangePickerOptions options = getDateRangePickerOptions();
  dateRangePicker.setup(options,
             (start, end, label) -> {
               selectedDate = start.milliseconds(0).asDate();
               dateRangePicker.getElement().setAttribute("placeholder",
                                    DateUtils.getDateTimeStr(selectedDate));
             });
}

代码示例来源:origin: org.jbpm/jbpm-wb-executor-service-client

@EventHandler("run-later")
public void onRunLater(@ForEvent("change") final Event event) {
  dateFiltersInput.setHidden(false);
  dateRangePicker.getElement().setAttribute("placeholder",
                       DateUtils.getDateTimeStr(selectedDate));
  resetDateTimePicker();
}

代码示例来源:origin: kiegroup/jbpm-wb

protected void setupDateTimePicker() {
  final DateRangePickerOptions options = getDateRangePickerOptions();
  dateRangePicker.setup(options,
             (start, end, label) -> {
               selectedDate = start.milliseconds(0).asDate();
               dateRangePicker.getElement().setAttribute("placeholder",
                                    DateUtils.getDateTimeStr(selectedDate));
             });
}

代码示例来源:origin: kiegroup/jbpm-wb

@EventHandler("run-later")
public void onRunLater(@ForEvent("change") final Event event) {
  dateFiltersInput.setHidden(false);
  dateRangePicker.getElement().setAttribute("placeholder",
                       DateUtils.getDateTimeStr(selectedDate));
  resetDateTimePicker();
}

代码示例来源:origin: org.jbpm/jbpm-wb-executor-service-client

protected void resetDateTimePicker() {
  final DateRangePickerOptions options = getDateRangePickerOptions();
  dateRangePicker.setup(options,
             null);
  dateRangePicker.addApplyListener((e, p) -> {
    selectedDate = p.getStartDate().milliseconds(0).asDate();
    dateRangePicker.getElement().setAttribute("placeholder",
                         DateUtils.getDateTimeStr(selectedDate));
  });
}

代码示例来源:origin: kiegroup/jbpm-wb

protected void resetDateTimePicker() {
  final DateRangePickerOptions options = getDateRangePickerOptions();
  dateRangePicker.setup(options,
             null);
  dateRangePicker.addApplyListener((e, p) -> {
    selectedDate = p.getStartDate().milliseconds(0).asDate();
    dateRangePicker.getElement().setAttribute("placeholder",
                         DateUtils.getDateTimeStr(selectedDate));
  });
}

代码示例来源:origin: org.kie.workbench.stunner/kie-wb-common-stunner-bpmn-client

@PostConstruct
public void init() {
  timeDuration.setAttribute(PLACEHOLDER_ATTR,
               translationService.getValue(TimeDuration_Placeholder));
  timeCycle.setAttribute(PLACEHOLDER_ATTR,
              translationService.getValue(TimeCycle_Placeholder));
  timeDate.setAttribute(PLACEHOLDER_ATTR,
             translationService.getValue(TimeDate_Placeholder));
  durationTimerHelp.setAttribute(DATA_CONTENT_ATTR,
                  getDurationTimerHtmlHelpText());
  durationTimerHelpPopover.wrap(durationTimerHelp).popover();
  multipleTimerHelp.setAttribute(DATA_CONTENT_ATTR,
                  getMultipleTimerHtmlHelpText());
  multipleTimerHelpPopover.wrap(multipleTimerHelp).popover();
  dateTimerHelp.setAttribute(DATA_CONTENT_ATTR,
                getDateTimerHtmlHelpText());
  dateTimerHelpPopover.wrap(dateTimerHelp).popover();
  timeDateTimePicker.setPlaceholder(translationService.getValue(TimeDateTimePicker_Placeholder));
  timeDateTimePicker.setAutoClose(true);
  timeDateTimePicker.setHighlightToday(true);
  timeDateTimePicker.setShowTodayButton(true);
  timeDateTimePicker.setForceParse(false);
  timeDateTimePicker.addValueChangeHandler(event -> presenter.onTimeDateTimePickerChange());
  timeDateTimePicker.addHideHandler(hideEvent -> presenter.onTimeDateTimePickerHidden());
  timeDateTimePicker.setPosition(DateTimePickerPosition.BOTTOM_RIGHT);
  timeDateTimePicker.reload();
}

代码示例来源:origin: org.jbpm/jbpm-wb-human-tasks-client

protected void initDateTimePicker() {
  this.dateRangePicker = dateRangePickerProvider.get();
  dateRangePicker.getElement().setReadOnly(true);
  dateRangePicker.getElement().setAttribute("placeholder",
                       Constants.INSTANCE.Due_On());
  dateRangePicker.getElement().getClassList().add("form-control");
  setupDateTimePicker();
  dateRangePickerInput.add(ElementWrapperWidget.getWidget(dateRangePicker.getElement()));
}

代码示例来源:origin: kiegroup/jbpm-wb

protected void initDateTimePicker() {
  this.dateRangePicker = dateRangePickerProvider.get();
  dateRangePicker.getElement().setReadOnly(true);
  dateRangePicker.getElement().setAttribute("placeholder",
                       Constants.INSTANCE.Due_On());
  dateRangePicker.getElement().getClassList().add("form-control");
  setupDateTimePicker();
  dateRangePickerInput.add(ElementWrapperWidget.getWidget(dateRangePicker.getElement()));
}

代码示例来源:origin: kiegroup/jbpm-wb

final DateRangePicker dateRangePicker = dateRangePickerProvider.get();
dateRangePicker.getElement().setReadOnly(true);
dateRangePicker.getElement().setAttribute("placeholder",
                     placeholder);
addCSSClass(dateRangePicker.getElement(),

代码示例来源:origin: org.jbpm/jbpm-wb-executor-service-client

protected void initDateTimePicker() {
  this.dateRangePicker = dateRangePickerProvider.get();
  dateRangePicker.getElement().setReadOnly(true);
  dateRangePicker.getElement().setAttribute("placeholder",
                       Constants.INSTANCE.Due_On());
  dateRangePicker.getElement().getClassList().add("form-control");
  final Div div = (Div) getDocument().createElement("div");
  div.setAttribute("data-filter",
           "Date");
  div.getClassList().add("input-group");
  div.getClassList().add("filter-control");
  div.appendChild(dateRangePicker.getElement());
  dateFiltersInput.appendChild(div);
  dateFiltersInput.setHidden(true);
}

代码示例来源:origin: kiegroup/jbpm-wb

protected void initDateTimePicker() {
  this.dateRangePicker = dateRangePickerProvider.get();
  dateRangePicker.getElement().setReadOnly(true);
  dateRangePicker.getElement().setAttribute("placeholder",
                       Constants.INSTANCE.Due_On());
  dateRangePicker.getElement().getClassList().add("form-control");
  final Div div = (Div) getDocument().createElement("div");
  div.setAttribute("data-filter",
           "Date");
  div.getClassList().add("input-group");
  div.getClassList().add("filter-control");
  div.appendChild(dateRangePicker.getElement());
  dateFiltersInput.appendChild(div);
  dateFiltersInput.setHidden(true);
}

相关文章