Add weather icon pack, updates frequency and fix google fit

This commit is contained in:
Tommaso Berlose
2020-05-12 23:54:07 +02:00
parent ba5a860e75
commit ac381c8542
89 changed files with 702 additions and 263 deletions

View File

@ -84,6 +84,7 @@
android:textColorHint="@color/colorSecondaryText"
android:textAlignment="viewStart"
android:id="@+id/search"
android:fontFamily="@font/product_sans"
android:gravity="center_vertical|start"
android:hint="@string/search"
android:text="@={viewModel.searchInput}"

View File

@ -87,6 +87,7 @@
android:maxLines="1"
android:singleLine="true"
android:hint="@string/settings_date_format_title"
android:fontFamily="@font/product_sans"
android:text="@={viewModel.dateInput}"
android:autofillHints=""
tools:ignore="TextFields" />
@ -116,7 +117,7 @@
android:layout_width="match_parent"
android:layout_height="48dp"
android:id="@+id/date_format_value"
android:textAppearance="@style/TextAppearance.AppCompat.Button"
android:textAppearance="@style/AnotherWidget.Settings.Title"
android:letterSpacing="0"
android:textColor="@color/colorPrimaryText"
android:textSize="20sp"

View File

@ -70,6 +70,7 @@
android:paddingRight="16dp"
android:inputType="textCapWords"
android:id="@+id/location"
android:fontFamily="@font/product_sans"
android:gravity="center_vertical|start"
android:hint="@string/search"
android:textAlignment="viewStart"

View File

@ -55,7 +55,7 @@
android:layout_height="wrap_content"
android:paddingBottom="20dp"
android:textColor="@color/colorSecondaryText"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textAppearance="@style/AnotherWidget.Settings.Subtitle"
android:textSize="16sp"
android:gravity="center"
android:text="@string/support_dev_subtitle" />

View File

@ -80,6 +80,7 @@
app:boxStrokeColor="@color/colorAccent"
app:hintTextColor="@color/colorAccent"
android:hint="@string/api_key_hint"
android:fontFamily="@font/product_sans"
android:textAlignment="viewStart"
android:textDirection="locale"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox">
@ -88,6 +89,7 @@
android:layout_height="wrap_content"
android:textAlignment="viewStart"
android:textDirection="locale"
android:fontFamily="@font/product_sans"
android:gravity="center_vertical|start" />
</com.google.android.material.textfield.TextInputLayout>
</LinearLayout>

View File

@ -16,7 +16,7 @@
android:paddingBottom="16dp"
android:orientation="vertical">
<androidx.appcompat.widget.AppCompatTextView
android:textAppearance="@style/TextAppearance.MaterialComponents.Button"
android:textAppearance="@style/AnotherWidget.Settings.Title"
app:textAllCaps="false"
android:letterSpacing="0"
android:layout_width="match_parent"
@ -29,7 +29,7 @@
android:text="Titolo"
android:textColor="@color/colorPrimaryText"/>
<androidx.appcompat.widget.AppCompatTextView
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:textAppearance="@style/AnotherWidget.Settings.Subtitle"
app:textAllCaps="false"
android:letterSpacing="0"
android:layout_width="match_parent"

View File

@ -11,7 +11,7 @@
android:visibility="gone"
android:orientation="vertical">
<androidx.appcompat.widget.AppCompatTextView
android:textAppearance="@style/TextAppearance.MaterialComponents.Button"
android:textAppearance="@style/AnotherWidget.Settings.Title"
app:textAllCaps="false"
android:letterSpacing="0"
android:layout_width="match_parent"
@ -22,12 +22,11 @@
android:paddingBottom="8dp"
android:paddingLeft="32dp"
android:paddingRight="32dp"
android:textSize="16sp"
android:id="@+id/header_text"
android:text=""
android:textColor="@color/colorPrimaryText"/>
<androidx.appcompat.widget.AppCompatTextView
android:textAppearance="@style/TextAppearance.MaterialComponents.Button"
android:textAppearance="@style/AnotherWidget.Settings.Subtitle"
app:textAllCaps="false"
android:letterSpacing="0"
android:layout_width="match_parent"
@ -38,7 +37,6 @@
android:paddingBottom="8dp"
android:paddingLeft="32dp"
android:paddingRight="32dp"
android:textSize="15sp"
android:id="@+id/warning_text"
android:text=""
android:textColor="@color/warningColorText"/>

