Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8328987
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T01:37:11+00:00 2026-06-09T01:37:11+00:00

My scenario is as follow: I’m implementing a tabhost that displays two tabs through

  • 0

My scenario is as follow: I’m implementing a tabhost that displays two tabs through LocalActivityManager. The first one holds a ListView that shows information about a geo-localized position (such distance, address name…), and in the second one, I have a MapView implementing Google’s Map API that shows the respective items within the first activity. I can’t implement both activities as one, in same view, because the two extends from different classes (the first one has a parent that creates a custom menu and the second one comes from MapView), so the option to do all things in one activity is not available.

My issue is: having a lazy-load (load content in demand, when user scrolls to the end of the list) feature in the first activity, how can I synchronize its items in the MapView activity, using the TabHost methods?

I’ve stated with some complex solutions already, such using BroadcastReceiver or creating AIDL, but I’m looking for the simplest possible solution. I’m not seeking for code itself but a plan to do this task.

Thanks in advance!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T01:37:14+00:00Added an answer on June 9, 2026 at 1:37 am

    I thik in this case you need to implement listener pattern, for example

     public interface MapDataLoadingListener{
        public void onMapDataLoaded(List<MapData> dataList);
    }
    
    public class YourListActivity extends Activity{
    
        ...
    
        // somewhere you push yoy lazy load task
        UpdateListTask task = new UpdateListTask();
        task.setMapDataListener(// your map activity)
        task.execute();
        ...
    }
    
    
    public class YourMapActivity extends MapActivity implements MapDataLoadingListener {
    
         ...
    
         public void onMapDataLoaded(List<MapData> dataList){
            updateMap(dataList); 
         }
    
        ...
    
        private void updateMap(List<MapData> dataList){
            ...
        }
    
    }
    
    
    public class UpdateListTask extends AsyncTask {
    
        private MapDataLoadingListener mapDataListener;
    
        public void setMapDataListener(MapDataLoadingListener mapDataListener){
            this.mapDataListener = mapDataListener;
        }
    
        ...
    
        @Override
        protected void onPostExecute(Object result) {
           mapDataListener.onMapDataLoaded((List<MapData>) result)
        }
    
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

My scenario is as follows. I have 7 tabs (one for each day) using
I have one scenario in which the user can define the column and that
Scenario 1 I have one table lets say member. In that table member i
Scenario A image website that has basic features such as upload, comment, like, follow
Our scenario is as follow: When the TCP connection is established (we can check
The scenario is as follows. My Order model has an after_create that contacts a
The scenario I am using LINQ is as follows: I have a method that
Scenario first :- I'm using Entity Framework to do some queries, to build my
I'm with a problem The scenario is the follow: After submitting a form the
I have a scenario in which I need a self reference property as follow:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.