Loading services/core/java/com/android/server/NetworkManagementService.java +0 −17 Original line number Diff line number Diff line Loading @@ -186,7 +186,6 @@ public class NetworkManagementService extends INetworkManagementService.Stub private final Handler mFgHandler; private final Handler mDaemonHandler; private final PhoneStateListener mPhoneStateListener; private IBatteryStats mBatteryStats; Loading Loading @@ -283,22 +282,6 @@ public class NetworkManagementService extends INetworkManagementService.Stub mDaemonHandler = new Handler(FgThread.get().getLooper()); mPhoneStateListener = new PhoneStateListener(SubscriptionManager.DEFAULT_SUBSCRIPTION_ID, mDaemonHandler.getLooper()) { @Override public void onDataConnectionRealTimeInfoChanged( DataConnectionRealTimeInfo dcRtInfo) { if (DBG) Slog.d(TAG, "onDataConnectionRealTimeInfoChanged: " + dcRtInfo); notifyInterfaceClassActivity(ConnectivityManager.TYPE_MOBILE, dcRtInfo.getDcPowerState(), dcRtInfo.getTime(), true); } }; TelephonyManager tm = (TelephonyManager)context.getSystemService(Context.TELEPHONY_SERVICE); if (tm != null) { tm.listen(mPhoneStateListener, PhoneStateListener.LISTEN_DATA_CONNECTION_REAL_TIME_INFO); } // Add ourself to the Watchdog monitors. Watchdog.getInstance().addMonitor(this); } Loading services/core/java/com/android/server/TelephonyRegistry.java +0 −36 Original line number Diff line number Diff line Loading @@ -34,7 +34,6 @@ import android.os.Message; import android.os.RemoteException; import android.os.UserHandle; import android.telephony.CellLocation; import android.telephony.DataConnectionRealTimeInfo; import android.telephony.Rlog; import android.telephony.TelephonyManager; import android.telephony.SubscriptionManager; Loading Loading @@ -179,8 +178,6 @@ class TelephonyRegistry extends ITelephonyRegistry.Stub { private int mDefaultPhoneId = SubscriptionManager.INVALID_PHONE_INDEX; private DataConnectionRealTimeInfo mDcRtInfo = new DataConnectionRealTimeInfo(); private int mRingingCallState = PreciseCallState.PRECISE_CALL_STATE_IDLE; private int mForegroundCallState = PreciseCallState.PRECISE_CALL_STATE_IDLE; Loading Loading @@ -624,13 +621,6 @@ class TelephonyRegistry extends ITelephonyRegistry.Stub { remove(r.binder); } } if ((events & PhoneStateListener.LISTEN_DATA_CONNECTION_REAL_TIME_INFO) != 0) { try { r.callback.onDataConnectionRealTimeInfoChanged(mDcRtInfo); } catch (RemoteException ex) { remove(r.binder); } } if ((events & PhoneStateListener.LISTEN_PRECISE_CALL_STATE) != 0) { try { r.callback.onPreciseCallStateChanged(mPreciseCallState); Loading Loading @@ -921,31 +911,6 @@ class TelephonyRegistry extends ITelephonyRegistry.Stub { } } public void notifyDataConnectionRealTimeInfo(DataConnectionRealTimeInfo dcRtInfo) { if (!checkNotifyPermission("notifyDataConnectionRealTimeInfo()")) { return; } synchronized (mRecords) { mDcRtInfo = dcRtInfo; for (Record r : mRecords) { if (validateEventsAndUserLocked(r, PhoneStateListener.LISTEN_DATA_CONNECTION_REAL_TIME_INFO)) { try { if (DBG_LOC) { log("notifyDataConnectionRealTimeInfo: mDcRtInfo=" + mDcRtInfo + " r=" + r); } r.callback.onDataConnectionRealTimeInfoChanged(mDcRtInfo); } catch (RemoteException ex) { mRemoveList.add(r.binder); } } } handleRemoveListLocked(); } } @Override public void notifyMessageWaitingChangedForPhoneId(int phoneId, int subId, boolean mwi) { if (!checkNotifyPermission("notifyMessageWaitingChanged()")) { Loading Loading @@ -1370,7 +1335,6 @@ class TelephonyRegistry extends ITelephonyRegistry.Stub { pw.println(" mCellLocation=" + mCellLocation[i]); pw.println(" mCellInfo=" + mCellInfo.get(i)); } pw.println(" mDcRtInfo=" + mDcRtInfo); pw.println("registrations: count=" + recordCount); for (Record r : mRecords) { pw.println(" " + r); Loading telephony/java/android/telephony/PhoneStateListener.java +3 −1 Original line number Diff line number Diff line Loading @@ -194,10 +194,12 @@ public class PhoneStateListener { * {@more} * Requires Permission: {@link android.Manifest.permission#READ_PRECISE_PHONE_STATE * READ_PRECISE_PHONE_STATE} * * @see #onDataConnectionRealTimeInfoChanged(DataConnectionRealTimeInfo) * * @deprecated Use {@link TelephonyManager#getModemActivityInfo()} * @hide */ @Deprecated public static final int LISTEN_DATA_CONNECTION_REAL_TIME_INFO = 0x00002000; /** Loading telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl +0 −2 Original line number Diff line number Diff line Loading @@ -21,7 +21,6 @@ import android.net.LinkProperties; import android.net.NetworkCapabilities; import android.os.Bundle; import android.telephony.CellInfo; import android.telephony.DataConnectionRealTimeInfo; import android.telephony.ServiceState; import android.telephony.SignalStrength; import android.telephony.CellInfo; Loading Loading @@ -65,7 +64,6 @@ interface ITelephonyRegistry { void notifyPreciseDataConnectionFailed(String reason, String apnType, String apn, String failCause); void notifyCellInfoForSubscriber(in int subId, in List<CellInfo> cellInfo); void notifyDataConnectionRealTimeInfo(in DataConnectionRealTimeInfo dcRtInfo); void notifyVoLteServiceStateChanged(in VoLteServiceState lteState); void notifyOemHookRawEventForSubscriber(in int subId, in byte[] rawData); void notifySubscriptionInfoChanged(); Loading Loading
services/core/java/com/android/server/NetworkManagementService.java +0 −17 Original line number Diff line number Diff line Loading @@ -186,7 +186,6 @@ public class NetworkManagementService extends INetworkManagementService.Stub private final Handler mFgHandler; private final Handler mDaemonHandler; private final PhoneStateListener mPhoneStateListener; private IBatteryStats mBatteryStats; Loading Loading @@ -283,22 +282,6 @@ public class NetworkManagementService extends INetworkManagementService.Stub mDaemonHandler = new Handler(FgThread.get().getLooper()); mPhoneStateListener = new PhoneStateListener(SubscriptionManager.DEFAULT_SUBSCRIPTION_ID, mDaemonHandler.getLooper()) { @Override public void onDataConnectionRealTimeInfoChanged( DataConnectionRealTimeInfo dcRtInfo) { if (DBG) Slog.d(TAG, "onDataConnectionRealTimeInfoChanged: " + dcRtInfo); notifyInterfaceClassActivity(ConnectivityManager.TYPE_MOBILE, dcRtInfo.getDcPowerState(), dcRtInfo.getTime(), true); } }; TelephonyManager tm = (TelephonyManager)context.getSystemService(Context.TELEPHONY_SERVICE); if (tm != null) { tm.listen(mPhoneStateListener, PhoneStateListener.LISTEN_DATA_CONNECTION_REAL_TIME_INFO); } // Add ourself to the Watchdog monitors. Watchdog.getInstance().addMonitor(this); } Loading
services/core/java/com/android/server/TelephonyRegistry.java +0 −36 Original line number Diff line number Diff line Loading @@ -34,7 +34,6 @@ import android.os.Message; import android.os.RemoteException; import android.os.UserHandle; import android.telephony.CellLocation; import android.telephony.DataConnectionRealTimeInfo; import android.telephony.Rlog; import android.telephony.TelephonyManager; import android.telephony.SubscriptionManager; Loading Loading @@ -179,8 +178,6 @@ class TelephonyRegistry extends ITelephonyRegistry.Stub { private int mDefaultPhoneId = SubscriptionManager.INVALID_PHONE_INDEX; private DataConnectionRealTimeInfo mDcRtInfo = new DataConnectionRealTimeInfo(); private int mRingingCallState = PreciseCallState.PRECISE_CALL_STATE_IDLE; private int mForegroundCallState = PreciseCallState.PRECISE_CALL_STATE_IDLE; Loading Loading @@ -624,13 +621,6 @@ class TelephonyRegistry extends ITelephonyRegistry.Stub { remove(r.binder); } } if ((events & PhoneStateListener.LISTEN_DATA_CONNECTION_REAL_TIME_INFO) != 0) { try { r.callback.onDataConnectionRealTimeInfoChanged(mDcRtInfo); } catch (RemoteException ex) { remove(r.binder); } } if ((events & PhoneStateListener.LISTEN_PRECISE_CALL_STATE) != 0) { try { r.callback.onPreciseCallStateChanged(mPreciseCallState); Loading Loading @@ -921,31 +911,6 @@ class TelephonyRegistry extends ITelephonyRegistry.Stub { } } public void notifyDataConnectionRealTimeInfo(DataConnectionRealTimeInfo dcRtInfo) { if (!checkNotifyPermission("notifyDataConnectionRealTimeInfo()")) { return; } synchronized (mRecords) { mDcRtInfo = dcRtInfo; for (Record r : mRecords) { if (validateEventsAndUserLocked(r, PhoneStateListener.LISTEN_DATA_CONNECTION_REAL_TIME_INFO)) { try { if (DBG_LOC) { log("notifyDataConnectionRealTimeInfo: mDcRtInfo=" + mDcRtInfo + " r=" + r); } r.callback.onDataConnectionRealTimeInfoChanged(mDcRtInfo); } catch (RemoteException ex) { mRemoveList.add(r.binder); } } } handleRemoveListLocked(); } } @Override public void notifyMessageWaitingChangedForPhoneId(int phoneId, int subId, boolean mwi) { if (!checkNotifyPermission("notifyMessageWaitingChanged()")) { Loading Loading @@ -1370,7 +1335,6 @@ class TelephonyRegistry extends ITelephonyRegistry.Stub { pw.println(" mCellLocation=" + mCellLocation[i]); pw.println(" mCellInfo=" + mCellInfo.get(i)); } pw.println(" mDcRtInfo=" + mDcRtInfo); pw.println("registrations: count=" + recordCount); for (Record r : mRecords) { pw.println(" " + r); Loading
telephony/java/android/telephony/PhoneStateListener.java +3 −1 Original line number Diff line number Diff line Loading @@ -194,10 +194,12 @@ public class PhoneStateListener { * {@more} * Requires Permission: {@link android.Manifest.permission#READ_PRECISE_PHONE_STATE * READ_PRECISE_PHONE_STATE} * * @see #onDataConnectionRealTimeInfoChanged(DataConnectionRealTimeInfo) * * @deprecated Use {@link TelephonyManager#getModemActivityInfo()} * @hide */ @Deprecated public static final int LISTEN_DATA_CONNECTION_REAL_TIME_INFO = 0x00002000; /** Loading
telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl +0 −2 Original line number Diff line number Diff line Loading @@ -21,7 +21,6 @@ import android.net.LinkProperties; import android.net.NetworkCapabilities; import android.os.Bundle; import android.telephony.CellInfo; import android.telephony.DataConnectionRealTimeInfo; import android.telephony.ServiceState; import android.telephony.SignalStrength; import android.telephony.CellInfo; Loading Loading @@ -65,7 +64,6 @@ interface ITelephonyRegistry { void notifyPreciseDataConnectionFailed(String reason, String apnType, String apn, String failCause); void notifyCellInfoForSubscriber(in int subId, in List<CellInfo> cellInfo); void notifyDataConnectionRealTimeInfo(in DataConnectionRealTimeInfo dcRtInfo); void notifyVoLteServiceStateChanged(in VoLteServiceState lteState); void notifyOemHookRawEventForSubscriber(in int subId, in byte[] rawData); void notifySubscriptionInfoChanged(); Loading