try without intent
This commit is contained in:
parent
2652230451
commit
d6c20dfc49
1 changed files with 10 additions and 10 deletions
|
@ -168,16 +168,16 @@ public class NavigatePointFragment extends SherlockFragment implements SearchAct
|
||||||
super.onResume();
|
super.onResume();
|
||||||
LatLon location = null;
|
LatLon location = null;
|
||||||
OsmandApplication app = (OsmandApplication) getActivity().getApplication();
|
OsmandApplication app = (OsmandApplication) getActivity().getApplication();
|
||||||
Intent intent = getSherlockActivity().getIntent();
|
//Intent intent = getSherlockActivity().getIntent();
|
||||||
if (intent != null) {
|
//if (intent != null) {
|
||||||
if (intent.hasExtra(SearchActivity.SEARCH_LAT) && intent.hasExtra(SearchActivity.SEARCH_LON)) {
|
// if (intent.hasExtra(SearchActivity.SEARCH_LAT) && intent.hasExtra(SearchActivity.SEARCH_LON)) {
|
||||||
double lat = intent.getDoubleExtra(SearchActivity.SEARCH_LAT, 0);
|
// double lat = intent.getDoubleExtra(SearchActivity.SEARCH_LAT, 0);
|
||||||
double lon = intent.getDoubleExtra(SearchActivity.SEARCH_LON, 0);
|
// double lon = intent.getDoubleExtra(SearchActivity.SEARCH_LON, 0);
|
||||||
if (lat != 0 || lon != 0) {
|
// if (lat != 0 || lon != 0) {
|
||||||
location = new LatLon(lat, lon);
|
// location = new LatLon(lat, lon);
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}
|
//}
|
||||||
if (location == null && getActivity() instanceof SearchActivity) {
|
if (location == null && getActivity() instanceof SearchActivity) {
|
||||||
location = ((SearchActivity) getActivity()).getSearchPoint();
|
location = ((SearchActivity) getActivity()).getSearchPoint();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue