umts / pvta-multiplatform

Transit realtime app for mobile devices
Other
6 stars 5 forks source link

Pass loaded trip to Google Maps for saved trip #403

Closed mboneil10 closed 7 years ago

mboneil10 commented 7 years ago

Closes #380 (hopefully I got this right. It works, but I don't know if I coded properly).

akaplo commented 7 years ago

This does solve the problem. FWIW I realize now, however, that the problem was in fact created by my own mediocre code that I'm still unsure how to fix.

The MapService function that downloads Google Maps gets passed the correct Plan Trip function as a callback, but the issue is that it doesn't get passed the loadedTrip param. Additionally, I don't think you can just pass parameters to the Google Maps callback that the MapService creates.

Long story short, @mboneil10 solved the problem with a good workaround and I think we should merge this as a hotfix, but the underlying issue still exists until we can figure out a better design pattern here.