Package com.alkacon.acacia.client.widgets

Examples of com.alkacon.acacia.client.widgets.I_EditWidget


            List<Element> elements = m_vie.getAttributeElements(parentEntity, attributeName, formParent.getElement());
            if (!elements.isEmpty()) {
                AttributeHandler handler = new AttributeHandler(m_vie, parentEntity, attributeName, m_widgetService);
                for (int i = 0; i < elements.size(); i++) {
                    Element element = elements.get(i);
                    I_EditWidget widget = m_widgetService.getAttributeInlineWidget(attributeName, element);
                    if (attribute.isSimpleValue() && (widget != null)) {
                        Element tempSpan = DOM.createSpan();
                        tempSpan.setInnerHTML(attribute.getSimpleValues().get(i));
                        String value = tempSpan.getInnerHTML().trim();
                        // verify the current value equals the element content
                        String innerHtml = element.getInnerHTML().trim();
                        if (innerHtml.equals(value)) {
                            widget.addValueChangeHandler(new WidgetChangeHandler(handler, i));
                            formParent.adoptWidget(widget);
                        } else {
                            InlineEntityWidget.createWidgetForEntity(
                                element,
                                formParent,
View Full Code Here


        if (attribute != null) {
            if (attribute.isSimpleValue()) {
                List<Element> elements = m_vie.getAttributeElements(parentEntity, attributeName, context);
                for (int i = 0; i < elements.size(); i++) {
                    Element element = elements.get(i);
                    I_EditWidget widget = m_widgetService.getAttributeInlineWidget(
                        attributeName,
                        (com.google.gwt.user.client.Element)element);
                    widget.onAttachWidget();
                    RootPanel.detachOnWindowClose(widget.asWidget());
                    widget.addValueChangeHandler(new WidgetChangeHandler(parentEntity, attributeName, i));
                }
            } else {
                for (I_Entity entity : attribute.getComplexValues()) {
                    renderInline(entity, context);
                }
View Full Code Here

                    parentEntity,
                    attributeName,
                    formParent.getElement());
                for (int i = 0; i < elements.size(); i++) {
                    Element element = elements.get(i);
                    I_EditWidget widget = m_widgetService.getAttributeInlineWidget(
                        attributeName,
                        (com.google.gwt.user.client.Element)element);
                    formParent.adoptWidget(widget);
                    widget.addValueChangeHandler(new WidgetChangeHandler(parentEntity, attributeName, i));
                }
            } else {
                for (I_Entity entity : attribute.getComplexValues()) {
                    renderInline(entity, formParent);
                }
View Full Code Here

            List<Element> elements = m_vie.getAttributeElements(parentEntity, attributeName, formParent.getElement());
            if (!elements.isEmpty()) {
                AttributeHandler handler = new AttributeHandler(m_vie, parentEntity, attributeName, m_widgetService);
                for (int i = 0; i < elements.size(); i++) {
                    Element element = elements.get(i);
                    I_EditWidget widget = m_widgetService.getAttributeInlineWidget(
                        attributeName,
                        (com.google.gwt.user.client.Element)element);
                    if (attribute.isSimpleValue() && (widget != null)) {
                        Element tempSpan = DOM.createSpan();
                        tempSpan.setInnerHTML(attribute.getSimpleValues().get(i));
                        String value = tempSpan.getInnerHTML().trim();
                        // verify the current value equals the element content
                        String innerHtml = element.getInnerHTML().trim();
                        if (innerHtml.equals(value)) {
                            widget.addValueChangeHandler(new WidgetChangeHandler(handler, i));
                            formParent.adoptWidget(widget);
                        } else {
                            InlineEntityWidget.createWidgetForEntity(
                                element,
                                formParent,
View Full Code Here

        if (attribute != null) {
            if (attribute.isSimpleValue()) {
                List<Element> elements = m_vie.getAttributeElements(parentEntity, attributeName, context);
                for (int i = 0; i < elements.size(); i++) {
                    Element element = elements.get(i);
                    I_EditWidget widget = m_widgetService.getAttributeInlineWidget(
                        attributeName,
                        (com.google.gwt.user.client.Element)element);
                    widget.onAttachWidget();
                    RootPanel.detachOnWindowClose(widget.asWidget());
                    widget.addValueChangeHandler(new WidgetChangeHandler(parentEntity, attributeName, i));
                }
            } else {
                for (I_Entity entity : attribute.getComplexValues()) {
                    renderInline(entity, context);
                }
View Full Code Here

                    parentEntity,
                    attributeName,
                    formParent.getElement());
                for (int i = 0; i < elements.size(); i++) {
                    Element element = elements.get(i);
                    I_EditWidget widget = m_widgetService.getAttributeInlineWidget(
                        attributeName,
                        (com.google.gwt.user.client.Element)element);
                    formParent.adoptWidget(widget);
                    widget.addValueChangeHandler(new WidgetChangeHandler(parentEntity, attributeName, i));
                }
            } else {
                for (I_Entity entity : attribute.getComplexValues()) {
                    renderInline(entity, formParent);
                }
View Full Code Here

TOP

Related Classes of com.alkacon.acacia.client.widgets.I_EditWidget

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.