Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ repositories {
}

android {
compileSdkVersion 24
buildToolsVersion "24.0.1"
compileSdkVersion 27
buildToolsVersion '28.0.3'

defaultConfig {
applicationId "com.google.firebase.udacity.friendlychat"
minSdkVersion 16
targetSdkVersion 24
minSdkVersion 21
targetSdkVersion 27
versionCode 1
versionName "1.0"
}
Expand All @@ -32,12 +32,12 @@ android {
}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
implementation fileTree(dir: 'libs', include: ['*.jar'])
testImplementation 'junit:junit:4.12'

compile 'com.android.support:design:24.2.0'
compile 'com.android.support:appcompat-v7:24.2.0'
implementation 'com.android.support:design:27.1.1'
implementation 'com.android.support:appcompat-v7:27.1.1'

// Displaying images
compile 'com.github.bumptech.glide:glide:3.6.1'
implementation 'com.github.bumptech.glide:glide:4.8.0'
}
8 changes: 5 additions & 3 deletions app/src/main/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,22 +25,24 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true"
android:orientation="horizontal">

<ImageButton
android:id="@+id/photoPickerButton"
android:layout_width="36dp"
android:layout_height="36dp"
android:background="@android:drawable/ic_menu_gallery" />
android:background="@android:drawable/ic_menu_gallery"
android:contentDescription="@string/image_button"/>

<EditText
android:id="@+id/messageEditText"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_weight="1" />
android:layout_weight="1"
android:inputType="text"
android:hint="@string/please_write_your_message_here"/>

<Button
android:id="@+id/sendButton"
Expand Down
4 changes: 2 additions & 2 deletions app/src/main/res/layout/item_message.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/activity_horizontal_margin"
android:layout_marginStart="@dimen/activity_horizontal_margin"
android:orientation="vertical">

<ImageView
android:id="@+id/photoImageView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:adjustViewBounds="true" />
android:adjustViewBounds="true"
android:contentDescription="@string/photo_image_view"/>

<TextView
android:id="@+id/messageTextView"
Expand Down
3 changes: 3 additions & 0 deletions app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,7 @@
<string name="app_name">Friendly Chat</string>
<string name="sign_out">Sign Out</string>
<string name="send_button_label">Send</string>
<string name="please_write_your_message_here">Please Write Your Message Here.</string>
<string name="image_button">Image Button</string>
<string name="photo_image_view">Photo Image View</string>
</resources>
4 changes: 3 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ buildscript {
repositories {
jcenter()
mavenLocal()
google()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.2.2'
classpath 'com.android.tools.build:gradle:3.2.1'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
Expand All @@ -17,6 +18,7 @@ allprojects {
repositories {
jcenter()
mavenLocal()
google()
}
}

Expand Down
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Tue Aug 16 17:43:49 PDT 2016
#Fri Oct 19 16:41:19 EET 2018
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip