Commit Graph

7579 Commits

Author SHA1 Message Date
Brendan Dahl
c8d729ff39 Merge pull request #5325 from fzembow/findcontrollerfix
Update findbar to wrap on initial search
2014-10-08 11:05:07 -07:00
Brendan Dahl
ccd7ae33e4 Merge pull request #5352 from Snuffleupagus/issue-2840
Use |toUnicode| when creating the glyph map for standard CIDFontType2 fonts without embedded font file
2014-10-08 10:09:10 -07:00
Yury Delendik
878fad47a7 Merge pull request #5351 from timvandermeij/destinations
Require destinations when they are needed and do not fetch all of them in advance
2014-10-06 17:34:55 -05:00
Tim van der Meij
aaa1f2cb11 Implemented NameTree.get() using binary search 2014-10-07 00:02:15 +02:00
Tim van der Meij
b215af30d3 Require destinations when they are needed and do not fetch all of them in advance 2014-10-06 22:26:18 +02:00
Jonas Jenwald
ecbb39f983 Fix loadingBar hiding when disableAutoFetch is enabled (issue 3590) 2014-10-05 23:16:36 +02:00
Jonas Jenwald
cfeb4c1019 Small refactoring of the loadingBar hiding code 2014-10-05 23:15:10 +02:00
Brendan Dahl
8a536ac346 Map missing glyphs in encoding to notdef glyph. 2014-10-03 12:11:20 -07:00
Brendan Dahl
2fc5e6a9ad Don't map glyphs to unicode non breaking space. 2014-10-02 10:58:56 -07:00
Fil Zembowicz
dcb931dbe0 Use existing page count in nextMatch 2014-10-02 08:57:01 -04:00
Fil Zembowicz
4275481e08 Fix how matches are found in search
Instead of keeping track of where the search starts, just
keep track of the number of pages and make sure we don't
visit pages more than once.
2014-10-01 19:57:57 -04:00
Yury Delendik
fb6d87c77b Merge pull request #5376 from yurydelendik/fontface3
Adds optional argument to FontFace contructor call.
2014-10-01 18:50:30 -05:00
Yury Delendik
8bec7ea8bd Adds optional argument to FontFace contructor call. 2014-10-01 18:15:23 -05:00
Yury Delendik
02b57416f4 Merge pull request #5374 from Snuffleupagus/viewer-cleanup-regression
Fix |cleanup| regression in the viewer
2014-10-01 17:49:22 -05:00
Jonas Jenwald
5f83739190 Fix |cleanup| regression in the viewer 2014-10-02 00:24:01 +02:00
Yury Delendik
56d11fc26b Merge pull request #5364 from Rob--W/firefox-pbu_isWindowPrivate
Firefox addon: Use isContentWindowPrivate instead of isWindowPrivate if available
2014-10-01 17:05:23 -05:00
Rob Wu
4fe92f6d01 addon: isWindowPrivate -> isContentWindowPrivate
As of Firefox 35, isContentWindowPrivate should be used for DOM windows instead of isWindowPrivate.
See https://bugzilla.mozilla.org/show_bug.cgi?id=1069059 and
http://hg.mozilla.org/mozilla-central/diff/324798b60ba3/toolkit/modules/PrivateBrowsingUtils.jsm

