[Pkg-javascript-commits] [pdf.js] 64/116: Fix function names in PDFThumbnailViewer

David Prévot taffit at moszumanska.debian.org
Fri Mar 6 16:20:01 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 dfa993d13d03d71dc645c96ffafbbacbe31144c1
Author: Jonas Jenwald <jonas.jenwald at gmail.com>
Date:   Sat Jan 24 15:40:18 2015 +0100

    Fix function names in PDFThumbnailViewer
    
    Also updates a couple of the JSDoc comments.
---
 web/pdf_thumbnail_viewer.js | 29 +++++++++++++++++++++--------
 1 file changed, 21 insertions(+), 8 deletions(-)

diff --git a/web/pdf_thumbnail_viewer.js b/web/pdf_thumbnail_viewer.js
index 570fbb3..d926028 100644
--- a/web/pdf_thumbnail_viewer.js
+++ b/web/pdf_thumbnail_viewer.js
@@ -25,18 +25,20 @@ var THUMBNAIL_SCROLL_MARGIN = -19;
 
 /**
  * @typedef {Object} PDFThumbnailViewerOptions
- * @property {HTMLDivElement} container - The container for the thumbs elements.
+ * @property {HTMLDivElement} container - The container for the thumbnail
+ *   elements.
  * @property {IPDFLinkService} linkService - The navigation/linking service.
  * @property {PDFRenderingQueue} renderingQueue - The rendering queue object.
  */
 
 /**
- * Simple viewer control to display thumbs for pages.
+ * Simple viewer control to display thumbnails for pages.
  * @class
+ * @implements {IRenderableView}
  */
-var PDFThumbnailViewer = (function pdfThumbnailViewer() {
+var PDFThumbnailViewer = (function PDFThumbnailViewerClosure() {
   /**
-   * @constructs
+   * @constructs PDFThumbnailViewer
    * @param {PDFThumbnailViewerOptions} options
    */
   function PDFThumbnailViewer(options) {
@@ -49,6 +51,9 @@ var PDFThumbnailViewer = (function pdfThumbnailViewer() {
   }
 
   PDFThumbnailViewer.prototype = {
+    /**
+     * @private
+     */
     _scrollUpdated: function PDFThumbnailViewer_scrollUpdated() {
       this.renderingQueue.renderHighestPriority();
     },
@@ -57,11 +62,15 @@ var PDFThumbnailViewer = (function pdfThumbnailViewer() {
       return this.thumbnails[index];
     },
 
+    /**
+     * @private
+     */
     _getVisibleThumbs: function PDFThumbnailViewer_getVisibleThumbs() {
       return getVisibleElements(this.container, this.thumbnails);
     },
 
-    scrollThumbnailIntoView: function (page) {
+    scrollThumbnailIntoView:
+        function PDFThumbnailViewer_scrollThumbnailIntoView(page) {
       var selected = document.querySelector('.thumbnail.selected');
       if (selected) {
         selected.classList.remove('selected');
@@ -98,13 +107,16 @@ var PDFThumbnailViewer = (function pdfThumbnailViewer() {
       ThumbnailView.tempImageCache = null;
     },
 
-    _resetView: function () {
+    /**
+     * @private
+     */
+    _resetView: function PDFThumbnailViewer_resetView() {
       this.thumbnails = [];
       this._pagesRotation = 0;
       this._pagesRequests = [];
     },
 
-    setDocument: function (pdfDocument) {
+    setDocument: function PDFThumbnailViewer_setDocument(pdfDocument) {
       if (this.pdfDocument) {
         // cleanup of the elements and views
         var thumbsView = this.container;
@@ -136,7 +148,8 @@ var PDFThumbnailViewer = (function pdfThumbnailViewer() {
      * @returns {PDFPage}
      * @private
      */
-    _ensurePdfPageLoaded: function (thumbView) {
+    _ensurePdfPageLoaded:
+        function PDFThumbnailViewer_ensurePdfPageLoaded(thumbView) {
       if (thumbView.pdfPage) {
         return Promise.resolve(thumbView.pdfPage);
       }

-- 
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