Package org.apache.tapestry

Examples of org.apache.tapestry.PageRenderSupport


        IForm form = getForm();
        String name = getName();

        if (!disabled)
        {
            PageRenderSupport pageRenderSupport = TapestryUtils.getPageRenderSupport(cycle, this);

            Map symbols = new HashMap();
            symbols.put("form", form);
            symbols.put("name", name);
View Full Code Here


        String anchor = component.getAnchor();
        ILink link = component.getLink(cycle);

        String url = link.getURL(anchor, true);

        PageRenderSupport support = TapestryUtils.getPageRenderSupport(cycle, component);

        String functionName = support.getUniqueString("popup_window");

        BodyBuilder builder = new BodyBuilder();

        builder.addln("function {0}()", functionName);
        builder.begin();
        builder.addln(
                "var newWindow = window.open({0}, {1}, {2});",
                TapestryUtils.enquote(url),
                TapestryUtils.enquote(getWindowName()),
                TapestryUtils.enquote(getFeatures()));
        builder.addln("newWindow.focus();");
        builder.end();

        support.addBodyScript(component, builder.toString());

        return "javascript:" + functionName + "();";
    }
View Full Code Here

       
        // check for dynamic parameters
        if (!direct.isAsync() && !direct.isJson())
            return;
       
        PageRenderSupport prs = TapestryUtils.getPageRenderSupport(cycle, component);
       
        if (prs == null)
            return;
       
        Map parms = new HashMap();
View Full Code Here

        String name = null;

        if (_eventHandlers == null)
            return;

        PageRenderSupport pageRenderSupport = TapestryUtils.getPageRenderSupport(cycle, this);

        Iterator i = _eventHandlers.entrySet().iterator();

        while (i.hasNext())
        {
View Full Code Here

    private void initialize(IRequestCycle cycle)
    {
        String functionName = "setCheckboxGroup";

        if (!cycle.isRewinding()) {
            PageRenderSupport body = TapestryUtils.getPageRenderSupport(cycle, this);
            if (body != null)
                functionName = body.getUniqueString("setCheckboxGroup");
        }
       
        setFunctionName(functionName);
    }
View Full Code Here

        //Setup our script includes
        Map scriptParms = new HashMap();
        scriptParms.put("id", getIdParameter());
        scriptParms.put("props", obj.toString());
        PageRenderSupport pageRenderSupport = TapestryUtils.getPageRenderSupport(cycle, this);
        getScript().execute(cycle, pageRenderSupport, scriptParms);
    }
View Full Code Here

    /**
     * Executes the associated script, which generates all the JavaScript to support this Palette.
     */
    private void runScript(IRequestCycle cycle)
    {
        PageRenderSupport pageRenderSupport = TapestryUtils.getPageRenderSupport(cycle, this);

        setImage(pageRenderSupport, cycle, "selectImage", getSelectImage());
        setImage(pageRenderSupport, cycle, "selectDisabledImage", getSelectDisabledImage());
        setImage(pageRenderSupport, cycle, "deselectImage", getDeselectImage());
        setImage(pageRenderSupport, cycle, "deselectDisabledImage", getDeselectDisabledImage());
View Full Code Here

        }
       
        parms.put("props", json.toString());
        parms.put("form", getForm().getName());
       
        PageRenderSupport prs = TapestryUtils.getPageRenderSupport(cycle, this);
        getScript().execute(cycle, prs, parms);
    }
View Full Code Here

        //Setup our script includes
        Map scriptParms = new HashMap();
        scriptParms.put("id", getIdParameter());
        scriptParms.put("props", obj.toString());
        PageRenderSupport pageRenderSupport = TapestryUtils.getPageRenderSupport(cycle, this);
        getScript().execute(cycle, pageRenderSupport, scriptParms);
    }
View Full Code Here

        IScript script = _scriptSource.getScript(location);

        // If there's an error, report it against the field (this validator object doesn't
        // have a location).

        PageRenderSupport pageRenderSupport = TapestryUtils.getPageRenderSupport(cycle, field);

        script.execute(cycle, pageRenderSupport, finalSymbols);
    }
View Full Code Here

TOP

Related Classes of org.apache.tapestry.PageRenderSupport

Copyright © 2018 www.massapicom. 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.