Skip to content

Commit d0e7f4f

Browse files
committed
refactor: extract reusable dimens from xml
1 parent d78cc7f commit d0e7f4f

3 files changed

Lines changed: 14 additions & 4 deletions

File tree

app/src/main/res/values/dimens.xml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<resources>
3+
<dimen name="appwidget_min_width">140dp</dimen>
4+
<dimen name="appwidget_min_height">110dp</dimen>
5+
</resources>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<resources>
3+
<integer name="appwidget_target_cell_width">4</integer>
4+
<integer name="appwidget_target_cell_height">2</integer>
5+
</resources>

app/src/main/res/xml/appwidget_info_price.xml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<appwidget-provider xmlns:android="http://schemas.android.com/apk/res/android"
3-
android:minWidth="140dp"
4-
android:minHeight="110dp"
5-
android:targetCellWidth="4"
6-
android:targetCellHeight="2"
3+
android:minWidth="@dimen/appwidget_min_width"
4+
android:minHeight="@dimen/appwidget_min_height"
5+
android:targetCellWidth="@integer/appwidget_target_cell_width"
6+
android:targetCellHeight="@integer/appwidget_target_cell_height"
77
android:resizeMode="horizontal|vertical"
88
android:widgetCategory="home_screen"
99
android:initialLayout="@layout/glance_default_loading_layout"

0 commit comments

Comments
 (0)