@Override public void recordDisconnectTime() { if (MovieUtils.isRtspOrSdp(getPlayer().getVideoType())) { // record the time disconnect from server mLastDisconnectTime = System.currentTimeMillis(); } if (LOG) { Log.v(TAG, "recordDisconnectTime() mLastDisconnectTime=" + mLastDisconnectTime); } }
private boolean passDisconnectCheck() { if (MovieUtils.isRtspOrSdp(getPlayer().getVideoType())) { // record the time disconnect from server long now = System.currentTimeMillis(); if (LOG) { Log.v( TAG, "passDisconnectCheck() now=" + now + ", mLastDisconnectTime=" + mLastDisconnectTime + ", mServerTimeout=" + mServerTimeout); } if (mServerTimeout > 0 && (now - mLastDisconnectTime) > mServerTimeout) { // disconnect time more than server timeout, notify user notifyServerTimeout(); return false; } } return true; }