mirror of
https://github.com/moparisthebest/k-9
synced 2024-11-30 13:12:25 -05:00
refactor display of the download button
This commit is contained in:
parent
9deea33426
commit
abc921093c
@ -1185,7 +1185,7 @@ public class MessageView extends K9Activity implements OnClickListener {
|
||||
|
||||
@Override
|
||||
public void loadMessageForViewFinished(Account account, String folder, String uid,
|
||||
Message message) {
|
||||
final Message message) {
|
||||
if (!mMessageReference.uid.equals(uid) || !mMessageReference.folderName.equals(folder)
|
||||
|| !mMessageReference.accountUuid.equals(account.getUuid())) {
|
||||
return;
|
||||
@ -1193,6 +1193,7 @@ public class MessageView extends K9Activity implements OnClickListener {
|
||||
mHandler.post(new Runnable() {
|
||||
public void run() {
|
||||
setProgressBarIndeterminateVisibility(false);
|
||||
mMessageView.setShowDownloadButton(message);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -96,6 +96,9 @@ public class SingleMessageView extends LinearLayout {
|
||||
} catch (Exception me) {
|
||||
Log.e(K9.LOG_TAG, "setHeaders - error", me);
|
||||
}
|
||||
}
|
||||
|
||||
public void setShowDownloadButton(Message message) {
|
||||
if (message.isSet(Flag.X_DOWNLOADED_FULL)) {
|
||||
mDownloadRemainder.setVisibility(View.GONE);
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user