List of usage examples for com.google.gwt.user.client.ui Label Label
protected Label(Element element)
From source file:com.alkacon.acacia.client.example.Example.java
License:Open Source License
/** * @see com.google.gwt.core.client.EntryPoint#onModuleLoad() *///from ww w . j a v a 2s.c o m public void onModuleLoad() { I_LayoutBundle.INSTANCE.form().ensureInjected(); I_Vie vie = Vie.getInstance(); ContentDefinition definition = generateContentDefinition(); I_Entity person = register(vie, definition); WidgetService service = new WidgetService(); service.init(definition); service.addWidgetFactory("string", new I_WidgetFactory() { public I_FormEditWidget createFormWidget(String configuration) { return new FormWidgetWrapper(new StringWidget()); } public I_EditWidget createInlineWidget(String configuration, Element element) { return new StringWidget(element); } }); service.addWidgetFactory("html", new I_WidgetFactory() { public I_FormEditWidget createFormWidget(String configuration) { return new FormWidgetWrapper(new TinyMCEWidget(null)); } public I_EditWidget createInlineWidget(String configuration, Element element) { return new TinyMCEWidget(element, null); } }); I_EntityRenderer defaultRenderer = new Renderer(vie, service); service.setDefaultRenderer(defaultRenderer); FormParent formParent = new FormParent(RootPanel.get("inline_form")); I_EntityRenderer renderer = service.getRendererForType(vie.getType(personTypeName)); renderer.renderInline(person, formParent, null); ((Entity) person).addValueChangeHandler(new ValueChangeHandler<Entity>() { public void onValueChange(ValueChangeEvent<Entity> event) { RootPanel.get().getElement().getStyle().setBackgroundColor("#77f3f3"); RootPanel.get().add(new Label(event.getValue().toJSON())); } }); }
From source file:com.alkacon.forms.client.example.Example.java
License:Open Source License
/** * @see com.google.gwt.core.client.EntryPoint#onModuleLoad() *///w ww .j av a2 s . c om public void onModuleLoad() { I_LayoutBundle.INSTANCE.style().ensureInjected(); I_Vie vie = Vie.getInstance(); ContentDefinition definition = generateContentDefinition(); registerTypes(vie, definition); I_Entity address = vie.createEntity("<myAdress>", addressTypeName); address.setAttributeValue(cityAttribute, "Hamburg"); address.setAttributeValue(countryAttribute, "fr"); I_Entity person = vie.createEntity("<myPerson>", personTypeName); person.setAttributeValue(firstnameAttribute, "Hans"); person.setAttributeValue(lastNameAttribute, "Albers"); person.setAttributeValue(addressAttribute, address); WidgetService service = new WidgetService(); service.init(definition); service.registerWidgetFactory("string", new I_WidgetFactory() { public I_EditWidget createWidget(String configuration) { return new StringWidget(); } }); I_EntityRenderer inlineRenderer = new InlineFormRenderer(vie, service); service.setDefaultComplexRenderer(inlineRenderer); service.setDefaultSimpleRenderer(inlineRenderer); I_EntityRenderer renderer = service.getRendererForType(vie.getType(personTypeName)); renderer.render(person, RootPanel.getBodyElement()); ((Entity) person).addValueChangeHandler(new ValueChangeHandler<I_Entity>() { public void onValueChange(ValueChangeEvent<I_Entity> event) { RootPanel.get().getElement().getStyle().setBackgroundColor("#77f3f3"); RootPanel.get().add(new Label(event.getValue().toJSON())); } }); }
From source file:com.alkacon.opencms.v8.calendar.client.input.CmsSerialDate.java
License:Open Source License
/** * Private function to set all the end selections.<p> * *//* www. j a v a 2 s . com*/ private void setLowPanel() { FlexTable table = new FlexTable(); table.insertRow(0); FlowPanel cell1 = new FlowPanel(); Label startDate = new Label(m_labels.get("GUI_SERIALDATE_TIME_STARTDATE_0").isString().stringValue()); startDate.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDateLable()); cell1.add(startDate); cell1.getElement().getStyle().setWidth(100, Unit.PCT); cell1.add(m_dateboxbegin); m_dateboxbegin.setDateOnly(true); m_dateboxbegin.getElement().getStyle().setWidth(108, Unit.PX); m_dateboxbegin.getElement().getStyle().setFloat(Float.RIGHT); m_dateboxbegin.addValueChangeHandler(new ValueChangeHandler<Date>() { public void onValueChange(ValueChangeEvent<Date> event) { fireValueChange(); } }); table.setWidget(0, 0, cell1); table.getCellFormatter().getElement(0, 0).getStyle().setWidth(185, Unit.PX); table.getCellFormatter().getElement(0, 0).getStyle().setVerticalAlign(VerticalAlign.TOP); FlowPanel cell2 = new FlowPanel(); CmsRadioButton sel1 = new CmsRadioButton("1", m_labels.get("GUI_SERIALDATE_DURATION_ENDTYPE_NEVER_0").isString().stringValue()); m_lowRadioButton[0] = sel1; sel1.setGroup(m_groupDuration); sel1.setChecked(true); sel1.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDatelowPanelSelection()); sel1.addStyleName( org.opencms.ade.contenteditor.client.css.I_CmsLayoutBundle.INSTANCE.widgetCss().radioButtonlabel()); sel1.getElement().getStyle().setMarginLeft(13, Unit.PX); sel1.getElement().getStyle().setMarginTop(0, Unit.PX); sel1.addClickHandler(new ClickHandler() { public void onClick(ClickEvent event) { fireValueChange(); } }); CmsRadioButton sel2 = new CmsRadioButton("2", m_labels.get("GUI_SERIALDATE_DURATION_ENDTYPE_OCC_0").isString().stringValue()); m_lowRadioButton[1] = sel2; sel2.setGroup(m_groupDuration); sel2.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDatelowPanelSelection()); sel2.addStyleName( org.opencms.ade.contenteditor.client.css.I_CmsLayoutBundle.INSTANCE.widgetCss().radioButtonlabel()); sel2.getElement().setAttribute("style", "clear:left"); sel2.getElement().getStyle().setMarginLeft(13, Unit.PX); sel2.getElement().getStyle().setMarginTop(6, Unit.PX); sel2.addClickHandler(new ClickHandler() { public void onClick(ClickEvent event) { if (m_times.getText().isEmpty()) { m_times.setValue("1"); } fireValueChange(); } }); CmsRadioButton sel3 = new CmsRadioButton("3", m_labels.get("GUI_SERIALDATE_DURATION_ENDTYPE_DATE_0").isString().stringValue()); m_lowRadioButton[2] = sel3; sel3.setGroup(m_groupDuration); sel3.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDatelowPanelSelection()); sel3.addStyleName( org.opencms.ade.contenteditor.client.css.I_CmsLayoutBundle.INSTANCE.widgetCss().radioButtonlabel()); sel3.getElement().setAttribute("style", "clear:left"); sel3.getElement().getStyle().setMarginLeft(13, Unit.PX); sel3.getElement().getStyle().setMarginTop(6, Unit.PX); sel3.addClickHandler(new ClickHandler() { public void onClick(ClickEvent event) { m_dateboxend.setValue(new Date()); fireValueChange(); } }); cell2.add(sel1); cell2.add(sel2); m_times.setStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().textBoxSerialDate()); m_times.getElement().getStyle().setMarginTop(5, Unit.PX); m_times.getElement().getStyle().setWidth(82, Unit.PX); cell2.add(m_times); m_times.addKeyPressHandler(new KeyPressHandler() { public void onKeyPress(KeyPressEvent event) { fireValueChange(); } }); m_times.addValueChangeHandler(new ValueChangeHandler<String>() { public void onValueChange(ValueChangeEvent<String> event) { fireValueChange(); } }); m_times.addFocusHandler(new FocusHandler() { public void onFocus(FocusEvent event) { selectEnding(1); } }); Label times = new Label( m_labels.get("GUI_SERIALDATE_DURATION_ENDTYPE_OCC_TIMES_0").isString().stringValue()); times.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDateLable()); times.getElement().getStyle().setMarginTop(7, Unit.PX); times.getElement().getStyle().setMarginLeft(2, Unit.PX); cell2.add(times); cell2.add(sel3); cell2.add(m_dateboxend); m_dateboxend.setDateOnly(true); m_dateboxend.getElement().getStyle().setWidth(90, Unit.PX); m_dateboxend.getElement().getStyle().setMarginTop(5, Unit.PX); m_dateboxend.getElement().getStyle().setMarginLeft(22, Unit.PX); m_dateboxend.addValueChangeHandler(new ValueChangeHandler<Date>() { public void onValueChange(ValueChangeEvent<Date> event) { fireValueChange(); } }); m_dateboxend.addDomHandler(new ClickHandler() { public void onClick(ClickEvent event) { selectEnding(2); } }, ClickEvent.getType()); table.setWidget(0, 1, cell2); m_lowPanel.add(table); m_lowPanel.setStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDatelowPanel()); }
From source file:com.alkacon.opencms.v8.calendar.client.input.CmsSerialDate.java
License:Open Source License
/** * Private function to set all the time selections.<p> * */// ww w .j a v a2 s . c o m private void setTopPanel() { Label l_start = new Label(m_labels.get("GUI_SERIALDATE_TIME_STARTTIME_0").isString().stringValue()); l_start.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDateLable()); l_start.getElement().getStyle().setFloat(Float.LEFT); m_startDate.setStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().textBoxSerialDate()); m_startDate.getElement().getStyle().setWidth(110, Unit.PX); m_startDate.getElement().getStyle().setMarginRight(1, Unit.PX); m_startDate.getElement().getStyle().setFloat(Float.RIGHT); m_startDate.addKeyPressHandler(new KeyPressHandler() { public void onKeyPress(KeyPressEvent event) { fireValueChange(); } }); Label l_end = new Label(m_labels.get("GUI_SERIALDATE_TIME_ENDTIME_0").isString().stringValue()); l_end.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDateLable()); l_end.getElement().getStyle().clearLeft(); l_end.getElement().getStyle().setFloat(Float.LEFT); l_end.getElement().getStyle().setMarginTop(8, Unit.PX); m_endDate.setStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().textBoxSerialDate()); m_endDate.getElement().getStyle().setWidth(110, Unit.PX); m_endDate.getElement().getStyle().setMarginRight(1, Unit.PX); m_endDate.getElement().getStyle().setMarginTop(5, Unit.PX); m_endDate.getElement().getStyle().setFloat(Float.RIGHT); m_endDate.addKeyPressHandler(new KeyPressHandler() { public void onKeyPress(KeyPressEvent event) { fireValueChange(); } }); m_duration = new CmsSelectBox(); m_duration.getElement().getStyle().setMarginTop(5, Unit.PX); m_duration.getElement().getStyle().setFloat(Float.RIGHT); m_duration.getElement().getStyle().setMarginRight(1, Unit.PX); m_duration.getElement().getStyle().setMarginBottom(3, Unit.PX); m_duration.getOpener().setWidth("118px"); m_duration.getOpener().setStyleName(org.opencms.ade.contenteditor.client.css.I_CmsLayoutBundle.INSTANCE .widgetCss().selectBoxSelected()); m_duration.getSelectorPopup().addStyleName(I_CmsLayoutBundle.INSTANCE.globalWidgetCss().selectBoxPopup()); m_duration.addValueChangeHandler(new ValueChangeHandler<String>() { public void onValueChange(ValueChangeEvent<String> event) { fireValueChange(); } }); m_duration.addOption("0", m_labels.get("GUI_SERIALDATE_DURATION_DURATION_SAMEDAY_0").isString().stringValue()); m_duration.addOption("1", m_labels.get("GUI_SERIALDATE_DURATION_DURATION_FIRST_0").isString().stringValue()); m_duration.addOption("2", m_labels.get("GUI_SERIALDATE_DURATION_DURATION_SECOND_0").isString().stringValue()); m_duration.addOption("3", m_labels.get("GUI_SERIALDATE_DURATION_DURATION_THIRD_0").isString().stringValue()); m_duration.addOption("4", m_labels.get("GUI_SERIALDATE_DURATION_DURATION_FOURTH_0").isString().stringValue()); m_duration.addOption("5", m_labels.get("GUI_SERIALDATE_DURATION_DURATION_FIFTH_0").isString().stringValue()); m_duration.addOption("6", m_labels.get("GUI_SERIALDATE_DURATION_DURATION_SIXTH_0").isString().stringValue()); m_duration.addOption("7", m_labels.get("GUI_SERIALDATE_DURATION_DURATION_ONEWEEK_0").isString().stringValue()); m_duration.addOption("8", m_labels.get("GUI_SERIALDATE_DURATION_DURATION_TWOWEEK_0").isString().stringValue()); m_topPanel.add(l_start); m_topPanel.add(m_startDate); m_topPanel.add(l_end); m_topPanel.add(m_endDate); m_topPanel.add(m_duration); }
From source file:com.alkacon.opencms.v8.calendar.client.input.serialdate.CmsPatternPanelDaily.java
License:Open Source License
/** * Creates the 'every' selection view.<p> * /* w ww. j a v a 2 s . c om*/ * */ private void createEverPanel() { m_everyPanel.add(m_everyDay); m_everyDay.setStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().textBoxSerialDate()); m_everyDay.setText("1"); m_everyDay.getElement().getStyle().setWidth(25, Unit.PX); m_everyDay.addKeyPressHandler(new KeyPressHandler() { public void onKeyPress(KeyPressEvent event) { fireValueChange(); } }); Label days = new Label(m_labels.get("GUI_SERIALDATE_DAILY_DAYS_0").isString().stringValue()); days.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDateLable()); m_everyPanel.add(days); }
From source file:com.alkacon.opencms.v8.calendar.client.input.serialdate.CmsPatternPanelMonthly.java
License:Open Source License
/** * Creates the 'at' selection view.<p> * *///from w ww .j a va2 s. c o m private void createAtPanel() { m_atPanel.add(m_atNummer); m_atNummer.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().selectBoxPanel()); m_atNummer.getOpener().setStyleName(org.opencms.ade.contenteditor.client.css.I_CmsLayoutBundle.INSTANCE .widgetCss().selectBoxSelected()); m_atNummer.getSelectorPopup().addStyleName(I_CmsLayoutBundle.INSTANCE.globalWidgetCss().selectBoxPopup()); m_atNummer.addOption("1", m_labels.get("GUI_SERIALDATE_WEEKDAYNUMBER_1_0").isString().stringValue()); m_atNummer.addOption("2", m_labels.get("GUI_SERIALDATE_WEEKDAYNUMBER_2_0").isString().stringValue()); m_atNummer.addOption("3", m_labels.get("GUI_SERIALDATE_WEEKDAYNUMBER_3_0").isString().stringValue()); m_atNummer.addOption("4", m_labels.get("GUI_SERIALDATE_WEEKDAYNUMBER_4_0").isString().stringValue()); m_atNummer.addOption("5", m_labels.get("GUI_SERIALDATE_WEEKDAYNUMBER_5_0").isString().stringValue()); m_atNummer.setWidth("80px"); m_atPanel.add(m_atDay); m_atDay.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().selectBoxPanel()); m_atDay.getOpener().setStyleName(org.opencms.ade.contenteditor.client.css.I_CmsLayoutBundle.INSTANCE .widgetCss().selectBoxSelected()); m_atDay.getSelectorPopup().addStyleName(I_CmsLayoutBundle.INSTANCE.globalWidgetCss().selectBoxPopup()); m_atDay.addOption("1", m_labels.get("GUI_SERIALDATE_DAY_SUNDAY_0").isString().stringValue()); m_atDay.addOption("2", m_labels.get("GUI_SERIALDATE_DAY_MONDAY_0").isString().stringValue()); m_atDay.addOption("3", m_labels.get("GUI_SERIALDATE_DAY_TUESDAY_0").isString().stringValue()); m_atDay.addOption("4", m_labels.get("GUI_SERIALDATE_DAY_WEDNESDAY_0").isString().stringValue()); m_atDay.addOption("5", m_labels.get("GUI_SERIALDATE_DAY_THURSDAY_0").isString().stringValue()); m_atDay.addOption("6", m_labels.get("GUI_SERIALDATE_DAY_FRIDAY_0").isString().stringValue()); m_atDay.addOption("7", m_labels.get("GUI_SERIALDATE_DAY_SATURDAY_0").isString().stringValue()); m_atDay.setWidth("100px"); Label every = new Label(m_labels.get("GUI_SERIALDATE_MONTHLY_WEEKDAY_EVERY_0").isString().stringValue()); every.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDateLable()); m_atPanel.add(every); m_atPanel.add(m_atMonth); m_atMonth.setStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().textBoxSerialDate()); m_atMonth.addKeyPressHandler(new KeyPressHandler() { public void onKeyPress(KeyPressEvent event) { fireValueChange(); } }); Label month = new Label(m_labels.get("GUI_SERIALDATE_MONTHLY_MONTH_0").isString().stringValue()); month.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDateLable()); m_atPanel.add(month); }
From source file:com.alkacon.opencms.v8.calendar.client.input.serialdate.CmsPatternPanelMonthly.java
License:Open Source License
/** * Creates the 'every' selection view.<p> * //from w w w . ja v a2 s . c om * */ private void createEverPanel() { m_everyPanel.add(m_everyDay); m_everyDay.setStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().textBoxSerialDate()); m_everyDay.setText("1"); m_everyDay.addKeyPressHandler(new KeyPressHandler() { public void onKeyPress(KeyPressEvent event) { fireValueChange(); } }); Label day = new Label(m_labels.get("GUI_SERIALDATE_MONTHLY_MONTHDAY_DAY_EVERY_0").isString().stringValue()); day.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDateLable()); m_everyPanel.add(day); m_everyPanel.add(m_everyMonth); m_everyMonth.setText("1"); m_everyMonth.setStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().textBoxSerialDate()); m_everyMonth.addKeyPressHandler(new KeyPressHandler() { public void onKeyPress(KeyPressEvent event) { fireValueChange(); } }); Label month = new Label(m_labels.get("GUI_SERIALDATE_MONTHLY_MONTH_0").isString().stringValue()); month.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().serialDateLable()); m_everyPanel.add(month); }
From source file:com.alkacon.opencms.v8.calendar.client.input.serialdate.CmsPatternPanelWeekly.java
License:Open Source License
/** * Creates the 'every' selection view.<p> * //from ww w . j a v a 2 s . c o m * */ private void createEverPanel() { m_everyPanel.add(new Label(m_labels.get("GUI_SERIALDATE_WEEKLY_EVERY_0").isString().stringValue())); m_everyPanel.add(m_everyDay); m_everyDay.setStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().textBoxSerialDate()); m_everyDay.setText("1"); m_everyDay.addKeyPressHandler(new KeyPressHandler() { public void onKeyPress(KeyPressEvent event) { fireValueChange(); } }); m_everyPanel.add(new Label(m_labels.get("GUI_SERIALDATE_WEEKLY_WEEK_AT_0").isString().stringValue())); }
From source file:com.alkacon.opencms.v8.calendar.client.input.serialdate.CmsPatternPanelYearly.java
License:Open Source License
/** * Creates the 'at' selection view.<p> * *//*from w w w. j a v a 2 s . c o m*/ private void createAtPanel() { m_atPanel.add(m_atNummer); m_atNummer.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().selectBoxPanel()); m_atNummer.getOpener().setStyleName(org.opencms.ade.contenteditor.client.css.I_CmsLayoutBundle.INSTANCE .widgetCss().selectBoxSelected()); m_atNummer.getSelectorPopup().addStyleName(I_CmsLayoutBundle.INSTANCE.globalWidgetCss().selectBoxPopup()); m_atNummer.setWidth("80px"); m_atNummer.addOption("1", m_labels.get("GUI_SERIALDATE_WEEKDAYNUMBER_1_0").isString().stringValue()); m_atNummer.addOption("2", m_labels.get("GUI_SERIALDATE_WEEKDAYNUMBER_2_0").isString().stringValue()); m_atNummer.addOption("3", m_labels.get("GUI_SERIALDATE_WEEKDAYNUMBER_3_0").isString().stringValue()); m_atNummer.addOption("4", m_labels.get("GUI_SERIALDATE_WEEKDAYNUMBER_4_0").isString().stringValue()); m_atNummer.addOption("5", m_labels.get("GUI_SERIALDATE_WEEKDAYNUMBER_5_0").isString().stringValue()); m_atPanel.add(m_atDay); m_atDay.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().selectBoxPanel()); m_atDay.getOpener().setStyleName(org.opencms.ade.contenteditor.client.css.I_CmsLayoutBundle.INSTANCE .widgetCss().selectBoxSelected()); m_atDay.getSelectorPopup().addStyleName(I_CmsLayoutBundle.INSTANCE.globalWidgetCss().selectBoxPopup()); m_atDay.setWidth("100px"); m_atDay.addOption("1", m_labels.get("GUI_SERIALDATE_DAY_SUNDAY_0").isString().stringValue()); m_atDay.addOption("2", m_labels.get("GUI_SERIALDATE_DAY_MONDAY_0").isString().stringValue()); m_atDay.addOption("3", m_labels.get("GUI_SERIALDATE_DAY_TUESDAY_0").isString().stringValue()); m_atDay.addOption("4", m_labels.get("GUI_SERIALDATE_DAY_WEDNESDAY_0").isString().stringValue()); m_atDay.addOption("5", m_labels.get("GUI_SERIALDATE_DAY_THURSDAY_0").isString().stringValue()); m_atDay.addOption("6", m_labels.get("GUI_SERIALDATE_DAY_FRIDAY_0").isString().stringValue()); m_atDay.addOption("7", m_labels.get("GUI_SERIALDATE_DAY_SATURDAY_0").isString().stringValue()); m_atPanel.add(new Label(m_labels.get("GUI_SERIALDATE_YEARLY_IN_0").isString().stringValue())); m_atPanel.add(m_atMonth); m_atMonth.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().selectBoxPanel()); m_atMonth.getOpener().setStyleName(org.opencms.ade.contenteditor.client.css.I_CmsLayoutBundle.INSTANCE .widgetCss().selectBoxSelected()); m_everyMonth.getSelectorPopup().addStyleName(I_CmsLayoutBundle.INSTANCE.globalWidgetCss().selectBoxPopup()); m_atMonth.setWidth("100px"); m_atMonth.addOption("0", m_labels.get("GUI_SERIALDATE_YEARLY_JAN_0").isString().stringValue()); m_atMonth.addOption("1", m_labels.get("GUI_SERIALDATE_YEARLY_FEB_0").isString().stringValue()); m_atMonth.addOption("2", m_labels.get("GUI_SERIALDATE_YEARLY_MAR_0").isString().stringValue()); m_atMonth.addOption("3", m_labels.get("GUI_SERIALDATE_YEARLY_APR_0").isString().stringValue()); m_atMonth.addOption("4", m_labels.get("GUI_SERIALDATE_YEARLY_MAY_0").isString().stringValue()); m_atMonth.addOption("5", m_labels.get("GUI_SERIALDATE_YEARLY_JUN_0").isString().stringValue()); m_atMonth.addOption("6", m_labels.get("GUI_SERIALDATE_YEARLY_JUL_0").isString().stringValue()); m_atMonth.addOption("7", m_labels.get("GUI_SERIALDATE_YEARLY_AUG_0").isString().stringValue()); m_atMonth.addOption("8", m_labels.get("GUI_SERIALDATE_YEARLY_SEP_0").isString().stringValue()); m_atMonth.addOption("9", m_labels.get("GUI_SERIALDATE_YEARLY_OCT_0").isString().stringValue()); m_atMonth.addOption("10", m_labels.get("GUI_SERIALDATE_YEARLY_NOV_0").isString().stringValue()); m_atMonth.addOption("11", m_labels.get("GUI_SERIALDATE_YEARLY_DEC_0").isString().stringValue()); }
From source file:com.alkacon.opencms.v8.calendar.client.input.serialdate.CmsPatternPanelYearly.java
License:Open Source License
/** * Creates the 'every' selection view.<p> * //from w ww . j a v a 2 s . c om * */ private void createEverPanel() { m_everyPanel.add(m_everyDay); m_everyDay.setStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().textBoxSerialDate()); m_everyDay.setText("1"); m_everyDay.addKeyPressHandler(new KeyPressHandler() { public void onKeyPress(KeyPressEvent event) { fireValueChange(); } }); m_everyPanel.add(new Label("")); m_everyPanel.add(m_everyMonth); m_everyMonth.addStyleName(I_CmsLayoutBundle.INSTANCE.widgetCss().selectBoxPanel()); m_everyMonth.getOpener().setStyleName(org.opencms.ade.contenteditor.client.css.I_CmsLayoutBundle.INSTANCE .widgetCss().selectBoxSelected()); m_everyMonth.getSelectorPopup().addStyleName(I_CmsLayoutBundle.INSTANCE.globalWidgetCss().selectBoxPopup()); m_everyMonth.setWidth("100px"); m_everyMonth.addOption("0", m_labels.get("GUI_SERIALDATE_YEARLY_JAN_0").isString().stringValue()); m_everyMonth.addOption("1", m_labels.get("GUI_SERIALDATE_YEARLY_FEB_0").isString().stringValue()); m_everyMonth.addOption("2", m_labels.get("GUI_SERIALDATE_YEARLY_MAR_0").isString().stringValue()); m_everyMonth.addOption("3", m_labels.get("GUI_SERIALDATE_YEARLY_APR_0").isString().stringValue()); m_everyMonth.addOption("4", m_labels.get("GUI_SERIALDATE_YEARLY_MAY_0").isString().stringValue()); m_everyMonth.addOption("5", m_labels.get("GUI_SERIALDATE_YEARLY_JUN_0").isString().stringValue()); m_everyMonth.addOption("6", m_labels.get("GUI_SERIALDATE_YEARLY_JUL_0").isString().stringValue()); m_everyMonth.addOption("7", m_labels.get("GUI_SERIALDATE_YEARLY_AUG_0").isString().stringValue()); m_everyMonth.addOption("8", m_labels.get("GUI_SERIALDATE_YEARLY_SEP_0").isString().stringValue()); m_everyMonth.addOption("9", m_labels.get("GUI_SERIALDATE_YEARLY_OCT_0").isString().stringValue()); m_everyMonth.addOption("10", m_labels.get("GUI_SERIALDATE_YEARLY_NOV_0").isString().stringValue()); m_everyMonth.addOption("11", m_labels.get("GUI_SERIALDATE_YEARLY_DEC_0").isString().stringValue()); }