From 9e9413840575053254c5e505b7491a76cc7677d1 Mon Sep 17 00:00:00 2001 From: robby syaifullah <robbysyaifullah19@gmail.com> Date: Mon, 19 Feb 2018 19:39:53 +0700 Subject: [PATCH] Add functionality and correct position referral button for Chat Room --- .idea/modules.xml | 3 +- app/src/main/AndroidManifest.xml | 1 + .../example/leo/fitnessdiy/HomeActivity.java | 3 +- app/src/main/res/layout/activity_home.xml | 30 +++++++++++-------- gradle.properties | 9 +----- 5 files changed, 23 insertions(+), 23 deletions(-) diff --git a/.idea/modules.xml b/.idea/modules.xml index 92af586..e7f8ce2 100644 --- a/.idea/modules.xml +++ b/.idea/modules.xml @@ -2,10 +2,11 @@ <project version="4"> <component name="ProjectModuleManager"> <modules> + <module fileurl="file://$PROJECT_DIR$/android.iml" filepath="$PROJECT_DIR$/android.iml" /> <module fileurl="file://F:\informatika\pbd\fitness\android.iml" filepath="F:\informatika\pbd\fitness\android.iml" /> <module fileurl="file://$PROJECT_DIR$/app/app.iml" filepath="$PROJECT_DIR$/app/app.iml" /> - <module fileurl="file://$PROJECT_DIR$/fitness.iml" filepath="$PROJECT_DIR$/fitness.iml" /> <module fileurl="file://D:\tugas\sem6\pbd\tubes\android\fitness.iml" filepath="D:\tugas\sem6\pbd\tubes\android\fitness.iml" /> + <module fileurl="file://D:\Semester 6\PBD\Tugas Besar\android\fitness.iml" filepath="D:\Semester 6\PBD\Tugas Besar\android\fitness.iml" /> </modules> </component> </project> \ No newline at end of file diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index f9de2d8..2bd5d5a 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -39,6 +39,7 @@ <activity android:name=".PlankActivity" /> <activity android:name=".PushupActivity" /> <activity android:name=".SitupActivity" /> + <activity android:name=".ChatActivity" /> <activity android:name=".LevelActivity" /> <activity android:name=".ExerciseActivity" /> <!-- diff --git a/app/src/main/java/com/example/leo/fitnessdiy/HomeActivity.java b/app/src/main/java/com/example/leo/fitnessdiy/HomeActivity.java index 7c9d1fb..2a28ad7 100644 --- a/app/src/main/java/com/example/leo/fitnessdiy/HomeActivity.java +++ b/app/src/main/java/com/example/leo/fitnessdiy/HomeActivity.java @@ -70,6 +70,7 @@ public class HomeActivity extends AppCompatActivity startActivity(i); } public void goToChat(View view) { - + Intent i = new Intent(getApplicationContext(), ChatActivity.class); + startActivity(i); } } diff --git a/app/src/main/res/layout/activity_home.xml b/app/src/main/res/layout/activity_home.xml index cb97e98..04118a3 100644 --- a/app/src/main/res/layout/activity_home.xml +++ b/app/src/main/res/layout/activity_home.xml @@ -11,23 +11,35 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal"> + <Button android:id="@+id/history_button" android:layout_width="wrap_content" android:layout_height="wrap_content" android:onClick="openHistory" - android:text="@string/history"/> + android:text="@string/history" /> + <Button android:id="@+id/exercise_button" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:text="@string/exercise" - android:onClick="changeFragment"/> + android:onClick="changeFragment" + android:text="@string/exercise" /> + <Button android:layout_width="wrap_content" android:layout_height="wrap_content" - android:text="Jogging" - android:onClick="openJogging"/> + android:onClick="openJogging" + android:text="Jogging" /> + + <android.support.design.widget.FloatingActionButton + android:id="@+id/chat_button" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_gravity="right" + android:layout_weight="3" + android:onClick="goToChat" /> + </LinearLayout> <fragment @@ -36,13 +48,5 @@ android:layout_width="match_parent" android:layout_height="471dp" /> - <android.support.design.widget.FloatingActionButton - android:id="@+id/chat_button" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_gravity="right" - android:onClick="goToChat"/> - - </LinearLayout> diff --git a/gradle.properties b/gradle.properties index 587d5bd..7be7ec5 100644 --- a/gradle.properties +++ b/gradle.properties @@ -13,11 +13,4 @@ # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects # org.gradle.parallel=true #Mon Feb 19 17:06:30 GMT+07:00 2018 -systemProp.http.proxyPassword=02414056 -systemProp.https.proxyUser=leo16515325 -systemProp.https.proxyPort=8080 -systemProp.http.proxyHost=cache.itb.ac.id -systemProp.https.proxyPassword=02414056 -systemProp.https.proxyHost=cache.itb.ac.id -systemProp.http.proxyPort=8080 -systemProp.http.proxyUser=leo16515325 + -- GitLab