public YearlyRecurrenceEditor() { setSpacing(6); getElement().removeAttribute("cellpadding"); HorizontalPanel p = new HorizontalPanel(); everyMonthOnNthDayRb.setStyleName("recurrenceRadioButton"); // $NON-NLS-1$ everyMonthOnNthDayRb.setChecked(true); p.add(everyMonthOnNthDayRb); p.add(monthOfYearLb0); dayOfMonthTb.setStylePrimaryName("DAY_OF_MONTH_TB"); // $NON-NLS-1$ dayOfMonthTb.setWidth("3em"); // $NON-NLS-1$ p.add(dayOfMonthTb); dayOfMonthLabel = new ErrorLabel(p); add(dayOfMonthLabel); p = new HorizontalPanel(); nthDayNameOfMonthNameRb.setStyleName("recurrenceRadioButton"); // $NON-NLS-1$ p.add(nthDayNameOfMonthNameRb); p.add(whichWeekLb); p.add(dayOfWeekLb); Label l = new Label(Messages.getString("schedule.of")); l.setStyleName("middleLabel"); // $NON-NLS-1$ p.add(l); p.add(monthOfYearLb1); add(p); configureOnChangeHandler(); }
protected void showEditor() { if (myTextEditor == null) { myTextEditor = new TextBox(); myTextEditor.setStylePrimaryName("field_edit"); myTextEditor.addValueChangeHandler( new ValueChangeHandler<String>() { public void onValueChange(ValueChangeEvent<String> aEvent) { hideEditor(true); } }); myTextEditor.addBlurHandler( new BlurHandler() { public void onBlur(BlurEvent aEvent) { hideEditor(false); } }); } if (allowHtml) { myTextEditor.setText(myHtmlView.getHTML()); myOuterPanel.remove(myHtmlView); } else { myTextEditor.setText(myTextView.getText()); myOuterPanel.remove(myTextView); } myOuterPanel.add(myTextEditor); myTextEditor.setFocus(true); }
@Override void wireEtc() { lookup.addItem("Select a Season"); listOrderEd.setStylePrimaryName("numbertextbox"); listOrderEd.setTitle( "This determines the order that the Seasons will be displayed in drop down selection boxes"); deleteBtn.setVisible(false); controller.addListener( EditSeasonDoIntialLoad.class, new ControllerListener<EditSeasonDoIntialLoad>() { @Override public void event(EditSeasonDoIntialLoad event) {} }); controller.addListener( LoadSeasonsReturned.class, new ControllerListener<LoadSeasonsReturned>() { @Override public void event(LoadSeasonsReturned result) { lookup.clear(); lookup.addItem("Select a Season"); seasonMap.clear(); int i = 0; for (TSe season : result.getSeasonList()) { String s = season.getSeason(); lookup.addItem(s, season.getId().toString()); seasonMap.put(++i, season); } setLookupLoaded(true); } }); controller.addListener( SaveSeasonReturned.class, new ControllerListener<SaveSeasonReturned>() { @Override public void event(SaveSeasonReturned event) { ContentEventDetail.setLastEventID(null); resetForm(); Window.alert("Data Saved"); saveBtn.setEnabled(true); service.loadSeasons(); } }); controller.addListener( SaveSeasonFailed.class, new ControllerListener<SaveSeasonFailed>() { @Override public void event(SaveSeasonFailed result) { saveBtn.setEnabled(true); } }); }