David PHAM-VAN

Fix PdfPreview timer dispose

1 # Changelog 1 # Changelog
2 2
  3 +## 5.0.5
  4 +
  5 +- Fix PdfPreview timer dispose [wwl901215]
  6 +
3 ## 5.0.4 7 ## 5.0.4
4 8
5 - Improve console error reporting 9 - Improve console error reporting
@@ -240,6 +240,12 @@ class _PdfPreviewState extends State<PdfPreview> { @@ -240,6 +240,12 @@ class _PdfPreviewState extends State<PdfPreview> {
240 } 240 }
241 241
242 @override 242 @override
  243 + void dispose() {
  244 + previewUpdate?.cancel();
  245 + super.dispose();
  246 + }
  247 +
  248 + @override
243 void reassemble() { 249 void reassemble() {
244 _raster(); 250 _raster();
245 super.reassemble(); 251 super.reassemble();
@@ -7,7 +7,7 @@ description: > @@ -7,7 +7,7 @@ description: >
7 homepage: https://github.com/DavBfr/dart_pdf/tree/master/printing 7 homepage: https://github.com/DavBfr/dart_pdf/tree/master/printing
8 repository: https://github.com/DavBfr/dart_pdf 8 repository: https://github.com/DavBfr/dart_pdf
9 issue_tracker: https://github.com/DavBfr/dart_pdf/issues 9 issue_tracker: https://github.com/DavBfr/dart_pdf/issues
10 -version: 5.0.4 10 +version: 5.0.5
11 11
12 environment: 12 environment:
13 sdk: ">=2.12.0-0 <3.0.0" 13 sdk: ">=2.12.0-0 <3.0.0"