Merge pull request #738 from arturadib/text-select

Text selection
This commit is contained in:
Brendan Dahl 2011-12-01 12:29:13 -08:00
commit b958fd41d8
5 changed files with 196 additions and 19 deletions

View file

@ -489,6 +489,10 @@ var PageView = function pageView(container, content, id, pageWidth, pageHeight,
div.appendChild(canvas);
this.canvas = canvas;
var textLayer = document.createElement('div');
textLayer.className = 'textLayer';
div.appendChild(textLayer);
var scale = this.scale;
canvas.width = pageWidth * scale;
canvas.height = pageHeight * scale;
@ -505,7 +509,7 @@ var PageView = function pageView(container, content, id, pageWidth, pageHeight,
this.updateStats();
if (this.onAfterDraw)
this.onAfterDraw();
}).bind(this));
}).bind(this), textLayer);
setupLinks(this.content, this.scale);
div.setAttribute('data-loaded', true);