Microsoft Windows Phone 8.1 support ends (13 Jul 2017)

Microsoft has ended support for Windows Phone 8.1

Questions about Android development and PDF

Is it possible to move SDK viewer from an activity to a fragment?

More
IP: 194.86.38.39 5 years 7 months ago #15181 by esaw
Hi!
Is it possible to move SDK viewer from an activity to a fragment? If so, do you have any examples?
Thanks!
More
IP: 93.42.249.223 5 years 7 months ago #15182 by luca.f
The reader is just an Android View (PDFLayoutView or PDFGLLayoutView).
You can include the view to the fragment (programmatically or by xml definition, it can be its root view if you want to), and implement ILayoutView.PDFLayoutListener to handle the callbacks and create a PDFViewController to manage the reader actions (check OpenTask in PDFGLViewAct or PDFViewAct).
More or less everything that's done in the activity can be moved to your fragment.
Do not forget to handle the onDestroy action to release SDK resources
Time to create page: 0.386 seconds
Powered by Kunena Forum