diff options
Diffstat (limited to 'client/src/assets/player/videojs-components')
-rw-r--r-- | client/src/assets/player/videojs-components/p2p-info-button.ts | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/client/src/assets/player/videojs-components/p2p-info-button.ts b/client/src/assets/player/videojs-components/p2p-info-button.ts index db6806fed..b1f7cd751 100644 --- a/client/src/assets/player/videojs-components/p2p-info-button.ts +++ b/client/src/assets/player/videojs-components/p2p-info-button.ts | |||
@@ -84,8 +84,17 @@ class P2pInfoButton extends Button { | |||
84 | const totalUploaded = bytes(p2pStats.uploaded + httpStats.uploaded) | 84 | const totalUploaded = bytes(p2pStats.uploaded + httpStats.uploaded) |
85 | const numPeers = p2pStats.numPeers | 85 | const numPeers = p2pStats.numPeers |
86 | 86 | ||
87 | subDivWebtorrent.title = this.player().localize('Total downloaded: ') + totalDownloaded.join(' ') + '\n' + | 87 | subDivWebtorrent.title = this.player().localize('Total downloaded: ') + totalDownloaded.join(' ') + '\n' |
88 | this.player().localize('Total uploaded: ' + totalUploaded.join(' ')) | 88 | |
89 | if (data.source === 'p2p-media-loader') { | ||
90 | const downloadedFromServer = bytes(httpStats.downloaded).join(' ') | ||
91 | const downloadedFromPeers = bytes(p2pStats.downloaded).join(' ') | ||
92 | |||
93 | subDivWebtorrent.title += | ||
94 | '* ' + this.player().localize('From the server: ') + downloadedFromServer + '\n' + | ||
95 | '* ' + this.player().localize('From peers: ') + downloadedFromPeers + '\n' | ||
96 | } | ||
97 | subDivWebtorrent.title += this.player().localize('Total uploaded: ') + totalUploaded.join(' ') | ||
89 | 98 | ||
90 | downloadSpeedNumber.textContent = downloadSpeed[ 0 ] | 99 | downloadSpeedNumber.textContent = downloadSpeed[ 0 ] |
91 | downloadSpeedUnit.textContent = ' ' + downloadSpeed[ 1 ] | 100 | downloadSpeedUnit.textContent = ' ' + downloadSpeed[ 1 ] |