switch from log_event to Logger.log

keep log_event for compatibility
This commit is contained in:
Miles Steele
2013-08-19 11:25:44 -04:00
committed by Carlos Andrés Rocha
parent 5692867b14
commit cb7a3ad8eb
5 changed files with 12 additions and 11 deletions

View File

@@ -42,5 +42,7 @@ class @Logger
page: window.location.href
async: false
# Keeping this for compatibility issue only.
# log_event exists for compatibility reasons
# and will soon be deprecated.
@log_event = Logger.log

View File

@@ -157,7 +157,7 @@ PDFJS.disableWorker = true;
}
// Update logging:
log_event("book", { "type" : "gotopage", "old" : pageNum, "new" : num });
Logger.log("book", { "type" : "gotopage", "old" : pageNum, "new" : num });
parentElement = viewerElement;
while (parentElement.hasChildNodes())
@@ -207,7 +207,7 @@ PDFJS.disableWorker = true;
if (pageNum <= 1)
return;
renderPage(pageNum - 1);
log_event("book", { "type" : "prevpage", "new" : pageNum });
Logger.log("book", { "type" : "prevpage", "new" : pageNum });
}
// Go to next page
@@ -215,7 +215,7 @@ PDFJS.disableWorker = true;
if (pageNum >= pdfDocument.numPages)
return;
renderPage(pageNum + 1);
log_event("book", { "type" : "nextpage", "new" : pageNum });
Logger.log("book", { "type" : "nextpage", "new" : pageNum });
}
selectScaleOption = function(value) {