Search in sources :

Example 6 with ForumController

use of org.olat.modules.fo.ui.ForumController in project openolat by klemens.

the class ForumUIFactory method getPopupableForumController.

/**
 * Provides a popable ForumController wrapped in a titled controller.
 * @param ureq
 * @param forum
 * @param forumCallback
 * @param title
 * @return a ChiefController
 */
public static PopupBrowserWindow getPopupableForumController(UserRequest ureq, WindowControl wControl, final Forum forum, final ForumCallback forumCallback, final TitleInfo titleInfo) {
    ControllerCreator ctrlCreator = new ControllerCreator() {

        public Controller createController(UserRequest lureq, WindowControl lwControl) {
            Controller forumWrapperController = getTitledForumController(lureq, lwControl, forum, forumCallback, titleInfo);
            // use on column layout
            LayoutMain3ColsController layoutCtr = new LayoutMain3ColsController(lureq, lwControl, forumWrapperController);
            // dispose content on layout dispose
            layoutCtr.addDisposableChildController(forumWrapperController);
            return layoutCtr;
        }
    };
    // wrap the content controller into a full header layout
    ControllerCreator layoutCtrlr = BaseFullWebappPopupLayoutFactory.createAuthMinimalPopupLayout(ureq, ctrlCreator);
    PopupBrowserWindow pbw = wControl.getWindowBackOffice().getWindowManager().createNewPopupBrowserWindowFor(ureq, layoutCtrlr);
    return pbw;
}
Also used : PopupBrowserWindow(org.olat.core.gui.control.generic.popup.PopupBrowserWindow) LayoutMain3ColsController(org.olat.core.commons.fullWebApp.LayoutMain3ColsController) WindowControl(org.olat.core.gui.control.WindowControl) TitledWrapperController(org.olat.core.gui.control.generic.title.TitledWrapperController) ForumController(org.olat.modules.fo.ui.ForumController) Controller(org.olat.core.gui.control.Controller) LayoutMain3ColsController(org.olat.core.commons.fullWebApp.LayoutMain3ColsController) ControllerCreator(org.olat.core.gui.control.creator.ControllerCreator) UserRequest(org.olat.core.gui.UserRequest)

Aggregations

ForumController (org.olat.modules.fo.ui.ForumController)6 WindowControl (org.olat.core.gui.control.WindowControl)4 TitledWrapperController (org.olat.core.gui.control.generic.title.TitledWrapperController)4 LayoutMain3ColsController (org.olat.core.commons.fullWebApp.LayoutMain3ColsController)2 UserRequest (org.olat.core.gui.UserRequest)2 TableController (org.olat.core.gui.components.table.TableController)2 Controller (org.olat.core.gui.control.Controller)2 ControllerCreator (org.olat.core.gui.control.creator.ControllerCreator)2 PopupBrowserWindow (org.olat.core.gui.control.generic.popup.PopupBrowserWindow)2 OLATResourceable (org.olat.core.id.OLATResourceable)2 ContextEntry (org.olat.core.id.context.ContextEntry)2 Forum (org.olat.modules.fo.Forum)2 ForumCallback (org.olat.modules.fo.ForumCallback)2 HistoryTableDateModel (org.olat.modules.wiki.versioning.HistoryTableDateModel)2