@Test public void testOnDateInputBlur() { dateSelectorView.onValueInputBlur(consumer); doReturn(target).when(dateSelectorView).getEventTarget(any()); dateSelectorView.onDateInputBlur(blurEvent); verify(consumer).accept(blurEvent); }
@EventHandler("date-input") public void onDateInputBlur(final BlurEvent blurEvent) { final Object target = getEventTarget(blurEvent); if (!Objects.isNull(onValueInputBlur) && !Objects.isNull(target)) { onValueInputBlur.accept(blurEvent); } }
DateSelectorView implements DateSelector.View { @EventHandler("date-input") public void onDateInputBlur(final BlurEvent blurEvent) { final Object target = getEventTarget(blurEvent); if (!Objects.isNull(onValueInputBlur) && !Objects.isNull(target)) { onValueInputBlur.accept(blurEvent); } } }
DateSelectorView implements DateSelector.View { @EventHandler("date-input") public void onDateInputBlur(final BlurEvent blurEvent) { final Object target = getEventTarget(blurEvent); if (!Objects.isNull(onValueInputBlur) && !Objects.isNull(target)) { onValueInputBlur.accept(blurEvent); } } @Inject  DateSelectorView(final HTMLInputElement dateInput,
                            final DateValueFormatter valueFormatter); }
DateSelectorView implements DateSelector.View { @EventHandler("date-input") public void onDateInputBlur(final BlurEvent blurEvent) { final Object target = getEventTarget(blurEvent); if (!Objects.isNull(onValueInputBlur) && !Objects.isNull(target)) { onValueInputBlur.accept(blurEvent); } } @Inject  DateSelectorView(final HTMLInputElement dateInput,
                            final DateValueFormatter valueFormatter); @Override String getValue(); @Override void setValue(final String value); @Override void setPlaceholder(final String placeholder); @Override void onValueChanged(final Consumer<Event> onValueChanged); @Override void select(); @EventHandler("date-input") void onDateInputBlur(final BlurEvent blurEvent); @Override void onValueInputBlur(final Consumer<BlurEvent> blurEvent); @Override boolean isChildOfView(final Object element); @Override void init(final DateSelectorView presenter); }
DateSelectorView implements DateSelector.View { @EventHandler("date-input") public void onDateInputBlur(final BlurEvent blurEvent) { final Object target = getEventTarget(blurEvent); if (!Objects.isNull(onValueInputBlur) && !Objects.isNull(target)) { onValueInputBlur.accept(blurEvent); } } @Inject  DateSelectorView(final HTMLInputElement dateInput,
                            final DateValueFormatter valueFormatter); @Override String getValue(); @Override void setValue(final String value); @Override void setPlaceholder(final String placeholder); @Override void onValueChanged(final Consumer<Event> onValueChanged); @Override void select(); @EventHandler("date-input") void onDateInputBlur(final BlurEvent blurEvent); @Override void onValueInputBlur(final Consumer<BlurEvent> blurEvent); @Override boolean isChildOfView(final Object element); @Override void init(final DateSelectorView presenter);  }