Skip to content

Auth code cleanup #376

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 37 commits into from
Nov 18, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
6ecc551
cleanup
SUPERCILEX Oct 23, 2016
00a59cd
cleanup
SUPERCILEX Oct 23, 2016
bb352e9
Update .travis.yml
SUPERCILEX Oct 23, 2016
d8f1e1a
Merge remote-tracking branch 'firebase/version-1.0.0-dev' into cleanup
SUPERCILEX Oct 23, 2016
e733913
More dependency updates
SUPERCILEX Oct 24, 2016
9ab7dd4
Reorganize dependencies
SUPERCILEX Oct 24, 2016
b5fe9f1
Cleanup
SUPERCILEX Oct 24, 2016
7a05e46
Update firebase
SUPERCILEX Oct 24, 2016
51dc270
Update constants.gradle
SUPERCILEX Oct 25, 2016
90f2c56
Remove unnecessary app dependencies
SUPERCILEX Oct 25, 2016
1234066
Style consistency in xml files
SUPERCILEX Oct 25, 2016
575cb9b
Upgrade EditTexts to android.support.design.widget.TextInputEditText
SUPERCILEX Oct 25, 2016
34a7800
Final cleanup
SUPERCILEX Oct 25, 2016
5e7c955
Even more xml refactoring. Extracted FirebaseUI.EditText.EmailField
SUPERCILEX Oct 25, 2016
97bc852
app dependency updates
SUPERCILEX Oct 25, 2016
41c5ddd
Massively cleaned up gradle ext variables.
SUPERCILEX Oct 26, 2016
e666a15
Merge remote-tracking branch 'firebase/version-1.0.0-dev' into cleanup
SUPERCILEX Oct 27, 2016
6798d92
Address review comments and fix mistakes
SUPERCILEX Oct 27, 2016
afd6fc9
Turns out braces are unnecessary in gradle
SUPERCILEX Oct 28, 2016
1cdf4f2
Merge remote-tracking branch 'firebase/version-1.0.0-dev' into cleanup
SUPERCILEX Oct 28, 2016
2b2da92
Fix merge mistakes
SUPERCILEX Oct 28, 2016
9d9b7f5
Cleanup SmartLock.java
SUPERCILEX Oct 29, 2016
47b204e
Fix nits
SUPERCILEX Nov 1, 2016
6e35dcb
Merge remote-tracking branch 'firebase/version-1.0.0-dev' into cleanup
SUPERCILEX Nov 2, 2016
18e969f
Move AcquireEmailHelper.java so as to narrow down access to RC_SIGN_IN
SUPERCILEX Nov 3, 2016
a183c7f
Cleanup
SUPERCILEX Nov 3, 2016
26343b4
Merge remote-tracking branch 'firebase/master' into cleanup
SUPERCILEX Nov 5, 2016
2ac59d9
Cleanup
SUPERCILEX Nov 5, 2016
8925f51
Cleanup
SUPERCILEX Nov 5, 2016
9603d9a
Cleanup
SUPERCILEX Nov 5, 2016
2e9f399
Update README.md
SUPERCILEX Nov 5, 2016
f60c448
More xml cleanup
SUPERCILEX Nov 5, 2016
0406cd8
Merge remote-tracking branch 'origin/cleanup' into cleanup
SUPERCILEX Nov 5, 2016
0c85d63
Update AuthMethodPickerActivity.java
SUPERCILEX Nov 6, 2016
7b95605
Merge remote-tracking branch 'firebase/master' into cleanup
SUPERCILEX Nov 18, 2016
5610ad1
Fix merge mistakes
SUPERCILEX Nov 18, 2016
af34fab
Merge remote-tracking branch 'origin/cleanup' into cleanup
SUPERCILEX Nov 18, 2016
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
3 changes: 0 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ language: android
jdk: oraclejdk8
# See https://github.com/travis-ci/travis-ci/issues/5582
sudo: required
# See https://docs.travis-ci.com/user/languages/java/#Caching
before_cache:
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
- rm -fr $HOME/.gradle/caches/*/plugin-resolution/
Expand All @@ -18,8 +17,6 @@ android:
- android-25

# Extras
- extra-google-google_play_services
- extra-google-m2repository
- extra-android-m2repository
- addon-google_apis-google-24
script: ./gradlew clean :library:testAll :library:prepareArtifacts
26 changes: 11 additions & 15 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ apply plugin: 'com.neenbedankt.android-apt'
apply from: "../common/constants.gradle"

android {
compileSdkVersion project.ext.compileSdk
buildToolsVersion "${project.ext.buildtools}"
compileSdkVersion compileSdk
buildToolsVersion buildTools

defaultConfig {
applicationId "com.firebase.uidemo"
minSdkVersion 16
targetSdkVersion project.ext.targetSdk
targetSdkVersion targetSdk
versionCode 1
versionName "1.0"
}
Expand All @@ -24,32 +24,28 @@ android {
signingConfig signingConfigs.debug
}
}

}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile "com.android.support:appcompat-v7:${project.ext.support_library_version}"
compile "com.android.support:design:${project.ext.support_library_version}"
compile "com.android.support:recyclerview-v7:${project.ext.support_library_version}"
compile "com.android.support:support-v4:${project.ext.support_library_version}"
compile "com.android.support:design:$support_library_version"

compile project(path: ':auth')
compile project(path: ':database')
compile project(path: ':storage')

compile "com.google.firebase:firebase-database:${project.ext.firebase_version}"
compile "com.google.firebase:firebase-auth:${project.ext.firebase_version}"
compile "com.google.firebase:firebase-storage:${project.ext.firebase_version}"
compile "com.google.android.gms:play-services-auth:${project.ext.firebase_version}"
compile "com.google.android.gms:play-services-auth:$firebase_version"
compile "com.google.firebase:firebase-auth:$firebase_version"
compile "com.google.firebase:firebase-database:$firebase_version"
compile "com.google.firebase:firebase-storage:$firebase_version"

// The following dependencies are not required to use the Firebase UI library.
// They are used to make some aspects of the demo app implementation simpler for
// demonstrative purposes, and you may find them useful in your own apps; YMMV.
compile 'com.jakewharton:butterknife:8.0.1'
compile 'com.github.bumptech.glide:glide:3.7.0'
compile 'pub.devrel:easypermissions:0.2.0'
apt 'com.jakewharton:butterknife-compiler:8.0.1'
compile 'pub.devrel:easypermissions:0.2.1'
compile 'com.jakewharton:butterknife:8.4.0'
apt 'com.jakewharton:butterknife-compiler:8.4.0'
}

apply plugin: 'com.google.gms.google-services'
24 changes: 13 additions & 11 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="com.firebase.uidemo">

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>

<application
android:allowBackup="true"
Expand All @@ -12,30 +13,31 @@
android:theme="@style/AppTheme">
<activity android:name=".ChooserActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
<meta-data android:name="android.app.shortcuts"
android:resource="@xml/shortcuts" />
<meta-data
android:name="android.app.shortcuts"
android:resource="@xml/shortcuts"/>
</activity>

<!-- Chat demo -->
<activity
android:name=".database.ChatActivity"
android:label="@string/name_chat" />
android:label="@string/name_chat"/>

<!-- Auth UI demo -->
<activity
android:name=".auth.AuthUiActivity"
android:label="@string/name_auth_ui" />
android:label="@string/name_auth_ui"/>
<activity
android:name=".auth.SignedInActivity"
android:label="@string/name_auth_ui" />
android:label="@string/name_auth_ui"/>

<!-- Storage UI demo-->
<activity
android:name=".storage.ImageActivity"
android:label="@string/name_image" />
android:label="@string/name_image"/>
</application>

</manifest>
11 changes: 6 additions & 5 deletions app/src/main/res/drawable/chat_message_arrow.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,12 @@
android:fromDegrees="45"
android:toDegrees="45"
android:pivotX="-40%"
android:pivotY="87%" >
android:pivotY="87%">
<shape
android:shape="rectangle" >
<stroke android:color="@android:color/transparent" android:width="10dp"/>
<solid
android:color="@color/material_grey_300" />
android:shape="rectangle">
<stroke
android:color="@android:color/transparent"
android:width="10dp"/>
<solid android:color="@color/material_grey_300"/>
</shape>
</rotate>
6 changes: 4 additions & 2 deletions app/src/main/res/drawable/chat_message_background.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle">
<shape
xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<corners android:radius="4dp"/>
<solid android:color="@color/material_grey_300" />
<solid android:color="@color/material_grey_300"/>
</shape>
17 changes: 10 additions & 7 deletions app/src/main/res/layout/activity_chat.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"

tools:context=".database.ChatActivity">

<android.support.v7.widget.RecyclerView
Expand All @@ -16,7 +16,7 @@
android:layout_alignParentTop="true"
android:clipToPadding="false"
android:padding="16dp"
tools:listitem="@layout/message" />
tools:listitem="@layout/message"/>

<LinearLayout
android:id="@+id/footer"
Expand All @@ -26,21 +26,24 @@
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true"
android:orientation="horizontal"
android:paddingStart="16dp"
android:paddingEnd="16dp"
android:paddingLeft="16dp">

<EditText
android:id="@+id/messageEdit"
android:layout_width="wrap_content"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1" />
android:layout_weight="1"/>

<Button
android:id="@+id/sendButton"
style="@style/Widget.AppCompat.Button.Borderless.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|right"
android:text="Send" />
android:layout_gravity="bottom|end"
android:text="Send"/>

</LinearLayout>

</RelativeLayout>
3 changes: 2 additions & 1 deletion app/src/main/res/layout/activity_chooser.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
Expand Down
14 changes: 7 additions & 7 deletions app/src/main/res/layout/activity_image.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
Expand All @@ -15,20 +15,20 @@
style="@style/TextAppearance.AppCompat.Medium"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Upload" />
android:text="Upload"/>

<Button
android:id="@+id/button_choose_photo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Choose Image" />
android:text="Choose Image"/>

<TextView
style="@style/TextAppearance.AppCompat.Medium"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
android:text="Download" />
android:text="Download"/>

<LinearLayout
android:layout_width="wrap_content"
Expand All @@ -40,7 +40,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:enabled="false"
android:text="Download" />
android:text="Download"/>

</LinearLayout>

Expand All @@ -51,6 +51,6 @@
android:scaleType="centerCrop"
android:src="#E6E6E6"
android:visibility="invisible"
tools:visibility="visible" />
tools:visibility="visible"/>

</LinearLayout>
Loading