/[mldonkey]/mldonkey/src/daemon/driver/driverCommands.ml
ViewVC logotype

Diff of /mldonkey/src/daemon/driver/driverCommands.ml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.96 by spiralvoice, Sun Oct 23 16:05:41 2005 UTC revision 1.97 by spiralvoice, Sun Oct 30 21:10:18 2005 UTC
# Line 1051  let _ = Line 1051  let _ =
1051                dlkbs ulkbs (CommonGlobals.version ())                dlkbs ulkbs (CommonGlobals.version ())
1052            end            end
1053          else          else
1054            Printf.bprintf buf "Down: %.1f KB/s ( %d + %d ) | Up: %.1f KB/s ( %d + %d ) | Shared: %d/%s | Uploaded: %s"            DriverInteractive.print_bw_stats buf;
             (( (float_of_int !udp_download_rate) +. (float_of_int !control_download_rate)) /. 1024.0)  
           !udp_download_rate  
             !control_download_rate  
             (( (float_of_int !udp_upload_rate) +. (float_of_int !control_upload_rate)) /. 1024.0)  
           !udp_upload_rate  
             !control_upload_rate  
             !nshared_files  
             (size_of_int64 !nshared_bytes)  
             (size_of_int64 !upload_counter);  
1055          ""          ""
1056      ), ":\t\t\t\tprint current bandwidth stats";      ), ":\t\t\t\tprint current bandwidth stats";
1057    
# Line 2567  let _ = Line 2558  let _ =
2558            | ["queued"] ->            | ["queued"] ->
2559                let list = List2.tail_map file_info !!files in                let list = List2.tail_map file_info !!files in
2560                let list = List.filter ( fun f -> f.file_state = FileQueued ) list in                let list = List.filter ( fun f -> f.file_state = FileQueued ) list in
2561                let list = Sort.list (fun f1 f2 -> f1.file_name >= f2.file_name) list in                DriverInteractive.display_active_file_list buf o list;
               simple_print_file_list false buf list o;  
2562                ""                ""
2563            | ["paused"] ->            | ["paused"] ->
2564                let list = List2.tail_map file_info !!files in                let list = List2.tail_map file_info !!files in
2565                let list = List.filter ( fun f -> f.file_state = FilePaused ) list in                let list = List.filter ( fun f -> f.file_state = FilePaused ) list in
2566                let list = Sort.list (fun f1 f2 -> f1.file_name >= f2.file_name) list in                DriverInteractive.display_active_file_list buf o list;
               simple_print_file_list false buf list o;  
2567                ""                ""
2568            | ["downloading"] ->            | ["downloading"] ->
2569                let list = List2.tail_map file_info !!files in                let list = List2.tail_map file_info !!files in
2570                let list = List.filter ( fun f -> f.file_state = FileDownloading ) list in                let list = List.filter ( fun f -> f.file_state = FileDownloading ) list in
2571                let list = Sort.list                DriverInteractive.display_file_list buf o list;
                 ( fun f1 f2 ->  
                   f2.file_size -- f2.file_downloaded <=  
                   f1.file_size -- f1.file_downloaded  
                 ) list in  
               simple_print_file_list false buf list o;  
               if !!done_files <> [] then  
                 begin  
                   simple_print_file_list true buf  
                     (List2.tail_map file_info !!done_files) o;  
                   Printf.bprintf buf "Use 'commit' to move downloaded files to the incoming directory"  
                 end;  
2572                ""                ""
2573            | [arg] ->            | [arg] ->
2574              let num = int_of_string arg in              let num = int_of_string arg in
# Line 2624  let _ = Line 2602  let _ =
2602              !!done_files;              !!done_files;
2603              ""              ""
2604          | _ ->          | _ ->
2605              DriverInteractive.display_file_list buf o;              let list = List2.tail_map file_info !!files in
2606                DriverInteractive.display_file_list buf o list;
2607              ""              ""
2608      ), "<num> :\t\t\t\t$bview file info$n";      ), "<num> :\t\t\t\t$bview file info$n";
2609    

Legend:
Removed from v.1.96  
changed lines
  Added in v.1.97

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26