Added widget option to disable separator lines

This commit is contained in:
M66B
2022-04-30 08:24:54 +02:00
parent 1d66c3426b
commit 9fc3fa16bb
5 changed files with 24 additions and 1 deletions

View File

@@ -49,6 +49,7 @@ public class WidgetUnified extends AppWidgetProvider {
long account = prefs.getLong("widget." + appWidgetId + ".account", -1L);
long folder = prefs.getLong("widget." + appWidgetId + ".folder", -1L);
String type = prefs.getString("widget." + appWidgetId + ".type", null);
boolean separators = prefs.getBoolean("widget." + appWidgetId + ".separators", true);
boolean semi = prefs.getBoolean("widget." + appWidgetId + ".semi", true);
int background = prefs.getInt("widget." + appWidgetId + ".background", Color.TRANSPARENT);
int font = prefs.getInt("widget." + appWidgetId + ".font", 0);
@@ -168,6 +169,8 @@ public class WidgetUnified extends AppWidgetProvider {
: R.drawable.twotone_edit_24_white);
}
views.setViewVisibility(R.id.separator, separators ? View.VISIBLE : View.GONE);
int dp6 = Helper.dp2pixels(context, 6);
views.setViewPadding(R.id.content, dp6, 0, dp6, 0);