Examples of syncPageFragments()


Examples of org.apache.jetspeed.layout.PortletPlacementContext.syncPageFragments()

            fragment.setName(portletId);
            fragment.setLayoutColumn(iCol);
            fragment.setLayoutRow(iRow);
           
            Coordinate coordinate = placement.add(fragment, new CoordinateImpl(iCol, iRow, iCol, iRow));
            Page page = placement.syncPageFragments();                                               
           
            // TODO: this does not handle nested layouts           
            Fragment root = requestContext.getPage().getRootFragment();
            root.getFragments().add(fragment);           
            pageManager.updatePage(page);
View Full Code Here

Examples of org.apache.jetspeed.layout.PortletPlacementContext.syncPageFragments()

            {
                returnCoordinate = placement.moveDown(fragment);
            }

            // synchronize back to the page layout root fragment
            Page page = placement.syncPageFragments();
           
            if (pageManager != null)
                pageManager.updatePage(page);
           
            // Use dummy values for now
View Full Code Here

Examples of org.apache.jetspeed.layout.PortletPlacementContext.syncPageFragments()

                success = false;
                resultMap.put( REASON, "Fragment not found" );
                return success;               
            }
            placement.remove(fragment);
            page = placement.syncPageFragments();
            page.removeFragmentById( fragment.getId() );
            if (!batch)
            {
                if (pageManager != null)
                    pageManager.updatePage( page );
View Full Code Here

Examples of org.apache.jetspeed.layout.PortletPlacementContext.syncPageFragments()

                success = false;
                resultMap.put( REASON, "Failed to find fragment to move to another layout for fragment id: " + moveFragmentId );
                return success;
            }
            placement.remove( placeFragment );
            page = placement.syncPageFragments();
            page.removeFragmentById( moveFragmentId );
        }
        if ( placeFragment != null )
        {
            return placeFragment( requestContext,
View Full Code Here

Examples of org.apache.jetspeed.layout.PortletPlacementContext.syncPageFragments()

                layoutFragment = getParentFragment(contentPage.getNonTemplateRootFragment(), addedContentFragmentId);
            }
           
            PortletPlacementContext ppc = new PortletPlacementContextImpl(contentPage, portletRegistry, layoutFragment);
            // synchronize back to the page layout root fragment
            contentPage = ppc.syncPageFragments();
           
            return new ContentFragmentBean(contentFragment);
        }
        catch (Exception e)
        {
View Full Code Here

Examples of org.apache.jetspeed.layout.PortletPlacementContext.syncPageFragments()

        {
            pageLayoutComponent.removeFragment(contentPage, fragmentId);
           
            PortletPlacementContext ppc = new PortletPlacementContextImpl(contentPage, portletRegistry, layoutFragment);
            // synchronize back to the page layout root fragment
            contentPage = ppc.syncPageFragments();
        }
        catch (Exception e)
        {
            throw new WebApplicationException(e);
        }
View Full Code Here

Examples of org.apache.jetspeed.layout.PortletPlacementContext.syncPageFragments()

                {
                    throw new WebApplicationException(new IllegalArgumentException("Invalid direction: " + direction));
                }
               
                // synchronize back to the page layout root fragment
                contentPage = ppc.syncPageFragments(PageLayoutComponent.USER_PROPERTY_SCOPE, null);
            }
            catch (PortletPlacementException e)
            {
                throw new WebApplicationException(e);
            }
View Full Code Here

Examples of org.apache.jetspeed.layout.PortletPlacementContext.syncPageFragments()

                    {
                        pageLayoutComponent.updatePosition(contentFragment, -1.0f, -1.0f, -1.0f, -1.0f, posHeight, PageLayoutComponent.USER_PROPERTY_SCOPE, null);
                    }
                   
                    // synchronize back to the page layout root fragment
                    contentPage = ppc.syncPageFragments(PageLayoutComponent.USER_PROPERTY_SCOPE, null);
                    if (attach)
                      pageLayoutComponent.updateStateMode(contentFragment, JetspeedActions.NORMAL, null, PageLayoutComponent.USER_PROPERTY_SCOPE, null);                   
                }
                catch (Exception e)
                {
View Full Code Here

Examples of org.apache.jetspeed.layout.PortletPlacementContext.syncPageFragments()

                    PortletPlacementContext ppc = new PortletPlacementContextImpl(contentPage, portletRegistry, layoutFragment);
                    int col = contentFragment.getLayoutColumn();
                    int row = ppc.getNumberRows((col <= 0) ? 0 : col - 1);
                    Coordinate coordinate = new CoordinateImpl(col, contentFragment.getLayoutRow(), col, row);
                    ppc.moveAbsolute(contentFragment, coordinate);
                    contentPage = ppc.syncPageFragments(PageLayoutComponent.USER_PROPERTY_SCOPE, null);
                }
            }
            catch (Exception e)
            {
                throw new WebApplicationException(e);
View Full Code Here

Examples of org.apache.jetspeed.layout.PortletPlacementContext.syncPageFragments()

                success = false;
                resultMap.put( REASON, "Failed to find fragment to move to another layout for fragment id: " + moveFragmentId );
                return success;
            }
            placement.remove( placeFragment );
            page = placement.syncPageFragments();
           
            page.moveFragment(placeFragment.getId(), removeFromLayoutFragment.getId(), moveToLayoutFragment.getId());
        }
        if ( placeFragment != null )
        {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.