Я пробую этот SDK
implementation 'com.google.android.libraries.places:places:1.1.0'
Это мой код
if (!Places.isInitialized()) {
Places.initialize(getApplicationContext(), "YOUR_API_KEY");
}
List<Place.Field> fields = Arrays.asList(Place.Field.ID, Place.Field.NAME);
// Start the autocomplete intent.
Intent intent = new Autocomplete.IntentBuilder(AutocompleteActivityMode.FULLSCREEN, fields)
.build(this);
startActivityForResult(intent, AUTOCOMPLETE_REQUEST_CODE);
А это мой бревенчатый кот
2019-05-21 17:21:52.921 13555-13555/com.pripun.ecom D/ViewRootImpl@50aa60a[Transaction]: ViewPostIme pointer 0
2019-05-21 17:21:53.076 13555-13555/com.pripun.ecom D/ViewRootImpl@50aa60a[Transaction]: ViewPostIme pointer 1
2019-05-21 17:21:53.172 13555-13555/com.pripun.ecom D/ViewRootImpl@4503997[AutocompleteActivity]: setView = DecorView@97eb784[AutocompleteActivity] TM=true MM=false
2019-05-21 17:21:53.172 13555-13555/com.pripun.ecom D/ViewRootImpl@50aa60a[Transaction]: MSG_WINDOW_FOCUS_CHANGED 0
2019-05-21 17:21:53.175 13555-13555/com.pripun.ecom V/InputMethodManager: Not IME target window, ignoring
2019-05-21 17:21:53.177 13555-13555/com.pripun.ecom D/ViewRootImpl@4503997[AutocompleteActivity]: dispatchAttachedToWindow
2019-05-21 17:21:53.187 13555-13555/com.pripun.ecom V/Surface: sf_framedrop debug : 0x4f4c, game : false, logging : 0
2019-05-21 17:21:53.187 13555-13555/com.pripun.ecom D/ViewRootImpl@4503997[AutocompleteActivity]: Relayout returned: old=[0,0][0,0] new=[0,0][1080,1920] result=0x7 surface={valid=true 547448614912} changed=true
2019-05-21 17:21:53.194 13555-13602/com.pripun.ecom D/mali_winsys: EGLint new_window_surface(egl_winsys_display *, void *, EGLSurface, EGLConfig, egl_winsys_surface **, egl_color_buffer_format *, EGLBoolean) returns 0x3000, [1080x1920]-format:1
2019-05-21 17:21:53.194 13555-13602/com.pripun.ecom D/OpenGLRenderer: eglCreateWindowSurface = 0x7f8a0190b0
2019-05-21 17:21:53.216 13555-13555/com.pripun.ecom D/ViewRootImpl@4503997[AutocompleteActivity]: MSG_RESIZED_REPORT: frame=Rect(0, 0 - 1080, 1920) ci=Rect(0, 72 - 0, 0) vi=Rect(0, 72 - 0, 0) or=1
2019-05-21 17:21:53.217 13555-13555/com.pripun.ecom D/ViewRootImpl@4503997[AutocompleteActivity]: MSG_WINDOW_FOCUS_CHANGED 1
2019-05-21 17:21:53.232 13555-13555/com.pripun.ecom V/InputMethodManager: Starting input: tba=android.view.inputmethod.EditorInfo@6a3d76 nm : com.pripun.ecom ic=com.android.internal.widget.EditableInputConnection@b3a4f77
2019-05-21 17:21:53.233 13555-13555/com.pripun.ecom I/InputMethodManager: startInputInner - mService.startInputOrWindowGainedFocus
2019-05-21 17:21:53.262 13555-13555/com.pripun.ecom D/ViewRootImpl@4503997[AutocompleteActivity]: MSG_RESIZED: frame=Rect(0, 0 - 1080, 1920) ci=Rect(0, 72 - 0, 750) vi=Rect(0, 72 - 0, 750) or=1
2019-05-21 17:21:53.263 13555-13555/com.pripun.ecom W/View: dispatchProvideAutofillStructure(): not laid out, ignoring
2019-05-21 17:21:53.264 13555-13555/com.pripun.ecom I/chatty: uid=10658(u0_a658) com.pripun.ecom identical 3 lines
2019-05-21 17:21:53.264 13555-13555/com.pripun.ecom W/View: dispatchProvideAutofillStructure(): not laid out, ignoring
2019-05-21 17:21:53.265 13555-13555/com.pripun.ecom I/AssistStructure: Flattened final assist data: 2272 bytes, containing 1 windows, 10 views
2019-05-21 17:21:53.266 13555-13555/com.pripun.ecom W/IInputConnectionWrapper: performPrivateCommand on inactive InputConnection
2019-05-21 17:21:53.268 13555-13565/com.pripun.ecom I/zygote64: Do partial code cache collection, code=1009KB, data=632KB
2019-05-21 17:21:53.269 13555-13565/com.pripun.ecom I/zygote64: After code cache collection, code=1009KB, data=632KB
2019-05-21 17:21:53.269 13555-13565/com.pripun.ecom I/zygote64: Increasing code cache capacity to 3MB
2019-05-21 17:21:53.274 13555-13555/com.pripun.ecom D/ViewRootImpl@4503997[AutocompleteActivity]: Relayout returned: old=[0,0][1080,1920] new=[0,0][1080,1920] result=0x1 surface={valid=true 547448614912} changed=false
2019-05-21 17:21:53.316 13555-13555/com.pripun.ecom D/ViewRootImpl@50aa60a[Transaction]: MSG_RESIZED: frame=Rect(0, 0 - 1080, 1920) ci=Rect(0, 72 - 0, 873) vi=Rect(0, 72 - 0, 873) or=1
2019-05-21 17:21:53.317 13555-13555/com.pripun.ecom D/ViewRootImpl@4503997[AutocompleteActivity]: MSG_RESIZED: frame=Rect(0, 0 - 1080, 1920) ci=Rect(0, 72 - 0, 873) vi=Rect(0, 72 - 0, 873) or=1
2019-05-21 17:21:53.338 13555-13555/com.pripun.ecom D/ViewRootImpl@50aa60a[Transaction]: Relayout returned: old=[0,0][1080,1920] new=[0,0][1080,1920] result=0x1 surface={valid=true 547475845120} changed=false
2019-05-21 17:21:53.352 13555-13555/com.pripun.ecom D/ViewRootImpl@4503997[AutocompleteActivity]: Relayout returned: old=[0,0][1080,1920] new=[0,0][1080,1920] result=0x1 surface={valid=true 547448614912} changed=false
Я пробую этот новейший код в местах Google, но карты не отображаются пустыми, но автозаполнение работает. Link