Examples of CanvasAttributes


Examples of com.volantis.mcs.papi.CanvasAttributes

        // If its a Canvas then param[1] will be the page title,
        // param[2] the theme file name
        // param[3] the layout file name and
        // param[4] the type.
        if (attributes instanceof CanvasAttributes && params.length >= 5) {
            CanvasAttributes ca = (CanvasAttributes)attributes;
            ca.setPageTitle(params[1]);
            ca.setTheme(params[2]);
            ca.setLayoutName(params[3]);

            if (params[4] != null) {
                ca.setType(params[4]);
            }
        }

        // If we are opening a Region param[1] will be the name
        if (attributes instanceof RegionAttributes && params.length >= 2) {
View Full Code Here

Examples of com.volantis.mcs.protocols.CanvasAttributes

    {
        privateSetUp();
        pageContext.pushOutputBuffer(buffer);
        setUpDeviceLayoutContext();

        CanvasAttributes attributes = new CanvasAttributes();
        attributes.setStyles(StylesBuilder.getInitialValueStyles());
        protocol.openCard(buffer, attributes);

        // Output buffer on stack should now be buffer
        assertEquals("wrong output buffer at top of stack",
                            buffer, pageContext.getCurrentOutputBuffer());
View Full Code Here

Examples of com.volantis.mcs.protocols.CanvasAttributes

    {
        privateSetUp();
        pageContext.pushOutputBuffer(buffer);
        setUpDeviceLayoutContext();

        CanvasAttributes attributes = new CanvasAttributes();
        attributes.setStyles(StylesBuilder.getInitialValueStyles());

        protocol.openCard(buffer, attributes);
        protocol.closeCard(buffer, attributes);

        document.addNode(buffer.getRoot());
View Full Code Here

Examples of com.volantis.mcs.protocols.CanvasAttributes

            private CanvasAttributes myCanvasAttributes = null;

            // javadoc inherited from superclass
            public CanvasAttributes getCanvasAttributes() {
                if (myCanvasAttributes == null) {
                    myCanvasAttributes = new CanvasAttributes();
                    myCanvasAttributes.setStyles(StylesBuilder.getDeprecatedStyles());
                    myCanvasAttributes.setInitialFocus("ID");
                }
                return myCanvasAttributes;
            }
View Full Code Here

Examples of com.volantis.mcs.protocols.CanvasAttributes

            private CanvasAttributes myCanvasAttributes = null;

            // javadoc inherited from superclass
            public CanvasAttributes getCanvasAttributes() {
                if (myCanvasAttributes == null) {
                    myCanvasAttributes = new CanvasAttributes();
                    myCanvasAttributes.setStyles(StylesBuilder.getDeprecatedStyles());
                    myCanvasAttributes.setInitialFocus("ID");
                }
                return myCanvasAttributes;
            }
View Full Code Here

Examples of com.volantis.mcs.protocols.CanvasAttributes

    public void testCanvas() throws LayoutException, ProtocolException {
        privateSetUp();

        context.setDeviceLayout(createDeviceLayout(false));
        protocol.setMarinerPageContext(context);
        CanvasAttributes attrib = new CanvasAttributes();
        attrib.setPageTitle("PageTitle");
        protocol.openCanvas(buffer, attrib);
        protocol.closeCanvas(buffer,attrib);
        String compare = "<smil><head><meta content=\"PageTitle\" name=\"title\"/>" +
        "<layout><root-layout/><region height=\"165\" id=\"Text\" " +
        "left=\"0\" top=\"0\" width=\"120\"/><region height=\"165\" " +
View Full Code Here

Examples of com.volantis.mcs.protocols.CanvasAttributes

        context.setDeviceLayout(createDeviceLayout(false));
        protocol.setMarinerPageContext(context);
        BodyAttributes body = new BodyAttributes();
        DOMOutputBuffer scratch = new DOMOutputBuffer();
        scratch.initialise();
        CanvasAttributes attrib = new CanvasAttributes();
        protocol.openCanvas(scratch,attrib);
        protocol.openBody(buffer, body);
        protocol.closeBody(buffer, body);
        String compare = "<body><par/></body>";
        assertTrue("Markup is incorrect: "+getMarkup(buffer),
View Full Code Here

Examples of com.volantis.mcs.protocols.CanvasAttributes

        context.setDeviceLayout(createDeviceLayout(true));
        protocol.setMarinerPageContext(context);
        DOMOutputBuffer scratch = new DOMOutputBuffer();
        scratch.initialise();
        CanvasAttributes attrib = new CanvasAttributes();
        protocol.openCanvas(scratch,attrib);
        BodyAttributes body = new BodyAttributes();
        protocol.openBody(buffer, body);
        protocol.closeBody(buffer, body);
        String compare = "<body/>";
View Full Code Here

Examples of com.volantis.mcs.protocols.CanvasAttributes

        referenceResolverMock.expects.resolveQuotedScriptExpression(ON_UNLOAD)
            .returns(new LiteralScriptAssetReference(ON_UNLOAD)).any();

        papiAttributes.setOnLoad(ON_LOAD);
        papiAttributes.setOnUnload(ON_UNLOAD);
        CanvasAttributes attributes = new CanvasAttributes();

        EventAttributes events = attributes.getEventAttributes(false);
        ScriptAssetReference event = events.getEvent(EventConstants.ON_LOAD);
        assertNull(event);
        PAPIInternals.initialisePageEventAttributes(pageContext,
                                                    papiAttributes,
                                                    attributes);
View Full Code Here

Examples of com.volantis.mcs.protocols.CanvasAttributes

            .returns(new LiteralScriptAssetReference(ON_RESET)).any();

        papiAttributes.setOnSubmit(ON_SUBMIT);
        papiAttributes.setOnReset(ON_RESET);

        CanvasAttributes attributes = new CanvasAttributes();

        EventAttributes events = attributes.getEventAttributes(false);
        ScriptAssetReference event = events.getEvent(EventConstants.ON_LOAD);
        assertNull(event);
        PAPIInternals.initialiseFormEventAttributes(pageContext,
                                                    papiAttributes,
                                                    attributes);
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.