Я пытаюсь передать координаты и заголовок, полученный при клике по RSS-каналу, и я хочу передать его в карты Google из отладки, которую он проходит без проблем, моя проблема отображает его на карте. Вот онклик с намерением:
public void onItemClick(AdapterView<?> parent, View view,
int position, long id) {
Intent in = new Intent(getApplicationContext(), MapsActivity.class);
String georss = ((TextView) view.findViewById(R.id.georss)).getText().toString();
String title = ((TextView) view.findViewById(R.id.title)).getText().toString();
String[] latLng = georss.split(" ");
double lat = Double.parseDouble(latLng[0]);
double lng = Double.parseDouble(latLng[1]);;
LatLng location = new LatLng(lat, lng);
in.putExtra("location", location);
in.putExtra("title", title);
startActivity(in);
}
});
, а вот карты Google при создании:
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_maps);
Intent intent = getIntent();
intent.getStringExtra("title");
intent.getStringExtra("location");
Я просто не уверен, как отобразить маркер, поэтому при нажатии на нем вы можете увидеть заголовок.