Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 192bcb2

Browse files
committed
Design chnages2
1 parent 7244396 commit 192bcb2

14 files changed

+238
-234
lines changed

‎app/src/main/java/com/example/chatfull/ChatActivity.java‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -438,18 +438,20 @@ public void run() {
438438
if (msg.getText() != null) {
439439
msg.setUser(user);
440440
adapter.addToStart(msg, true);
441+
messageArrayList.add(msg);
441442
} else if (msg.isImage()) {
442443
msg.setUser(user);
443444
adapter.addToStart(msg, true);
445+
messageArrayList.add(msg);
444446
} else if (msg.isFile()) {
445447
msg.setUser(user);
446448
adapter.addToStart(msg, true);
449+
messageArrayList.add(msg);
447450
} else if (msg.isColor()) {
448451
back_view.setBackgroundColor(msg.getColor());
449452
}
450453

451-
if(!msg.isColor())
452-
messageArrayList.add(msg);
454+
453455
}
454456
});
455457
}

‎app/src/main/java/com/example/chatfull/MainActivity.java‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88

99
import androidx.appcompat.app.AppCompatActivity;
1010

11+
import com.google.android.material.snackbar.Snackbar;
12+
1113
public class MainActivity extends AppCompatActivity {
1214

1315
Button showInfoBtn, enterInfoBtn;
@@ -26,6 +28,12 @@ protected void onCreate(Bundle savedInstanceState) {
2628
showInfoBtn.setOnClickListener(new View.OnClickListener() {
2729
@Override
2830
public void onClick(View view) {
31+
if(nameInput.getText().toString().length() < 1){
32+
Snackbar snackbar = Snackbar
33+
.make(nameInput, "Please Enter Username", Snackbar.LENGTH_LONG);
34+
snackbar.show();
35+
return;
36+
}
2937
me = new User("1", nameInput.getText().toString());
3038
Intent intent = new Intent(getApplicationContext(), ShowInfoActivity.class);
3139
startActivity(intent);
@@ -35,6 +43,12 @@ public void onClick(View view) {
3543
enterInfoBtn.setOnClickListener(new View.OnClickListener() {
3644
@Override
3745
public void onClick(View view) {
46+
if(nameInput.getText().toString().length() < 1){
47+
Snackbar snackbar = Snackbar
48+
.make(nameInput, "Please Enter Username", Snackbar.LENGTH_LONG);
49+
snackbar.show();
50+
return;
51+
}
3852
me = new User("1", nameInput.getText().toString());
3953
Intent intent = new Intent(getApplicationContext(), ConnectToUserActivity.class);
4054
startActivity(intent);

‎app/src/main/res/drawable/background_gradient.xml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<shape xmlns:android="http://schemas.android.com/apk/res/android"
33
android:shape="rectangle">
44
<gradient
5-
android:startColor="#FF1B2338"
6-
android:endColor="#FF1C2747"
5+
android:startColor="#56499b"
6+
android:endColor="#3a3170"
77
android:angle="90"/>
88
</shape>

‎app/src/main/res/drawable/buttonshape.xml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle" >
33
<corners
4-
android:radius="10dp"
4+
android:radius="3dp"
55
/>
66
<solid
7-
android:color="#2690ED"
7+
android:color="#B586D9"
88
/>
99
<size
1010
android:width="300dp"

‎app/src/main/res/drawable/ic_person.xml‎

Lines changed: 0 additions & 9 deletions
This file was deleted.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<vector android:height="24dp" android:viewportHeight="682"
2+
android:viewportWidth="682.6667" android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
3+
<path android:fillColor="#FF000000" android:pathData="m98.289,109.605v173.563c0,6.934 5.621,12.551 12.551,12.551h173.566c6.93,0 12.551,-5.617 12.551,-12.551v-32.91c0,-6.934 -5.621,-12.551 -12.551,-12.551s-12.547,5.617 -12.547,12.551v20.363h-148.469v-148.469h148.469v30.215c0,6.934 5.617,12.555 12.547,12.555s12.551,-5.621 12.551,-12.555v-42.762c0,-6.934 -5.621,-12.551 -12.551,-12.551h-173.566c-6.93,0 -12.551,5.617 -12.551,12.551zM98.289,109.605"/>
4+
<path android:fillColor="#FF000000" android:pathData="m171.59,157.805c-6.934,0 -12.547,5.617 -12.547,12.547v52.07c0,6.93 5.613,12.551 12.547,12.551h52.07c6.93,0 12.551,-5.621 12.551,-12.551v-52.07c0,-6.93 -5.621,-12.547 -12.551,-12.547zM211.113,209.875h-26.973v-26.973h26.973zM211.113,209.875"/>
5+
<path android:fillColor="#FF000000" android:pathData="m284.406,385.344h-173.566c-6.93,0 -12.551,5.617 -12.551,12.547v173.57c0,6.93 5.621,12.547 12.551,12.547h173.566c6.93,0 12.551,-5.617 12.551,-12.547v-173.57c0,-6.93 -5.621,-12.547 -12.551,-12.547zM271.859,558.91h-148.469v-148.469h148.469zM271.859,558.91"/>
6+
<path android:fillColor="#FF000000" android:pathData="m400,295.719h173.57c6.926,0 12.547,-5.617 12.547,-12.551v-173.563c0,-6.934 -5.621,-12.551 -12.547,-12.551h-173.57c-6.93,0 -12.551,5.617 -12.551,12.551v173.563c0,6.934 5.621,12.551 12.551,12.551zM412.547,122.152h148.469v148.469h-148.469zM412.547,122.152"/>
7+
<path android:fillColor="#FF000000" android:pathData="m586.117,571.461v-173.57c0,-6.93 -5.621,-12.547 -12.547,-12.547h-173.57c-6.93,0 -12.551,5.617 -12.551,12.547v173.57c0,6.93 5.621,12.547 12.551,12.547h173.57c6.926,0 12.547,-5.617 12.547,-12.547zM561.016,558.91h-148.469v-148.469h148.469zM561.016,558.91"/>
8+
<path android:fillColor="#FF000000" android:pathData="m573.57,353.84c6.926,0 12.547,-5.621 12.547,-12.551 0,-6.934 -5.621,-12.547 -12.547,-12.547h-220.031v-220.527c0,-6.93 -5.621,-12.551 -12.547,-12.551 -6.938,0 -12.555,5.621 -12.555,12.551v220.527h-166.57c-6.926,0 -12.547,5.617 -12.547,12.547 0,6.934 5.621,12.551 12.547,12.551h166.57v217.621c0,6.93 5.617,12.547 12.555,12.547 6.926,0 12.547,-5.617 12.547,-12.547v-217.621zM573.57,353.84"/>
9+
<path android:fillColor="#FF000000" android:pathData="m171.59,524.195h52.07c6.93,0 12.551,-5.621 12.551,-12.551v-52.07c0,-6.934 -5.621,-12.547 -12.551,-12.547h-52.07c-6.934,0 -12.547,5.613 -12.547,12.547v52.07c0,6.93 5.613,12.551 12.547,12.551zM184.141,472.125h26.973v26.973h-26.973zM184.141,472.125"/>
10+
<path android:fillColor="#FF000000" android:pathData="m512.816,157.805h-52.07c-6.93,0 -12.551,5.617 -12.551,12.547v52.07c0,6.93 5.621,12.551 12.551,12.551h52.07c6.934,0 12.551,-5.621 12.551,-12.551v-52.07c0,-6.93 -5.617,-12.547 -12.551,-12.547zM500.266,209.875h-26.965v-26.973h26.965zM500.266,209.875"/>
11+
<path android:fillColor="#FF000000" android:pathData="m460.746,524.195h52.07c6.934,0 12.551,-5.621 12.551,-12.551v-52.07c0,-6.934 -5.617,-12.547 -12.551,-12.547h-52.07c-6.93,0 -12.551,5.613 -12.551,12.547v52.07c0,6.93 5.621,12.551 12.551,12.551zM473.301,472.125h26.965v26.973h-26.965zM473.301,472.125"/>
12+
<path android:fillColor="#FF000000" android:pathData="m108.301,328.793 l-0.676,0.156c-6.746,1.594 -10.926,8.352 -9.336,15.098 1.363,5.777 6.516,9.676 12.203,9.676 0.957,0 1.922,-0.113 2.891,-0.344l0.672,-0.156c6.75,-1.59 10.93,-8.348 9.336,-15.094 -1.586,-6.742 -8.344,-10.922 -15.09,-9.336zM108.301,328.793"/>
13+
<path android:fillColor="#FF000000" android:pathData="m281.879,188.789 l-0.676,0.16c-6.746,1.582 -10.93,8.336 -9.348,15.086 1.352,5.785 6.508,9.688 12.207,9.688 0.945,0 1.906,-0.109 2.875,-0.34l0.672,-0.156c6.75,-1.582 10.934,-8.34 9.352,-15.082 -1.582,-6.746 -8.34,-10.938 -15.082,-9.355zM281.879,188.789"/>
14+
<path android:fillColor="#FF000000" android:pathData="m33.547,124.125c6.938,0 12.551,-5.617 12.551,-12.547v-65.148h62.777c6.934,0 12.555,-5.613 12.555,-12.547 0,-6.93 -5.621,-12.551 -12.555,-12.551h-75.328c-6.926,0 -12.547,5.621 -12.547,12.551v77.695c0,6.93 5.621,12.547 12.547,12.547zM33.547,124.125"/>
15+
<path android:fillColor="#FF000000" android:pathData="m648.453,21.332h-75.328c-6.934,0 -12.555,5.621 -12.555,12.551 0,6.934 5.621,12.547 12.555,12.547h62.777v65.148c0,6.93 5.613,12.547 12.551,12.547 6.926,0 12.547,-5.617 12.547,-12.547v-77.695c0,-6.93 -5.621,-12.551 -12.547,-12.551zM648.453,21.332"/>
16+
<path android:fillColor="#FF000000" android:pathData="m108.875,635.695h-62.777v-65.145c0,-6.926 -5.613,-12.547 -12.551,-12.547 -6.926,0 -12.547,5.621 -12.547,12.547v77.695c0,6.93 5.621,12.551 12.547,12.551h75.328c6.934,0 12.555,-5.621 12.555,-12.551 0,-6.934 -5.621,-12.551 -12.555,-12.551zM108.875,635.695"/>
17+
<path android:fillColor="#FF000000" android:pathData="m648.453,558.004c-6.938,0 -12.551,5.621 -12.551,12.547v65.145h-62.777c-6.934,0 -12.555,5.617 -12.555,12.551 0,6.93 5.621,12.551 12.555,12.551h75.328c6.926,0 12.547,-5.621 12.547,-12.551v-77.695c0,-6.926 -5.621,-12.547 -12.547,-12.547zM648.453,558.004"/>
18+
</vector>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<vector android:height="24dp" android:viewportHeight="512"
2+
android:viewportWidth="496" android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
3+
<path android:fillColor="#fff" android:pathData="M248,8C111,8 0,119 0,256s111,248 248,248 248,-111 248,-248S385,8 248,8zM248,104c48.6,0 88,39.4 88,88s-39.4,88 -88,88 -88,-39.4 -88,-88 39.4,-88 88,-88zM248,448c-58.7,0 -111.3,-26.6 -146.5,-68.2 18.8,-35.4 55.6,-59.8 98.5,-59.8 2.4,0 4.8,0.4 7.1,1.1 13,4.2 26.6,6.9 40.9,6.9 14.3,0 28,-2.7 40.9,-6.9 2.3,-0.7 4.7,-1.1 7.1,-1.1 42.9,0 79.7,24.4 98.5,59.8C359.3,421.4 306.7,448 248,448z"/>
4+
</vector>

‎app/src/main/res/font/font.xml‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,14 @@
55
android:fontStyle="normal"
66
android:fontWeight="400"
77
android:font="@font/sanfran" />
8+
9+
<font
10+
android:fontStyle="normal"
11+
android:fontWeight="400"
12+
android:font="@font/moon_light" />
13+
14+
<font
15+
android:fontStyle="normal"
16+
android:fontWeight="400"
17+
android:font="@font/moon_bold" />
818
</font-family>

‎app/src/main/res/font/moon_bold.otf‎

24.6 KB
Binary file not shown.

‎app/src/main/res/font/moon_light.otf‎

23.6 KB
Binary file not shown.

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /