Package org.exoplatform.webui.core

Examples of org.exoplatform.webui.core.UIComponent


            }
        }
    }

    private static void buildUIContainer(UIContainer uiContainer, Object model, boolean dashboard) throws Exception {
        UIComponent uiComponent = null;
        WebuiRequestContext context = Util.getPortalRequestContext();

        if (model instanceof SiteBody) {
            UISiteBody uiSiteBody = uiContainer.createUIComponent(context, UISiteBody.class, null, null);
            uiSiteBody.setStorageId(((SiteBody) model).getStorageId());
View Full Code Here


            ctx.setState(new NavigationState(priority));
            service.saveNavigation(ctx);

            UIPopupWindow uiPopup = uiForm.getParent();
            uiPopup.setShow(false);
            UIComponent opener = uiPopup.getParent();

            ActionResponse response = event.getRequestContext().getResponse();
            response.setEvent(new QName("NavigationChange"), null);

            WebuiRequestContext pcontext = event.getRequestContext();
View Full Code Here

            /* Put the portal back in place as we have removed it in
             * org.exoplatform.portal.webui.workspace.UIMainActionListener.EditInlineActionListener.execute(Event<UIWorkingWorkspace>) */
            UISiteBody siteBody = uiWorkingWS.findFirstComponentOfType(UISiteBody.class);
            UIEditInlineWorkspace uiEditWS = uiWorkingWS.getChild(UIEditInlineWorkspace.class);
            UIComponent editComponent = uiEditWS.getUIComponent();
            if (editComponent instanceof UIPortal) {
                UIPortal editPortal = (UIPortal) editComponent;
                editPortal.setHeaderAndFooterRendered(true);
                siteBody.setUIComponent(editPortal);
            }
View Full Code Here

        }
    }

    public static class DeleteComponentActionListener extends EventListener<UIComponent> {
        public void execute(Event<UIComponent> event) throws Exception {
            UIComponent uiComponentTobeRemoved = event.getSource();
            String id = uiComponentTobeRemoved.getId();
            UIPortalApplication uiApp = Util.getUIPortalApplication();
            if (uiComponentTobeRemoved.findFirstComponentOfType(UIPageBody.class) != null) {
                uiApp.addMessage(new ApplicationMessage("UIPortalApplication.msg.deletePageBody", new Object[] {},
                        ApplicationMessage.WARNING));
                return;
            }

            org.exoplatform.portal.webui.container.UIContainer uiParent = uiComponentTobeRemoved.getParent();
            if (!canMove(uiComponentTobeRemoved, (org.exoplatform.portal.webui.container.UIContainer) uiParent)) {
                /* deletion not allowed */
                return;
            }

            UIPortalComposer portalComposer = uiApp.findFirstComponentOfType(UIPortalComposer.class);
            portalComposer.setEditted(true);

            UIPage uiPage = uiComponentTobeRemoved.getAncestorOfType(UIPage.class);
            if (uiPage != null && uiPage.getMaximizedUIPortlet() != null) {
                if (id.equals(uiPage.getMaximizedUIPortlet().getId())) {
                    uiPage.setMaximizedUIPortlet(null);
                }
            } else {
View Full Code Here

                portalComposer.updateWorkspaceComponent();
                pcontext.ignoreAJAXUpdateOnPortlets(true);
            }

            UIWorkingWorkspace uiWorkingWS = uiApp.getChild(UIWorkingWorkspace.class);
            UIComponent uiWorking = uiWorkingWS.findFirstComponentOfType(UIPortalToolPanel.class);
            if (!uiWorking.isRendered()) {
                UIEditInlineWorkspace uiEditWS = uiWorkingWS.getChild(UIEditInlineWorkspace.class);
                uiWorking = uiEditWS.getUIComponent();
            }

            String sourceId = pcontext.getRequestParameter("srcID");
            UIComponent uiSource = uiWorking.findComponentById(sourceId);

            final UIContainer uiTarget = uiWorking.findComponentById(pcontext.getRequestParameter("targetID"));
            if (position < 0 && uiTarget.getChildren().size() > 0) {
                position = uiTarget.getChildren().size();
            } else if (position < 0) {
View Full Code Here

            }
        }

        private UIComponent prepareUiSource(boolean newComponent, UIPortalApplication uiApp, UIPortalComposer portalComposer,
                String sourceId, final UIContainer uiTarget) throws Exception {
            UIComponent uiSource;
            UITabPane subTabPane = portalComposer.getChild(UITabPane.class);
            UIContainerList uiContainerConfig = subTabPane.getChild(UIContainerList.class);
            if (uiContainerConfig != null && subTabPane.getSelectedTabId().equals(uiContainerConfig.getId())) {
                org.exoplatform.portal.webui.container.UIContainer uiContainer = uiTarget.createUIComponent(
                        org.exoplatform.portal.webui.container.UIContainer.class, null, null);
View Full Code Here

        }
    }

    private UserNode saveData() throws Exception {
        UIPagePreview uiPagePreview = getChild(UIPagePreview.class);
        UIComponent uiPreviewComponent = uiPagePreview.getUIComponent();
        UIPage uiPage = null;
        if (uiPreviewComponent instanceof UIPage) {
            uiPage = (UIPage) uiPreviewComponent;
        } else if (uiPreviewComponent instanceof UIPortal) {
            UIPageBody uiPageBody = uiPreviewComponent.findFirstComponentOfType(UIPageBody.class);
            uiPage = (UIPage) uiPageBody.getUIComponent();
        }

        UIWizardPageSetInfo uiPageInfo = getChild(UIWizardPageSetInfo.class);
        UIPageNodeSelector uiNodeSelector = uiPageInfo.getChild(UIPageNodeSelector.class);
View Full Code Here

     * @return
     */
    private boolean isUsedInWizard() {
        UIWorkingWorkspace uiWorkingWS = getAncestorOfType(UIWorkingWorkspace.class);
        UIPortalToolPanel uiToolPanel = uiWorkingWS.findFirstComponentOfType(UIPortalToolPanel.class);
        UIComponent uicomponent = uiToolPanel.getUIComponent();
        if (uicomponent != null && uicomponent instanceof UIWizard) {
            return true;
        }
        return false;
    }
View Full Code Here

            }
            page.setTitle(title);

            UIPagePreview uiPagePreview = uiWizard.getChild(UIPagePreview.class);

            UIComponent uiPreviewComponent = UIPage.isFullPreview()
                    ? prepareUIPortal(uiPortalApp, (PortalRequestContext) context, uiWorkingWS, page)
                    : prepareUIPage(page, context);
            uiPagePreview.setUIComponent(uiPreviewComponent);

            uiWizard.updateWizardComponent();
View Full Code Here

    }

    public static class ViewSitePropertiesActionListener extends EventListener<UIPortalComposer> {

        public void execute(Event<UIPortalComposer> event) throws Exception {
            UIComponent temp = null;
            UIPortal uiPortal = null;
            String portalOwner = null;
            UIEditInlineWorkspace uiEditWS = event.getSource().getAncestorOfType(UIEditInlineWorkspace.class);
            temp = uiEditWS.getUIComponent();
            if (temp != null && (temp instanceof UIPortal)) {
View Full Code Here

TOP

Related Classes of org.exoplatform.webui.core.UIComponent

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.