Package com.volantis.mcs.protocols.widgets.attributes

Examples of com.volantis.mcs.protocols.widgets.attributes.DetailAttributes


*/
public class DetailElement extends WidgetElement {

    public DetailElement(XDIMEContextInternal context) {
        super(WidgetElements.DETAIL, context);
        protocolAttributes = new DetailAttributes();
    }
View Full Code Here


   
    // Javadoc inherited
    protected void initialiseElementSpecificAttributes(
            XDIMEContextInternal context, XDIMEAttributes attributes)
            throws XDIMEException {
        DetailAttributes detailAttributes = (DetailAttributes) protocolAttributes;

        XDIMEElementInternal parent = context.getCurrentElement().getParent();
       
        if (parent != null && parent.getElementType() == GalleryElements.ITEM) {
            detailAttributes.setInsideGalleryItem(true);
        }
    }
View Full Code Here

    // Javadoc inherited
    public void doRenderOpen(VolantisProtocol protocol,
        MCSAttributes attributes) throws ProtocolException {

        // Handle the widget:detail element enclosed within the gallery:item element.
        DetailAttributes detailAttributes = (DetailAttributes) attributes;
       
        if (detailAttributes.isInsideGalleryItem()) {
            renderOpenForGalleryItem(protocol, attributes);
           
            return;
        }
       
View Full Code Here

    // Javadoc inherited   
    public void doRenderClose(VolantisProtocol protocol,
        MCSAttributes attributes) throws ProtocolException {
             
        // Handle the widget:detail element enclosed within the gallery:item element.
        DetailAttributes detailAttributes = (DetailAttributes) attributes;
       
        if (detailAttributes.isInsideGalleryItem()) {
            renderCloseForGalleryItem(protocol, attributes);
           
            return;
        }
       
View Full Code Here

      closeDivElement(currentBuffer);
      closeDivElement(currentBuffer);
    }

    public boolean shouldRenderContents(VolantisProtocol protocol, MCSAttributes attributes) throws ProtocolException {
        DetailAttributes detailAttributes = (DetailAttributes) attributes;

        if (detailAttributes.isInsideGalleryItem()) {
            // The strategy for ItemGallery is not to render contents on fallback
            return isWidgetSupported(protocol);
        } else {
            // in other cases use the default strategy           
            return super.shouldRenderContents(protocol, attributes);
View Full Code Here

            (GalleryDefaultModule) protocol.getGalleryModule();
        ItemDefaultRenderer itemRenderer =
            (ItemDefaultRenderer) galleryModule.getElementRenderer(ItemAttributes.class);
        itemRenderer.setDetailSlideId(slideId);
       
        DetailAttributes detailAttributes = (DetailAttributes) attributes;
       
        StringBuffer buffer = new StringBuffer();

        StylesExtractor detailStylesExtractor =
            createStylesExtractor(protocol, detailAttributes.getStyles());
       
        double detailDuration = detailStylesExtractor.getDuration();

        buffer.append("Widget.register(")
            .append(createJavaScriptString(slideId))
View Full Code Here

TOP

Related Classes of com.volantis.mcs.protocols.widgets.attributes.DetailAttributes

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.