Skip to content

Commit 036748e

Browse files
committed
Add additional layout options to support SDK<17
Google Play statistics show that the earliest Android version in use which has installs for this app is 4.0.3, which is SDK 15. This changes cleans up some layouts so that it will work on SDK 15.
1 parent 5cae974 commit 036748e

File tree

3 files changed

+21
-7
lines changed

3 files changed

+21
-7
lines changed

app/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ android {
1111

1212
defaultConfig {
1313
applicationId "protect.card_locker"
14-
minSdkVersion 17
14+
minSdkVersion 15
1515
targetSdkVersion 27
1616
versionCode 26
1717
versionName "0.23.1"

app/src/main/res/layout/loyalty_card_edit_activity.xml

+19-6
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@
6161
android:layout_width="wrap_content"
6262
android:textSize="@dimen/inputSize"
6363
android:padding="@dimen/inputPadding"
64-
android:layout_alignParentStart="true"/>
64+
android:layout_alignParentStart="true"
65+
android:layout_alignParentLeft="true"/>
6566

6667
<EditText
6768
android:id="@+id/storeNameEdit"
@@ -70,7 +71,9 @@
7071
android:layout_width="match_parent"
7172
android:padding="@dimen/inputPadding"
7273
android:textSize="@dimen/inputSize"
73-
android:layout_toEndOf="@id/storeNameField"/>
74+
android:layout_toEndOf="@id/storeNameField"
75+
android:layout_toRightOf="@id/storeNameField"
76+
/>
7477

7578
</RelativeLayout>
7679

@@ -110,7 +113,9 @@
110113
android:layout_width="wrap_content"
111114
android:textSize="@dimen/inputSize"
112115
android:padding="@dimen/inputPadding"
113-
android:layout_alignParentStart="true"/>
116+
android:layout_alignParentStart="true"
117+
android:layout_alignParentLeft="true"
118+
/>
114119

115120
<EditText
116121
android:id="@+id/noteEdit"
@@ -119,7 +124,9 @@
119124
android:layout_width="match_parent"
120125
android:padding="@dimen/inputPadding"
121126
android:textSize="@dimen/inputSize"
122-
android:layout_toEndOf="@id/noteField"/>
127+
android:layout_toEndOf="@id/noteField"
128+
android:layout_toRightOf="@id/noteField"
129+
/>
123130
</RelativeLayout>
124131

125132
<View
@@ -190,6 +197,7 @@
190197
android:layout_width="wrap_content"
191198
android:layout_height="match_parent"
192199
android:layout_toEndOf="@id/headingColorSampleBorder"
200+
android:layout_toRightOf="@id/headingColorSampleBorder"
193201
app:layout_constraintEnd_toEndOf="parent"/>
194202
</android.support.constraint.ConstraintLayout>
195203

@@ -261,6 +269,7 @@
261269
android:layout_width="wrap_content"
262270
android:layout_height="match_parent"
263271
android:layout_toEndOf="@id/headingStoreTextColorSampleBorder"
272+
android:layout_toRightOf="@id/headingStoreTextColorSampleBorder"
264273
app:layout_constraintEnd_toEndOf="parent"/>
265274
</android.support.constraint.ConstraintLayout>
266275

@@ -303,7 +312,9 @@
303312
android:layout_width="wrap_content"
304313
android:textSize="@dimen/inputSize"
305314
android:padding="@dimen/inputPadding"
306-
android:layout_alignParentStart="true"/>
315+
android:layout_alignParentStart="true"
316+
android:layout_alignParentLeft="true"
317+
/>
307318

308319
<TextView
309320
android:id="@+id/cardIdView"
@@ -312,7 +323,9 @@
312323
android:padding="@dimen/inputPadding"
313324
android:textSize="@dimen/inputSize"
314325
android:textIsSelectable="true"
315-
android:layout_toEndOf="@id/cardIdField"/>
326+
android:layout_toEndOf="@id/cardIdField"
327+
android:layout_toRightOf="@id/cardIdField"
328+
/>
316329
</RelativeLayout>
317330

318331
<View

app/src/main/res/layout/loyalty_card_layout.xml

+1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
android:layout_width="@dimen/cardThumbnailSize"
1414
android:layout_height="@dimen/cardThumbnailSize"
1515
android:layout_marginEnd="@dimen/activity_margin"
16+
android:layout_marginRight="@dimen/activity_margin"
1617
android:src="@mipmap/ic_launcher"
1718
android:contentDescription="@string/thumbnailDescription"/>
1819

0 commit comments

Comments
 (0)