Пример #1
0
 public override void OnDetach()
 {
     base.OnDetach();
     if (_cropImageView != null)
     {
         _cropImageView.SetOnSetImageUriCompleteListener(null);
         _cropImageView.SetOnCropImageCompleteListener(null);
     }
 }
Пример #2
0
        public override void OnViewCreated(View view, Bundle savedInstanceState)
        {
            base.OnViewCreated(view, savedInstanceState);

            mCropImageView = (CropImageView)view.FindViewById(Resource.Id.cropImageView);
            mCropImageView.SetOnSetImageUriCompleteListener(this);
            mCropImageView.SetOnCropImageCompleteListener(this);

            UpdateCurrentCropViewOptions();

            if (savedInstanceState == null)
            {
                mCropImageView.SetImageUriAsync(imageUri);
            }
            ((ImageCropActivity)Activity).SetCurrentFragment(this);
        }
Пример #3
0
        public override void OnViewCreated(View view, Bundle savedInstanceState)
        {
            base.OnViewCreated(view, savedInstanceState);

            _cropImageView = (CropImageView)view.FindViewById(Resource.Id.cropImageView);
            _cropImageView.SetOnSetImageUriCompleteListener(this);
            _cropImageView.SetOnCropImageCompleteListener(this);

            UpdateCurrentCropViewOptions();

            if (savedInstanceState == null)
            {
                if (_demoPreset == CropDemoPreset.ScaleCenterInside)
                {
                    _cropImageView.ImageResource = Resource.Drawable.cat_small;
                }
                else
                {
                    _cropImageView.ImageResource = Resource.Drawable.cat;
                }
            }
        }
Пример #4
0
        public override void OnViewCreated(View view, Bundle savedInstanceState)
        {
            base.OnViewCreated(view, savedInstanceState);

            mCropImageView = (CropImageView)view.FindViewById(Resource.Id.cropImageView);
            mCropImageView.SetOnSetImageUriCompleteListener(this);
            mCropImageView.SetOnCropImageCompleteListener(this);

            UpdateCurrentCropViewOptions();

            if (savedInstanceState == null)
            {
                if (mDemoPreset == CropDemoPreset.SCALE_CENTER_INSIDE)
                {
                    mCropImageView.ImageResource = (Resource.Drawable.cat_small);
                }
                else
                {
                    mCropImageView.ImageResource = (Resource.Drawable.cat);
                }
            }
        }