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

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

Merge "Implement receiver flow of WiFi sharing feature II"

parents 18873b92 8ff2852f
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -2071,6 +2071,8 @@
    <string name="wifi_dpp_scan_qr_code">Scan QR code</string>
    <!-- Hint for the user to center another device's QR code in the below camera window [CHAR LIMIT=NONE] -->
    <string name="wifi_dpp_scan_qr_code_join_network">Join \u201c<xliff:g id="ssid" example="OfficeWifi">%1$s</xliff:g>\u201d by scanning a QR code</string>
    <!-- Hint for the user to center another device's QR code in the below camera window [CHAR LIMIT=NONE] -->
    <string name="wifi_dpp_scan_qr_code_join_unknown_network">Join Wi\u2011Fi by scanning a QR code</string>
    <!-- Title for the fragment to share Wi-Fi [CHAR LIMIT=50]  -->
    <string name="wifi_dpp_share_wifi">Share Wi\u2011Fi</string>
    <!-- Hint for the user to use another device to scan QR code on screen to join Wi-Fi [CHAR LIMIT=NONE] -->
+1 −1
Original line number Diff line number Diff line
@@ -73,7 +73,7 @@ public class AddNetworkFragment extends InstrumentedFragment implements WifiConf
                scannerButton.setOnClickListener((View v) -> {
                    // Launch QR code scanner to join a network.
                    getContext().startActivity(
                            WifiDppUtils.getConfiguratorQRCodeScannerIntent(/* ssid */ null));
                            WifiDppUtils.getEnrolleeQrCodeScannerIntent(/* ssid */ null));
                });
            }
        }
+5 −1
Original line number Diff line number Diff line
@@ -86,9 +86,13 @@ public class WifiDialog extends AlertDialog implements WifiConfigUiBase,
            if (scannerButton != null) {
                scannerButton.setVisibility(View.VISIBLE);
                scannerButton.setOnClickListener((View v) -> {
                    String ssid = null;
                    if (mAccessPoint != null) {
                        ssid = mAccessPoint.getSsidStr();
                    }
                    // Launch QR code scanner to join a network.
                    getContext().startActivity(
                            WifiDppUtils.getConfiguratorQRCodeScannerIntent(/* ssid */ null));
                            WifiDppUtils.getEnrolleeQrCodeScannerIntent(ssid));
                });
            }
        }
+1 −1
Original line number Diff line number Diff line
@@ -244,7 +244,7 @@ public class WifiSettings extends RestrictedSettingsFragment
            mAddPreference.setButtonOnClickListener((View v) -> {
                // Launch QR code scanner to join a network.
                getContext().startActivity(
                        WifiDppUtils.getConfiguratorQRCodeScannerIntent(/* ssid */ null));
                        WifiDppUtils.getEnrolleeQrCodeScannerIntent(/* ssid */ null));
            });
        }
        mStatusMessagePreference = (LinkablePreference) findPreference(PREF_KEY_STATUS_MESSAGE);
+1 −4
Original line number Diff line number Diff line
@@ -549,11 +549,8 @@ public class WifiDetailPreferenceController extends AbstractPreferenceController
     * Show QR code to share the network represented by this preference.
     */
    public void launchQRCodeGenerator() {
        final Intent intent = new Intent(
                WifiDppConfiguratorActivity.ACTION_CONFIGURATOR_QR_CODE_GENERATOR);
        intent.putExtra(WifiDppUtils.EXTRA_WIFI_SECURITY,
        Intent intent = WifiDppUtils.getConfiguratorQrCodeGeneratorIntent(mAccessPoint.getSsidStr(),
                mAccessPoint.getSecurityString(/* concise */ false));
        intent.putExtra(WifiDppUtils.EXTRA_WIFI_SSID, mAccessPoint.getSsidStr());
        mContext.startActivity(intent);
    }

Loading