|
|
|
@ -135,26 +135,19 @@ export default { |
|
|
|
|
}) |
|
|
|
|
}, |
|
|
|
|
pdfTimer () { |
|
|
|
|
// this.renderPage(this.pageNumber) |
|
|
|
|
// pdf canvas update hack |
|
|
|
|
var canvas = document.getElementById('mypdfview'); |
|
|
|
|
var context = canvas.getContext('2d'); |
|
|
|
|
var text = '.'; |
|
|
|
|
|
|
|
|
|
//Set the font size and the fontface to use. |
|
|
|
|
context.font = '25px Arial'; |
|
|
|
|
|
|
|
|
|
//Set the color of the text. This can be |
|
|
|
|
//an RGB color or a textual description |
|
|
|
|
//such as red. |
|
|
|
|
context.fillStyle = '0,0,0'; |
|
|
|
|
|
|
|
|
|
//The X coordinate where to start |
|
|
|
|
var x = 0; |
|
|
|
|
|
|
|
|
|
//The Y coordinate where to start |
|
|
|
|
var y = 0; |
|
|
|
|
|
|
|
|
|
//Use the fillText method to draw the text. |
|
|
|
|
context.fillText(text, x, y); |
|
|
|
|
}, |
|
|
|
|
nextPage () { |
|
|
|
@ -187,7 +180,7 @@ export default { |
|
|
|
|
// var pageNumber = 1; |
|
|
|
|
this.pdf = pdf |
|
|
|
|
this.loading = true |
|
|
|
|
setInterval(this.pdfTimer, 1000/60) |
|
|
|
|
setInterval(this.pdfTimer, 1000/15) |
|
|
|
|
this.renderPage(1) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|