mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-07 20:31:06 -05:00
Hide loading bar once loaded enough to render
This commit is contained in:
parent
48d4e96221
commit
b94a9aab0d
2 changed files with 6 additions and 1 deletions
|
@ -90,6 +90,10 @@ define [
|
|||
# initializePosition()
|
||||
# flashControls()
|
||||
|
||||
scope.$on "loaded", () ->
|
||||
console.log "LOADED"
|
||||
scope.loading = false
|
||||
|
||||
#scope.$watch "highlights", (areas) ->
|
||||
# console.log 'got HIGHLIGHTS in pdfJS', areas
|
||||
|
||||
|
@ -151,7 +155,7 @@ define [
|
|||
|
||||
scope.$on 'progress', (event, progress) ->
|
||||
scope.$apply () ->
|
||||
console.log 'progress', progress.loaded, progress.total, progress
|
||||
#console.log 'progress', progress.loaded, progress.total, progress
|
||||
scope.progress = Math.floor(progress.loaded/progress.total*100)
|
||||
|
||||
template: """
|
||||
|
|
|
@ -50,6 +50,7 @@ define [
|
|||
$scope.destinations = result.destinations
|
||||
# console.log 'resolved q.all, page size is', result
|
||||
$scope.numPages = result.numPages
|
||||
$scope.$emit "loaded"
|
||||
|
||||
@setScale = (scale, containerHeight, containerWidth) ->
|
||||
$scope.loaded.then () ->
|
||||
|
|
Loading…
Reference in a new issue