From 2109b0ed66b507bfe8e0b4cc541184a0bcee917b Mon Sep 17 00:00:00 2001 From: Michael Rapp Date: Sun, 19 Apr 2015 20:08:14 +0200 Subject: [PATCH] Suppressed deprecation warnings. --- .../mrapp/android/preference/activity/PreferenceActivity.java | 4 ++++ .../mrapp/android/preference/activity/PreferenceFragment.java | 1 + .../preference/activity/adapter/PreferenceHeaderAdapter.java | 1 + 3 files changed, 6 insertions(+) diff --git a/src/de/mrapp/android/preference/activity/PreferenceActivity.java b/src/de/mrapp/android/preference/activity/PreferenceActivity.java index 729fd24..c9941a6 100644 --- a/src/de/mrapp/android/preference/activity/PreferenceActivity.java +++ b/src/de/mrapp/android/preference/activity/PreferenceActivity.java @@ -1794,6 +1794,7 @@ public final Drawable getPreferenceScreenBackground() { * valid drawable resource * @return True, if the background has been set, false otherwise */ + @SuppressWarnings("deprecation") public final boolean setPreferenceScreenBackground(final int resourceId) { return setPreferenceScreenBackground(getResources().getDrawable( resourceId)); @@ -1855,6 +1856,7 @@ public final Drawable getNavigationBackground() { * {@link Integer} value. The resource id must correspond to a * valid drawable resource */ + @SuppressWarnings("deprecation") public final void setNavigationBackground(final int resourceId) { setNavigationBackground(getResources().getDrawable(resourceId)); } @@ -1912,6 +1914,7 @@ public final Drawable getButtonBarBackground() { * valid drawable resource * @return True, if the background has been set, false otherwise */ + @SuppressWarnings("deprecation") public final boolean setButtonBarBackground(final int resourceId) { return setButtonBarBackground(getResources().getDrawable(resourceId)); } @@ -1981,6 +1984,7 @@ public final Drawable getBreadCrumbBackground() { * valid drawable resource * @return True, if the background has been set, false otherwise */ + @SuppressWarnings("deprecation") public final boolean setBreadCrumbBackground(final int resourceId) { return setBreadCrumbBackground(getResources().getDrawable(resourceId)); } diff --git a/src/de/mrapp/android/preference/activity/PreferenceFragment.java b/src/de/mrapp/android/preference/activity/PreferenceFragment.java index 8456fd7..dcde5dc 100644 --- a/src/de/mrapp/android/preference/activity/PreferenceFragment.java +++ b/src/de/mrapp/android/preference/activity/PreferenceFragment.java @@ -591,6 +591,7 @@ public final Drawable getButtonBarBackground() { * valid drawable resource * @return True, if the background has been set, false otherwise */ + @SuppressWarnings("deprecation") public final boolean setButtonBarBackground(final int resourceId) { return setButtonBarBackground(getResources().getDrawable(resourceId)); } diff --git a/src/de/mrapp/android/preference/activity/adapter/PreferenceHeaderAdapter.java b/src/de/mrapp/android/preference/activity/adapter/PreferenceHeaderAdapter.java index 1d88dc8..70f914a 100644 --- a/src/de/mrapp/android/preference/activity/adapter/PreferenceHeaderAdapter.java +++ b/src/de/mrapp/android/preference/activity/adapter/PreferenceHeaderAdapter.java @@ -250,6 +250,7 @@ private void visualizePreferenceHeaderSummary(final ViewHolder viewHolder, * instance of the class {@link PreferenceHeader}. The preference * header may not be null */ + @SuppressWarnings("deprecation") private void visualizePreferenceHeaderIcon(final ViewHolder viewHolder, final PreferenceHeader preferenceHeader) { if (viewHolder.iconImageView != null) {