Without this fix, you will get the following error message when Firefox+PDF.js is started:
>
WARNING: content window passed to PrivateBrowsingUtils.isWindowPrivate. Use isContentWindowPrivate instead (but only for frame scripts).
pbu_isWindowPrivate@resource://gre/modules/PrivateBrowsingUtils.jsm:25:14
ChromeActions.prototype.isInPrivateBrowsing@resource://pdf.js/PdfStreamConverter.jsm:237:12
xhr_onreadystatechange@resource://pdf.js/PdfStreamConverter.jsm:545:30
NetworkManager_requestRange@resource://pdf.js/network.js:95:7
NetworkManager_requestRange@resource://pdf.js/network.js:81:14
RangedChromeActions_requestDataRange@resource://pdf.js/PdfStreamConverter.jsm:596:1
RequestListener.prototype.receive@resource://pdf.js/PdfStreamConverter.jsm:705:5
PdfStreamConverter.prototype.onStartRequest/proxy.onStopRequest/<@resource://pdf.js/PdfStreamConverter.jsm:909:11
FirefoxComClosure/<.request@resource://pdf.js/web/viewer.js:529:14
PdfDataRangeTransport_requestDataRange@resource://pdf.js/web/viewer.js:2977:9
transportDataRange@resource://pdf.js/build/pdf.js:2122:13
messageHandlerComObjOnMessage@resource://pdf.js/build/pdf.js:1219:9
2014-10-01 23:50:03 +02:00
Yury Delendik
dc30dba760 Merge pull request #5371 from Snuffleupagus/disableAutoFetch-regression
Fix disableAutoFetch regression in the generic viewer
2014-10-01 16:46:35 -05:00
Tim van der Meij
2b8ff7bd49 Merge pull request #5369 from Snuffleupagus/viewer-temp-pref-names
Fix inconsistencies in the preference names used by PDFViewerApplication
2014-10-01 23:25:14 +02:00
Yury Delendik
09b62e8317 Merge pull request #5373 from yurydelendik/issue5372
Disables streaming in the extension when length is undefined.
2014-10-01 15:34:37 -05:00
Yury Delendik
c0e933682a Disables streaming in the extension when length is undefined. 2014-10-01 14:16:50 -05:00
Jonas Jenwald
cb3e5903cb Fix disableAutoFetch regression in the generic viewer
After PR 5263, setting `disableAutoFetch = true` in the generic viewer no longer works correctly, since the entire file loads even with `disableStream = true`.
2014-10-01 20:53:17 +02:00
Jonas Jenwald
a429e88c3b Fix inconsistencies in the preference names used by PDFViewerApplication
Since `preferenceSidebarViewOnLoad` is an enumeration value, it seems better to initialize it with the default one instead of a boolean.
`preferencesPdfBugEnabled` uses a superfluous "s", which is a typo I made when I introduced it.
2014-10-01 12:30:11 +02:00
Yury Delendik
29eb147d42 Merge pull request #4150 from Snuffleupagus/issue-3990
Add a page loading indicator to the page number input
2014-09-30 18:06:39 -05:00
Yury Delendik
77631cc84e Merge pull request #5368 from yurydelendik/fixprintcss
Fixes printing regression a10fde1
2014-09-30 18:01:52 -05:00
Yury Delendik
193b55dba0 Fixes printing regression a10fde1 2014-09-30 18:01:30 -05:00
Jonas Jenwald
902b72ba50 Add updated loading-small.png (and corresponding Retina) asset 2014-10-01 00:13:45 +02:00
Jonas Jenwald
b9ef80e167 Add a page loading indicator to the page number input 2014-10-01 00:13:44 +02:00
Yury Delendik
1858fbfe82 Merge pull request #5366 from Rob--W/use-font-loader-api
Use font loader api
2014-09-30 16:35:41 -05:00
Yury Delendik
88d5fa0fc3 Fixes examples comments. 2014-09-30 15:42:28 -05:00
Yury Delendik
dfd23b50cb Merge pull request #5367 from yurydelendik/fixpdfbug
Fixes enabling pdfBug
2014-09-30 15:20:22 -05:00
Yury Delendik
5e0b2d383f Fixes enabling pdfBug 2014-09-30 15:19:39 -05:00
Rob Wu
d0845df971 Use Font Loading API if available
http://dev.w3.org/csswg/css-font-loading/
2014-09-30 22:18:53 +02:00
Jonas Jenwald
5c56cdc544 Merge pull request #5363 from yurydelendik/pdfviewecomponent
Packages PDFViewer as a UI component.
2014-09-30 20:16:30 +02:00
Yury Delendik
5740b96020 Introduces 'pagesinit' event. 2014-09-30 12:41:53 -05:00
Yury Delendik
b16a406f3a Packages PDFViewer as a UI component. 2014-09-30 12:41:53 -05:00
Rob Wu
6a230af332 Rename FontFace to FontFaceObject
This name clashes with the FontFace constructor from the Font Loading CSS module:
http://dev.w3.org/csswg/css-font-loading/#font-face-constructor
2014-09-30 19:33:16 +02:00
Jonas Jenwald
a10fde165c Merge pull request #5362 from yurydelendik/css-import
Use CSS import to separate pdfviewer styles
2014-09-30 17:55:13 +02:00
Yury Delendik
70a0935737 Move text_layer_builder and pdf_viewer styles out 2014-09-30 10:48:29 -05:00
Jonas Jenwald
7059358534 Merge pull request #5361 from yurydelendik/movescrollinto
Moves scrollPageIntoView to the PDFViewer.
2014-09-30 15:32:01 +02:00
Yury Delendik
5b93cc102c Adds css import preprocessing 2014-09-30 08:11:43 -05:00
Yury Delendik
374b94381d Moves scrollPageIntoView to the PDFViewer. 2014-09-30 07:13:46 -05:00
Yury Delendik
f5d416cfdf Merge pull request #5360 from Snuffleupagus/pr-5359-followup
Followup fix for entering/exiting Presentation mode
2014-09-30 06:41:52 -05:00
Jonas Jenwald
b06e65e5d6 Followup fix for entering/exiting Presentation mode
Even after PR 5359, switching to/from Presentation mode is still sluggish and I'm still seeing `too much recursion` printed in the console.
I've managed to track down the issue to line https://github.com/mozilla/pdf.js/blob/master/web/page_view.js#L371. It appears that for this particular case, we actually *need* to set `noScroll = true` when calling the `_setScale` function. (Note that it only applies to *this* line, and not to Presentation mode in general.)
Given the amount of refactoring done to the viewer, I'm not sure what the best way to fix this would be. However I'm submitting this patch as an easy workaround for now, but we should probably refactor this to avoid calling a "private" method directly.
2014-09-30 13:02:53 +02:00
Yury Delendik
f852a44383 Merge pull request #5359 from yurydelendik/pdfviewer2
Fixes typo/regression of #5295 for presentation mode
2014-09-29 20:19:10 -05:00
Yury Delendik
504d2c19e0 Fixes typo/regression of #5295 for presentation mode 2014-09-29 20:17:26 -05:00
Brendan Dahl
1145eb8c09 Merge pull request #5295 from yurydelendik/pdfviewer
Refactoring to move page display code into separate class
2014-09-29 15:23:35 -07:00
Yury Delendik
44779f14b0 Renames and refactors PDFView to PDFViewerApplication. 2014-09-28 10:39:56 -05:00
Yury Delendik
a89bba35b2 Adds types definitions (jsdoc) for the PDFViewer code. 2014-09-28 10:39:56 -05:00
Yury Delendik
3773972dce Marks some private methods in PDFViewer and PDFThumbnailViewer
Conflicts:
	web/pdf_viewer.js
2014-09-28 10:39:56 -05:00