Compiled
This commit is contained in:
parent
1d9c566134
commit
62892f453e
3 changed files with 22 additions and 14 deletions
|
@ -190,15 +190,15 @@
|
|||
dbg('Destroyed torrent');
|
||||
};
|
||||
$scope.onTorrent = function(torrent, isSeed) {
|
||||
$scope.client.validTorrents.push(torrent);
|
||||
torrent.safeTorrentFileURL = torrent.torrentFileURL;
|
||||
torrent.fileName = torrent.name + '.torrent';
|
||||
if (!isSeed) {
|
||||
$scope.client.validTorrents.push(torrent);
|
||||
if (!($scope.selectedTorrent != null)) {
|
||||
$scope.selectedTorrent = torrent;
|
||||
}
|
||||
$scope.client.processing = false;
|
||||
}
|
||||
if (!($scope.selectedTorrent != null) || isSeed) {
|
||||
$scope.selectedTorrent = torrent;
|
||||
}
|
||||
torrent.files.forEach(function(file) {
|
||||
file.getBlobURL(function(err, url) {
|
||||
if (err) {
|
||||
|
@ -206,6 +206,10 @@
|
|||
}
|
||||
if (isSeed) {
|
||||
dbg('Started seeding', torrent);
|
||||
$scope.client.validTorrents.push(torrent);
|
||||
if (!($scope.selectedTorrent != null)) {
|
||||
$scope.selectedTorrent = torrent;
|
||||
}
|
||||
$scope.client.processing = false;
|
||||
}
|
||||
file.url = url;
|
||||
|
|
|
@ -8,8 +8,9 @@
|
|||
<meta name="keywords" content="βTorrent, btorrent, client, webtorrent, browser, torrent, stream, bittorrent">
|
||||
<meta name="author" content="Diego Rodríguez Baquero - DiegoRBaquero">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<script src="https://cdn.jsdelivr.net/g/webtorrent@0.63.3,momentjs@2.10,angularjs@1.4,angular.ui-grid@3.0,angular.ng-notify@0.7"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/danialfarid-angular-file-upload/10.1.8/ng-file-upload.min.js"></script>
|
||||
<!--webtorrent@0.63.3,-->
|
||||
<script src="webtorrent.min.js">//WebTorrent 0.63.4</script>
|
||||
<script src="https://cdn.jsdelivr.net/g/momentjs@2.10,angularjs@1.4,angular.ui-grid@3.0,angular.ng-notify@0.7,angular.file-upload@10.1"></script>
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/g/normalize@3.0,skeleton@2.0,angular.ng-notify@0.7(ng-notify.min.css)">
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/fontawesome/4.5/css/font-awesome.min.css">
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/angular.ui-grid/3.0.7/ui-grid.min.css">
|
||||
|
@ -17,7 +18,7 @@
|
|||
</head>
|
||||
<body ng-controller="bTorrentCtrl" ng-cloak="">
|
||||
<header>
|
||||
<h1>βTorrent<span class="version"> v0.7.1</span></h1>
|
||||
<h1>βTorrent<span class="version"> v0.8.0</span></h1>
|
||||
</header>
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
|
@ -65,12 +66,16 @@
|
|||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<hr>
|
||||
<div class="center"><strong>
|
||||
Client Stats:
|
||||
↓ {{client.downloadSpeed() | pbytes}}/s ·
|
||||
↑ {{client.uploadSpeed() | pbytes}}/s ·
|
||||
Ratio: {{client.ratio | number:2}}</strong></div>
|
||||
</div>
|
||||
<footer><a href="https://github.com/DiegoRBaquero/BTorrent/issues" target="_blank" class="button">Suggest a new feature / Report a bug<i class="fa comment"></i></a><br>An Open-Source project by <a href="http://diegorbaquero.com">DiegoRBaquero</a><br>Powered by <a href="https://webtorrent.io">WebTorrent</a>
|
||||
<footer><a href="https://github.com/DiegoRBaquero/BTorrent/issues" target="_blank" class="button"><i class="fa fa-github fa-5"> </i> Suggest a feature / Report a bug <i class="fa fa-comment"></i></a><br>An Open-Source project by <a href="http://diegorbaquero.com">DiegoRBaquero</a><br>Powered by <a href="https://webtorrent.io">WebTorrent</a>
|
||||
<p></p>
|
||||
</footer>
|
||||
<div ng-show="client.processing" class="spinner"><i class="fa fa-spinner fa-6 fa-spin spinner-icon"></i></div>
|
||||
<div ng-show="client.processing" class="spinner"><i class="fa fa-spinner fa-spin spinner-icon"></i></div>
|
||||
<script src="app.js"></script>
|
||||
</body>
|
||||
</html>
|
|
@ -11,13 +11,12 @@ th, td {
|
|||
overflow: auto;
|
||||
white-space: nowrap; }
|
||||
|
||||
hr {
|
||||
margin-top: 20px;
|
||||
margin-bottom: 10px; }
|
||||
|
||||
h2, h3, h4, h5, h6, ul, li {
|
||||
margin-bottom: 0; }
|
||||
|
||||
footer {
|
||||
margin-top: 10px; }
|
||||
|
||||
.container {
|
||||
width: 95%;
|
||||
max-width: 95%; }
|
||||
|
|
Loading…
Reference in a new issue