async void Handle_Clicked(object sender, EventArgs e)
        {
            IPhotoPickerService photoPicker = App.Factory.Create();

            Stream stream = await photoPicker.GetImageStreamAsync();

            if (stream != null)
            {
                imgPhoto.Source = ImageSource.FromStream(() => stream);
            }
        }
示例#2
0
        internal async void OnChangeProfilePic()
        {
            Stream stream = await _photoPickerService.GetImageStreamAsync();

            if (stream != null)
            {
                string message = await _userController.ChangeProfilePicture(User.Id, stream);

                if (string.IsNullOrEmpty(message))
                {
                    ProfilePic = ByteToImage(_constantUserInstance.GetProfilePic());
                }
            }
        }
示例#3
0
 private void BrowsePicture()
 {
     _photoPickerService.GetImageStreamAsync();
 }