[Pkg-javascript-commits] [pdf.js] 36/115: Use `DEFAULT_SCALE` instead of `1.0` as the default value if the `scale` option isn't specified when initializing `PDFPageView`
David Prévot
taffit at moszumanska.debian.org
Wed Dec 16 20:03:12 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository pdf.js.
commit 93f4f7a6499524a068d2bfcea4d3a9db4476cab4
Author: Jonas Jenwald <jonas.jenwald at gmail.com>
Date: Tue Aug 18 12:54:08 2015 +0200
Use `DEFAULT_SCALE` instead of `1.0` as the default value if the `scale` option isn't specified when initializing `PDFPageView`
A small piece of cleanup, in order to avoid unnecessarily hardcoding a default value.
---
web/pdf_page_view.js | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/web/pdf_page_view.js b/web/pdf_page_view.js
index 021fe7f..3f1a30c 100644
--- a/web/pdf_page_view.js
+++ b/web/pdf_page_view.js
@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-/* globals RenderingStates, PDFJS, CSS_UNITS, getOutputScale,
+/* globals RenderingStates, PDFJS, DEFAULT_SCALE, CSS_UNITS, getOutputScale,
TextLayerBuilder, AnnotationsLayerBuilder, Promise,
approximateFraction, roundToDivide */
@@ -55,7 +55,7 @@ var PDFPageView = (function PDFPageViewClosure() {
this.renderingId = 'page' + id;
this.rotation = 0;
- this.scale = scale || 1.0;
+ this.scale = scale || DEFAULT_SCALE;
this.viewport = defaultViewport;
this.pdfPageRotate = defaultViewport.rotation;
this.hasRestrictedScaling = false;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/pdf.js.git
More information about the Pkg-javascript-commits
mailing list