質問編集履歴
1
xmlファイルのコードを追加しました
test
CHANGED
File without changes
|
test
CHANGED
@@ -204,5 +204,99 @@
|
|
204
204
|
|
205
205
|
|
206
206
|
}
|
207
|
-
|
207
|
+
```java
|
208
|
-
|
208
|
+
activity_main.xml
|
209
|
+
|
210
|
+
<?xml version="1.0" encoding="utf-8"?>
|
211
|
+
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
212
|
+
xmlns:app="http://schemas.android.com/apk/res-auto"
|
213
|
+
xmlns:tools="http://schemas.android.com/tools"
|
214
|
+
android:layout_width="match_parent"
|
215
|
+
android:layout_height="match_parent">
|
216
|
+
|
217
|
+
<TextView
|
218
|
+
android:id="@+id/P2"
|
219
|
+
android:layout_width="0dp"
|
220
|
+
android:layout_height="0dp"
|
221
|
+
android:layout_marginStart="8dp"
|
222
|
+
android:layout_marginEnd="8dp"
|
223
|
+
android:layout_marginBottom="13dp"
|
224
|
+
android:hint="dealer"
|
225
|
+
android:textSize="20sp"
|
226
|
+
app:layout_constraintBottom_toTopOf="@+id/stand"
|
227
|
+
app:layout_constraintEnd_toEndOf="parent"
|
228
|
+
app:layout_constraintStart_toStartOf="parent"
|
229
|
+
app:layout_constraintTop_toBottomOf="@+id/P1" />
|
230
|
+
|
231
|
+
<Button
|
232
|
+
android:id="@+id/stand"
|
233
|
+
android:layout_width="0dp"
|
234
|
+
android:layout_height="0dp"
|
235
|
+
android:layout_marginBottom="22dp"
|
236
|
+
android:onClick="hiku"
|
237
|
+
android:text="sTand"
|
238
|
+
app:layout_constraintBottom_toTopOf="@+id/hit"
|
239
|
+
app:layout_constraintEnd_toEndOf="parent"
|
240
|
+
app:layout_constraintStart_toStartOf="parent"
|
241
|
+
app:layout_constraintTop_toBottomOf="@+id/P2" />
|
242
|
+
|
243
|
+
<Button
|
244
|
+
android:id="@+id/hit"
|
245
|
+
android:layout_width="0dp"
|
246
|
+
android:layout_height="0dp"
|
247
|
+
android:layout_marginBottom="38dp"
|
248
|
+
android:onClick="hiku"
|
249
|
+
android:text="hIt"
|
250
|
+
app:layout_constraintBottom_toTopOf="@+id/reset"
|
251
|
+
app:layout_constraintEnd_toEndOf="parent"
|
252
|
+
app:layout_constraintStart_toStartOf="parent"
|
253
|
+
app:layout_constraintTop_toBottomOf="@+id/stand" />
|
254
|
+
|
255
|
+
<TextView
|
256
|
+
android:id="@+id/P1"
|
257
|
+
android:layout_width="0dp"
|
258
|
+
android:layout_height="0dp"
|
259
|
+
android:layout_marginStart="12dp"
|
260
|
+
android:layout_marginEnd="12dp"
|
261
|
+
android:layout_marginBottom="16dp"
|
262
|
+
android:hint="player"
|
263
|
+
android:textSize="20sp"
|
264
|
+
app:layout_constraintBottom_toTopOf="@+id/P2"
|
265
|
+
app:layout_constraintEnd_toEndOf="parent"
|
266
|
+
app:layout_constraintStart_toStartOf="parent"
|
267
|
+
app:layout_constraintTop_toBottomOf="@+id/TiT" />
|
268
|
+
|
269
|
+
|
270
|
+
<TextView
|
271
|
+
android:id="@+id/TiT"
|
272
|
+
android:layout_width="0dp"
|
273
|
+
android:layout_height="0dp"
|
274
|
+
android:layout_marginStart="8dp"
|
275
|
+
android:layout_marginTop="52dp"
|
276
|
+
android:layout_marginEnd="8dp"
|
277
|
+
android:layout_marginBottom="14dp"
|
278
|
+
android:inputType="textMultiLine"
|
279
|
+
android:text=''
|
280
|
+
android:textSize="20sp"
|
281
|
+
app:layout_constraintBottom_toTopOf="@+id/P1"
|
282
|
+
app:layout_constraintEnd_toEndOf="parent"
|
283
|
+
app:layout_constraintHorizontal_bias="1.0"
|
284
|
+
app:layout_constraintStart_toStartOf="parent"
|
285
|
+
app:layout_constraintTop_toTopOf="parent"
|
286
|
+
tools:ignore="SpeakableTextPresentCheck" />
|
287
|
+
|
288
|
+
<Button
|
289
|
+
android:id="@+id/reset"
|
290
|
+
android:layout_width="wrap_content"
|
291
|
+
android:layout_height="wrap_content"
|
292
|
+
android:layout_marginBottom="268dp"
|
293
|
+
android:text="Button"
|
294
|
+
app:layout_constraintBottom_toBottomOf="parent"
|
295
|
+
app:layout_constraintEnd_toEndOf="parent"
|
296
|
+
app:layout_constraintStart_toStartOf="parent"
|
297
|
+
app:layout_constraintTop_toBottomOf="@+id/hit"
|
298
|
+
tools:ignore="UsingOnClickInXml" />
|
299
|
+
|
300
|
+
|
301
|
+
</androidx.constraintlayout.widget.ConstraintLayout>
|
302
|
+
```
|