use of org.olat.core.gui.control.WindowControl in project OpenOLAT by OpenOLAT.
the class PortfolioHomeController method doOpenMyPages.
private MyPageListController doOpenMyPages(UserRequest ureq) {
removeAsListenerAndDispose(myPageListCtrl);
stackPanel.popUpToRootController(ureq);
OLATResourceable pagesOres = OresHelper.createOLATResourceableInstance("MyPages", 0l);
WindowControl swControl = addToHistory(ureq, pagesOres, null);
// owners of all pages
BinderSecurityCallback secCallback = BinderSecurityCallbackFactory.getCallbackForMyPageList();
myPageListCtrl = new MyPageListController(ureq, swControl, stackPanel, secCallback);
listenTo(myPageListCtrl);
stackPanel.pushController(translate("my.portfolio.pages.breadcrump"), myPageListCtrl);
return myPageListCtrl;
}
use of org.olat.core.gui.control.WindowControl in project OpenOLAT by OpenOLAT.
the class PortfolioHomeController method doDeletedPages.
private TrashController doDeletedPages(UserRequest ureq) {
OLATResourceable bindersOres = OresHelper.createOLATResourceableInstance("Trash", 0l);
WindowControl swControl = addToHistory(ureq, bindersOres, null);
BinderSecurityCallback secCallback = BinderSecurityCallbackFactory.getCallbackForMyPageList();
deletedItemsCtrl = new TrashController(ureq, swControl, stackPanel, secCallback);
listenTo(deletedItemsCtrl);
stackPanel.pushController(translate("deleted.pages.breadcrump"), deletedItemsCtrl);
return deletedItemsCtrl;
}
use of org.olat.core.gui.control.WindowControl in project OpenOLAT by OpenOLAT.
the class PageRunController method doPrint.
private void doPrint(UserRequest ureq) {
ControllerCreator ctrlCreator = new ControllerCreator() {
@Override
public Controller createController(UserRequest lureq, WindowControl lwControl) {
BinderOnePageController printCtrl = new BinderOnePageController(lureq, lwControl, page, ExtendedMediaRenderingHints.toPrint(), true);
LayoutMain3ColsController layoutCtr = new LayoutMain3ColsController(lureq, lwControl, printCtrl);
// dispose controller on layout dispose
layoutCtr.addDisposableChildController(printCtrl);
return layoutCtr;
}
};
ControllerCreator layoutCtrlr = BaseFullWebappPopupLayoutFactory.createPrintPopupLayout(ctrlCreator);
openInNewBrowserWindow(ureq, layoutCtrlr);
}
use of org.olat.core.gui.control.WindowControl in project OpenOLAT by OpenOLAT.
the class VideoListingController method doShowVideo.
/**
* Launch a single video and add to breadcrumb
* @param ureq
* @param id the video resource ID
*/
private void doShowVideo(UserRequest ureq, Long id) {
RepositoryEntry videoEntry = repositoryManager.lookupRepositoryEntry(id);
if (repositoryManager.isAllowed(ureq, videoEntry).canLaunch()) {
boolean readOnly = repositoryManager.createRepositoryEntryStatus(videoEntry.getStatusCode()).isClosed();
VideoDisplayController videoDisplayCtr = new VideoDisplayController(ureq, getWindowControl(), videoEntry, true, true, true, true, null, false, true, null, readOnly);
listenTo(videoDisplayCtr);
toolbarPanel.pushController(videoEntry.getDisplayname(), videoDisplayCtr);
// Update launch counter
repositoryService.incrementLaunchCounter(videoEntry);
// Update business path and URL
ContextEntry ce = BusinessControlFactory.getInstance().createContextEntry(videoEntry);
ThreadLocalUserActivityLogger.addLoggingResourceInfo(LoggingResourceable.wrapBusinessPath(ce.getOLATResourceable()));
WindowControl bwControl = BusinessControlFactory.getInstance().createBusinessWindowControl(ce, getWindowControl());
addToHistory(ureq, bwControl);
}
}
use of org.olat.core.gui.control.WindowControl in project OpenOLAT by OpenOLAT.
the class VideoRuntimeController method doSettings.
private Activateable2 doSettings(UserRequest ureq) {
removeAsListenerAndDispose(settingsCtr);
RepositoryEntry entry = getRepositoryEntry();
OLATResourceable ores = OresHelper.createOLATResourceableType("settings");
WindowControl swControl = addToHistory(ureq, ores, null);
VideoSettingsController configCtrl = new VideoSettingsController(ureq, swControl, entry);
listenTo(configCtrl);
settingsCtr = pushController(ureq, translate("tab.video.settings"), configCtrl);
setActiveTool(settingsLink);
return settingsCtr;
}
Aggregations