Click here to Skip to main content
15,868,016 members
Home / Discussions / Android
   

Android

 
AnswerRe: Hello, I am a newbie here, good to meet yah. Pin
Seechon Boontharikwong10-Apr-20 6:26
Seechon Boontharikwong10-Apr-20 6:26 
QuestionGlobalization issues with Dates Pin
Vimalsoft(Pty) Ltd29-Dec-19 10:17
professionalVimalsoft(Pty) Ltd29-Dec-19 10:17 
AnswerRe: Globalization issues with Dates Pin
Eddy Vluggen29-Dec-19 12:05
professionalEddy Vluggen29-Dec-19 12:05 
AnswerRe: Globalization issues with Dates Pin
Richard MacCutchan30-Dec-19 0:09
mveRichard MacCutchan30-Dec-19 0:09 
GeneralRe: Globalization issues with Dates Pin
Vimalsoft(Pty) Ltd30-Dec-19 7:35
professionalVimalsoft(Pty) Ltd30-Dec-19 7:35 
SuggestionRe: Globalization issues with Dates Pin
Richard Deeming7-Jan-20 9:16
mveRichard Deeming7-Jan-20 9:16 
GeneralRe: Globalization issues with Dates Pin
Exoskeletor12-Mar-20 22:58
Exoskeletor12-Mar-20 22:58 
QuestionFirebase infinite scroll list view Load 10 items on Scrolling using firebase realtime database "Android Project" Pin
lucas houmga19-Dec-19 22:47
lucas houmga19-Dec-19 22:47 
I'm looking for a way to implement a simple list view scrolling in my Firebase app, but I am not getting any way out how to implement this. I have already tried 2-3 tutorials and documentation available on the Internet, but didn't the required result.

In my app I want scrolling like at starting first 10 list items load then each time on scrolling next 10 or 20 items will load until the last item appears at the bottom of the list.

So I tried retrieving first 10 items the following way :



<pre>private void readsposts(){

        DatabaseReference reference = FirebaseDatabase.getInstance().getReference();
        reference.keepSynced(true);

        reference.child("Posts")
                .limitToLast(10)
                .addValueEventListener(new ValueEventListener() {
                    @Override
                    public void onDataChange(DataSnapshot dataSnapshot) {
                       
                        postList.clear();
                        for(DataSnapshot snapshot:dataSnapshot.getChildren()){
                            Post post = snapshot.getValue(Post.class);
                            for(String id:followingList){

                                if(post.getPublisher()!=null && post.getPublisher().equals(id)){

                                    postList.add(post);
                                   

                                }

                            }

                            if(post.getPublisher()!=null && post.getPublisher().equals(firebaseUser.getUid())){
                                postList.add(post);

                            }

                            postAdapter.notifyDataSetChanged();


                        }
                        
                        mProgressBar.setVisibility(RecyclerView.GONE);

                    }


                    @Override public void onCancelled(DatabaseError databaseError) {
                        mProgressBar.setVisibility(RecyclerView.GONE);
                    }
                });
    }




In the above code, as you can see I am generating Log to check if data is fetched from the firebase, but I got no output Android monitor.
I have no idea how can I implement Firebase Scrolling in my Recycler view. I think this is a common problem for those who implement infinite-scroll in recycler view/ list view.
Could you please help me implementing this feature. Thanks.
AnswerRe: Firebase infinite scroll list view Load 10 items on Scrolling using firebase realtime database "Android Project" Pin
Exoskeletor13-Mar-20 1:58
Exoskeletor13-Mar-20 1:58 
QuestionHelp me with this simple app. Pin
All Matter25-Nov-19 8:02
All Matter25-Nov-19 8:02 
SuggestionRe: Help me with this simple app. Pin
David Crow30-Nov-19 4:33
David Crow30-Nov-19 4:33 
AnswerRe: Help me with this simple app. Pin
Exoskeletor13-Mar-20 2:09
Exoskeletor13-Mar-20 2:09 
QuestionUnmanaged library exception handling Pin
wakeup4424-Nov-19 23:01
wakeup4424-Nov-19 23:01 
QuestionAre BroadcastReciever and ContentObserver killed If Started From Service? Pin
Django_Untaken27-Oct-19 19:15
Django_Untaken27-Oct-19 19:15 
AnswerRe: Are BroadcastReciever and ContentObserver killed If Started From Service? Pin
Richard MacCutchan27-Oct-19 22:21
mveRichard MacCutchan27-Oct-19 22:21 
QuestionDo you believe that Kotlin will become more popular than Java? Pin
Darina Smartym15-Oct-19 22:28
Darina Smartym15-Oct-19 22:28 
AnswerRe: Do you believe that Kotlin will become more popular than Java? Pin
Afzaal Ahmad Zeeshan28-Oct-19 1:02
professionalAfzaal Ahmad Zeeshan28-Oct-19 1:02 
GeneralRe: Do you believe that Kotlin will become more popular than Java? Pin
The_Arcaniac1-Feb-20 23:13
The_Arcaniac1-Feb-20 23:13 
GeneralRe: Do you believe that Kotlin will become more popular than Java? Pin
Afzaal Ahmad Zeeshan2-Feb-20 7:14
professionalAfzaal Ahmad Zeeshan2-Feb-20 7:14 
AnswerRe: Do you believe that Kotlin will become more popular than Java? Pin
Alicia Lim11-Jan-22 23:21
professionalAlicia Lim11-Jan-22 23:21 
Questionattach .jar file to already running apk in emulator Pin
Member 1457084310-Oct-19 6:41
Member 1457084310-Oct-19 6:41 
AnswerRe: attach .jar file to already running apk in emulator Pin
Richard MacCutchan10-Oct-19 22:10
mveRichard MacCutchan10-Oct-19 22:10 
GeneralRe: attach .jar file to already running apk in emulator Pin
Member 1457084311-Oct-19 0:11
Member 1457084311-Oct-19 0:11 
GeneralRe: attach .jar file to already running apk in emulator Pin
Richard MacCutchan11-Oct-19 0:53
mveRichard MacCutchan11-Oct-19 0:53 
AnswerRe: attach .jar file to already running apk in emulator Pin
Leanbridge Technologies21-Nov-19 19:48
professionalLeanbridge Technologies21-Nov-19 19:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.