Merge branch '5.8-MAINT' into main
This commit is contained in:
commit
beaefd84d0
8 changed files with 27 additions and 5 deletions
|
@ -392,7 +392,7 @@ public class MessagingController {
|
|||
public void refreshFolderListSynchronous(Account account) {
|
||||
try {
|
||||
ServerSettings serverSettings = account.getIncomingServerSettings();
|
||||
if (serverSettings.password == null) {
|
||||
if (serverSettings.isMissingCredentials()) {
|
||||
handleAuthenticationFailure(account, true);
|
||||
return;
|
||||
}
|
||||
|
@ -651,7 +651,7 @@ public class MessagingController {
|
|||
|
||||
private void syncFolder(Account account, long folderId, MessagingListener listener, Backend backend) {
|
||||
ServerSettings serverSettings = account.getIncomingServerSettings();
|
||||
if (serverSettings.password == null) {
|
||||
if (serverSettings.isMissingCredentials()) {
|
||||
handleAuthenticationFailure(account, true);
|
||||
return;
|
||||
}
|
||||
|
@ -1512,7 +1512,7 @@ public class MessagingController {
|
|||
boolean wasPermanentFailure = false;
|
||||
try {
|
||||
ServerSettings serverSettings = account.getOutgoingServerSettings();
|
||||
if (serverSettings.password == null) {
|
||||
if (serverSettings.isMissingCredentials()) {
|
||||
handleAuthenticationFailure(account, false);
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -39,7 +39,7 @@ class MailSyncWorker(
|
|||
return Result.success()
|
||||
}
|
||||
|
||||
if (account.incomingServerSettings.password == null) {
|
||||
if (account.incomingServerSettings.isMissingCredentials) {
|
||||
Timber.d("Password for this account is missing. Skipping mail sync.")
|
||||
return Result.success()
|
||||
}
|
||||
|
|
10
app/ui/legacy/src/main/res/drawable/ic_download.xml
Normal file
10
app/ui/legacy/src/main/res/drawable/ic_download.xml
Normal file
|
@ -0,0 +1,10 @@
|
|||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M5,20h14v-2H5V20zM19,9h-4V3H9v6H5l7,7L19,9z" />
|
||||
</vector>
|
|
@ -90,7 +90,7 @@
|
|||
android:layout_marginBottom="8dp"
|
||||
android:background="?attr/selectableItemBackgroundBorderless"
|
||||
android:contentDescription="@string/remove_attachment_action"
|
||||
app:srcCompat="?attr/iconActionSave"
|
||||
app:srcCompat="?attr/iconActionSaveAttachment"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/attachment_preview" />
|
||||
|
|
|
@ -5,6 +5,10 @@
|
|||
Locale-specific versions are kept in res/raw-<locale qualifier>/changelog.xml.
|
||||
-->
|
||||
<changelog>
|
||||
<release version="5.805" versioncode="28005" date="2021-08-21">
|
||||
<change>Fixed the check for missing incoming/outgoing server credentials (introduced in K-9 Mail 5.804)</change>
|
||||
<change>Changed the 'save attachment' icon (apparently floppy disks are no longer a thing)</change>
|
||||
</release>
|
||||
<release version="5.804" versioncode="28004" date="2021-08-18">
|
||||
<change>Fixed a bug where Push didn't work with some servers</change>
|
||||
<change>Don't connect to the incoming or outgoing server when passwords haven't been provided after import</change>
|
||||
|
|
|
@ -39,6 +39,7 @@
|
|||
<attr name="iconActionUpload" format="reference" />
|
||||
<attr name="iconActionSelectAll" format="reference" />
|
||||
<attr name="iconActionSave" format="reference" />
|
||||
<attr name="iconActionSaveAttachment" format="reference" />
|
||||
<attr name="iconActionCancel" format="reference" />
|
||||
<attr name="iconActionRequestReadReceipt" format="reference" />
|
||||
<attr name="iconActionExpand" format="reference" />
|
||||
|
|
|
@ -53,6 +53,7 @@
|
|||
<item name="iconActionUpload">@drawable/ic_file_upload</item>
|
||||
<item name="iconActionSelectAll">@drawable/ic_select_all</item>
|
||||
<item name="iconActionSave">@drawable/ic_floppy</item>
|
||||
<item name="iconActionSaveAttachment">@drawable/ic_download</item>
|
||||
<item name="iconActionCancel">@drawable/ic_clear</item>
|
||||
<item name="iconActionRequestReadReceipt">@drawable/ic_action_request_read_receipt_light</item>
|
||||
<item name="iconActionExpand">@drawable/ic_chevron_down</item>
|
||||
|
@ -171,6 +172,7 @@
|
|||
<item name="iconActionUpload">@drawable/ic_file_upload</item>
|
||||
<item name="iconActionSelectAll">@drawable/ic_select_all</item>
|
||||
<item name="iconActionSave">@drawable/ic_floppy</item>
|
||||
<item name="iconActionSaveAttachment">@drawable/ic_download</item>
|
||||
<item name="iconActionCancel">@drawable/ic_clear</item>
|
||||
<item name="iconActionRequestReadReceipt">@drawable/ic_action_request_read_receipt_dark</item>
|
||||
<item name="iconActionExpand">@drawable/ic_chevron_down</item>
|
||||
|
|
|
@ -16,6 +16,11 @@ data class ServerSettings @JvmOverloads constructor(
|
|||
@JvmField val clientCertificateAlias: String?,
|
||||
val extra: Map<String, String?> = emptyMap()
|
||||
) {
|
||||
val isMissingCredentials: Boolean = when (authenticationType) {
|
||||
AuthType.EXTERNAL -> clientCertificateAlias == null
|
||||
else -> password == null
|
||||
}
|
||||
|
||||
init {
|
||||
require(type == type.toLowerCase(Locale.ROOT)) { "type must be all lower case" }
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue