java - How can i detect which fragment/tab is being utilised? -


There are several tabs in my application, which contain all the list views which are in one piece. These list views are populated using a square. I use a variable called current tab to find out which tab is selected and therefore the requirements of the list can be populated according to its requirements.

I have realized that when a tab is selected the previous and next UI are loaded to increase liquidity. I am currently unable to distinguish which list is being run on the scene, as a result I am unable to retrieve its corresponding data.

On-tab selection will not work. I'm wondering if there is any other function / method that will allow me to do this.

You can try to override setUserVisibleHint:

  @Override Public Zero setUserVisibleHint (boolean isVisibleToUser) {super.setUserVisibleToUser}; If (isVisibleToUser) this fragment appears to the user}}  

Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

How to access user directory in lazarus? -

java - Gradle dependencies: compile project by relative path -