if articlepager is also available, notify it about updated item count after lazy load

This commit is contained in:
Andrew Dolgov 2014-10-20 21:48:18 +04:00
parent f6deb68c76
commit 31440437fe
4 changed files with 14 additions and 5 deletions

View File

@ -1,8 +1,8 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" <manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.fox.ttrss" package="org.fox.ttrss"
android:versionCode="244" android:versionCode="245"
android:versionName="1.45" > android:versionName="1.46" >
<uses-sdk <uses-sdk
android:minSdkVersion="8" android:minSdkVersion="8"

View File

@ -255,6 +255,8 @@ public class ArticlePager extends Fragment {
} }
}; };
Log.d(TAG, "[AP] request more headlines...");
req.execute(map); req.execute(map);
} }

View File

@ -237,6 +237,11 @@ public class HeadlinesActivity extends OnlineActivity implements HeadlinesEventL
@Override @Override
public void onHeadlinesLoaded(boolean appended) { public void onHeadlinesLoaded(boolean appended) {
HeadlinesFragment hf = (HeadlinesFragment) getSupportFragmentManager().findFragmentByTag(FRAG_HEADLINES); HeadlinesFragment hf = (HeadlinesFragment) getSupportFragmentManager().findFragmentByTag(FRAG_HEADLINES);
ArticlePager ap = (ArticlePager) getSupportFragmentManager().findFragmentByTag(FRAG_ARTICLE);
if (ap != null) {
ap.notifyUpdated();
}
if (hf != null) { if (hf != null) {
Article article = hf.getActiveArticle(); Article article = hf.getActiveArticle();

View File

@ -555,6 +555,8 @@ public class HeadlinesFragment extends Fragment implements OnItemClickListener,
} }
}; };
Log.d(TAG, "[HP] request more headlines...");
req.execute(map); req.execute(map);
} }
} }