Ejemplo n.º 1
0
 /*
  * (non-Javadoc)
  *
  * @see
  * org.exoplatform.webui.event.EventListener#execute(org.exoplatform
  * .webui.event.Event)
  */
 public void execute(Event<UINavigationForm> event) throws Exception {
   UINavigationForm uiNavigationForm = event.getSource();
   UIPageSelector pageSelector =
       uiNavigationForm.createUIComponent(UIPageSelector.class, null, null);
   pageSelector.setSourceComponent(
       uiNavigationForm, new String[] {DETAIL_TARGET_PAGE_STRING_INPUT});
   UIJCRExplorer uiExplorer = event.getSource().getAncestorOfType(UIJCRExplorer.class);
   UIPopupContainer popupContainer = uiExplorer.getChild(UIPopupContainer.class);
   popupContainer.removeChildById(DETAIL_TARGET_PAGE_SELECTOR_POPUP_WINDOW);
   UIPopupWindow popupWindow =
       popupContainer.addChild(
           UIPopupWindow.class, null, DETAIL_TARGET_PAGE_SELECTOR_POPUP_WINDOW);
   popupWindow.setUIComponent(pageSelector);
   popupWindow.setWindowSize(800, 0);
   popupWindow.setShow(true);
   popupWindow.setRendered(true);
   popupWindow.setResizable(true);
   WebuiRequestContext requestContext = WebuiRequestContext.getCurrentInstance();
   requestContext.addUIComponentToUpdateByAjax(popupContainer);
   uiNavigationForm.setPopupId(DETAIL_TARGET_PAGE_SELECTOR_POPUP_WINDOW);
 }