Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
7cbdaa6161
1 changed files with 10 additions and 11 deletions
|
@ -276,15 +276,14 @@ public class MapActivityLayers {
|
|||
app.getSettings().isLightContent());
|
||||
final ListView listView = new ListView(activity);
|
||||
listView.setDivider(null);
|
||||
listView.setClickable(true);
|
||||
listView.setAdapter(listAdapter);
|
||||
listView.setOnItemClickListener(
|
||||
new ListView.OnItemClickListener() {
|
||||
listView.setOnItemClickListener(new ListView.OnItemClickListener() {
|
||||
@Override
|
||||
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
|
||||
ContextMenuItem item = listAdapter.getItem(position);
|
||||
PoiUIFilter filter = list.get(position);
|
||||
boolean isChecked = getApplication().getPoiFilters().isPoiFilterSelected(filter);
|
||||
item.getItemClickListener().onContextMenuClick(listAdapter, position, position, !isChecked);
|
||||
item.setSelected(!item.getSelected());
|
||||
item.getItemClickListener().onContextMenuClick(listAdapter, position, position, item.getSelected());
|
||||
listAdapter.notifyDataSetChanged();
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue