diff options
author | Stefan Niedermann <info@niedermann.it> | 2020-05-12 16:49:49 +0300 |
---|---|---|
committer | Stefan Niedermann <info@niedermann.it> | 2020-05-12 16:49:49 +0300 |
commit | 2ba392f999aa7be7017a5ef4d72ac0d5e0e5031e (patch) | |
tree | 151718554bb1b3127b2804ea47444ccbb1ac5613 /app | |
parent | 4b5b964510ca5493d1b7a4c5c06a547840b187fe (diff) |
#217 SingleCardWidget
Diffstat (limited to 'app')
-rw-r--r-- | app/src/main/AndroidManifest.xml | 7 | ||||
-rw-r--r-- | app/src/main/res/layout/widget_single_card.xml | 8 | ||||
-rw-r--r-- | app/src/main/res/values-night/colors.xml | 2 | ||||
-rw-r--r-- | app/src/main/res/values/colors.xml | 1 | ||||
-rw-r--r-- | app/src/main/res/xml/widget_single_card_info.xml | 4 |
5 files changed, 18 insertions, 4 deletions
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index d81c47fd3..4cdbca33c 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -138,7 +138,12 @@ <activity android:name=".ui.widget.singlecard.SelectCardForWidgetActivity" android:label="@string/share_add_to_card" - android:theme="@style/SplashTheme" /> + android:theme="@style/SplashTheme"> + + <intent-filter> + <action android:name="android.appwidget.action.APPWIDGET_CONFIGURE" /> + </intent-filter> + </activity> <receiver android:name=".ui.widget.singlecard.SingleCardWidget"> <intent-filter> diff --git a/app/src/main/res/layout/widget_single_card.xml b/app/src/main/res/layout/widget_single_card.xml index c0efbbfe4..14b5a6a2c 100644 --- a/app/src/main/res/layout/widget_single_card.xml +++ b/app/src/main/res/layout/widget_single_card.xml @@ -5,7 +5,7 @@ android:id="@+id/widget_card" android:layout_width="match_parent" android:layout_height="match_parent" - android:background="@color/bg_info_box" + android:background="@color/widget_background" android:orientation="vertical" android:padding="@dimen/spacer_2x"> @@ -19,7 +19,9 @@ android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" + android:textColor="@color/grey600" android:textSize="18sp" + tools:maxLength="200" tools:text="@tools:sample/lorem/random" /> <TextView @@ -29,6 +31,7 @@ android:drawablePadding="@dimen/spacer_1hx" android:gravity="center" android:padding="@dimen/spacer_1hx" + android:textColor="@color/grey600" app:drawableStartCompat="@drawable/calendar_blank_grey600_24dp" tools:text="tomorrow" /> </LinearLayout> @@ -44,6 +47,7 @@ android:drawablePadding="@dimen/spacer_1hx" android:gravity="center_vertical" android:padding="@dimen/spacer_1hx" + android:textColor="@color/grey600" app:drawableLeftCompat="@drawable/ic_comment_white_24dp" app:drawableStartCompat="@drawable/ic_comment_white_24dp" app:drawableTint="@color/grey600" @@ -55,6 +59,7 @@ android:layout_height="wrap_content" android:gravity="center_vertical" android:padding="@dimen/spacer_1hx" + android:textColor="@color/grey600" app:drawableLeftCompat="@drawable/ic_check_grey600_24dp" app:drawableStartCompat="@drawable/ic_check_grey600_24dp" tools:text="1/2" /> @@ -65,6 +70,7 @@ android:layout_height="wrap_content" android:gravity="center_vertical" android:padding="@dimen/spacer_1hx" + android:textColor="@color/grey600" app:drawableLeftCompat="@drawable/ic_attach_file_grey600_24dp" app:drawableStartCompat="@drawable/ic_attach_file_grey600_24dp" tools:text="3" /> diff --git a/app/src/main/res/values-night/colors.xml b/app/src/main/res/values-night/colors.xml index da000d8f6..ce8d4e4e5 100644 --- a/app/src/main/res/values-night/colors.xml +++ b/app/src/main/res/values-night/colors.xml @@ -4,5 +4,7 @@ <color name="bg_highlighted">#2a2a2a</color> <color name="bg_info_box">#222222</color> <color name="avatars_overlapping_border_color">#424242</color> + <color name="widget_background">#212121</color> + <color name="widget_foreground">#f5f5f5</color> </resources> diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml index 21aa33c19..312cc9461 100644 --- a/app/src/main/res/values/colors.xml +++ b/app/src/main/res/values/colors.xml @@ -37,4 +37,5 @@ </string-array> <color name="widget_background">#f5f5f5</color> + <color name="widget_foreground">#212121</color> </resources> diff --git a/app/src/main/res/xml/widget_single_card_info.xml b/app/src/main/res/xml/widget_single_card_info.xml index 1ec00314c..f60de8a8b 100644 --- a/app/src/main/res/xml/widget_single_card_info.xml +++ b/app/src/main/res/xml/widget_single_card_info.xml @@ -2,8 +2,8 @@ xmlns:tools="http://schemas.android.com/tools" android:configure="it.niedermann.nextcloud.deck.ui.widget.singlecard.SelectCardForWidgetActivity" android:initialLayout="@layout/widget_single_card" - android:minWidth="60dp" - android:minHeight="80dp" + android:minWidth="80dp" + android:minHeight="40dp" android:previewImage="@drawable/ic_app_logo" android:resizeMode="horizontal|vertical" android:updatePeriodMillis="86400000" |