Hello, I think I have asked this before, but now I am getting to a point where the whole business logic from our WP7 app works on Monodroid. Now I need a lot of this displayed on a map, hence I need a way to communicate with the the Google Maps activity. The data in the data model we have is updated in near real-time and we want to display that on the Google Maps View along with the real-time updates to the data. I have made some initial tests and made some methods to update points on the map from some data I generated randomly. Now I need to get that to work with a real data set.
The app I have is structured in the following way: The start activity is a TabActivity containing a TabHost with 3 tabs. The first with the Google Maps Activity, second one with an Activity displaying some more detailed Location information (this works) and the third one which is supposed to display chart data (not yet implemented). The TabActivity instantiates the data model behind, which then begins a worker thread that fetches real-time data and creates events when something happens. Right now I have the second tab Activity reacting to when new location data has been fetched and updates the View with that data. So I want something similar to happen to the MapView in the first tab. I want it to react to such an event and get the location data somehow and update the overlays with the new data. As the Google Maps Activity is written in Java it is not able handle the events created in the C# code, so I have to work my way around this somehow, so I am seeking suggestions on how to do this, hoping that you would have some good ones. I was thinking of a BroadcastReciever in the MapActivity invoking a method in the TabActivity fetching data. But is that even possible? Will the MapActivity know the TabActivity, how do I cast that? And maybe even more important, how do I encapsulate the data? Is there a better method of achieving this? Examples and suggestions are really appreciated. -- Med Venlig Hilsen / With Best Regards Tomasz Cielecki http://ostebaronen.dk _______________________________________________ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid