Current RxJava version, not reloading when downloads are queued
This commit is contained in:
parent
af30f4f9d2
commit
c45797631d
@ -28,6 +28,7 @@ dependencies {
|
|||||||
compile "com.squareup.okio:okio:$okioVersion"
|
compile "com.squareup.okio:okio:$okioVersion"
|
||||||
compile "de.greenrobot:eventbus:$eventbusVersion"
|
compile "de.greenrobot:eventbus:$eventbusVersion"
|
||||||
compile "io.reactivex:rxandroid:$rxAndroidVersion"
|
compile "io.reactivex:rxandroid:$rxAndroidVersion"
|
||||||
|
compile "io.reactivex:rxjava:$rxJavaVersion"
|
||||||
compile "com.joanzapata.iconify:android-iconify-fontawesome:2.1.0"
|
compile "com.joanzapata.iconify:android-iconify-fontawesome:2.1.0"
|
||||||
compile "com.afollestad:material-dialogs:0.7.8.1"
|
compile "com.afollestad:material-dialogs:0.7.8.1"
|
||||||
compile "com.yqritc:recyclerview-flexibledivider:1.2.6"
|
compile "com.yqritc:recyclerview-flexibledivider:1.2.6"
|
||||||
|
@ -393,7 +393,11 @@ public class AllEpisodesFragment extends Fragment {
|
|||||||
@Override
|
@Override
|
||||||
public void update(EventDistributor eventDistributor, Integer arg) {
|
public void update(EventDistributor eventDistributor, Integer arg) {
|
||||||
if ((arg & EVENTS) != 0) {
|
if ((arg & EVENTS) != 0) {
|
||||||
|
if((arg & EventDistributor.DOWNLOAD_QUEUED) != 0) {
|
||||||
|
listAdapter.notifyDataSetChanged();
|
||||||
|
} else {
|
||||||
loadItems();
|
loadItems();
|
||||||
|
}
|
||||||
if (isUpdatingFeeds != updateRefreshMenuItemChecker.isRefreshing()) {
|
if (isUpdatingFeeds != updateRefreshMenuItemChecker.isRefreshing()) {
|
||||||
getActivity().supportInvalidateOptionsMenu();
|
getActivity().supportInvalidateOptionsMenu();
|
||||||
}
|
}
|
||||||
|
@ -557,7 +557,12 @@ public class QueueFragment extends Fragment {
|
|||||||
@Override
|
@Override
|
||||||
public void update(EventDistributor eventDistributor, Integer arg) {
|
public void update(EventDistributor eventDistributor, Integer arg) {
|
||||||
if ((arg & EVENTS) != 0) {
|
if ((arg & EVENTS) != 0) {
|
||||||
|
Log.d(TAG, "arg: " + arg);
|
||||||
|
if((arg & EventDistributor.DOWNLOAD_QUEUED) != 0) {
|
||||||
|
recyclerAdapter.notifyDataSetChanged();
|
||||||
|
} else {
|
||||||
loadItems();
|
loadItems();
|
||||||
|
}
|
||||||
if (isUpdatingFeeds != updateRefreshMenuItemChecker.isRefreshing()) {
|
if (isUpdatingFeeds != updateRefreshMenuItemChecker.isRefreshing()) {
|
||||||
getActivity().supportInvalidateOptionsMenu();
|
getActivity().supportInvalidateOptionsMenu();
|
||||||
}
|
}
|
||||||
@ -566,6 +571,7 @@ public class QueueFragment extends Fragment {
|
|||||||
};
|
};
|
||||||
|
|
||||||
private void loadItems() {
|
private void loadItems() {
|
||||||
|
Log.d(TAG, "loadItems()");
|
||||||
if(subscription != null) {
|
if(subscription != null) {
|
||||||
subscription.unsubscribe();
|
subscription.unsubscribe();
|
||||||
}
|
}
|
||||||
|
@ -49,6 +49,7 @@ project.ext {
|
|||||||
glideVersion = "3.6.1"
|
glideVersion = "3.6.1"
|
||||||
jsoupVersion = "1.7.3"
|
jsoupVersion = "1.7.3"
|
||||||
rxAndroidVersion = "1.0.1"
|
rxAndroidVersion = "1.0.1"
|
||||||
|
rxJavaVersion = "1.0.16"
|
||||||
okhttpVersion = "2.5.0"
|
okhttpVersion = "2.5.0"
|
||||||
okioVersion = "1.6.0"
|
okioVersion = "1.6.0"
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user