mirror of
https://github.com/revanced/revanced-integrations.git
synced 2024-12-02 16:52:55 +01:00
fix(YouTube - SponsorBlock): Adjust import/export UI text (#491)
This commit is contained in:
parent
a198ef83dd
commit
4215be4250
@ -72,7 +72,7 @@ public class SponsorBlockSettingsFragment extends PreferenceFragment {
|
||||
} else if (!SettingsEnum.SB_CREATE_NEW_SEGMENT.getBoolean()) {
|
||||
SponsorBlockViewController.hideNewSegmentLayout();
|
||||
}
|
||||
// voting and add new segment buttons automatically shows/hides themselves
|
||||
// Voting and add new segment buttons automatically shows/hide themselves.
|
||||
|
||||
sbEnabled.setChecked(enabled);
|
||||
|
||||
@ -109,6 +109,12 @@ public class SponsorBlockSettingsFragment extends PreferenceFragment {
|
||||
privateUserId.setText(SettingsEnum.SB_PRIVATE_USER_ID.getString());
|
||||
privateUserId.setEnabled(enabled);
|
||||
|
||||
// If the user has a private user id, then include a subtext that mentions not to share it.
|
||||
String exportSummarySubText = SponsorBlockSettings.userHasSBPrivateId()
|
||||
? str("sb_settings_ie_sum_warning")
|
||||
: "";
|
||||
importExport.setSummary(str("sb_settings_ie_sum", exportSummarySubText));
|
||||
|
||||
apiUrl.setEnabled(enabled);
|
||||
importExport.setEnabled(enabled);
|
||||
segmentCategory.setEnabled(enabled);
|
||||
@ -329,6 +335,7 @@ public class SponsorBlockSettingsFragment extends PreferenceFragment {
|
||||
return false;
|
||||
}
|
||||
SettingsEnum.SB_PRIVATE_USER_ID.saveValue(newUUID);
|
||||
updateUI();
|
||||
fetchAndDisplayStats();
|
||||
return true;
|
||||
});
|
||||
@ -375,7 +382,7 @@ public class SponsorBlockSettingsFragment extends PreferenceFragment {
|
||||
}
|
||||
};
|
||||
importExport.setTitle(str("sb_settings_ie"));
|
||||
importExport.setSummary(str("sb_settings_ie_sum"));
|
||||
// Summary is set in updateUI()
|
||||
importExport.getEditText().setInputType(InputType.TYPE_CLASS_TEXT
|
||||
| InputType.TYPE_TEXT_FLAG_MULTI_LINE
|
||||
| InputType.TYPE_TEXT_FLAG_NO_SUGGESTIONS);
|
||||
|
Loading…
Reference in New Issue
Block a user