Changeset 8854
- Timestamp:
- Jul 28, 2009, 4:52:59 AM (13 years ago)
- Location:
- trunk/web
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/web/javascript/torrent.js
r8853 r8854 452 452 else 453 453 { 454 // Update the 'in progress' bar455 e = root._progress_complete_container;456 c = 'torrent_progress_bar';457 c += (this.isActive()) ? ' complete' : ' complete_stopped';458 e.className = c;459 460 454 // Create the 'progress details' label 461 455 // Eg: '698.05 MB, uploaded 8.59 GB (Ratio: 12.3)' … … 467 461 c += ')'; 468 462 progress_details = c; 469 470 // Hide the 'incomplete' bar 471 root._progress_incomplete_container.style.display = 'none'; 472 473 // Set progress to maximum 474 root._progress_complete_container.style.width = MaxBarWidth + '%'; 463 464 var status = this.isActive() ? 'complete' : 'complete_stopped'; 465 466 if(this.isActive() && this.seedRatio() > 0){ 467 status = 'complete seeding' 468 var seedRatioRatio = this._upload_ratio / this.seedRatio(); 469 var seedRatioPercent = Math.round( seedRatioRatio * 100 * MaxBarWidth ) / 100; 470 471 root._progress_incomplete_container.className = 'torrent_progress_bar incomplete seeding' 472 root._progress_incomplete_container.style.display = 'block'; 473 root._progress_incomplete_container.style.width = seedRatioPercent + '%'; 474 475 // Set progress to maximum 476 root._progress_complete_container.style.width = MaxBarWidth - seedRatioPercent + '%'; 477 } 478 else 479 { 480 // Hide the 'incomplete' bar 481 root._progress_incomplete_container.className = 'torrent_progress_bar incomplete' 482 root._progress_incomplete_container.style.display = 'none'; 483 484 // Set progress to maximum 485 root._progress_complete_container.style.width = MaxBarWidth + '%'; 486 } 487 488 // Update the 'in progress' bar 489 e = root._progress_complete_container; 490 e.className = 'torrent_progress_bar ' + status; 475 491 } 476 492 -
trunk/web/stylesheets/common.css
r8787 r8854 428 428 border: 1px solid #29AD35; 429 429 } 430 ul.torrent_list li.torrent div.torrent_progress_bar.complete.seeding { 431 background-position: left -40px; 432 border: 1px solid #269e30; 433 border-right: none; 434 } 430 435 431 436 ul.torrent_list li.torrent div.torrent_progress_bar.in_progress { … … 440 445 border: 1px solid #C8CACD; 441 446 border-left: none; 447 } 448 449 ul.torrent_list li.torrent div.torrent_progress_bar.incomplete.seeding { 450 background-position: left -10px; 451 border: 1px solid #29AD35; 442 452 } 443 453
Note: See TracChangeset
for help on using the changeset viewer.