use of org.olat.core.gui.components.stack.PopEvent in project openolat by klemens.
the class LecturesToolController method event.
@Override
protected void event(UserRequest ureq, Component source, Event event) {
if (event instanceof SegmentViewEvent) {
SegmentViewEvent sve = (SegmentViewEvent) event;
String segmentCName = sve.getComponentName();
Component clickedLink = mainVC.getComponent(segmentCName);
if (clickedLink == teacherLink) {
doOpenTeacherView(ureq);
} else if (clickedLink == participantLink) {
doOpenParticipantView(ureq);
}
} else if (stackPanel == source) {
if (event instanceof PopEvent) {
PopEvent popEvent = (PopEvent) event;
if (popEvent.getController() instanceof TeacherRollCallController) {
addToHistory(ureq, teacherOverviewCtrl);
} else if (popEvent.getController() instanceof ParticipantLectureBlocksController) {
addToHistory(ureq, participantOverviewCtrl);
}
}
}
}
use of org.olat.core.gui.components.stack.PopEvent in project openolat by klemens.
the class BusinessGroupMainRunController method event.
/**
* @see org.olat.core.gui.control.DefaultController#event(org.olat.core.gui.UserRequest,
* org.olat.core.gui.components.Component, org.olat.core.gui.control.Event)
*/
@Override
public void event(UserRequest ureq, Component source, Event event) {
// events from menutree
if (source == bgTree) {
// administration
if (!groupRunDisabled && event.getCommand().equals(MenuTree.COMMAND_TREENODE_CLICKED)) {
TreeNode selTreeNode = bgTree.getSelectedNode();
String cmd = (String) selTreeNode.getUserObject();
handleTreeActions(ureq, cmd);
} else if (groupRunDisabled) {
handleTreeActions(ureq, ACTIVITY_MENUSELECT_OVERVIEW);
showError("grouprun.disabled");
}
} else if (source == toolbarPanel) {
if (event == Event.CLOSE_EVENT) {
doClose(ureq);
} else if (event instanceof PopEvent) {
PopEvent pe = (PopEvent) event;
Controller popedCtrl = pe.getController();
if (popedCtrl == collabToolCtr) {
handleTreeActions(ureq, ACTIVITY_MENUSELECT_OVERVIEW);
bgTree.setSelectedNode(bgTree.getTreeModel().getRootNode());
}
}
}
}
use of org.olat.core.gui.components.stack.PopEvent in project openolat by klemens.
the class EvaluationFormRuntimeController method event.
@Override
protected void event(UserRequest ureq, Component source, Event event) {
if (toolbarPanel == source) {
if (event instanceof PopEvent) {
PopEvent pe = (PopEvent) event;
Controller popedCtrl = pe.getController();
if (popedCtrl instanceof EvaluationFormEditorController) {
EvaluationFormEditorController formEditorCtrl = (EvaluationFormEditorController) popedCtrl;
if (formEditorCtrl.hasChanges()) {
doReloadRuntimeController(ureq);
}
}
}
}
super.event(ureq, source, event);
}
use of org.olat.core.gui.components.stack.PopEvent in project OpenOLAT by OpenOLAT.
the class BusinessGroupMainRunController method event.
/**
* @see org.olat.core.gui.control.DefaultController#event(org.olat.core.gui.UserRequest,
* org.olat.core.gui.components.Component, org.olat.core.gui.control.Event)
*/
@Override
public void event(UserRequest ureq, Component source, Event event) {
// events from menutree
if (source == bgTree) {
// administration
if (!groupRunDisabled && event.getCommand().equals(MenuTree.COMMAND_TREENODE_CLICKED)) {
TreeNode selTreeNode = bgTree.getSelectedNode();
String cmd = (String) selTreeNode.getUserObject();
handleTreeActions(ureq, cmd);
} else if (groupRunDisabled) {
handleTreeActions(ureq, ACTIVITY_MENUSELECT_OVERVIEW);
showError("grouprun.disabled");
}
} else if (source == toolbarPanel) {
if (event == Event.CLOSE_EVENT) {
doClose(ureq);
} else if (event instanceof PopEvent) {
PopEvent pe = (PopEvent) event;
Controller popedCtrl = pe.getController();
if (popedCtrl == collabToolCtr) {
handleTreeActions(ureq, ACTIVITY_MENUSELECT_OVERVIEW);
bgTree.setSelectedNode(bgTree.getTreeModel().getRootNode());
}
}
}
}
use of org.olat.core.gui.components.stack.PopEvent in project OpenOLAT by OpenOLAT.
the class EvaluationFormRuntimeController method event.
@Override
protected void event(UserRequest ureq, Component source, Event event) {
if (toolbarPanel == source) {
if (event instanceof PopEvent) {
PopEvent pe = (PopEvent) event;
Controller popedCtrl = pe.getController();
if (popedCtrl instanceof EvaluationFormEditorController) {
EvaluationFormEditorController formEditorCtrl = (EvaluationFormEditorController) popedCtrl;
if (formEditorCtrl.hasChanges()) {
doReloadRuntimeController(ureq);
}
}
}
}
super.event(ureq, source, event);
}
Aggregations