Refactoring

This commit is contained in:
M66B
2022-03-05 11:10:53 +01:00
parent ba0809ba2d
commit d060febc4d
7 changed files with 36 additions and 36 deletions

View File

@@ -59,9 +59,9 @@ public class WidgetSync extends AppWidgetProvider {
if (background == Color.TRANSPARENT) {
if (semi)
views.setInt(android.R.id.background, "setBackgroundResource", R.drawable.widget_background);
views.setInt(R.id.background, "setBackgroundResource", R.drawable.widget_background);
else
views.setInt(android.R.id.background, "setBackgroundColor", background);
views.setInt(R.id.background, "setBackgroundColor", background);
views.setInt(R.id.ivSync, "setColorFilter",
context.getResources().getColor(R.color.colorWidgetForeground));
} else {
@@ -70,7 +70,7 @@ public class WidgetSync extends AppWidgetProvider {
if (semi)
background = ColorUtils.setAlphaComponent(background, 127);
views.setInt(android.R.id.background, "setBackgroundColor", background);
views.setInt(R.id.background, "setBackgroundColor", background);
if (lum > 0.7f)
views.setInt(R.id.ivSync, "setColorFilter", Color.BLACK);