synchronized around cache clear in avatar service
This commit is contained in:
parent
c058594ff5
commit
283d5058e5
|
@ -58,11 +58,13 @@ public class AvatarService {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void clear(Contact contact) {
|
public void clear(Contact contact) {
|
||||||
|
synchronized (this.sizes) {
|
||||||
for (Integer size : sizes) {
|
for (Integer size : sizes) {
|
||||||
this.mXmppConnectionService.getBitmapCache().remove(
|
this.mXmppConnectionService.getBitmapCache().remove(
|
||||||
key(contact, size));
|
key(contact, size));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private String key(Contact contact, int size) {
|
private String key(Contact contact, int size) {
|
||||||
synchronized (this.sizes) {
|
synchronized (this.sizes) {
|
||||||
|
@ -150,11 +152,13 @@ public class AvatarService {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void clear(MucOptions options) {
|
public void clear(MucOptions options) {
|
||||||
|
synchronized (this.sizes) {
|
||||||
for (Integer size : sizes) {
|
for (Integer size : sizes) {
|
||||||
this.mXmppConnectionService.getBitmapCache().remove(
|
this.mXmppConnectionService.getBitmapCache().remove(
|
||||||
key(options, size));
|
key(options, size));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private String key(MucOptions options, int size) {
|
private String key(MucOptions options, int size) {
|
||||||
synchronized (this.sizes) {
|
synchronized (this.sizes) {
|
||||||
|
@ -182,11 +186,13 @@ public class AvatarService {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void clear(Account account) {
|
public void clear(Account account) {
|
||||||
|
synchronized (this.sizes) {
|
||||||
for (Integer size : sizes) {
|
for (Integer size : sizes) {
|
||||||
this.mXmppConnectionService.getBitmapCache().remove(
|
this.mXmppConnectionService.getBitmapCache().remove(
|
||||||
key(account, size));
|
key(account, size));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private String key(Account account, int size) {
|
private String key(Account account, int size) {
|
||||||
synchronized (this.sizes) {
|
synchronized (this.sizes) {
|
||||||
|
|
4
src/main/res/menu/muc_details_context.xml
Normal file
4
src/main/res/menu/muc_details_context.xml
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<menu xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
</menu>
|
Loading…
Reference in a new issue