Skip to content

Commit 37518da

Browse files
authored
Improve the edit dialog fragment. (#393)
- Able to put MinWidth, MinHeight, MaxWidth and MaxHeight as either of one line [MinWidth] [MinHeight] [MaxWidth] [MaxHeight] OR Two line such as [MinWidth] [MinHeight] [MaxWidth] [MaxHeight] Instead of being placed as follows [MinWidth] [MinHeight] [MaxWidth] [MaxHeight] - Give WrapBefore smaller space so that it's more likely that AlignSelf spinner is placed in the same line
1 parent b5ce3f1 commit 37518da

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

demo-playground/src/main/res/layout/fragment_flex_item_edit.xml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,10 @@ limitations under the License.
128128

129129
<android.support.design.widget.TextInputLayout
130130
android:id="@+id/input_layout_min_width"
131-
android:layout_width="150dp"
131+
android:layout_width="0dp"
132132
android:layout_height="wrap_content"
133+
app:layout_flexBasisPercent="22%"
134+
app:layout_minWidth="130dp"
133135
app:layout_wrapBefore="true"
134136
app:layout_flexGrow="1">
135137

@@ -145,8 +147,10 @@ limitations under the License.
145147

146148
<android.support.design.widget.TextInputLayout
147149
android:id="@+id/input_layout_min_height"
148-
android:layout_width="150dp"
150+
android:layout_width="0dp"
149151
android:layout_height="wrap_content"
152+
app:layout_flexBasisPercent="22%"
153+
app:layout_minWidth="130dp"
150154
app:layout_flexGrow="1">
151155

152156
<EditText
@@ -161,8 +165,10 @@ limitations under the License.
161165

162166
<android.support.design.widget.TextInputLayout
163167
android:id="@+id/input_layout_max_width"
164-
android:layout_width="150dp"
168+
android:layout_width="0dp"
165169
android:layout_height="wrap_content"
170+
app:layout_flexBasisPercent="22%"
171+
app:layout_minWidth="130dp"
166172
app:layout_flexGrow="1">
167173

168174
<EditText
@@ -177,8 +183,10 @@ limitations under the License.
177183

178184
<android.support.design.widget.TextInputLayout
179185
android:id="@+id/input_layout_max_height"
180-
android:layout_width="150dp"
186+
android:layout_width="0dp"
181187
android:layout_height="wrap_content"
188+
app:layout_flexBasisPercent="22%"
189+
app:layout_minWidth="130dp"
182190
app:layout_flexGrow="1">
183191

184192
<EditText
@@ -193,7 +201,7 @@ limitations under the License.
193201

194202
<CheckBox
195203
android:id="@+id/checkbox_wrap_before"
196-
android:layout_width="150dp"
204+
android:layout_width="130dp"
197205
android:layout_height="wrap_content"
198206
android:text="@string/hint_wrap_before"
199207
app:layout_wrapBefore="true"

0 commit comments

Comments
 (0)