use of org.olat.core.gui.control.generic.closablewrapper.CloseableModalController in project OpenOLAT by OpenOLAT.
the class QuestionListController method doConfirmCopy.
protected void doConfirmCopy(UserRequest ureq, List<QuestionItemShort> items) {
copyConfirmationCtrl = new CopyConfirmationController(ureq, getWindowControl(), items, getSource());
listenTo(copyConfirmationCtrl);
cmc = new CloseableModalController(getWindowControl(), translate("close"), copyConfirmationCtrl.getInitialComponent(), true, translate("confirm.copy.title"), true);
listenTo(cmc);
cmc.activate();
}
use of org.olat.core.gui.control.generic.closablewrapper.CloseableModalController in project OpenOLAT by OpenOLAT.
the class QuestionListController method doOpenCreateRepositoryTest.
private void doOpenCreateRepositoryTest(UserRequest ureq, List<QuestionItemShort> items, String type) {
removeAsListenerAndDispose(cmc);
removeAsListenerAndDispose(addController);
RepositoryHandler handler = repositoryHandlerFactory.getRepositoryHandler(type);
addController = handler.createCreateRepositoryEntryController(ureq, getWindowControl());
addController.setCreateObject(new QItemList(items));
listenTo(addController);
cmc = new CloseableModalController(getWindowControl(), translate("close"), addController.getInitialComponent());
listenTo(cmc);
cmc.activate();
}
use of org.olat.core.gui.control.generic.closablewrapper.CloseableModalController in project OpenOLAT by OpenOLAT.
the class QuestionListController method doOpenRepositoryImport.
private void doOpenRepositoryImport(UserRequest ureq) {
removeAsListenerAndDispose(importTestCtrl);
String[] allowed;
if (qtiModule.isCreateResourcesEnabled()) {
allowed = new String[] { ImsQTI21Resource.TYPE_NAME, TestFileResource.TYPE_NAME, SurveyFileResource.TYPE_NAME };
} else {
allowed = new String[] { ImsQTI21Resource.TYPE_NAME };
}
importTestCtrl = new ReferencableEntriesSearchController(getWindowControl(), ureq, allowed, null, translate("import.repository"), false, false, false, true, Can.copyable);
listenTo(importTestCtrl);
cmc = new CloseableModalController(getWindowControl(), translate("close"), importTestCtrl.getInitialComponent(), true, translate("import.repository"));
cmc.setContextHelp(getTranslator(), "Data Management#qb_share");
cmc.activate();
listenTo(cmc);
}
use of org.olat.core.gui.control.generic.closablewrapper.CloseableModalController in project OpenOLAT by OpenOLAT.
the class QuestionListController method doChooseNewItemType.
private void doChooseNewItemType(UserRequest ureq) {
removeAsListenerAndDispose(newItemOptionsCtrl);
if (getSource() instanceof TaxonomyLevelItemsSource) {
TaxonomyLevelItemsSource tliSource = (TaxonomyLevelItemsSource) getSource();
newItemOptionsCtrl = new NewItemOptionsController(ureq, getWindowControl(), getSecurityCallback(), tliSource.getTaxonomyLevel(), getSource().isAdminItemSource());
} else {
newItemOptionsCtrl = new NewItemOptionsController(ureq, getWindowControl(), getSecurityCallback(), getSource().isAdminItemSource());
}
listenTo(newItemOptionsCtrl);
removeAsListenerAndDispose(cmc);
cmc = new CloseableModalController(getWindowControl(), translate("close"), newItemOptionsCtrl.getInitialComponent(), true, translate("new.item"));
cmc.activate();
listenTo(cmc);
}
use of org.olat.core.gui.control.generic.closablewrapper.CloseableModalController in project OpenOLAT by OpenOLAT.
the class QuestionListController method doOpenFileImport.
private void doOpenFileImport(UserRequest ureq) {
removeAsListenerAndDispose(importItemCtrl);
importItemCtrl = new ImportController(ureq, getWindowControl(), getSource());
listenTo(importItemCtrl);
cmc = new CloseableModalController(getWindowControl(), translate("close"), importItemCtrl.getInitialComponent(), true, translate("import.item"));
cmc.activate();
listenTo(cmc);
}
Aggregations