Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 1e88b58

Browse files
author
Kaushik Gopal
committed
fix: update LeakCanary + use ContextCompat color
1 parent 29b081f commit 1e88b58

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

‎app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ dependencies {
5151

5252
// ----------------------------------
5353

54-
debugCompile 'com.squareup.leakcanary:leakcanary-android:1.3'
55-
releaseCompile 'com.squareup.leakcanary:leakcanary-android-no-op:1.3'
54+
debugCompile 'com.squareup.leakcanary:leakcanary-android:1.5.1'
55+
releaseCompile 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.1'
5656
}
5757

5858
android {

‎app/src/main/java/com/morihacky/android/rxjava/fragments/FormValidationCombineLatestFragment.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55

66
import android.os.Bundle;
77
import android.support.annotation.Nullable;
8+
import android.support.v4.content.ContextCompat;
89
import android.view.LayoutInflater;
910
import android.view.View;
1011
import android.view.ViewGroup;
@@ -72,9 +73,11 @@ private void _combineLatestEvents() {
7273
@Override
7374
public void onNext(Boolean formValid) {
7475
if (formValid) {
75-
_btnValidIndicator.setBackgroundColor(getResources().getColor(R.color.blue));
76+
_btnValidIndicator.setBackgroundColor(
77+
ContextCompat.getColor(getContext(), R.color.blue));
7678
} else {
77-
_btnValidIndicator.setBackgroundColor(getResources().getColor(R.color.gray));
79+
_btnValidIndicator.setBackgroundColor(
80+
ContextCompat.getColor(getContext(), R.color.gray));
7881
}
7982
}
8083

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /