Code example for AutoCompleteTextView

Methods: getWindowToken

0
				Log.d(TAG, "Set arrival Marker: " + address.getAddressLine(0));
				toMarker.setPosition(new LatLng(address.getLatitude(), address.getLongitude()));
				toMarker.setVisible(true);
				InputMethodManager imm = (InputMethodManager)getSystemService(
			      Context.INPUT_METHOD_SERVICE);
				imm.hideSoftInputFromWindow(toStreet.getWindowToken(), InputMethodManager.HIDE_NOT_ALWAYS);
      } 
		}); 
	} 
 
	@Override 
	public boolean onCreateOptionsMenu(Menu menu) {
		getMenuInflater().inflate(R.menu.main, menu);
		return true; 
	} 
 
	private void testGeocoding() { 
		Geocoder geocoder = new Geocoder(this, Locale.getDefault());
		Log.d(TAG, "Geocoder ready");
		try { 
			List<Address> list = geocoder.getFromLocation(55.973414, -3.188782, 1);