Use telecom.Connection state for WFC StatusHint.

Attempting another rewrite of this logic, since the existence of
the original connection seemed to be inconsistent.

Instead, leverage other mechanisms to identify whether the call is
"incoming" or "active. Originally, I wanted to just check for
getState() == STATE_RINGING, but this seemed to be skipped.
Using isValidRingingCall() instead worked correctly though.

This is more consistent and fixes some janky SIP/account status
label formatting which used to be happening.

I'm not sure if it's necessary, but it also seemed safer to update
the status hints after class-level status update as well.

Bug: 19995266
Bug: 19970744
Change-Id: I5885da7ca6cb93e163a558f42c594d29b191c03c
diff --git a/src/com/android/services/telephony/TelephonyConnection.java b/src/com/android/services/telephony/TelephonyConnection.java
index 3d9a7e0..ac384fd 100644
--- a/src/com/android/services/telephony/TelephonyConnection.java
+++ b/src/com/android/services/telephony/TelephonyConnection.java
@@ -670,6 +670,7 @@
                     break;
             }
         }
+        updateStatusHints();
         updateConnectionCapabilities();
         updateAddress();
         updateMultiparty();
@@ -869,10 +870,9 @@
     }
 
     private void updateStatusHints() {
-        if (mIsWifi && mOriginalConnection != null &&
-                (mOriginalConnection.getState() == Call.State.INCOMING
-                        || mOriginalConnection.getState() == Call.State.ACTIVE)) {
-            int labelId = mOriginalConnection.getState() == Call.State.INCOMING
+        boolean isIncoming = isValidRingingCall();
+        if (mIsWifi && (isIncoming || getState() == STATE_ACTIVE)) {
+            int labelId = isIncoming
                     ? R.string.status_hint_label_incoming_wifi_call
                     : R.string.status_hint_label_wifi_call;