Skip to content

Commit 96a9e8f

Browse files
committed
Update on RssReader implementation
1 parent d187b20 commit 96a9e8f

5 files changed

Lines changed: 24 additions & 17 deletions

File tree

RssReader/app/build.gradle

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ apply plugin: 'com.android.application'
22

33
android {
44
compileSdkVersion 25
5-
buildToolsVersion "25.0.3"
5+
buildToolsVersion '27.0.3'
66
defaultConfig {
77
applicationId "com.example.android.rssreader"
88
minSdkVersion 25
@@ -20,15 +20,15 @@ android {
2020
}
2121

2222
dependencies {
23-
compile fileTree(include: ['*.jar'], dir: 'libs')
24-
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
23+
implementation fileTree(include: ['*.jar'], dir: 'libs')
24+
androidTestImplementation('com.android.support.test.espresso:espresso-core:2.2.2', {
2525
exclude group: 'com.android.support', module: 'support-annotations'
2626
})
27-
compile "com.android.support:recyclerview-v7:25.3.1"
28-
testCompile 'junit:junit:4.12'
29-
compile project(':com.example.android.rssfeedlibrary')
30-
compile 'com.github.bumptech.glide:glide:3.8.0'
31-
compile 'com.android.support:support-v4:25.3.1'
32-
compile 'com.google.code.gson:gson:2.8.1'
33-
compile 'com.squareup:otto:1.3.8'
27+
implementation "com.android.support:recyclerview-v7:25.4.0"
28+
testImplementation 'junit:junit:4.12'
29+
implementation project(':com.example.android.rssfeedlibrary')
30+
implementation 'com.github.bumptech.glide:glide:4.2.0'
31+
implementation 'com.android.support:support-v4:25.4.0'
32+
implementation 'com.google.code.gson:gson:2.8.1'
33+
implementation 'com.squareup:otto:1.3.8'
3434
}

RssReader/app/src/main/java/com/example/android/rssreader/MyListFragment.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,12 @@ public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle sa
4646
return view;
4747
}
4848

49+
@Override
50+
public void onDestroyView() {
51+
RssApplication.bus.unregister(this);
52+
super.onDestroyView();
53+
}
54+
4955
public interface OnItemSelectedListener {
5056
void onRssItemSelected(String link);
5157
}

RssReader/build.gradle

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,10 @@
33
buildscript {
44
repositories {
55
jcenter()
6+
google()
67
}
78
dependencies {
8-
classpath 'com.android.tools.build:gradle:2.3.3'
9+
classpath 'com.android.tools.build:gradle:3.1.4'
910

1011
// NOTE: Do not place your application dependencies here; they belong
1112
// in the individual module build.gradle files
@@ -15,6 +16,7 @@ buildscript {
1516
allprojects {
1617
repositories {
1718
jcenter()
19+
google()
1820
}
1921
}
2022

RssReader/com.example.android.rssfeedlibrary/build.gradle

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ apply plugin: 'com.android.library'
22

33
android {
44
compileSdkVersion 25
5-
buildToolsVersion "25.0.3"
65

76
defaultConfig {
87
minSdkVersion 25
@@ -22,10 +21,10 @@ android {
2221
}
2322

2423
dependencies {
25-
compile fileTree(dir: 'libs', include: ['*.jar'])
26-
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
24+
implementation fileTree(dir: 'libs', include: ['*.jar'])
25+
androidTestImplementation('com.android.support.test.espresso:espresso-core:2.2.2', {
2726
exclude group: 'com.android.support', module: 'support-annotations'
2827
})
29-
testCompile 'junit:junit:4.12'
28+
testImplementation 'junit:junit:4.12'
3029

3130
}
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
#Tue Jun 27 16:14:35 CEST 2017
1+
#Mon Sep 24 22:20:27 CEST 2018
22
distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists
6-
distributionUrl=https\://services.gradle.org/distributions/gradle-3.3-all.zip
6+
distributionUrl=https\://services.gradle.org/distributions/gradle-4.4-all.zip

0 commit comments

Comments
 (0)