문제

Good Morning,

I have Stuck in a strange problem. I want to open PDF file in android...and i succeeded in two ways

1)-->First Using API (But that is damn slow)

2)-->Second Using ACTION_VIEW.It work on phone that has Quick Office Code is

File file = new File("/mnt/sdcard/videosadoce.pdf");

     if (file.exists()) {
         Uri path = Uri.fromFile(file);
         Intent intent = new Intent(Intent.ACTION_VIEW);
         intent.setDataAndType(path, "application/pdf");
         intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
         try {
             startActivity(intent);
         } 
         catch (ActivityNotFoundException e) {
             Toast.makeText(MyPdfViewer.this, 
                 "No Application Available to View PDF", 
                 Toast.LENGTH_SHORT).show();
         }
     }

Now i want to customize that view start by default activity.I want to add some animation to give effect of page open like book while i am navigating PDF file pages. So how to customize that pre-define view

도움이 되었습니까?

해결책

You cannot customize any animation to the third party application, which you launched by your application to view your pdf document. The only way you can achieve this is by integrating any Open Source PDF project and customize it as you want.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top