Skip to content

Commit

Permalink
Merge pull request #6669 from Snuffleupagus/PDFPageView-default-scale
Browse files Browse the repository at this point in the history
Use `DEFAULT_SCALE` instead of `1.0` as the default value if the `scale` option isn't specified when initializing `PDFPageView`
  • Loading branch information
timvandermeij committed Nov 20, 2015
2 parents 27292b2 + 93f4f7a commit df46b64
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions web/pdf_page_view.js
Original file line number Diff line number Diff line change
Expand Up @@ -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 */

Expand Down Expand Up @@ -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;
Expand Down

0 comments on commit df46b64

Please sign in to comment.