After opening the application, then leaving it and returning, the list of applications are no longer visible. Fix this UI bug.
After initial launch:
After leaving app and returning:
Error stacktrace on Android 9:
2021-08-31 12:33:30.975 13575-16705/ai.elimu.appstore.debug E/AndroidRuntime: FATAL EXCEPTION: pool-2-thread-2
Process: ai.elimu.appstore.debug, PID: 13575
android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views.
at android.view.ViewRootImpl.checkThread(ViewRootImpl.java:8031)
at android.view.ViewRootImpl.requestLayout(ViewRootImpl.java:1276)
at android.view.View.requestLayout(View.java:23120)
at android.view.View.requestLayout(View.java:23120)
at android.view.View.requestLayout(View.java:23120)
at android.view.View.requestLayout(View.java:23120)
at android.view.View.requestLayout(View.java:23120)
at android.view.View.requestLayout(View.java:23120)
at android.view.View.requestLayout(View.java:23120)
at androidx.core.widget.NestedScrollView.requestLayout(NestedScrollView.java:1849)
at android.view.View.requestLayout(View.java:23120)
at androidx.recyclerview.widget.RecyclerView.requestLayout(RecyclerView.java:4412)
at androidx.recyclerview.widget.RecyclerView$RecyclerViewDataObserver.onChanged(RecyclerView.java:5541)
at androidx.recyclerview.widget.RecyclerView$AdapterDataObservable.notifyChanged(RecyclerView.java:12253)
at androidx.recyclerview.widget.RecyclerView$Adapter.notifyDataSetChanged(RecyclerView.java:7354)
at ai.elimu.appstore.ui.applications.ApplicationListActivity.lambda$onStart$0$ApplicationListActivity(ApplicationListActivity.java:74)
Slightly different error stacktrace on Android 7:
2021-08-31 15:19:13.936 31713-31772/ai.elimu.appstore.debug E/AndroidRuntime: FATAL EXCEPTION: pool-2-thread-2
Process: ai.elimu.appstore.debug, PID: 31713
java.lang.IllegalStateException: Cannot call this method while RecyclerView is computing a layout or scrolling androidx.recyclerview.widget.RecyclerView{f89a623 VFED..... .F....ID 0,0-1504,4896 #7f09012d app:id/recycler_view}, adapter:ai.elimu.appstore.ui.applications.ApplicationListAdapter@f47fd20, layout:androidx.recyclerview.widget.LinearLayoutManager@786b6d9, context:ai.elimu.appstore.ui.applications.ApplicationListActivity@74a3a1d
at androidx.recyclerview.widget.RecyclerView.assertNotInLayoutOrScroll(RecyclerView.java:3051)
at androidx.recyclerview.widget.RecyclerView$RecyclerViewDataObserver.onChanged(RecyclerView.java:5536)
at androidx.recyclerview.widget.RecyclerView$AdapterDataObservable.notifyChanged(RecyclerView.java:12253)
at androidx.recyclerview.widget.RecyclerView$Adapter.notifyDataSetChanged(RecyclerView.java:7354)
at ai.elimu.appstore.ui.applications.ApplicationListActivity.lambda$onStart$0$ApplicationListActivity(ApplicationListActivity.java:74)
After opening the application, then leaving it and returning, the list of applications are no longer visible. Fix this UI bug.
After initial launch:
After leaving app and returning:
Error stacktrace on Android 9:
Slightly different error stacktrace on Android 7: