cziegeler    2004/03/03 13:44:54

  Modified:    
src/blocks/portal/java/org/apache/cocoon/portal/layout/renderer/aspect/impl
                        FullScreenCopletAspect.java
  Log:
  If a coplet supports full screen is now configurable as well
  
  Revision  Changes    Path
  1.6       +11 -9     
cocoon-2.1/src/blocks/portal/java/org/apache/cocoon/portal/layout/renderer/aspect/impl/FullScreenCopletAspect.java
  
  Index: FullScreenCopletAspect.java
  ===================================================================
  RCS file: 
/home/cvs/cocoon-2.1/src/blocks/portal/java/org/apache/cocoon/portal/layout/renderer/aspect/impl/FullScreenCopletAspect.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- FullScreenCopletAspect.java       8 Dec 2003 13:47:51 -0000       1.5
  +++ FullScreenCopletAspect.java       3 Mar 2004 21:44:54 -0000       1.6
  @@ -80,15 +80,17 @@
           
           CopletInstanceData cid = 
((CopletLayout)layout).getCopletInstanceData();
   
  -        final Layout fullScreenLayout = 
service.getComponentManager().getProfileManager().getEntryLayout();
  -        if ( fullScreenLayout != null && fullScreenLayout.equals( layout )) {
  -            FullScreenCopletEvent event = new FullScreenCopletEvent( cid, 
null );
  -            XMLUtils.createElement(handler, "fullscreen-uri", 
service.getComponentManager().getLinkService().getLinkURI(event));
  -        } else {
  -            FullScreenCopletEvent event = new FullScreenCopletEvent( cid, 
layout );
  -            XMLUtils.createElement(handler, "fullscreen-uri", 
service.getComponentManager().getLinkService().getLinkURI(event));
  +        Boolean supportsFullScreen = 
(Boolean)cid.getCopletData().getAspectData("full-screen");
  +        if ( supportsFullScreen == null || 
supportsFullScreen.equals(Boolean.TRUE) ) {
  +            final Layout fullScreenLayout = 
service.getComponentManager().getProfileManager().getEntryLayout();
  +            if ( fullScreenLayout != null && fullScreenLayout.equals( layout 
)) {
  +                FullScreenCopletEvent event = new FullScreenCopletEvent( 
cid, null );
  +                XMLUtils.createElement(handler, "fullscreen-uri", 
service.getComponentManager().getLinkService().getLinkURI(event));
  +            } else {
  +                FullScreenCopletEvent event = new FullScreenCopletEvent( 
cid, layout );
  +                XMLUtils.createElement(handler, "fullscreen-uri", 
service.getComponentManager().getLinkService().getLinkURI(event));
  +            }
           }
  -
           context.invokeNext(layout, service, handler);
        }
   
  
  
  

Reply via email to