コード例 #1
0
        protected override void OnElementPropertyChanged(object sender, System.ComponentModel.PropertyChangedEventArgs e)
        {
            base.OnElementPropertyChanged(sender, e);

            if (e.PropertyName == nameof(_view.LocalFilePath))
            {
                try
                {
                    var docViewController = new DocumentVC(1, "Document", _view.LocalFilePath.Replace("file://", string.Empty));

                    if (docViewController.View == null)
                    {
                        return;
                    }

                    _nativeView = docViewController.View;

                    SetNativeControl(_nativeView);

                    _view.SetFinished();
                }
                catch
                {
                    _view.SetError();
                }
            }
        }
コード例 #2
0
            private void openDocument(int rowId)
            {
                var docViewController = new DocumentVC(PDFDocumentFile.PDFFiles[rowId].Id, PDFDocumentFile.PDFFiles[rowId].Name, PDFDocumentFile.PDFFiles[rowId].FilePath);

                _vc.NavigationController.PushViewController(docViewController, true);
            }
コード例 #3
0
 private void openDocument(int rowId)
 {
     var docViewController = new DocumentVC(PDFDocumentFile.PDFFiles[rowId].Id, PDFDocumentFile.PDFFiles[rowId].Name, PDFDocumentFile.PDFFiles[rowId].FilePath);
     _vc.NavigationController.PushViewController(docViewController, true);
 }