Add button to always refresh over mobile data
This commit is contained in:
parent
60e2c2e113
commit
5cf6051d88
|
@ -123,7 +123,7 @@ public class AutoUpdateManager {
|
||||||
Log.d(TAG, "Run auto update immediately in background.");
|
Log.d(TAG, "Run auto update immediately in background.");
|
||||||
if (!NetworkUtils.networkAvailable()) {
|
if (!NetworkUtils.networkAvailable()) {
|
||||||
Log.d(TAG, "Ignoring: No network connection.");
|
Log.d(TAG, "Ignoring: No network connection.");
|
||||||
} else if (NetworkUtils.isEpisodeDownloadAllowed()) {
|
} else if (NetworkUtils.isFeedRefreshAllowed()) {
|
||||||
startRefreshAllFeeds(context);
|
startRefreshAllFeeds(context);
|
||||||
} else {
|
} else {
|
||||||
confirmMobileAllFeedsRefresh(context);
|
confirmMobileAllFeedsRefresh(context);
|
||||||
|
@ -134,8 +134,12 @@ public class AutoUpdateManager {
|
||||||
AlertDialog.Builder builder = new AlertDialog.Builder(context)
|
AlertDialog.Builder builder = new AlertDialog.Builder(context)
|
||||||
.setTitle(R.string.feed_refresh_title)
|
.setTitle(R.string.feed_refresh_title)
|
||||||
.setMessage(R.string.confirm_mobile_feed_refresh_dialog_message)
|
.setMessage(R.string.confirm_mobile_feed_refresh_dialog_message)
|
||||||
.setPositiveButton(R.string.yes,
|
.setPositiveButton(R.string.confirm_mobile_streaming_button_once,
|
||||||
(dialog, which) -> startRefreshAllFeeds(context))
|
(dialog, which) -> startRefreshAllFeeds(context))
|
||||||
|
.setNeutralButton(R.string.confirm_mobile_streaming_button_always, (dialog, which) -> {
|
||||||
|
UserPreferences.setAllowMobileFeedRefresh(true);
|
||||||
|
startRefreshAllFeeds(context);
|
||||||
|
})
|
||||||
.setNegativeButton(R.string.no, null);
|
.setNegativeButton(R.string.no, null);
|
||||||
builder.show();
|
builder.show();
|
||||||
}
|
}
|
||||||
|
|
|
@ -188,7 +188,7 @@
|
||||||
</plurals>
|
</plurals>
|
||||||
<string name="edit_tags">Edit tags</string>
|
<string name="edit_tags">Edit tags</string>
|
||||||
<string name="rename_tag_label">Rename tag</string>
|
<string name="rename_tag_label">Rename tag</string>
|
||||||
<string name="confirm_mobile_feed_refresh_dialog_message">Downloading episodes over mobile data connection is disabled in the settings.\n\nDo you still want to refresh all podcasts over mobile data?</string>
|
<string name="confirm_mobile_feed_refresh_dialog_message">Refreshing podcasts over mobile data connection is disabled in the settings.\n\nDo you want to refresh anyway?</string>
|
||||||
|
|
||||||
<!-- actions on feeditems -->
|
<!-- actions on feeditems -->
|
||||||
<string name="download_label">Download</string>
|
<string name="download_label">Download</string>
|
||||||
|
|
Loading…
Reference in New Issue