質問編集履歴
4
写真の変更
test
CHANGED
File without changes
|
test
CHANGED
@@ -286,6 +286,6 @@
|
|
286
286
|
|
287
287
|
|
288
288
|
|
289
|
-
![イメージ説明](
|
289
|
+
![イメージ説明](f13e09cc8f287780da7436b2ec9e553a.png)
|
290
290
|
|
291
291
|
どうぞよろしくお願いします。
|
3
写真の追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -286,6 +286,6 @@
|
|
286
286
|
|
287
287
|
|
288
288
|
|
289
|
-
|
289
|
+
![イメージ説明](1b4ffa67f6a126ec14b80785e136824e.png)
|
290
290
|
|
291
291
|
どうぞよろしくお願いします。
|
2
マニフェストファイルの追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -234,4 +234,58 @@
|
|
234
234
|
|
235
235
|
```
|
236
236
|
|
237
|
+
manifestfileです。
|
238
|
+
|
239
|
+
```xml
|
240
|
+
|
241
|
+
<?xml version="1.0" encoding="utf-8"?>
|
242
|
+
|
243
|
+
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
244
|
+
|
245
|
+
package="jp.study.example37" >
|
246
|
+
|
247
|
+
|
248
|
+
|
249
|
+
<application
|
250
|
+
|
251
|
+
android:allowBackup="true"
|
252
|
+
|
253
|
+
android:icon="@mipmap/ic_launcher"
|
254
|
+
|
255
|
+
android:label="@string/app_name"
|
256
|
+
|
257
|
+
android:supportsRtl="true"
|
258
|
+
|
259
|
+
android:theme="@style/AppTheme" >
|
260
|
+
|
261
|
+
<activity
|
262
|
+
|
263
|
+
android:name=".MainActivity"
|
264
|
+
|
265
|
+
android:label="@string/app_name"
|
266
|
+
|
267
|
+
android:theme="@style/AppTheme.NoActionBar" >
|
268
|
+
|
269
|
+
<intent-filter>
|
270
|
+
|
271
|
+
<action android:name="android.intent.action.MAIN" />
|
272
|
+
|
273
|
+
|
274
|
+
|
275
|
+
<category android:name="android.intent.category.LAUNCHER" />
|
276
|
+
|
277
|
+
</intent-filter>
|
278
|
+
|
279
|
+
</activity>
|
280
|
+
|
281
|
+
</application>
|
282
|
+
|
283
|
+
|
284
|
+
|
285
|
+
</manifest>
|
286
|
+
|
287
|
+
|
288
|
+
|
289
|
+
```
|
290
|
+
|
237
291
|
どうぞよろしくお願いします。
|
1
コードを追加しました。
test
CHANGED
File without changes
|
test
CHANGED
@@ -43,3 +43,195 @@
|
|
43
43
|
エラーはこのようなものです。
|
44
44
|
|
45
45
|
どうぞよろしくお願いします。
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
activity_chat.xml
|
50
|
+
|
51
|
+
```xml
|
52
|
+
|
53
|
+
<?xml version="1.0" encoding="utf-8"?>
|
54
|
+
|
55
|
+
<android.support.design.widget.CoordinatorLayout
|
56
|
+
|
57
|
+
xmlns:android="http://schemas.android.com/apk/res/android"
|
58
|
+
|
59
|
+
xmlns:app="http://schemas.android.com/apk/res-auto"
|
60
|
+
|
61
|
+
xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent"
|
62
|
+
|
63
|
+
android:layout_height="match_parent" android:fitsSystemWindows="true"
|
64
|
+
|
65
|
+
tools:context=".ChatActivity">
|
66
|
+
|
67
|
+
|
68
|
+
|
69
|
+
<android.support.design.widget.AppBarLayout android:layout_height="wrap_content"
|
70
|
+
|
71
|
+
android:layout_width="match_parent" android:theme="@style/AppTheme.AppBarOverlay">
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
<android.support.v7.widget.Toolbar android:id="@+id/toolbar"
|
76
|
+
|
77
|
+
android:layout_width="match_parent" android:layout_height="?attr/actionBarSize"
|
78
|
+
|
79
|
+
android:background="?attr/colorPrimary" app:popupTheme="@style/AppTheme.PopupOverlay" />
|
80
|
+
|
81
|
+
|
82
|
+
|
83
|
+
</android.support.design.widget.AppBarLayout>
|
84
|
+
|
85
|
+
|
86
|
+
|
87
|
+
<include layout="@layout/content_chat" />
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
<android.support.design.widget.FloatingActionButton android:id="@+id/fab"
|
92
|
+
|
93
|
+
android:layout_width="wrap_content" android:layout_height="wrap_content"
|
94
|
+
|
95
|
+
android:layout_gravity="bottom|end" android:layout_margin="@dimen/fab_margin"
|
96
|
+
|
97
|
+
android:src="@android:drawable/ic_dialog_email" />
|
98
|
+
|
99
|
+
|
100
|
+
|
101
|
+
</android.support.design.widget.CoordinatorLayout>
|
102
|
+
|
103
|
+
|
104
|
+
|
105
|
+
```
|
106
|
+
|
107
|
+
content_chat.xml
|
108
|
+
|
109
|
+
```xml
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
<?xml version="1.0" encoding="utf-8"?>
|
114
|
+
|
115
|
+
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
116
|
+
|
117
|
+
xmlns:tools="http://schemas.android.com/tools"
|
118
|
+
|
119
|
+
|
120
|
+
|
121
|
+
android:layout_width="match_parent"
|
122
|
+
|
123
|
+
android:layout_height="match_parent"
|
124
|
+
|
125
|
+
android:paddingLeft="@dimen/activity_horizontal_margin"
|
126
|
+
|
127
|
+
android:paddingRight="@dimen/activity_horizontal_margin"
|
128
|
+
|
129
|
+
android:paddingTop="@dimen/activity_vertical_margin"
|
130
|
+
|
131
|
+
android:paddingBottom="@dimen/activity_vertical_margin"
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
tools:context=".ChatActivity">
|
136
|
+
|
137
|
+
|
138
|
+
|
139
|
+
|
140
|
+
|
141
|
+
|
142
|
+
|
143
|
+
<EditText
|
144
|
+
|
145
|
+
android:layout_width="wrap_content"
|
146
|
+
|
147
|
+
android:layout_height="wrap_content"
|
148
|
+
|
149
|
+
android:id="@+id/input_message"
|
150
|
+
|
151
|
+
android:layout_alignParentTop="true"
|
152
|
+
|
153
|
+
android:layout_alignParentLeft="true"
|
154
|
+
|
155
|
+
android:layout_alignParentStart="true"
|
156
|
+
|
157
|
+
android:layout_toLeftOf="@+id/send_message"
|
158
|
+
|
159
|
+
android:layout_toStartOf="@+id/send_message" />
|
160
|
+
|
161
|
+
|
162
|
+
|
163
|
+
<Button
|
164
|
+
|
165
|
+
android:layout_width="wrap_content"
|
166
|
+
|
167
|
+
android:layout_height="wrap_content"
|
168
|
+
|
169
|
+
android:text="SEND"
|
170
|
+
|
171
|
+
android:id="@+id/send_message"
|
172
|
+
|
173
|
+
android:layout_alignParentTop="true"
|
174
|
+
|
175
|
+
android:layout_alignParentRight="true"
|
176
|
+
|
177
|
+
android:layout_alignParentEnd="true" />
|
178
|
+
|
179
|
+
|
180
|
+
|
181
|
+
<LinearLayout
|
182
|
+
|
183
|
+
android:orientation="vertical"
|
184
|
+
|
185
|
+
android:layout_width="fill_parent"
|
186
|
+
|
187
|
+
android:layout_height="fill_parent"
|
188
|
+
|
189
|
+
android:layout_below="@+id/input_message"
|
190
|
+
|
191
|
+
android:layout_alignParentLeft="true"
|
192
|
+
|
193
|
+
android:layout_alignParentStart="true"
|
194
|
+
|
195
|
+
android:id="@+id/message_log">
|
196
|
+
|
197
|
+
|
198
|
+
|
199
|
+
<TextView
|
200
|
+
|
201
|
+
android:layout_width="wrap_content"
|
202
|
+
|
203
|
+
android:layout_height="wrap_content"
|
204
|
+
|
205
|
+
android:text="こんにちは"
|
206
|
+
|
207
|
+
android:id="@+id/cpu_message"
|
208
|
+
|
209
|
+
android:layout_gravity="start"/>
|
210
|
+
|
211
|
+
|
212
|
+
|
213
|
+
<TextView
|
214
|
+
|
215
|
+
android:layout_width="wrap_content"
|
216
|
+
|
217
|
+
android:layout_height="wrap_content"
|
218
|
+
|
219
|
+
android:text=""
|
220
|
+
|
221
|
+
android:id="@+id/user_message"
|
222
|
+
|
223
|
+
android:layout_gravity="end" />
|
224
|
+
|
225
|
+
</LinearLayout>
|
226
|
+
|
227
|
+
|
228
|
+
|
229
|
+
</RelativeLayout>
|
230
|
+
|
231
|
+
|
232
|
+
|
233
|
+
|
234
|
+
|
235
|
+
```
|
236
|
+
|
237
|
+
どうぞよろしくお願いします。
|