View File

@ -21,6 +21,7 @@
android:duplicateParentState="true"
android:id="@+id/label"
android:textSize="15sp"
android:textStyle="bold"
android:textColor="@color/colorAccent"
android:textAppearance="@style/TextAppearance.AppCompat.Button"
app:textAllCaps="false" />

View File

@ -19,7 +19,7 @@
android:visibility="gone"
android:orientation="vertical">
<androidx.appcompat.widget.AppCompatTextView
android:textAppearance="@style/TextAppearance.MaterialComponents.Button"
android:textAppearance="@style/AnotherWidget.Settings.Title"
app:textAllCaps="false"
android:letterSpacing="0"
android:layout_width="match_parent"
@ -28,7 +28,6 @@
android:paddingBottom="8dp"
android:paddingLeft="32dp"
android:paddingRight="32dp"
android:textSize="16sp"
android:gravity="start"
android:textAlignment="viewStart"
android:id="@+id/header_text"
@ -49,7 +48,7 @@
android:gravity="center_vertical"
android:orientation="vertical">
<androidx.appcompat.widget.AppCompatTextView
android:textAppearance="@style/TextAppearance.MaterialComponents.Button"
android:textAppearance="@style/AnotherWidget.Settings.Subtitle"
app:textAllCaps="false"
android:letterSpacing="0"
android:layout_width="match_parent"
@ -58,7 +57,6 @@
android:paddingBottom="16dp"
android:paddingLeft="32dp"
android:paddingRight="32dp"
android:textSize="15sp"
android:gravity="start"
android:textAlignment="viewStart"
android:id="@+id/text_alpha"

View File

@ -25,9 +25,10 @@
android:paddingBottom="12dp"
android:duplicateParentState="true"
android:id="@+id/label"
android:textSize="15sp"
android:textSize="16sp"
android:textStyle="bold"
android:textColor="@drawable/menu_text_color"
android:textAppearance="@style/TextAppearance.AppCompat.Button"
android:textAppearance="@style/AnotherWidget.Settings.Subtitle"
app:textAllCaps="false" />
<androidx.appcompat.widget.AppCompatImageView
android:layout_width="24dp"

View File

@ -14,7 +14,7 @@
android:layout_weight="1"
android:layout_height="wrap_content"
android:textColor="@color/colorPrimaryText"
android:textAppearance="@style/TextAppearance.AppCompat.Button"
android:textAppearance="@style/AnotherWidget.Settings.Title"
app:textAllCaps="false"
android:gravity="start"
android:textSize="18sp"
@ -28,7 +28,7 @@
android:layout_height="wrap_content"
android:gravity="start"
android:textColor="@color/colorSecondaryText"
android:textAppearance="@style/TextAppearance.AppCompat.Button"
android:textAppearance="@style/AnotherWidget.Settings.Title"
app:textAllCaps="false"
android:textSize="18sp"
android:textAlignment="viewStart"

View File

@ -6,7 +6,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:orientation="vertical">
<androidx.appcompat.widget.AppCompatTextView
android:textAppearance="@style/TextAppearance.MaterialComponents.Button"
android:textAppearance="@style/AnotherWidget.Settings.Title"
app:textAllCaps="false"
android:letterSpacing="0"
android:layout_width="match_parent"
@ -29,7 +29,7 @@
android:background="@color/disabledButtonBackground" />
<EditText
android:layout_width="match_parent"
android:layout_height="48dp"
android:layout_height="64dp"
android:background="@color/colorPrimaryDark"
android:paddingStart="16dp"
android:paddingEnd="56dp"
@ -37,13 +37,12 @@
android:layout_marginStart="24dp"
android:layout_marginTop="8dp"
android:id="@+id/notes"
android:gravity="center_vertical|start"
android:gravity="center"
android:textDirection="locale"
android:textAlignment="viewStart"
android:lines="1"
android:inputType="textCapSentences"
android:maxLines="1"
android:singleLine="true"
android:fontFamily="@font/product_sans"
android:inputType="textCapSentences|textMultiLine"
android:maxLines="2"
android:lines="2"
android:autofillHints=""
tools:ignore="TextFields" />
<LinearLayout

