Small improvements

This commit is contained in:
M66B 2019-11-15 14:02:50 +01:00
parent 7d551073d8
commit 4981b569b5
3 changed files with 7 additions and 3 deletions

View File

@ -65,7 +65,7 @@ public class ActivityWidgetUnified extends ActivityBase {
appWidgetId = extras.getInt(
AppWidgetManager.EXTRA_APPWIDGET_ID, AppWidgetManager.INVALID_APPWIDGET_ID);
getSupportActionBar().setSubtitle(R.string.title_folder_unified);
getSupportActionBar().setSubtitle(R.string.title_widget_title_list);
setContentView(R.layout.activity_widget_unified);
spAccount = findViewById(R.id.spAccount);
@ -153,6 +153,8 @@ public class ActivityWidgetUnified extends ActivityBase {
adapterFolder.clear();
adapterFolder.addAll(folders);
spFolder.setSelection(0);
}
@Override

View File

@ -80,7 +80,9 @@ public class WidgetUnified extends AppWidgetProvider {
views.setViewVisibility(R.id.pro, pro ? View.GONE : View.VISIBLE);
if (pro) {
String name = prefs.getString("widget." + appWidgetId + ".name", null);
if (name != null)
if (name == null)
views.setTextViewText(R.id.title, context.getString(R.string.title_folder_unified));
else
views.setTextViewText(R.id.title, name);
views.setOnClickPendingIntent(R.id.title, pi);

View File

@ -14,7 +14,7 @@
android:gravity="center"
android:paddingTop="6dp"
android:paddingBottom="6dp"
android:text="@string/title_folder_unified"
android:text="@string/title_widget_title_list"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:textColor="@color/colorWidgetForeground"
android:textStyle="bold" />