aboutsummaryrefslogtreecommitdiffstats
path: root/src/com/cyanogenmod/lockclock
diff options
context:
space:
mode:
authorDvTonder <david.vantonder@gmail.com>2013-03-28 16:40:15 -0400
committerDvTonder <david.vantonder@gmail.com>2013-03-28 16:44:03 -0400
commitbe49a05d836cb49819ad38da9aa76ed782a2e566 (patch)
treebc47086332442f8ab57f0eb762af0b22e5f05aff /src/com/cyanogenmod/lockclock
parentd98a33880e40cba01c5f0f5d285f29233937ad62 (diff)
downloadandroid_packages_apps_LockClock-be49a05d836cb49819ad38da9aa76ed782a2e566.tar.gz
android_packages_apps_LockClock-be49a05d836cb49819ad38da9aa76ed782a2e566.tar.bz2
android_packages_apps_LockClock-be49a05d836cb49819ad38da9aa76ed782a2e566.zip
cLock: Fix FC when using monochrome icons with an unknown condition code
Change-Id: I56bf948f9902a20b4153b8628afcec845a6d1bfd
Diffstat (limited to 'src/com/cyanogenmod/lockclock')
-rwxr-xr-xsrc/com/cyanogenmod/lockclock/weather/WeatherInfo.java6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/com/cyanogenmod/lockclock/weather/WeatherInfo.java b/src/com/cyanogenmod/lockclock/weather/WeatherInfo.java
index 331f6f8..fb7c5c5 100755
--- a/src/com/cyanogenmod/lockclock/weather/WeatherInfo.java
+++ b/src/com/cyanogenmod/lockclock/weather/WeatherInfo.java
@@ -68,11 +68,9 @@ public class WeatherInfo {
public int getConditionResource() {
final Resources res = mContext.getResources();
final int resId = res.getIdentifier("weather2_" + conditionCode, "drawable", mContext.getPackageName());
-
if (resId != 0) {
return resId;
}
-
return R.drawable.weather2_na;
}
@@ -80,7 +78,7 @@ public class WeatherInfo {
final Resources res = mContext.getResources();
int resId = res.getIdentifier("weather_" + conditionCode, "drawable", mContext.getPackageName());
if (resId == 0) {
- resId = res.getInteger(R.drawable.weather_na);
+ resId = R.drawable.weather_na;
}
return WidgetUtils.getOverlaidBitmap(mContext, resId, color);
}
@@ -92,11 +90,9 @@ public class WeatherInfo {
public String getCondition() {
final Resources res = mContext.getResources();
final int resId = res.getIdentifier("weather_" + conditionCode, "string", mContext.getPackageName());
-
if (resId != 0) {
return res.getString(resId);
}
-
return condition;
}