Loading android/app/src/com/android/bluetooth/hfpclient/HeadsetClientStateMachine.java +4 −11 Original line number Original line Diff line number Diff line Loading @@ -1224,19 +1224,12 @@ public class HeadsetClientStateMachine extends StateMachine { } } break; break; case QUERY_CURRENT_CALLS: case QUERY_CURRENT_CALLS: // Whenever the timer expires we query calls if there are outstanding requests // for query calls. long currentElapsed = SystemClock.elapsedRealtime(); if (mClccTimer < currentElapsed) { queryCallsStart(); mClccTimer = currentElapsed + QUERY_CURRENT_CALLS_WAIT_MILLIS; // Request satisfied, ignore all other call query messages. removeMessages(QUERY_CURRENT_CALLS); } else { // Replace all messages with one concrete message. removeMessages(QUERY_CURRENT_CALLS); removeMessages(QUERY_CURRENT_CALLS); if (mCalls.size() > 0) { // If there are ongoing calls periodically check their status. sendMessageDelayed(QUERY_CURRENT_CALLS, QUERY_CURRENT_CALLS_WAIT_MILLIS); sendMessageDelayed(QUERY_CURRENT_CALLS, QUERY_CURRENT_CALLS_WAIT_MILLIS); } } queryCallsStart(); break; break; case StackEvent.STACK_EVENT: case StackEvent.STACK_EVENT: Intent intent = null; Intent intent = null; Loading Loading
android/app/src/com/android/bluetooth/hfpclient/HeadsetClientStateMachine.java +4 −11 Original line number Original line Diff line number Diff line Loading @@ -1224,19 +1224,12 @@ public class HeadsetClientStateMachine extends StateMachine { } } break; break; case QUERY_CURRENT_CALLS: case QUERY_CURRENT_CALLS: // Whenever the timer expires we query calls if there are outstanding requests // for query calls. long currentElapsed = SystemClock.elapsedRealtime(); if (mClccTimer < currentElapsed) { queryCallsStart(); mClccTimer = currentElapsed + QUERY_CURRENT_CALLS_WAIT_MILLIS; // Request satisfied, ignore all other call query messages. removeMessages(QUERY_CURRENT_CALLS); } else { // Replace all messages with one concrete message. removeMessages(QUERY_CURRENT_CALLS); removeMessages(QUERY_CURRENT_CALLS); if (mCalls.size() > 0) { // If there are ongoing calls periodically check their status. sendMessageDelayed(QUERY_CURRENT_CALLS, QUERY_CURRENT_CALLS_WAIT_MILLIS); sendMessageDelayed(QUERY_CURRENT_CALLS, QUERY_CURRENT_CALLS_WAIT_MILLIS); } } queryCallsStart(); break; break; case StackEvent.STACK_EVENT: case StackEvent.STACK_EVENT: Intent intent = null; Intent intent = null; Loading