Side sliders no longer owerlap with checkboxes #1657
This commit is contained in:
parent
c31bd9eea5
commit
7bc3a4e75e
4 changed files with 76 additions and 76 deletions
|
@ -1,10 +1,11 @@
|
||||||
package net.osmand.plus.activities;
|
package net.osmand.plus.activities;
|
||||||
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import android.content.DialogInterface;
|
||||||
import java.util.LinkedHashMap;
|
import android.content.Intent;
|
||||||
import java.util.List;
|
import android.support.v7.app.AlertDialog;
|
||||||
import java.util.Map.Entry;
|
import android.widget.ListAdapter;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
import net.osmand.CallbackWithObject;
|
import net.osmand.CallbackWithObject;
|
||||||
import net.osmand.ResultMatcher;
|
import net.osmand.ResultMatcher;
|
||||||
|
@ -12,7 +13,6 @@ import net.osmand.StateChangedListener;
|
||||||
import net.osmand.access.AccessibleToast;
|
import net.osmand.access.AccessibleToast;
|
||||||
import net.osmand.map.ITileSource;
|
import net.osmand.map.ITileSource;
|
||||||
import net.osmand.map.TileSourceManager.TileSourceTemplate;
|
import net.osmand.map.TileSourceManager.TileSourceTemplate;
|
||||||
import net.osmand.osm.PoiCategory;
|
|
||||||
import net.osmand.plus.ContextMenuAdapter;
|
import net.osmand.plus.ContextMenuAdapter;
|
||||||
import net.osmand.plus.ContextMenuAdapter.Item;
|
import net.osmand.plus.ContextMenuAdapter.Item;
|
||||||
import net.osmand.plus.GPXUtilities.GPXFile;
|
import net.osmand.plus.GPXUtilities.GPXFile;
|
||||||
|
@ -47,12 +47,11 @@ import net.osmand.plus.views.RouteLayer;
|
||||||
import net.osmand.plus.views.TransportInfoLayer;
|
import net.osmand.plus.views.TransportInfoLayer;
|
||||||
import net.osmand.plus.views.TransportStopsLayer;
|
import net.osmand.plus.views.TransportStopsLayer;
|
||||||
import net.osmand.plus.views.mapwidgets.MapWidgetRegistry;
|
import net.osmand.plus.views.mapwidgets.MapWidgetRegistry;
|
||||||
import android.app.AlertDialog;
|
|
||||||
import android.app.AlertDialog.Builder;
|
import java.util.ArrayList;
|
||||||
import android.content.DialogInterface;
|
import java.util.LinkedHashMap;
|
||||||
import android.content.Intent;
|
import java.util.List;
|
||||||
import android.widget.ListAdapter;
|
import java.util.Map.Entry;
|
||||||
import android.widget.Toast;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Object is responsible to maintain layers using by map activity
|
* Object is responsible to maintain layers using by map activity
|
||||||
|
@ -259,7 +258,7 @@ public class MapActivityLayers {
|
||||||
addFilterToList(adapter, list, f);
|
addFilterToList(adapter, list, f);
|
||||||
}
|
}
|
||||||
|
|
||||||
Builder builder = new AlertDialog.Builder(activity);
|
AlertDialog.Builder builder = new AlertDialog.Builder(activity);
|
||||||
ListAdapter listAdapter = adapter.createListAdapter(activity, app.getSettings().isLightContent());
|
ListAdapter listAdapter = adapter.createListAdapter(activity, app.getSettings().isLightContent());
|
||||||
builder.setAdapter(listAdapter, new DialogInterface.OnClickListener(){
|
builder.setAdapter(listAdapter, new DialogInterface.OnClickListener(){
|
||||||
@Override
|
@Override
|
||||||
|
@ -321,7 +320,7 @@ public class MapActivityLayers {
|
||||||
|
|
||||||
final List<Entry<String, String>> entriesMapList = new ArrayList<Entry<String, String>>(entriesMap.entrySet());
|
final List<Entry<String, String>> entriesMapList = new ArrayList<Entry<String, String>>(entriesMap.entrySet());
|
||||||
|
|
||||||
Builder builder = new AlertDialog.Builder(activity);
|
AlertDialog.Builder builder = new AlertDialog.Builder(activity);
|
||||||
|
|
||||||
String selectedTileSourceKey = settings.MAP_TILE_SOURCES.get();
|
String selectedTileSourceKey = settings.MAP_TILE_SOURCES.get();
|
||||||
|
|
||||||
|
|
|
@ -1,12 +1,16 @@
|
||||||
package net.osmand.plus.dialogs;
|
package net.osmand.plus.dialogs;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import android.content.Context;
|
||||||
import java.util.Arrays;
|
import android.content.DialogInterface;
|
||||||
import java.util.Collection;
|
import android.content.DialogInterface.OnMultiChoiceClickListener;
|
||||||
import java.util.Iterator;
|
import android.content.Intent;
|
||||||
import java.util.List;
|
import android.support.v7.app.AlertDialog;
|
||||||
|
import android.view.View;
|
||||||
|
import android.widget.ArrayAdapter;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
import net.osmand.access.AccessibleToast;
|
import net.osmand.access.AccessibleToast;
|
||||||
|
import net.osmand.core.android.MapRendererContext;
|
||||||
import net.osmand.plus.ContextMenuAdapter;
|
import net.osmand.plus.ContextMenuAdapter;
|
||||||
import net.osmand.plus.ContextMenuAdapter.OnContextMenuClick;
|
import net.osmand.plus.ContextMenuAdapter.OnContextMenuClick;
|
||||||
import net.osmand.plus.ContextMenuAdapter.OnRowItemClick;
|
import net.osmand.plus.ContextMenuAdapter.OnRowItemClick;
|
||||||
|
@ -20,7 +24,6 @@ import net.osmand.plus.activities.MapActivity;
|
||||||
import net.osmand.plus.activities.PluginActivity;
|
import net.osmand.plus.activities.PluginActivity;
|
||||||
import net.osmand.plus.activities.SettingsActivity;
|
import net.osmand.plus.activities.SettingsActivity;
|
||||||
import net.osmand.plus.activities.TransportRouteHelper;
|
import net.osmand.plus.activities.TransportRouteHelper;
|
||||||
import net.osmand.plus.dashboard.DashboardOnMap.DashboardType;
|
|
||||||
import net.osmand.plus.poi.PoiUIFilter;
|
import net.osmand.plus.poi.PoiUIFilter;
|
||||||
import net.osmand.plus.rastermaps.OsmandRasterMapsPlugin;
|
import net.osmand.plus.rastermaps.OsmandRasterMapsPlugin;
|
||||||
import net.osmand.plus.render.RendererRegistry;
|
import net.osmand.plus.render.RendererRegistry;
|
||||||
|
@ -28,21 +31,18 @@ import net.osmand.plus.views.GPXLayer;
|
||||||
import net.osmand.plus.views.OsmandMapTileView;
|
import net.osmand.plus.views.OsmandMapTileView;
|
||||||
import net.osmand.plus.views.RouteLayer;
|
import net.osmand.plus.views.RouteLayer;
|
||||||
import net.osmand.plus.views.corenative.NativeCoreContext;
|
import net.osmand.plus.views.corenative.NativeCoreContext;
|
||||||
import gnu.trove.list.array.TIntArrayList;
|
|
||||||
import net.osmand.core.android.MapRendererContext;
|
|
||||||
import net.osmand.render.RenderingRuleProperty;
|
import net.osmand.render.RenderingRuleProperty;
|
||||||
import net.osmand.render.RenderingRuleStorageProperties;
|
import net.osmand.render.RenderingRuleStorageProperties;
|
||||||
import net.osmand.render.RenderingRulesStorage;
|
import net.osmand.render.RenderingRulesStorage;
|
||||||
import net.osmand.util.Algorithms;
|
import net.osmand.util.Algorithms;
|
||||||
import android.app.AlertDialog;
|
|
||||||
import android.app.AlertDialog.Builder;
|
import java.util.ArrayList;
|
||||||
import android.content.Context;
|
import java.util.Arrays;
|
||||||
import android.content.DialogInterface;
|
import java.util.Collection;
|
||||||
import android.content.Intent;
|
import java.util.Iterator;
|
||||||
import android.content.DialogInterface.OnMultiChoiceClickListener;
|
import java.util.List;
|
||||||
import android.view.View;
|
|
||||||
import android.widget.ArrayAdapter;
|
import gnu.trove.list.array.TIntArrayList;
|
||||||
import android.widget.Toast;
|
|
||||||
|
|
||||||
public class ConfigureMapMenu {
|
public class ConfigureMapMenu {
|
||||||
|
|
||||||
|
@ -473,7 +473,7 @@ public class ConfigureMapMenu {
|
||||||
|
|
||||||
protected void showPreferencesDialog(final ContextMenuAdapter adapter, final ArrayAdapter<?> a, final int pos, final MapActivity activity,
|
protected void showPreferencesDialog(final ContextMenuAdapter adapter, final ArrayAdapter<?> a, final int pos, final MapActivity activity,
|
||||||
String category, List<RenderingRuleProperty> ps, final List<CommonPreference<Boolean>> prefs) {
|
String category, List<RenderingRuleProperty> ps, final List<CommonPreference<Boolean>> prefs) {
|
||||||
Builder bld = new AlertDialog.Builder(activity);
|
AlertDialog.Builder bld = new AlertDialog.Builder(activity);
|
||||||
boolean[] checkedItems = new boolean[prefs.size()];
|
boolean[] checkedItems = new boolean[prefs.size()];
|
||||||
for (int i = 0; i < prefs.size(); i++) {
|
for (int i = 0; i < prefs.size(); i++) {
|
||||||
checkedItems[i] = prefs.get(i).get();
|
checkedItems[i] = prefs.get(i).get();
|
||||||
|
|
|
@ -1,12 +1,24 @@
|
||||||
package net.osmand.plus.helpers;
|
package net.osmand.plus.helpers;
|
||||||
|
|
||||||
import java.io.File;
|
import android.app.Activity;
|
||||||
import java.util.ArrayList;
|
import android.app.Application;
|
||||||
import java.util.Collections;
|
import android.app.ProgressDialog;
|
||||||
import java.util.Comparator;
|
import android.content.DialogInterface;
|
||||||
import java.util.HashMap;
|
import android.content.DialogInterface.OnClickListener;
|
||||||
import java.util.List;
|
import android.os.Build;
|
||||||
import java.util.Map;
|
import android.support.v7.app.AlertDialog;
|
||||||
|
import android.util.TypedValue;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
import android.widget.AdapterView;
|
||||||
|
import android.widget.AdapterView.OnItemClickListener;
|
||||||
|
import android.widget.ArrayAdapter;
|
||||||
|
import android.widget.CheckBox;
|
||||||
|
import android.widget.CompoundButton;
|
||||||
|
import android.widget.CompoundButton.OnCheckedChangeListener;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
import android.widget.TextView;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
import net.osmand.CallbackWithObject;
|
import net.osmand.CallbackWithObject;
|
||||||
import net.osmand.IndexConstants;
|
import net.osmand.IndexConstants;
|
||||||
|
@ -20,26 +32,14 @@ import net.osmand.plus.OsmAndFormatter;
|
||||||
import net.osmand.plus.OsmandApplication;
|
import net.osmand.plus.OsmandApplication;
|
||||||
import net.osmand.plus.R;
|
import net.osmand.plus.R;
|
||||||
import net.osmand.util.Algorithms;
|
import net.osmand.util.Algorithms;
|
||||||
import android.app.Activity;
|
|
||||||
import android.app.AlertDialog;
|
import java.io.File;
|
||||||
import android.app.AlertDialog.Builder;
|
import java.util.ArrayList;
|
||||||
import android.app.Application;
|
import java.util.Collections;
|
||||||
import android.app.ProgressDialog;
|
import java.util.Comparator;
|
||||||
import android.content.DialogInterface;
|
import java.util.HashMap;
|
||||||
import android.content.DialogInterface.OnClickListener;
|
import java.util.List;
|
||||||
import android.os.Build;
|
import java.util.Map;
|
||||||
import android.util.TypedValue;
|
|
||||||
import android.view.View;
|
|
||||||
import android.view.ViewGroup;
|
|
||||||
import android.widget.AdapterView;
|
|
||||||
import android.widget.AdapterView.OnItemClickListener;
|
|
||||||
import android.widget.ArrayAdapter;
|
|
||||||
import android.widget.CheckBox;
|
|
||||||
import android.widget.CompoundButton;
|
|
||||||
import android.widget.CompoundButton.OnCheckedChangeListener;
|
|
||||||
import android.widget.ImageView;
|
|
||||||
import android.widget.TextView;
|
|
||||||
import android.widget.Toast;
|
|
||||||
|
|
||||||
public class GpxUiHelper {
|
public class GpxUiHelper {
|
||||||
|
|
||||||
|
@ -232,7 +232,7 @@ public class GpxUiHelper {
|
||||||
final List<String> list, final ContextMenuAdapter adapter) {
|
final List<String> list, final ContextMenuAdapter adapter) {
|
||||||
final OsmandApplication app = (OsmandApplication) activity.getApplication();
|
final OsmandApplication app = (OsmandApplication) activity.getApplication();
|
||||||
final File dir = app.getAppPath(IndexConstants.GPX_INDEX_DIR);
|
final File dir = app.getAppPath(IndexConstants.GPX_INDEX_DIR);
|
||||||
Builder b = new AlertDialog.Builder(activity);
|
AlertDialog.Builder b = new AlertDialog.Builder(activity);
|
||||||
// final int padding = (int) (12 * activity.getResources().getDisplayMetrics().density + 0.5f);
|
// final int padding = (int) (12 * activity.getResources().getDisplayMetrics().density + 0.5f);
|
||||||
final boolean light = app.getSettings().isLightContent();
|
final boolean light = app.getSettings().isLightContent();
|
||||||
final int layout;
|
final int layout;
|
||||||
|
|
|
@ -1,7 +1,20 @@
|
||||||
package net.osmand.plus.helpers;
|
package net.osmand.plus.helpers;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import android.app.Activity;
|
||||||
import java.util.List;
|
import android.content.DialogInterface;
|
||||||
|
import android.content.DialogInterface.OnClickListener;
|
||||||
|
import android.content.DialogInterface.OnDismissListener;
|
||||||
|
import android.os.AsyncTask;
|
||||||
|
import android.support.v4.app.FragmentActivity;
|
||||||
|
import android.support.v7.app.AlertDialog;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
import android.widget.AdapterView;
|
||||||
|
import android.widget.ArrayAdapter;
|
||||||
|
import android.widget.CompoundButton;
|
||||||
|
import android.widget.ImageButton;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
import android.widget.TextView;
|
||||||
|
|
||||||
import net.osmand.data.LatLon;
|
import net.osmand.data.LatLon;
|
||||||
import net.osmand.data.LocationPoint;
|
import net.osmand.data.LocationPoint;
|
||||||
|
@ -16,21 +29,9 @@ import net.osmand.plus.helpers.WaypointHelper.LocationPointWrapper;
|
||||||
import net.osmand.plus.poi.PoiUIFilter;
|
import net.osmand.plus.poi.PoiUIFilter;
|
||||||
import net.osmand.plus.views.AnimateDraggingMapThread;
|
import net.osmand.plus.views.AnimateDraggingMapThread;
|
||||||
import net.osmand.util.MapUtils;
|
import net.osmand.util.MapUtils;
|
||||||
import android.app.Activity;
|
|
||||||
import android.app.AlertDialog;
|
import java.util.ArrayList;
|
||||||
import android.content.DialogInterface;
|
import java.util.List;
|
||||||
import android.content.DialogInterface.OnClickListener;
|
|
||||||
import android.content.DialogInterface.OnDismissListener;
|
|
||||||
import android.os.AsyncTask;
|
|
||||||
import android.support.v4.app.FragmentActivity;
|
|
||||||
import android.view.View;
|
|
||||||
import android.view.ViewGroup;
|
|
||||||
import android.widget.AdapterView;
|
|
||||||
import android.widget.ArrayAdapter;
|
|
||||||
import android.widget.CompoundButton;
|
|
||||||
import android.widget.ImageButton;
|
|
||||||
import android.widget.ImageView;
|
|
||||||
import android.widget.TextView;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in a new issue