final Layout layout = (Layout)coplet.getTemporaryAttribute(ATTRIBUTE_NAME_LAYOUT);
final Layout fullScreenLayout = service.getEntryLayout(null);
if ( fullScreenLayout != null
&& fullScreenLayout.equals( layout )
&& !windowState.equals(WindowStates._maximized) ) {
FullScreenCopletEvent e = new FullScreenCopletEvent( coplet, null );
service.getComponentManager().getEventManager().send(e);
}
if ( windowState.equals(WindowStates._minimized) ) {
ChangeCopletInstanceAspectDataEvent e = new ChangeCopletInstanceAspectDataEvent(coplet, "size", SizingStatus.STATUS_MINIMIZED);
service.getComponentManager().getEventManager().send(e);
}
if ( windowState.equals(WindowStates._normal) ) {
ChangeCopletInstanceAspectDataEvent e = new ChangeCopletInstanceAspectDataEvent(coplet, "size", SizingStatus.STATUS_MAXIMIZED);
service.getComponentManager().getEventManager().send(e);
}
if ( windowState.equals(WindowStates._maximized) ) {
FullScreenCopletEvent e = new FullScreenCopletEvent( coplet, layout );
service.getComponentManager().getEventManager().send(e);
}
windowSession.setWindowState(windowState);
}
}