1
0
mirror of https://github.com/KokaKiwi/BarInsta synced 2024-12-23 05:16:58 +00:00

add material design icons attribution

This commit is contained in:
Austin Huang 2020-09-19 23:25:16 -04:00
parent f9f3d4620b
commit 6aead8ff2b
No known key found for this signature in database
GPG Key ID: 84C23AA04587A91F

View File

@ -29,12 +29,13 @@ public class AboutFragment extends BasePreferencesFragment {
final PreferenceCategory thirdPartyCategory = new PreferenceCategory(context);
screen.addPreference(thirdPartyCategory);
thirdPartyCategory.setTitle(R.string.about_category_3pt);
thirdPartyCategory.setSummary(R.string.about_category_3pt_summary);
//thirdPartyCategory.setSummary(R.string.about_category_3pt_summary);
thirdPartyCategory.setIconSpaceReserved(false);
// alphabetical order!!!
thirdPartyCategory.addPreference(getExoPlayerPreference());
thirdPartyCategory.addPreference(getFrescoPreference());
thirdPartyCategory.addPreference(getJsoupPreference());
thirdPartyCategory.addPreference(getMDIPreference());
thirdPartyCategory.addPreference(getRetrofitPreference());
final PreferenceCategory licenseCategory = new PreferenceCategory(context);
@ -157,6 +158,22 @@ public class AboutFragment extends BasePreferencesFragment {
return preference;
}
private Preference getMDIPreference() {
final Context context = getContext();
if (context == null) return null;
final Preference preference = new Preference(context);
preference.setTitle("Material Design Icons");
preference.setSummary("Copyright (C) 2014 Austin Andrews & Google LLC. Apache Version 2.0.");
preference.setIconSpaceReserved(false);
preference.setOnPreferenceClickListener(p -> {
final Intent intent = new Intent(Intent.ACTION_VIEW);
intent.setData(Uri.parse("https://exoplayer.dev/"));
startActivity(intent);
return true;
});
return preference;
}
private Preference getLicensePreference() {
final Context context = getContext();
if (context == null) return null;