guimsgVc.contextPut("guiMessage", guiMessage);
guimsgPanel = new OncePanel("guimsgPanel");
mainVc.put("guimessage", guimsgPanel);
final WindowControl origWCo = wControl; //no need to use: super.getWindowControl();
myWControl = new WindowControl() {
private WindowControlInfo wci;
{
wci = new WindowControlInfoImpl(SimpleBaseController.this, origWCo.getWindowControlInfo());
}
/**
* @see org.olat.core.gui.control.WindowControl#pushToMainArea(org.olat.core.gui.components.Component)
*/
public void pushToMainArea(Component newMainArea) {
currentGuiStack.pushContent(newMainArea);
}
/**
* @see org.olat.core.gui.control.WindowControl#pushAsModalDialog(java.lang.String,
* org.olat.core.gui.components.Component)
*/
public void pushAsModalDialog(Component newModalDialog) {
currentGuiStack.pushModalDialog(newModalDialog);
}
/**
* @see org.olat.core.gui.control.WindowControl#pop()
*/
public void pop() {
// reactivate latest dialog from stack, dumping current one
currentGuiStack.popContent();
}
/**
* @see org.olat.core.gui.control.WindowControl#setInfo(java.lang.String)
*/
public void setInfo(String info) {
guiMessage.setInfo(info);
guimsgPanel.setContent(guimsgVc);
}
/**
* @see org.olat.core.gui.control.WindowControl#setError(java.lang.String)
*/
public void setError(String error) {
guiMessage.setError(error);
guimsgPanel.setContent(guimsgVc);
}
/**
* @see org.olat.core.gui.control.WindowControl#setWarning(java.lang.String)
*/
public void setWarning(String warning) {
guiMessage.setWarn(warning);
guimsgPanel.setContent(guimsgVc);
}
public WindowControlInfo getWindowControlInfo() {
return wci;
}
public void makeFlat() {
throw new AssertException("should never be called!");
}
public BusinessControl getBusinessControl() {
return origWCo.getBusinessControl();
}
public WindowBackOffice getWindowBackOffice() {
return origWCo.getWindowBackOffice();
}
};
overrideWindowControl(myWControl);