espresso3389 / pdfrx

pdfrx is yet another PDF viewer implementation that built on the top of pdfium. The plugin currently supports Android, iOS, Windows, macOS, Linux, and Web.
MIT License
60 stars 36 forks source link

PdfViewer doesn't update the pdf after setState #113

Open cyberneid opened 1 month ago

cyberneid commented 1 month ago

With version 1.0.50 and later there is the following issue:

I added PdfViewr by using Uint8list data in this way:

pdfrx.PdfViewer.data(
     _pdfData!,
      controller: _controller,

Then I change _pdfData in a function and call setState:

_pdfData = Uint8List.fromList(newDocumentData);                 
 setState(() {  });

After that, the PdfViewer doesn't show the new pdf. It still shows the old pdf.

With the previous version 0.4.5 it worked. The issue was not present.