allow base cast manager to save information of wifi network when it connects

This commit is contained in:
Domingos Lopes 2016-04-17 16:25:42 -04:00
parent c4b25269de
commit b3fbc5258e
1 changed files with 16 additions and 0 deletions

View File

@ -128,6 +128,7 @@ public class CastManager extends BaseCastManager implements OnFailedListener {
CastConfiguration castConfiguration = new CastConfiguration.Builder(CAST_APP_ID)
.enableDebug()
.enableAutoReconnect()
.enableWifiReconnection()
.setLaunchOptions(true, Locale.getDefault())
.build();
Log.d(TAG, "New instance of CastManager is created");
@ -1736,4 +1737,19 @@ public class CastManager extends BaseCastManager implements OnFailedListener {
}
return mediaRouteActionProvider;
}
/* (non-Javadoc)
* These methods startReconnectionService and stopReconnectionService simply override the ones
* from BaseCastManager with empty implementations because we handle the service ourselves, but
* need to allow BaseCastManager to save current network information.
*/
@Override
protected void startReconnectionService(long mediaDurationLeft) {
// Do nothing
}
@Override
protected void stopReconnectionService() {
// Do nothing
}
}