73 lines
2.2 KiB
Java
73 lines
2.2 KiB
Java
|
|
package com.ssb.simplitend.patientprofile;
|
||
|
|
|
||
|
|
import android.animation.Animator;
|
||
|
|
import android.os.Bundle;
|
||
|
|
import android.view.LayoutInflater;
|
||
|
|
import android.view.View;
|
||
|
|
import android.view.ViewGroup;
|
||
|
|
|
||
|
|
import androidx.annotation.NonNull;
|
||
|
|
import androidx.annotation.Nullable;
|
||
|
|
import androidx.fragment.app.Fragment;
|
||
|
|
|
||
|
|
import com.daimajia.androidanimations.library.Techniques;
|
||
|
|
import com.daimajia.androidanimations.library.YoYo;
|
||
|
|
import com.ssb.simplitend.R;
|
||
|
|
import com.ssb.simplitend.apputils.AppUtil;
|
||
|
|
import com.ssb.simplitend.databinding.RegisterationDoneFragmentBinding;
|
||
|
|
|
||
|
|
public class RegisterCompleteFragment extends Fragment {
|
||
|
|
|
||
|
|
public RegisterationDoneFragmentBinding binding;
|
||
|
|
|
||
|
|
public RegisterCompleteFragment(){
|
||
|
|
// required
|
||
|
|
}
|
||
|
|
|
||
|
|
@Nullable
|
||
|
|
@Override
|
||
|
|
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
|
||
|
|
binding = RegisterationDoneFragmentBinding.inflate(inflater, container, false);
|
||
|
|
|
||
|
|
binding.animIv.setAnimation(R.raw.done_anim_2);
|
||
|
|
binding.animIv.playAnimation();
|
||
|
|
|
||
|
|
binding.animIv.addAnimatorListener(new Animator.AnimatorListener() {
|
||
|
|
@Override
|
||
|
|
public void onAnimationStart(@NonNull Animator animator) {
|
||
|
|
|
||
|
|
}
|
||
|
|
|
||
|
|
@Override
|
||
|
|
public void onAnimationEnd(@NonNull Animator animator) {
|
||
|
|
binding.title.setText(getString(R.string.your_profile_is_100_complete));
|
||
|
|
YoYo.with(Techniques.FadeIn)
|
||
|
|
.duration(100)
|
||
|
|
.playOn(binding.title);
|
||
|
|
}
|
||
|
|
|
||
|
|
@Override
|
||
|
|
public void onAnimationCancel(@NonNull Animator animator) {
|
||
|
|
|
||
|
|
}
|
||
|
|
|
||
|
|
@Override
|
||
|
|
public void onAnimationRepeat(@NonNull Animator animator) {
|
||
|
|
|
||
|
|
}
|
||
|
|
});
|
||
|
|
|
||
|
|
binding.proceed.setOnClickListener(v -> {
|
||
|
|
AppUtil.showAlert(requireContext(),
|
||
|
|
"Ask Caregiver to register",
|
||
|
|
"Kindly ask CareGiver to complete registeration.",
|
||
|
|
"OK",
|
||
|
|
((dialogInterface, i) -> {
|
||
|
|
|
||
|
|
}), null, null);
|
||
|
|
});
|
||
|
|
|
||
|
|
return binding.getRoot();
|
||
|
|
}
|
||
|
|
}
|