Skip to content

Commit a410e24

Browse files
committed
Remove unused state booleans
1 parent 99d5a47 commit a410e24

1 file changed

Lines changed: 1 addition & 35 deletions

File tree

android/sdl_android/src/main/java/com/smartdevicelink/managers/lifecycle/LifecycleManager.java

Lines changed: 1 addition & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -69,14 +69,9 @@
6969
*/
7070
@RestrictTo(RestrictTo.Scope.LIBRARY)
7171
public class LifecycleManager extends BaseLifecycleManager {
72-
private static final int RESPONSE_WAIT_TIME = 2000;
7372
private ISdlServiceListener videoServiceListener;
74-
private boolean videoServiceStartResponseReceived = false; //FIXME these statuses should be improved
73+
private boolean videoServiceStartResponseReceived = false;
7574
private boolean videoServiceStartResponse = false;
76-
private boolean videoServiceEndResponseReceived = false;
77-
private boolean videoServiceEndResponse = false;
78-
private boolean audioServiceEndResponseReceived = false;
79-
private boolean audioServiceEndResponse = false;
8075
private WeakReference<Context> contextWeakReference;
8176

8277
public LifecycleManager(AppConfig appConfig, BaseTransportConfig config, LifecycleListener listener) {
@@ -181,30 +176,6 @@ void onStartServiceNACKed(SessionType sessionType) {
181176
}
182177
}
183178

184-
@Override
185-
void onServiceEnded(SessionType sessionType) {
186-
super.onServiceEnded(sessionType);
187-
if (sessionType.eq(SessionType.NAV)) {
188-
videoServiceEndResponseReceived = true;
189-
videoServiceEndResponse = true;
190-
} else if (sessionType.eq(SessionType.PCM)) {
191-
audioServiceEndResponseReceived = true;
192-
audioServiceEndResponse = true;
193-
}
194-
}
195-
196-
@Override
197-
void onStopServiceNACKed(SessionType sessionType) {
198-
super.onStopServiceNACKed(sessionType);
199-
if (sessionType.eq(SessionType.NAV)) {
200-
videoServiceEndResponseReceived = true;
201-
videoServiceEndResponse = false;
202-
} else if (sessionType.eq(SessionType.PCM)) {
203-
audioServiceEndResponseReceived = true;
204-
audioServiceEndResponse = false;
205-
}
206-
}
207-
208179
/**
209180
* This method will try to start the video service with the requested parameters.
210181
* When it returns it will attempt to store the accepted parameters if available.
@@ -311,10 +282,7 @@ void endVideoStream() {
311282
return;
312283
}
313284

314-
videoServiceEndResponseReceived = false;
315-
videoServiceEndResponse = false;
316285
session.stopVideoStream();
317-
318286
}
319287

320288
@Override
@@ -346,8 +314,6 @@ void endAudioStream() {
346314
return;
347315
}
348316

349-
audioServiceEndResponseReceived = false;
350-
audioServiceEndResponse = false;
351317
session.stopAudioStream();
352318
}
353319
}

0 commit comments

Comments
 (0)