Пример #1
0
        public override View AddContentView(LayoutInflater inflater, ViewGroup container)
        {
            workflow    = (Workflow)Arguments.GetParcelable(WORKFLOW_EXTRA);
            stepResults = Arguments.GetParcelableArrayList(WORKFLOW_RESULT_EXTRA).Cast <WorkflowStepResult>().ToList();

            var view  = inflater.Inflate(Resource.Layout.fragment_workflow_result_dialog, container);
            var title = (TextView)view.FindViewById(Resource.Id.title);

            title.Text = "Result";

            var first = stepResults[0] as MachineReadableZoneWorkflowStepResult;

            if (!(first.Step is ScanMachineReadableZoneWorkflowStep))
            {
                return(view);
            }

            CopyText = ParseData(first.MrzResult);

            var text = view.FindViewById <TextView>(Resource.Id.tv_data);

            text.Text = CopyText;

            view.FindViewById(Resource.Id.images_container).Visibility  = ViewStates.Visible;
            view.FindViewById(Resource.Id.front_snap_result).Visibility = ViewStates.Visible;

            var uri = PageRepository.FindUri(first.CapturedPage);

            view.FindViewById <ImageView>(Resource.Id.front_snap_result).SetImageURI(uri);

            return(view);
        }