View File

@ -45,6 +45,7 @@
android:layout_height="match_parent"
android:text="@string/app_name"
android:gravity="center"
android:textStyle="bold"
android:layout_marginBottom="1dp"
style="@style/AnotherWidget.Main.Title"/>
</LinearLayout>

View File

@ -274,6 +274,43 @@
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:clickable="true"
android:focusable="true"
android:background="?android:attr/selectableItemBackground"
android:gravity="center_vertical"
android:id="@+id/action_widget_update_frequency"
android:orientation="horizontal">
<ImageView
android:layout_width="48dp"
android:layout_height="48dp"
android:padding="12dp"
android:src="@drawable/round_update"
android:tint="@color/colorPrimaryText"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
style="@style/AnotherWidget.Settings.Title"
android:text="@string/settings_widget_update_frequency_title"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/widget_update_frequency_label"
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"

View File

@ -48,7 +48,7 @@
android:text="@string/clock_warning"
android:textColor="@color/colorPrimaryText"
android:letterSpacing="0"
android:textAppearance="@style/TextAppearance.AppCompat.Button"
android:textAppearance="@style/AnotherWidget.Settings.Title"
app:textAllCaps="false" />
<com.google.android.material.button.MaterialButton
android:layout_width="wrap_content"
@ -149,6 +149,43 @@
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:clickable="true"
android:focusable="true"
android:background="?android:attr/selectableItemBackground"
android:gravity="center_vertical"
android:id="@+id/action_clock_text_color"
android:orientation="horizontal">
<ImageView
android:layout_width="48dp"
android:layout_height="48dp"
android:padding="12dp"
android:src="@drawable/round_palette"
android:tint="@color/colorPrimaryText"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
style="@style/AnotherWidget.Settings.Title"
android:text="@string/settings_clock_text_color_title"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/clock_text_color_label"
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
@ -187,43 +224,6 @@
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:clickable="true"
android:focusable="true"
android:background="?android:attr/selectableItemBackground"
android:gravity="center_vertical"
android:id="@+id/action_clock_text_color"
android:orientation="horizontal">
<ImageView
android:layout_width="48dp"
android:layout_height="48dp"
android:padding="12dp"
android:src="@drawable/round_palette"
android:tint="@color/colorPrimaryText"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
style="@style/AnotherWidget.Settings.Title"
android:text="@string/settings_clock_text_color_title"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/clock_text_color_label"
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
@ -316,6 +316,7 @@
android:text="@string/clock_warning"
android:textColor="@color/colorPrimaryText"
android:letterSpacing="0"
android:fontFamily="@font/product_sans"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
app:textAllCaps="false" />
</LinearLayout>

View File

@ -55,6 +55,43 @@
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:clickable="true"
android:focusable="true"
android:background="?android:attr/selectableItemBackground"
android:gravity="center_vertical"
android:id="@+id/action_font_color"
android:orientation="horizontal">
<ImageView
android:layout_width="48dp"
android:layout_height="48dp"
android:padding="12dp"
android:src="@drawable/round_palette"
android:tint="@color/colorPrimaryText"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
style="@style/AnotherWidget.Settings.Title"
android:text="@string/settings_font_color_title"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/font_color_label"
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
@ -103,7 +140,7 @@
android:focusable="true"
android:background="?android:attr/selectableItemBackground"
android:gravity="center_vertical"
android:id="@+id/action_font_color"
android:id="@+id/action_secondary_font_color"
android:orientation="horizontal">
<ImageView
android:layout_width="48dp"
@ -121,11 +158,11 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
style="@style/AnotherWidget.Settings.Title"
android:text="@string/settings_font_color_title"/>
android:text="@string/settings_secondary_font_color_title"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/font_color_label"
android:id="@+id/secondary_font_color_label"
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>

