mirror of
https://github.com/M66B/FairEmail.git
synced 2025-12-26 23:50:58 +01:00
Use ContentLoadingProgressBar
This commit is contained in:
@@ -23,7 +23,6 @@ import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.ProgressBar;
|
||||
|
||||
import com.google.android.material.floatingactionbutton.FloatingActionButton;
|
||||
|
||||
@@ -33,6 +32,7 @@ import java.util.List;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.constraintlayout.widget.Group;
|
||||
import androidx.core.widget.ContentLoadingProgressBar;
|
||||
import androidx.fragment.app.FragmentTransaction;
|
||||
import androidx.lifecycle.Observer;
|
||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||
@@ -40,7 +40,7 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
public class FragmentIdentities extends FragmentEx {
|
||||
private RecyclerView rvIdentity;
|
||||
private ProgressBar pbWait;
|
||||
private ContentLoadingProgressBar pbWait;
|
||||
private Group grpReady;
|
||||
private FloatingActionButton fab;
|
||||
|
||||
@@ -81,7 +81,7 @@ public class FragmentIdentities extends FragmentEx {
|
||||
|
||||
// Initialize
|
||||
grpReady.setVisibility(View.GONE);
|
||||
pbWait.setVisibility(View.VISIBLE);
|
||||
pbWait.show();
|
||||
|
||||
return view;
|
||||
}
|
||||
@@ -96,7 +96,7 @@ public class FragmentIdentities extends FragmentEx {
|
||||
public void onChanged(@Nullable List<TupleIdentityEx> identities) {
|
||||
adapter.set(identities == null ? new ArrayList<TupleIdentityEx>() : identities);
|
||||
|
||||
pbWait.setVisibility(View.GONE);
|
||||
pbWait.hide();
|
||||
grpReady.setVisibility(View.VISIBLE);
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user