aboutsummaryrefslogtreecommitdiffstats
path: root/main/src
diff options
context:
space:
mode:
authorSammysHP <sven@sammyshp.de>2011-11-18 19:01:18 +0100
committerSammysHP <sven@sammyshp.de>2011-11-18 19:18:11 +0100
commite4fb6c596ba35e3ed6c7d2341ffb5e006417ec4e (patch)
treecf53786622a29787e1b39b3c3f329ee889725ddb /main/src
parent0737248e6617e542b81f72115e09af57410f6a3a (diff)
downloadcgeo-e4fb6c596ba35e3ed6c7d2341ffb5e006417ec4e.zip
cgeo-e4fb6c596ba35e3ed6c7d2341ffb5e006417ec4e.tar.gz
cgeo-e4fb6c596ba35e3ed6c7d2341ffb5e006417ec4e.tar.bz2
Partially revert e5efa831a88cab7675b65a3fb596990d88975ee2
Make options menu look equal in all map views. See #811 for reference. Closes #811.
Diffstat (limited to 'main/src')
-rw-r--r--main/src/cgeo/geocaching/maps/CGeoMap.java12
1 files changed, 1 insertions, 11 deletions
diff --git a/main/src/cgeo/geocaching/maps/CGeoMap.java b/main/src/cgeo/geocaching/maps/CGeoMap.java
index d40ee3f..ea6b19e 100644
--- a/main/src/cgeo/geocaching/maps/CGeoMap.java
+++ b/main/src/cgeo/geocaching/maps/CGeoMap.java
@@ -14,7 +14,6 @@ import cgeo.geocaching.cgWaypoint;
import cgeo.geocaching.cgeoapplication;
import cgeo.geocaching.cgeocaches;
import cgeo.geocaching.activity.ActivityMixin;
-import cgeo.geocaching.apps.cache.navi.NavigationAppFactory;
import cgeo.geocaching.enumerations.CacheType;
import cgeo.geocaching.enumerations.WaypointType;
import cgeo.geocaching.geopoint.Geopoint;
@@ -89,7 +88,6 @@ public class CGeoMap extends AbstractMap implements OnDragListener, ViewFactory
private static final int MENU_TRAIL_MODE = 4;
private static final int MENU_CIRCLE_MODE = 5;
private static final int MENU_AS_LIST = 6;
- private static final int MENU_NAVIGATE = 7;
private static final String EXTRAS_MAP_TITLE = "mapTitle";
@@ -525,8 +523,6 @@ public class CGeoMap extends AbstractMap implements OnDragListener, ViewFactory
menu.add(0, MENU_TRAIL_MODE, 0, res.getString(R.string.map_trail_hide)).setIcon(android.R.drawable.ic_menu_recent_history);
menu.add(0, MENU_CIRCLE_MODE, 0, res.getString(R.string.map_circles_hide)).setIcon(R.drawable.ic_menu_circle);
menu.add(0, MENU_AS_LIST, 0, res.getString(R.string.map_as_list)).setIcon(android.R.drawable.ic_menu_agenda);
- submenu = menu.addSubMenu(2, MENU_NAVIGATE, 0, res.getString(R.string.cache_menu_navigate)).setIcon(android.R.drawable.ic_menu_more);
- NavigationAppFactory.addMenuItems(submenu, this.activity, res, false);
return true;
}
@@ -571,10 +567,7 @@ public class CGeoMap extends AbstractMap implements OnDragListener, ViewFactory
}
item = menu.findItem(MENU_AS_LIST);
- item.setVisible(live);
- item.setEnabled(CollectionUtils.isNotEmpty(caches));
-
- menu.findItem(MENU_NAVIGATE).setEnabled(cachesCnt <= 1);
+ item.setEnabled(live && CollectionUtils.isNotEmpty(caches));
} catch (Exception e) {
Log.e(Settings.tag, "cgeomap.onPrepareOptionsMenu: " + e.toString());
}
@@ -726,10 +719,7 @@ public class CGeoMap extends AbstractMap implements OnDragListener, ViewFactory
}
return true;
- } else {
- NavigationAppFactory.onMenuItemSelected(item, geo, activity, res, caches != null && caches.size() > 0 ? caches.get(0) : null, search, null, coordsIntent);
}
- break;
}
return false;
}