Guest User

Untitled

a guest
May 20th, 2018
92
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.75 KB | None | 0 0
  1. Intent intent = new Intent();
  2. intent.setType("image/*");
  3. intent.setAction(Intent.ACTION_GET_CONTENT);
  4. startActivityForResult(Intent.createChooser(intent,"Select Picture"), PICK_IMAGE_REQUEST);
  5.  
  6.  
  7.  
  8. FirebaseUser user = FirebaseAuth.getInstance().getCurrentUser();
  9.  
  10. UserProfileChangeRequest profileUpdates = new UserProfileChangeRequest.Builder()
  11. .setPhotoUri(Uri.parse(""))//Falta la eleccion de la foto
  12. .build();
  13.  
  14. user.updateProfile(profileUpdates)
  15. .addOnCompleteListener(new OnCompleteListener<Void>() {
  16. @Override
  17. public void onComplete(@NonNull Task<Void> task) {
  18. if (task.isSuccessful()) {
  19.  
  20. }
  21. }
  22. });
  23. }
Add Comment
Please, Sign In to add comment