Skip to content

Commit

Permalink
chore(*): disable jetifier (firebase#1303)
Browse files Browse the repository at this point in the history
  • Loading branch information
thatfiredev authored Jun 22, 2021
1 parent cdf2619 commit 42b947c
Show file tree
Hide file tree
Showing 24 changed files with 44 additions and 69 deletions.
2 changes: 0 additions & 2 deletions admob/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 0 additions & 2 deletions analytics/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 0 additions & 2 deletions app-indexing/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 1 addition & 1 deletion auth/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ dependencies {

// Facebook Android SDK (only required for Facebook Login)
// Used in FacebookLoginActivity.
implementation 'com.facebook.android:facebook-login:4.42.0'
implementation 'com.facebook.android:facebook-login:8.1.0'
implementation 'androidx.browser:browser:1.0.0'

androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public void onClick(View v) {
// Initialize Facebook Login button
mCallbackManager = CallbackManager.Factory.create();
LoginButton loginButton = mBinding.buttonFacebookLogin;
loginButton.setReadPermissions("email", "public_profile");
loginButton.setPermissions("email", "public_profile");
loginButton.registerCallback(mCallbackManager, new FacebookCallback<LoginResult>() {
@Override
public void onSuccess(LoginResult loginResult) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class FacebookLoginFragment : BaseFragment() {
// Initialize Facebook Login button
callbackManager = CallbackManager.Factory.create()

binding.buttonFacebookLogin.setReadPermissions("email", "public_profile")
binding.buttonFacebookLogin.setPermissions("email", "public_profile")
binding.buttonFacebookLogin.registerCallback(callbackManager, object : FacebookCallback<LoginResult> {
override fun onSuccess(loginResult: LoginResult) {
Log.d(TAG, "facebook:onSuccess:$loginResult")
Expand Down
4 changes: 0 additions & 4 deletions auth/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 0 additions & 2 deletions config/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 0 additions & 2 deletions crash/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 0 additions & 2 deletions database/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 0 additions & 2 deletions dynamiclinks/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 1 addition & 1 deletion firestore/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ dependencies {

// Third-party libraries
implementation 'me.zhanghai.android.materialratingbar:library:1.4.0'
implementation 'com.github.bumptech.glide:glide:3.7.0'
implementation 'com.github.bumptech.glide:glide:4.12.0'

androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
androidTestImplementation 'androidx.test.espresso:espresso-contrib:3.3.0'
Expand Down
1 change: 0 additions & 1 deletion firestore/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,3 @@ org.gradle.jvmargs=-Xmx1536m
# Don't use the gradle build cache since this sample uses experimental SDKs
android.enableBuildCache=false
android.useAndroidX=true
android.enableJetifier=true
2 changes: 0 additions & 2 deletions functions/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
1 change: 0 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,3 @@ org.gradle.caching=true

## Play and Firebase moving to AndroidX
android.useAndroidX=true
android.enableJetifier=true
4 changes: 4 additions & 0 deletions inappmessaging/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,10 @@ dependencies {
// FIAM (Kotlin)
implementation 'com.google.firebase:firebase-inappmessaging-ktx'
implementation 'com.google.firebase:firebase-inappmessaging-display-ktx'
implementation('com.squareup.picasso:picasso') {
version { strictly("2.8") }
because("Firebase In-App Messaging includes a Picasso version that doesn't use AndroidX")
}

// The Firebase SDK for Google Analytics is required to use In-App Messaging
// Analytics (Java)
Expand Down
2 changes: 0 additions & 2 deletions inappmessaging/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 1 addition & 1 deletion messaging/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ dependencies {

implementation 'com.google.firebase:firebase-installations-ktx:17.0.0'

implementation 'android.arch.work:work-runtime:1.0.1'
implementation 'androidx.work:work-runtime:2.5.0'

// Testing dependencies
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
Expand Down
2 changes: 0 additions & 2 deletions messaging/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 1 addition & 1 deletion perf/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ dependencies {
implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.3.1'

implementation 'com.github.bumptech.glide:glide:3.7.0'
implementation 'com.github.bumptech.glide:glide:4.12.0'

testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
package com.google.firebase.quickstart.perfmon.java;

import android.graphics.drawable.ColorDrawable;
import android.graphics.drawable.Drawable;
import android.os.Bundle;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.core.content.ContextCompat;
import androidx.appcompat.app.AppCompatActivity;
import android.util.Log;
import android.view.View;
import android.widget.Toast;

import com.bumptech.glide.Glide;
import com.bumptech.glide.load.resource.drawable.GlideDrawable;
import com.bumptech.glide.load.DataSource;
import com.bumptech.glide.load.engine.GlideException;
import com.bumptech.glide.request.RequestListener;
import com.bumptech.glide.request.target.Target;
import com.google.android.gms.tasks.OnCompleteListener;
Expand Down Expand Up @@ -110,20 +113,16 @@ private void loadImageFromWeb() {
Glide.with(this).
load(IMAGE_URL)
.placeholder(new ColorDrawable(ContextCompat.getColor(this, R.color.colorAccent)))
.listener(new RequestListener<String, GlideDrawable>() {
.listener(new RequestListener<Drawable>() {
@Override
public boolean onException(
Exception e, String model, Target<GlideDrawable> target,
boolean isFirstResource) {
mNumStartupTasks.countDown(); // Signal end of image load task.
public boolean onLoadFailed(@Nullable GlideException e, Object model, Target<Drawable> target, boolean isFirstResource) {
mNumStartupTasks.countDown();
return false;
}

@Override
public boolean onResourceReady(
GlideDrawable resource, String model, Target<GlideDrawable> target,
boolean isFromMemoryCache, boolean isFirstResource) {
mNumStartupTasks.countDown(); // Signal end of image load task.
public boolean onResourceReady(Drawable resource, Object model, Target<Drawable> target, DataSource dataSource, boolean isFirstResource) {
mNumStartupTasks.countDown();
return false;
}
}).into(binding.headerIcon);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
package com.google.firebase.quickstart.perfmon.kotlin

import android.graphics.drawable.ColorDrawable
import android.graphics.drawable.Drawable
import android.os.Bundle
import androidx.core.content.ContextCompat
import androidx.appcompat.app.AppCompatActivity
import android.util.Log
import android.widget.Toast
import androidx.lifecycle.lifecycleScope
import com.bumptech.glide.Glide
import com.bumptech.glide.load.resource.drawable.GlideDrawable
import com.bumptech.glide.load.DataSource
import com.bumptech.glide.load.engine.GlideException
import com.bumptech.glide.request.RequestListener
import com.bumptech.glide.request.target.Target
import com.google.android.gms.tasks.OnCompleteListener
Expand Down Expand Up @@ -85,29 +87,29 @@ class MainActivity : AppCompatActivity() {

private fun loadImageFromWeb() {
Glide.with(this).load(IMAGE_URL)
.placeholder(ColorDrawable(ContextCompat.getColor(this, R.color.colorAccent)))
.listener(object : RequestListener<String, GlideDrawable> {
override fun onException(
e: Exception,
model: String,
target: Target<GlideDrawable>,
isFirstResource: Boolean
): Boolean {
numStartupTasks.countDown() // Signal end of image load task.
return false
}
.placeholder(ColorDrawable(ContextCompat.getColor(this, R.color.colorAccent)))
.listener(object : RequestListener<Drawable> {
override fun onLoadFailed(
e: GlideException?,
model: Any?,
target: Target<Drawable>?,
isFirstResource: Boolean
): Boolean {
numStartupTasks.countDown() // Signal end of image load task.
return false
}

override fun onResourceReady(
resource: GlideDrawable,
model: String,
target: Target<GlideDrawable>,
isFromMemoryCache: Boolean,
isFirstResource: Boolean
): Boolean {
numStartupTasks.countDown() // Signal end of image load task.
return false
}
}).into(binding.headerIcon)
override fun onResourceReady(
resource: Drawable?,
model: Any?,
target: Target<Drawable>?,
dataSource: DataSource?,
isFirstResource: Boolean
): Boolean {
numStartupTasks.countDown() // Signal end of image load task.
return false
}
}).into(binding.headerIcon)
}

private fun writeStringToFile(filename: String, content: String): Task<Void> {
Expand Down
2 changes: 0 additions & 2 deletions perf/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true
2 changes: 0 additions & 2 deletions storage/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
android.useAndroidX=true
android.enableJetifier=true

0 comments on commit 42b947c

Please sign in to comment.