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

Commit 6e245f47 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Fix Settings crash after clicking 'Share Wi-Fi' button"

parents 5d0d664a 730a6c0f
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -156,7 +156,7 @@ public class WifiDppConfiguratorActivity extends InstrumentedActivity implements
                    cancelActivity = true;
                } else {
                    final WifiNetworkConfig connectedConfig = getConnectedWifiNetworkConfigOrNull();
                    if (connectedConfig == null) {
                    if (connectedConfig == null || !connectedConfig.isSupportWifiDpp(this)) {
                        showChooseSavedWifiNetworkFragment(/* addToBackStack */ false);
                    } else {
                        mWifiNetworkConfig = connectedConfig;
+1 −1
Original line number Diff line number Diff line
@@ -86,7 +86,7 @@ public class WifiDppQrCodeGeneratorFragment extends WifiDppQrCodeBaseFragment {
    public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
        final WifiNetworkConfig wifiNetworkConfig = getWifiNetworkConfigFromHostActivity();
        MenuItem menuItem;
        if (wifiNetworkConfig.isSupportConfiguratorQrCodeScanner(getActivity())) {
        if (wifiNetworkConfig.isSupportWifiDpp(getActivity())) {
            menuItem = menu.add(0, Menu.FIRST, 0, R.string.next_label);
            menuItem.setIcon(R.drawable.ic_scan_24dp);
            menuItem.setShowAsAction(MenuItem.SHOW_AS_ACTION_ALWAYS);
+1 −1
Original line number Diff line number Diff line
@@ -212,7 +212,7 @@ public class WifiNetworkConfig {
        wifiManager.connect(wifiConfiguration, listener);
    }

    public boolean isSupportConfiguratorQrCodeScanner(Context context) {
    public boolean isSupportWifiDpp(Context context) {
        if (!WifiDppUtils.isWifiDppEnabled(context)) {
            return false;
        }