Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 21c645cd authored by dhacker29's avatar dhacker29 Committed by Danny Baumann
Browse files

Fix WifiHandler for MSim

Commit 7c26a5cc attempted to fix
this issue by adding back the old code, but it needs to be a method
that can be called by MSimNetworkController. So sync it back to caf
to fix the merge issue.

Change-Id: Ifc721cbf372ec50810924d7ac6d55f54663458a1
parent 961fffc4
Loading
Loading
Loading
Loading
+5 −0
Original line number Original line Diff line number Diff line
@@ -195,6 +195,11 @@ public class MSimNetworkController extends NetworkController {
        mLastSimIconId = mMSimLastSimIconId[mDefaultSubscription];
        mLastSimIconId = mMSimLastSimIconId[mDefaultSubscription];
    }
    }


    @Override
    protected Handler createWifiHandler() {
        return new MSimWifiHandler();
    }

    @Override
    @Override
    protected void registerPhoneStateListener(Context context) {
    protected void registerPhoneStateListener(Context context) {
        // telephony
        // telephony
+6 −2
Original line number Original line Diff line number Diff line
@@ -237,7 +237,7 @@ public class NetworkController extends BroadcastReceiver implements DemoMode {


        // wifi
        // wifi
        mWifiManager = (WifiManager) context.getSystemService(Context.WIFI_SERVICE);
        mWifiManager = (WifiManager) context.getSystemService(Context.WIFI_SERVICE);
        Handler handler = new WifiHandler();
        Handler handler = createWifiHandler();
        mWifiChannel = new AsyncChannel();
        mWifiChannel = new AsyncChannel();
        Messenger wifiMessenger = mWifiManager.getWifiServiceMessenger();
        Messenger wifiMessenger = mWifiManager.getWifiServiceMessenger();
        if (wifiMessenger != null) {
        if (wifiMessenger != null) {
@@ -282,6 +282,10 @@ public class NetworkController extends BroadcastReceiver implements DemoMode {
        return (mServiceState != null && mServiceState.isEmergencyOnly());
        return (mServiceState != null && mServiceState.isEmergencyOnly());
    }
    }


    protected Handler createWifiHandler() {
        return new WifiHandler();
    }

    public void addPhoneSignalIconView(ImageView v) {
    public void addPhoneSignalIconView(ImageView v) {
        mPhoneSignalIconViews.add(v);
        mPhoneSignalIconViews.add(v);
    }
    }