Examples of FormInfo


Examples of org.apache.myfaces.shared_tomahawk.renderkit.html.util.FormInfo

        HtmlRendererUtils.writePrettyLineSeparator(facesContext);

        int selectedIndex = tabbedPane.getSelectedIndex();

        FormInfo parentFormInfo = RendererUtils.findNestingForm(tabbedPane, facesContext);
        if (parentFormInfo == null)
        {
            writeFormStart(writer, facesContext, tabbedPane);
        }
View Full Code Here

Examples of org.apache.myfaces.shared_tomahawk.renderkit.html.util.FormInfo

                .replaceAll("<.+?>", "");
    }

    private void encodeEndNormalMode(FacesContext context, InputHtml editor) throws IOException {
        String clientId = editor.getClientId(context);
        FormInfo parentFormInfo = RendererUtils.findNestingForm(editor, context);
        if(parentFormInfo == null)
            throw new FacesException("InputHtml must be embedded in a form.");
        String formId = parentFormInfo.getFormName();

        AddResource addResource = AddResourceFactory.getInstance(context);
        addResource.addStyleSheet(context, AddResource.HEADER_BEGIN, InputHtmlRenderer.class, "kupustyles.css");
        addResource.addStyleSheet(context, AddResource.HEADER_BEGIN, InputHtmlRenderer.class, "kupudrawerstyles.css");
        addResource.addStyleSheet(context, AddResource.HEADER_BEGIN, InputHtmlRenderer.class, "myFaces.css");
View Full Code Here

Examples of org.apache.myfaces.shared_tomahawk.renderkit.html.util.FormInfo

    }


    protected StringBuffer buildOnClick(UIComponent uiComponent, FacesContext facesContext, ResponseWriter writer)
        throws IOException {
        FormInfo formInfo = findNestingForm(uiComponent, facesContext);
        if (formInfo == null) {
            throw new IllegalArgumentException("Component " + uiComponent.getClientId(facesContext) + " must be embedded in an form");
        }
        String formName = formInfo.getFormName();
        UIComponent nestingForm = formInfo.getForm();

        StringBuffer onClick = new StringBuffer();
        String commandOnClick = (String) uiComponent.getAttributes().get(HTML.ONCLICK_ATTR);

        if (commandOnClick != null) {
View Full Code Here

Examples of org.apache.myfaces.shared_tomahawk.renderkit.html.util.FormInfo

        }

        HtmlSchedule schedule = (HtmlSchedule) component;
        ResponseWriter writer = context.getResponseWriter();
        String clientId = schedule.getClientId(context);
        FormInfo parentFormInfo = RendererUtils.findNestingForm(schedule, context);
        String formId = parentFormInfo == null ? null : parentFormInfo.getFormName();

        for (Iterator dayIterator = schedule.getModel().iterator(); dayIterator
                .hasNext();)
        {
            ScheduleDay day = (ScheduleDay) dayIterator.next();
View Full Code Here

Examples of org.apache.myfaces.shared_tomahawk.renderkit.html.util.FormInfo

        writer.endElement(HTML.FORM_ELEM);
    }

    public static FormInfo findNestingForm(UIComponent uiComponent, FacesContext facesContext) {
        FormInfo formInfo = RendererUtils.findNestingForm(uiComponent, facesContext);
        if (formInfo != null) {
            return formInfo;
        }

        DummyFormUtils.setWriteDummyForm(facesContext, true);
        return new FormInfo(null, DUMMY_FORM_NAME);
    }
View Full Code Here

Examples of org.apache.myfaces.shared_tomahawk.renderkit.html.util.FormInfo

    protected void writeEntries(FacesContext context, HtmlSchedule schedule,
                              ScheduleDay day, ResponseWriter writer) throws IOException
    {
        final String clientId = schedule.getClientId(context);
        FormInfo parentFormInfo = RendererUtils.findNestingForm(schedule, context);
        String formId = parentFormInfo == null ? null : parentFormInfo.getFormName();

        TreeSet entrySet = new TreeSet();

        for (Iterator entryIterator = day.iterator(); entryIterator.hasNext();)
        {
View Full Code Here

Examples of org.apache.myfaces.shared_tomahawk.renderkit.html.util.FormInfo

                                      HtmlSchedule schedule, ResponseWriter writer) throws IOException
    {
        final int rowHeight = getRowHeight(schedule.getAttributes()) - 1;
        final int headerHeight = rowHeight + 10;
        final String clientId = schedule.getClientId(context);
        FormInfo parentFormInfo = RendererUtils.findNestingForm(schedule, context);
        String formId = parentFormInfo == null ? null : parentFormInfo.getFormName();

        writer.startElement(HTML.DIV_ELEM, schedule);
        writer.writeAttribute(HTML.CLASS_ATTR, getStyleClass(schedule,
                "foreground"), null);
        writer
View Full Code Here

Examples of org.apache.myfaces.shared_tomahawk.renderkit.html.util.FormInfo

        if (parent != null)
        {
            //link is nested inside a form
            String formName = parent.getClientId(facesContext);
            return new FormInfo(parent, formName);
        }

        return null;
    }
View Full Code Here

Examples of org.apache.myfaces.shared_tomahawk.renderkit.html.util.FormInfo

                                int dayOfWeek, int dayOfMonth, boolean isWeekend,
                                boolean isCurrentMonth, int rowspan) throws IOException
    {
        final String clientId = schedule.getClientId(context);
        final Map attributes = schedule.getAttributes();
        final FormInfo parentFormInfo = RendererUtils.findNestingForm(schedule, context);
        final String formId = parentFormInfo == null ? null : parentFormInfo.getFormName();
        final String dayHeaderId = clientId + "_header_" + ScheduleUtil.getDateId(day.getDate());
        final String dayBodyId = clientId + "_body_" + ScheduleUtil.getDateId(day.getDate());
        writer.startElement(HTML.TD_ELEM, schedule);

        writer.writeAttribute("rowspan", String.valueOf(rowspan), null);
View Full Code Here

Examples of org.apache.myfaces.shared_tomahawk.renderkit.html.util.FormInfo

     */
    protected void writeEntries(FacesContext context, HtmlSchedule schedule,
                                ScheduleDay day, ResponseWriter writer) throws IOException
    {
        final String clientId = schedule.getClientId(context);
        final FormInfo parentFormInfo = RendererUtils.findNestingForm(schedule, context);
        final String formId = parentFormInfo == null ? null : parentFormInfo.getFormName();
        final TreeSet entrySet = new TreeSet(comparator);

        for (Iterator entryIterator = day.iterator(); entryIterator.hasNext();)
        {
            ScheduleEntry entry = (ScheduleEntry) entryIterator.next();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.