Merge "[Provider Model] Show searching sub-title only when the Wi-Fi network is empty" into sc-dev

This commit is contained in:
TreeHugger Robot
2021-05-12 06:54:02 +00:00
committed by Android (Google) Code Review
2 changed files with 7 additions and 6 deletions

View File

@@ -322,11 +322,13 @@ public class InternetConnectivityPanel implements PanelContent, LifecycleObserve
final List<ScanResult> wifiList = mWifiManager.getScanResults();
if (wifiList != null && wifiList.size() != 0) {
if (mIsProgressBarVisible) {
// When the Wi-Fi scan result callback is received
// Sub-Title: Searching for networks...
mSubtitle = SUBTITLE_TEXT_SEARCHING_FOR_NETWORKS;
}
return;
}
if (mIsProgressBarVisible) {
// When the Wi-Fi scan result callback is received
// Sub-Title: Searching for networks...
mSubtitle = SUBTITLE_TEXT_SEARCHING_FOR_NETWORKS;
return;
}

View File

@@ -360,7 +360,6 @@ public class InternetConnectivityPanelTest {
assertThat(mPanel.isProgressBarVisible()).isTrue();
verify(mPanelContentCallback).onProgressBarVisibleChanged();
verify(mPanelContentCallback).onHeaderChanged();
verify(mMainThreadHandler).postDelayed(any() /* mHideProgressBarRunnable */, anyLong());
}