aboutsummaryrefslogtreecommitdiffstats
path: root/main/src/cgeo
diff options
context:
space:
mode:
authorBananeweizen <Bananeweizen@gmx.de>2012-02-18 12:15:00 +0100
committerBananeweizen <Bananeweizen@gmx.de>2012-02-18 12:15:00 +0100
commit0c3001d695a2a99a2aaf057ed3c8d799a42854d4 (patch)
tree0b87fff27f1ca05939786b06f101e8d591830b24 /main/src/cgeo
parent34c0e4065a45c55daf5c230c5d27df2d63703b23 (diff)
downloadcgeo-0c3001d695a2a99a2aaf057ed3c8d799a42854d4.zip
cgeo-0c3001d695a2a99a2aaf057ed3c8d799a42854d4.tar.gz
cgeo-0c3001d695a2a99a2aaf057ed3c8d799a42854d4.tar.bz2
fix #945: unify navigation methods
* next step would be the removal of cgGeo after that becomes singleton
Diffstat (limited to 'main/src/cgeo')
-rw-r--r--main/src/cgeo/geocaching/CacheDetailActivity.java2
-rw-r--r--main/src/cgeo/geocaching/apps/cache/navi/NavigationAppFactory.java14
-rw-r--r--main/src/cgeo/geocaching/cgeowaypoint.java2
3 files changed, 8 insertions, 10 deletions
diff --git a/main/src/cgeo/geocaching/CacheDetailActivity.java b/main/src/cgeo/geocaching/CacheDetailActivity.java
index c159cb7..c24ea41 100644
--- a/main/src/cgeo/geocaching/CacheDetailActivity.java
+++ b/main/src/cgeo/geocaching/CacheDetailActivity.java
@@ -566,7 +566,7 @@ public class CacheDetailActivity extends AbstractActivity {
}
return false;
}
- if (NavigationAppFactory.onMenuItemSelected(item, geolocation, this, cache, search, null, null)) {
+ if (NavigationAppFactory.onMenuItemSelected(item, geolocation, this, cache, null, null)) {
return true;
}
if (GeneralAppsFactory.onMenuItemSelected(item, this, cache)) {
diff --git a/main/src/cgeo/geocaching/apps/cache/navi/NavigationAppFactory.java b/main/src/cgeo/geocaching/apps/cache/navi/NavigationAppFactory.java
index dfef8fa..53240bc 100644
--- a/main/src/cgeo/geocaching/apps/cache/navi/NavigationAppFactory.java
+++ b/main/src/cgeo/geocaching/apps/cache/navi/NavigationAppFactory.java
@@ -90,7 +90,7 @@ public final class NavigationAppFactory extends AbstractAppFactory {
/**
* Specialized way to handle selection of navigation tool.<br />
* A dialog is created for tool selection and the selected tool is started afterwards.
- *
+ *
* @param geo
* @param activity
* @param cache
@@ -103,8 +103,8 @@ public final class NavigationAppFactory extends AbstractAppFactory {
* should be <code>false</code> only when called from within the internal map
* @param showDefaultNavigation
* should be <code>false</code> by default
- *
- * @see #showNavigationMenu(cgGeo, Activity, cgCache, SearchResult, cgWaypoint, Geopoint)
+ *
+ * @see #showNavigationMenu(cgGeo, Activity, cgCache, cgWaypoint, Geopoint)
*/
public static void showNavigationMenu(final cgGeo geo, final Activity activity,
final cgCache cache, final cgWaypoint waypoint, final Geopoint destination,
@@ -211,11 +211,11 @@ public final class NavigationAppFactory extends AbstractAppFactory {
/**
* Adds the installed navigation tools to the given menu.
- * Use {@link #onMenuItemSelected(MenuItem, cgGeo, Activity, cgCache, SearchResult, cgWaypoint, Geopoint)} on
+ * Use {@link #onMenuItemSelected(MenuItem, cgGeo, Activity, cgCache, cgWaypoint, Geopoint)} on
* selection event to start the selected navigation tool.
*
* <b>Only use this way if
- * {@link #showNavigationMenu(cgGeo, Activity, cgCache, SearchResult, cgWaypoint, Geopoint, boolean, boolean)} is
+ * {@link #showNavigationMenu(cgGeo, Activity, cgCache, cgWaypoint, Geopoint, boolean, boolean)} is
* not suitable for the given usecase.</b>
*
* @param menu
@@ -242,14 +242,12 @@ public final class NavigationAppFactory extends AbstractAppFactory {
* @param geo
* @param activity
* @param cache
- * @param search
* @param waypoint
* @param destination
* @return
*/
public static boolean onMenuItemSelected(final MenuItem item,
- final cgGeo geo, Activity activity, cgCache cache,
- final SearchResult search, cgWaypoint waypoint, final Geopoint destination) {
+ final cgGeo geo, Activity activity, cgCache cache, cgWaypoint waypoint, final Geopoint destination) {
if (cache == null && waypoint == null && destination == null) {
return false;
}
diff --git a/main/src/cgeo/geocaching/cgeowaypoint.java b/main/src/cgeo/geocaching/cgeowaypoint.java
index 190c54d..04c0d13 100644
--- a/main/src/cgeo/geocaching/cgeowaypoint.java
+++ b/main/src/cgeo/geocaching/cgeowaypoint.java
@@ -358,6 +358,6 @@ public class cgeowaypoint extends AbstractActivity {
if (handled) {
return true;
}
- return NavigationAppFactory.onMenuItemSelected(item, geo, this, null, null, waypoint, null);
+ return NavigationAppFactory.onMenuItemSelected(item, geo, this, null, waypoint, null);
}
}