mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-25 05:23:51 +00:00
Adjusted component ordering in mobile event overview for single regatta
and series events
This commit is contained in:
1 parent
e079fc8f20
commit
ca67e9c32a
2 files changed
+32
-24
No files matched your search
+1
-1
@@ -4,7 +4,7 @@
|
||||
<ui:with field="i18n" type="com.sap.sailing.gwt.ui.client.StringMessages" />
|
||||
<ui:with field="res" type="com.sap.sailing.gwt.home.mobile.resources.SharedResources" />
|
||||
<ui:with field="local_res" type="com.sap.sailing.gwt.home.mobile.partials.eventsteps.EventStepsResources" />
|
||||
<mp:section.MobileSection addStyleNames="{local_res.css.eventsteps} {res.mediaCss.small12} {res.mediaCss.columns}">
|
||||
<mp:section.MobileSection addStyleNames="{local_res.css.eventsteps}">
|
||||
<mp:header>
|
||||
<mp:sectionHeader.SectionHeaderContent ui:field="sectionHeaderUi" />
|
||||
</mp:header>
|
||||
|
||||
+31
-23
@@ -39,9 +39,18 @@ public class EventViewImpl extends AbstractEventView<EventView.Presenter> implem
|
||||
public EventViewImpl(EventView.Presenter presenter) {
|
||||
super(presenter, false, false);
|
||||
FlowPanel container = new FlowPanel();
|
||||
this.setupOverviewStage(container);
|
||||
this.setupProgress(container);
|
||||
this.setupListContent(container);
|
||||
if (isMultiRegattaEvent()) {
|
||||
this.setupOverviewStage(container);
|
||||
this.setupRegattaStatusList(container);
|
||||
} else {
|
||||
this.setupProgress(container);
|
||||
this.setupLiveRaces(container);
|
||||
this.setupOverviewStage(container);
|
||||
this.setupMiniLeaderboard(container);
|
||||
if (ExperimentalFeatures.SHOW_REGATTA_OVERVIEW_AND_RACES_ON_MOBILE) {
|
||||
initRacesNavigation(container);
|
||||
}
|
||||
}
|
||||
this.setupUpdateBox(container);
|
||||
this.setupImpressions(container);
|
||||
this.setupStatisticsBox(container);
|
||||
@@ -50,8 +59,7 @@ public class EventViewImpl extends AbstractEventView<EventView.Presenter> implem
|
||||
|
||||
private void setupProgress(Panel container) {
|
||||
eventStepsUi = new EventSteps();
|
||||
boolean showRegattaProgress = !isMultiRegattaEvent() && ExperimentalFeatures.SHOW_REGATTA_PROGRESS_ON_MOBILE;
|
||||
if (showRegattaProgress) {
|
||||
if (ExperimentalFeatures.SHOW_REGATTA_PROGRESS_ON_MOBILE) {
|
||||
refreshManager.add(eventStepsUi, new GetRegattaWithProgressAction(getEventId(), getRegattaId()));
|
||||
container.add(eventStepsUi);
|
||||
}
|
||||
@@ -63,27 +71,27 @@ public class EventViewImpl extends AbstractEventView<EventView.Presenter> implem
|
||||
container.add(overviewStageUi);
|
||||
}
|
||||
|
||||
private void setupListContent(Panel container) {
|
||||
if (isMultiRegattaEvent()) {
|
||||
RegattaStatus regattaStatus = new RegattaStatus(currentPresenter);
|
||||
container.add(regattaStatus);
|
||||
refreshManager.add(regattaStatus, new GetRegattasAndLiveRacesForEventAction(getEventId()));
|
||||
} else {
|
||||
if (ExperimentalFeatures.SHOW_REGATTA_LIVE_RACES_ON_MOBILE) {
|
||||
liveRacesUi = new RegattaLiveRaces();
|
||||
refreshManager.add(liveRacesUi, new GetLiveRacesForRegattaAction(getEventId(), getRegattaId()));
|
||||
container.add(liveRacesUi);
|
||||
}
|
||||
MinileaderboardBox miniLeaderboard = new MinileaderboardBox(false);
|
||||
miniLeaderboard.setAction(MSG.showAll(), currentPresenter.getRegattaMiniLeaderboardNavigation(getRegattaId()));
|
||||
refreshManager.add(miniLeaderboard, new GetMiniLeaderbordAction(getEventId(), getRegattaId(), 3));
|
||||
container.add(miniLeaderboard);
|
||||
if (ExperimentalFeatures.SHOW_REGATTA_OVERVIEW_AND_RACES_ON_MOBILE) {
|
||||
initRacesNavigation(container);
|
||||
}
|
||||
private void setupRegattaStatusList(Panel container) {
|
||||
RegattaStatus regattaStatus = new RegattaStatus(currentPresenter);
|
||||
container.add(regattaStatus);
|
||||
refreshManager.add(regattaStatus, new GetRegattasAndLiveRacesForEventAction(getEventId()));
|
||||
}
|
||||
|
||||
private void setupLiveRaces(Panel container) {
|
||||
if (ExperimentalFeatures.SHOW_REGATTA_LIVE_RACES_ON_MOBILE) {
|
||||
liveRacesUi = new RegattaLiveRaces();
|
||||
refreshManager.add(liveRacesUi, new GetLiveRacesForRegattaAction(getEventId(), getRegattaId()));
|
||||
container.add(liveRacesUi);
|
||||
}
|
||||
}
|
||||
|
||||
private void setupMiniLeaderboard(Panel container) {
|
||||
MinileaderboardBox miniLeaderboard = new MinileaderboardBox(false);
|
||||
miniLeaderboard.setAction(MSG.showAll(), currentPresenter.getRegattaMiniLeaderboardNavigation(getRegattaId()));
|
||||
refreshManager.add(miniLeaderboard, new GetMiniLeaderbordAction(getEventId(), getRegattaId(), 3));
|
||||
container.add(miniLeaderboard);
|
||||
}
|
||||
|
||||
private void setupUpdateBox(Panel container) {
|
||||
updatesBoxUi = new UpdatesBox(currentPresenter, refreshManager);
|
||||
if (currentPresenter.getCtx().getEventDTO().getState() == EventState.RUNNING) {
|
||||
|
||||
Reference in new issue
Block a user