View File

@ -45,7 +45,7 @@
android:text="@string/settings_title"
android:textColor="@color/colorPrimaryText"
android:gravity="center"
android:textAppearance="@style/TextAppearance.AppCompat.Title"
android:textAppearance="@style/AnotherWidget.Main.Title"
tools:ignore="RelativeOverlap" />
</RelativeLayout>
</com.google.android.material.card.MaterialCardView>

View File

@ -48,7 +48,7 @@
android:text="@string/weather_warning"
android:textColor="@color/colorPrimaryText"
android:letterSpacing="0"
android:textAppearance="@style/TextAppearance.AppCompat.Button"
android:textAppearance="@style/AnotherWidget.Settings.Title"
app:textAllCaps="false" />
<com.google.android.material.button.MaterialButton
android:layout_width="wrap_content"
@ -286,6 +286,43 @@
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:clickable="true"
android:focusable="true"
android:background="?android:attr/selectableItemBackground"
android:gravity="center_vertical"
android:id="@+id/action_weather_icon_pack"
android:orientation="horizontal">
<ImageView
android:layout_width="48dp"
android:layout_height="48dp"
android:padding="12dp"
android:src="@drawable/round_cloud_queue"
android:tint="@color/colorPrimaryText"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
style="@style/AnotherWidget.Settings.Title"
android:text="@string/settings_weather_icon_pack_title"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/label_weather_icon_pack"
style="@style/AnotherWidget.Settings.Subtitle"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"

View File

@ -39,22 +39,6 @@
android:textSize="16sp"
style="@style/AnotherWidget.Settings.Title"
android:text="@string/settings_show_music_title"/>
<com.google.android.material.button.MaterialButton
android:layout_width="wrap_content"
android:layout_height="36dp"
style="@style/Widget.MaterialComponents.Button.TextButton"
android:letterSpacing="0"
android:textAllCaps="false"
android:clickable="true"
android:layout_marginStart="-8dp"
android:layout_marginBottom="-8dp"
android:paddingBottom="0dp"
android:paddingTop="0dp"
android:focusable="true"
android:visibility="gone"
android:id="@+id/button"
android:textColor="@color/errorColorText"
android:text="@string/action_grant_permission"/>
</LinearLayout>
<ImageView
android:layout_width="48dp"

View File

@ -10,7 +10,7 @@
android:id="@+id/header"
android:orientation="vertical">
<androidx.appcompat.widget.AppCompatTextView
android:textAppearance="@style/TextAppearance.MaterialComponents.Button"
android:textAppearance="@style/AnotherWidget.Settings.Title"
app:textAllCaps="false"
android:letterSpacing="0"
android:layout_width="match_parent"

View File

@ -26,7 +26,7 @@
android:textSize="16sp"
android:textColor="@color/colorPrimaryText"
android:letterSpacing="0"
android:textAppearance="@style/TextAppearance.MaterialComponents.Button"/>
android:textAppearance="@style/AnotherWidget.Settings.Title"/>
<com.google.android.material.card.MaterialCardView
android:layout_width="wrap_content"
@ -42,6 +42,7 @@
android:paddingRight="12dp"
android:gravity="center"
android:text="12.00$"
android:fontFamily="@font/product_sans"
android:textColor="@color/colorAccent"
android:id="@+id/product_price"
android:textSize="14sp"/>

View File

@ -43,7 +43,7 @@
android:layout_height="20dp"
android:id="@+id/empty_weather_icon"
android:layout_marginStart="4dp"
android:layout_marginEnd="4dp"/>
android:layout_marginEnd="8dp"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@ -156,9 +156,9 @@
<TextView
android:id="@+id/next_event_date"
android:layout_width="wrap_content"
android:ellipsize="end"
android:lines="1"
android:maxLines="1"
android:ellipsize="end"
android:includeFontPadding="false"
android:layout_height="wrap_content"
style="@style/AnotherWidget.Subtitle" />