mirror of https://github.com/M66B/FairEmail.git
Prevent showing wrong html
This commit is contained in:
parent
32651f48f8
commit
cf777f3966
|
@ -1398,10 +1398,16 @@ public class AdapterMessage extends RecyclerView.Adapter<AdapterMessage.ViewHold
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onExecuted(Bundle args, String html) {
|
protected void onExecuted(Bundle args, String html) {
|
||||||
properties.setHtml(message.id, html);
|
long id = args.getLong("id");
|
||||||
|
properties.setHtml(id, html);
|
||||||
|
|
||||||
|
TupleMessageEx amessage = getMessage();
|
||||||
|
if (amessage == null || !amessage.id.equals(id))
|
||||||
|
return;
|
||||||
|
|
||||||
webView.loadDataWithBaseURL("email://", html, "text/html", "UTF-8", null);
|
webView.loadDataWithBaseURL("email://", html, "text/html", "UTF-8", null);
|
||||||
|
|
||||||
boolean expanded = properties.getValue("expanded", message.id);
|
boolean expanded = properties.getValue("expanded", id);
|
||||||
pbBody.setVisibility(View.GONE);
|
pbBody.setVisibility(View.GONE);
|
||||||
webView.setVisibility(expanded ? View.VISIBLE : View.GONE);
|
webView.setVisibility(expanded ? View.VISIBLE : View.GONE);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue