Merge pull request #5725 from ByteHamster/smaller-hidden-suggestions

Shrink discovery section when hidden
This commit is contained in:
ByteHamster 2022-02-18 22:14:04 +01:00 committed by GitHub
commit 814d513964
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 5 deletions

View File

@ -119,13 +119,12 @@ public class QuickFeedDiscoveryFragment extends Fragment implements AdapterView.
String countryCode = prefs.getString(ItunesTopListLoader.PREF_KEY_COUNTRY_CODE,
Locale.getDefault().getCountry());
if (countryCode.equals(ItunesTopListLoader.DISCOVER_HIDE_FAKE_COUNTRY_CODE)) {
errorTextView.setText(String.format(getResources().getString(R.string.discover_is_hidden),
getResources().getString(R.string.discover_hide)));
errorTextView.setText(R.string.discover_is_hidden);
errorView.setVisibility(View.VISIBLE);
progressBar.setVisibility(View.GONE);
discoverGridLayout.setVisibility(View.INVISIBLE);
errorRetry.setVisibility(View.INVISIBLE);
poweredByTextView.setVisibility(View.INVISIBLE);
discoverGridLayout.setVisibility(View.GONE);
errorRetry.setVisibility(View.GONE);
poweredByTextView.setVisibility(View.GONE);
return;
}