public GridLayout initialize() { LOG.debug("Initializing the category and post view"); buildCategoryTree(); buildCategoryCRUDAccordion(); postCRUDAccordion = postView.buildPostCRUDAccordion(); postCRUDAccordion.setHeight("100%"); postViewGrid = postView.buildPostViewGrid(); topLayout.setImmediate(true); topLayout.setHeight("100%"); topLayout.setWidth("100%"); topLayout.setSpacing(true); // first row of the grid layout topLayout.addComponent(categoryAccordionCRUD); topLayout.addComponent(topTreeLayout); topLayout.addComponent(postCRUDAccordion); // builds the CRUD accordion for Posts management // second row of the grid layout topLayout.addComponent( postViewGrid, 0, 1, 2, 1); // builds the Grid for the Posts view which spans over 3 columns of the row topLayout.setComponentAlignment(postViewGrid, Alignment.TOP_LEFT); return topLayout; }