默认提示值自动完成 https://developers.google.com/places/android-api/autocomplete小部件是Search
。如何将该值更改为不同的值String
?
尝试下面的代码:
PlaceAutocompleteFragment places= (PlaceAutocompleteFragment)getFragmentManager().findFragmentById(R.id.place_autocomplete_fragment);
EditText etPlace = (EditText)places.getView().findViewById(R.id.place_autocomplete_search_input);
etPlace.setHint("Your Text");
希望这可以帮助。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)