Fixed NPE in map controls
This commit is contained in:
parent
15ca02abbf
commit
6b7474601b
1 changed files with 10 additions and 6 deletions
|
@ -112,12 +112,16 @@ public abstract class MapControls {
|
|||
|
||||
protected void removeButton(final FrameLayout layout, final View b) {
|
||||
b.setVisibility(View.GONE);
|
||||
|
||||
if (layout.getHandler() != null){
|
||||
layout.getHandler().post(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
layout.removeView(b);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
mapActivity.accessibleContent.remove(b);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue