Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into release/v1.3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
ashvayka committed Feb 19, 2016
2 parents de0db95 + de20621 commit d4f02ef
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -165,24 +165,29 @@ protected void initCenterPanel() {
projectDetailsPanel = new HTML();
projectDetailsPanel.addStyleName(Utils.sandboxStyle.projectDetails());
projectDetailsPanel.getElement().getStyle().setPaddingTop(15, Style.Unit.PX);
projectDetailsPanel.getElement().getStyle().setPaddingBottom(15, Style.Unit.PX);
flexTable.setWidget(2, 1, projectDetailsPanel);
flexTable.getFlexCellFormatter().setColSpan(2, 1, 2);


carousel = new CarouselWidget();
HorizontalPanel carouselPanel = new HorizontalPanel();
carouselPanel.addStyleName(sandboxStyle.bundleProjectsPanel());
carouselPanel.getElement().getStyle().setPadding(15, Unit.PX);
carouselPanel.setHeight("330px");
carouselPanel.setWidth("100%");
carouselPanel.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);
carouselPanel.add(carousel);


VerticalPanel content = new VerticalPanel();
content.add(flexTable);
content.add(carouselPanel);
content.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);
content.getElement().getStyle().setOverflowX(Overflow.AUTO);

DockLayoutPanel dockPanel = new DockLayoutPanel(Unit.PX);
dockPanel.getElement().getStyle().setPropertyPx("minHeight", 350);
dockPanel.addSouth(carouselPanel, 350);
dockPanel.add(new ScrollPanel(flexTable));
dockPanel.getWidgetContainerElement(carouselPanel).getStyle().setOverflowX(Overflow.AUTO);

dockPanel.add(new ScrollPanel(content));

centerPanel.add(dockPanel);
centerPanel.getWidgetContainerElement(dockPanel).getStyle().setOverflowY(Overflow.AUTO);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
public class CarouselWidget extends FlexTable implements HasProjectActionEventHandlers,
ProjectActionEventHandler {

public static final int DEFAULT_VISIBLE_RANGE = 5;
public static final int DEFAULT_VISIBLE_RANGE = 3;

private final int initialVisibleRange;
private int visibleRange;
Expand Down Expand Up @@ -67,6 +67,7 @@ public CarouselWidget(int visibleRange) {
goLeftButton.addStyleName(Utils.sandboxStyle.carouselLeftButton());
goLeftButton.setHeight("100px");
goLeftButton.setEnabled(false);
goLeftButton.getElement().getStyle().setMarginRight(25, Style.Unit.PX);
goLeftButton.addClickHandler(new ClickHandler() {
@Override
public void onClick(ClickEvent clickEvent) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public FilterPanel(String title) {

headerItem = new FilterItem<T>(null, Utils.resources.collapse(), null, title);
headerItem.addStyleName(Utils.sandboxStyle.primary());
headerItem.setValue(isExpanded);
headerItem.setValue(false);
headerUl.add(headerItem);
headerItem.addValueChangeHandler(new ValueChangeHandler<Boolean>() {
@Override
Expand All @@ -73,6 +73,7 @@ public void onValueChange(ValueChangeEvent<Boolean> event) {

public void updateItemsHeight() {
itemsUl.getElement().getStyle().setPropertyPx("maxHeight", itemsUl.getElement().getClientHeight());
setExpanded(false);
}

public void setExpanded(boolean expanded) {
Expand Down Expand Up @@ -104,7 +105,6 @@ public void reset() {
itemsUl.remove(item);
}
items.clear();
setExpanded(true);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -611,7 +611,6 @@ nav.navPrimary.collapsed li.primary > a > span.icon > img {
}

.bundleProjectsPanel {
box-shadow: inset 0 8px 8px -8px rgba(0, 0, 0, 0.5);
padding-top: 10px;
padding-bottom: 10px;
}

0 comments on commit d4f02ef

Please sign in to comment.