mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-09-30 01:16:40 +00:00
Did some cleanup by removing unnecessary code
This commit is contained in:
+1
-5
@@ -56,11 +56,7 @@ public class RegattaOverviewTabView extends Composite implements RegattaTabView<
|
||||
|
||||
@Override
|
||||
public TabView.State getState() {
|
||||
if (currentPresenter.getEventDTO().getType() == EventType.MULTI_REGATTA) {
|
||||
return State.VISIBLE;
|
||||
} else {
|
||||
return State.VISIBLE;
|
||||
}
|
||||
return State.VISIBLE;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
-6
@@ -7,7 +7,6 @@ import com.google.gwt.dom.client.Style.Display;
|
||||
import com.google.gwt.uibinder.client.UiBinder;
|
||||
import com.google.gwt.uibinder.client.UiField;
|
||||
import com.sap.sailing.gwt.home.communication.race.SimpleRaceMetadataDTO;
|
||||
import com.sap.sailing.gwt.home.communication.race.SimpleRaceMetadataDTO.RaceTrackingState;
|
||||
import com.sap.sailing.gwt.home.shared.partials.regattacompetition.AbstractRegattaCompetitionFleetRace;
|
||||
import com.sap.sailing.gwt.home.shared.partials.regattacompetition.RegattaCompetitionPresenter;
|
||||
|
||||
@@ -67,9 +66,4 @@ public class RegattaCompetitionFleetRace extends AbstractRegattaCompetitionFleet
|
||||
return local_res.css().regattacompetition_phase_fleet_raceuntracked();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean isUntrackedRace(RaceTrackingState trackingState) {
|
||||
return super.isUntrackedRace(trackingState);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
+1
-7
@@ -72,8 +72,7 @@ public abstract class AbstractRegattaCompetitionFleetRace extends Widget impleme
|
||||
}
|
||||
|
||||
private void setupRaceState(RaceTrackingState trackingState, RaceViewState viewState) {
|
||||
// boolean isUntrackedRace = trackingState != RaceTrackingState.TRACKED_VALID_DATA;
|
||||
boolean isUntrackedRace = isUntrackedRace(trackingState);
|
||||
boolean isUntrackedRace = trackingState != RaceTrackingState.TRACKED_VALID_DATA;
|
||||
if (viewState == RaceViewState.RUNNING) {
|
||||
mainElement.addClassName(getRaceLiveStyleName());
|
||||
getRaceStateUiElement().setInnerText(isUntrackedRace ? I18N.live() : I18N.actionWatch());
|
||||
@@ -109,9 +108,4 @@ public abstract class AbstractRegattaCompetitionFleetRace extends Widget impleme
|
||||
|
||||
protected abstract String getRaceUntrackedStyleName();
|
||||
|
||||
// TODO: As long as there is no mobile race viewer, show all races as untracked
|
||||
// This is a temporary method to be able to fulfill this requirement
|
||||
protected boolean isUntrackedRace(RaceTrackingState trackingState) {
|
||||
return trackingState != RaceTrackingState.TRACKED_VALID_DATA;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user