Package com.volantis.mcs.css.version

Examples of com.volantis.mcs.css.version.CSSProperty


            boolean supportsDisplayKeyword;
            final CSSVersion cssVersion = getCssVersion();
            if (cssVersion == null) {
                supportsDisplayKeyword = false;
            } else {
                CSSProperty display = cssVersion.getProperty(
                        StylePropertyDetails.DISPLAY);
                // In for the marquee css properties to have an effect, the
                // display must be set to marquee. If this keyword isn't
                // supported, then all marquee properties must be emulated.
                supportsDisplayKeyword = display.supportsKeyword(
                        DisplayKeywords.MCS_MARQUEE);
            }

            // The value of mcs-marquee-style determines if the other marquee
            // styles apply. So, if the mcs-marquee-style property css isn't
View Full Code Here


        // Tell log4j to log everything for your test packages.
        category.setLevel(Level.ALL);

        final String ssversion = DevicePolicyConstants.CSS_MOBILE_PROFILE1;
        DefaultDevice device = createDevice("Master", ssversion, null);
        CSSProperty cssProperty;

        // Test the default setup for CSSWAP.
        cssConfigurator.initialise(config,
            INTERNAL_DEVICE_FACTORY.createInternalDevice(device));
        cssProperty = config.getCssVersion().getProperty(
                StylePropertyDetails.VERTICAL_ALIGN);

        // It should not have top or bottom.
        assertFalse(cssProperty.supportsKeyword(VerticalAlignKeywords.TOP));
        assertFalse(cssProperty.supportsKeyword(VerticalAlignKeywords.BOTTOM));
        // It should have super and sub.
        assertTrue(cssProperty.supportsKeyword(VerticalAlignKeywords.SUPER));
        assertTrue(cssProperty.supportsKeyword(VerticalAlignKeywords.SUB));

        final Map policies = new HashMap();
        policies.put("ssversion", ssversion);
        // Add top and bottom.
        policies.put(
            "x-css.properties.vertical-align.keyword.top.support", "full");
        policies.put(
            "x-css.properties.vertical-align.keyword.bottom.support", "full");
        // Remove super and sub.
        policies.put(
            "x-css.properties.vertical-align.keyword.super.support", "none");
        policies.put(
            "x-css.properties.vertical-align.keyword.sub.support", "none");
        device = createDevice("Master", policies, null);

        cssConfigurator.initialise(config,
            INTERNAL_DEVICE_FACTORY.createInternalDevice(device));
        cssProperty = config.getCssVersion().getProperty(
                StylePropertyDetails.VERTICAL_ALIGN);
        // It should have top and bottom.
        assertTrue(cssProperty.supportsKeyword(VerticalAlignKeywords.TOP));
        assertTrue(cssProperty.supportsKeyword(VerticalAlignKeywords.BOTTOM));
        // It should not have super or sub.
        assertFalse(cssProperty.supportsKeyword(VerticalAlignKeywords.SUPER));
        assertFalse(cssProperty.supportsKeyword(VerticalAlignKeywords.SUB));
    }
View Full Code Here

TOP

Related Classes of com.volantis.mcs.css.version.CSSProperty

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.