ios - Google places - GMSAutocompleteViewController didAutocompleteWith full text -


this delegate function in viewcontroller :

func viewcontroller(_ viewcontroller: gmsautocompleteviewcontroller, didautocompletewith place: gmsplace) {         print("place name: \(place.name)")         print("place address: \(place.formattedaddress)")          dismiss(animated: true, completion: nil)     }   

i searched "grav skole" , selected first option here :

enter image description here

following logs :

place name: grav skole
place address: "hosleveien 24, 1358 jar, norway"

on android, result displayed "grav skole, hosleveien, jar, norway", desired text , not match ios.
missing ?

it sounds want access text of predictions displayed in list gmsautocompleteviewcontroller. can implementing viewcontroller:didselectprediction method of gmsautocompleteviewcontrollerdelegate, called when item selected.

func viewcontroller(_ viewcontroller: gmsautocompleteviewcontroller,  didselectprediction prediction: gmsautocompleteprediction) -> bool {     print("primary: \(prediction.attributedprimarytext)")     print("secondary: \(prediction.attributedsecondarytext)")     return false;             }   

Comments

Popular posts from this blog

javascript - Clear button on addentry page doesn't work -

c# - Selenium Authentication Popup preventing driver close or quit -

tensorflow when input_data MNIST_data , zlib.error: Error -3 while decompressing: invalid block type -