Changeset 331


Ignore:
Timestamp:
11/05/07 14:01:27 (13 years ago)
Author:
Eoin
Message:

File list is now accessible again for stopped torrents. File list update bug fixed.

Files:
8 edited

Legend:

Unmodified
Added
Removed
  • Halite.pnproj

    r330 r331  
    1 <Project name="Halite"><MagicFolder excludeFolders="CVS;.svn" filter="*.*" name="res" path="res\"><File path="afxres.h"></File><File path="English.rtf"></File><File path="Halite.aps"></File><File path="Halite.ico"></File><File path="Halite.rc"></File><File path="Manifest.xml"></File><File path="resource.h"></File><File path="toolbar.bmp"></File></MagicFolder><MagicFolder excludeFolders="CVS;.svn" filter="*.*" name="src" path="src\"><MagicFolder excludeFolders="CVS;.svn" filter="*.*" name="advtabs" path="advtabs\"><File path="Debug.cpp"></File><File path="Debug.hpp"></File><File path="Files.cpp"></File><File path="Files.hpp"></File><File path="Peers.cpp"></File><File path="Peers.hpp"></File><File path="ThemeTestDialog.hpp"></File><File path="Torrent.cpp"></File><File path="Torrent.hpp"></File><File path="Tracker.cpp"></File><File path="Tracker.hpp"></File><File path="TrackerAddDialog.hpp"></File><File path="TrackerListView.cpp"></File><File path="TrackerListView.hpp"></File></MagicFolder><MagicFolder excludeFolders="CVS;.svn" filter="*.*" name="global" path="global\"><File path="InheritEnum.hpp"></File><File path="ini.cpp"></File><File path="ini.hpp"></File><File path="ini_adapter.cpp"></File><File path="ini_adapter.hpp"></File><File path="logger.cpp"></File><File path="logger.hpp"></File><File path="string_conv.cpp"></File><File path="string_conv.hpp"></File><File path="tinyxml.cpp"></File><File path="tinyxml.hpp"></File><File path="TinyXml.rb"></File><File path="tinyxmlerror.cpp"></File><File path="tinyxmlparser.cpp"></File><File path="unicode.hpp"></File><File path="utf8.hpp"></File><File path="wtl_app.cpp"></File><File path="wtl_app.hpp"></File></MagicFolder><File path="AddTorrentDialog.hpp"></File><File path="AdvHaliteDialog.cpp"></File><File path="AdvHaliteDialog.hpp"></File><File path="AtlAutosizeDlg.h"></File><File path="ConfigOptions.cpp"></File><File path="ConfigOptions.hpp"></File><File path="CSSFileDialog.hpp"></File><File path="DdxEx.hpp"></File><File path="DebugDialog.hpp"></File><File path="DropFileTarget.h"></File><File path="halConfig.cpp"></File><File path="halConfig.hpp"></File><File path="halEvent.cpp"></File><File path="halEvent.hpp"></File><File path="Halite.cpp"></File><File path="Halite.hpp"></File><File path="HaliteDialog.cpp"></File><File path="HaliteDialog.hpp"></File><File path="HaliteDialogBase.hpp"></File><File path="HaliteEditCtrl.hpp"></File><File path="HaliteIni.hpp"></File><File path="HaliteListManager.hpp"></File><File path="HaliteListView.cpp"></File><File path="HaliteListView.hpp"></File><File path="HaliteListViewCtrl.hpp"></File><File path="HaliteSortListViewCtrl.hpp"></File><File path="HaliteTabCtrl.hpp"></File><File path="HaliteTabPage.hpp"></File><File path="HaliteUpdateLock.hpp"></File><File path="HaliteWindow.cpp"></File><File path="HaliteWindow.hpp"></File><File path="halTorrent.cpp"></File><File path="halTorrent.hpp"></File><File path="halTorrentInternal.hpp"></File><File path="halXmlRpc.cpp"></File><File path="halXmlRpc.hpp"></File><File path="NTray.cpp"></File><File path="NTray.hpp"></File><File path="ProgressDialog.hpp"></File><File path="SimpleHtml.h"></File><File path="SplashDialog.hpp"></File><File path="SSFileDialog.hpp"></File><File path="stdAfx.cpp"></File><File path="stdAfx.hpp"></File><File path="UxthemeWrapper.cpp"></File><File path="UxthemeWrapper.hpp"></File><File path="WinAPIMutex.hpp"></File><File path="WinAPIWaitableTimer.hpp"></File></MagicFolder><File path="Jamfile.v2"></File></Project> 
     1<Project name="Halite"><MagicFolder excludeFolders="CVS;.svn" filter="*.*" name="res" path="res\"><MagicFolder excludeFolders="CVS;.svn" filter="*.*" name="res24" path="res24\"><File path="ad.ico"></File><File path="ae.ico"></File><File path="af.ico"></File><File path="ag.ico"></File><File path="ai.ico"></File><File path="al.ico"></File><File path="am.ico"></File><File path="an.ico"></File><File path="ao.ico"></File><File path="ar.ico"></File><File path="as.ico"></File><File path="at.ico"></File><File path="au.ico"></File><File path="aw.ico"></File><File path="ax.ico"></File><File path="az.ico"></File><File path="ba.ico"></File><File path="bb.ico"></File><File path="bd.ico"></File><File path="be.ico"></File><File path="bf.ico"></File><File path="bg.ico"></File><File path="bh.ico"></File><File path="bi.ico"></File><File path="bj.ico"></File><File path="bm.ico"></File><File path="bn.ico"></File><File path="bo.ico"></File><File path="br.ico"></File><File path="bs.ico"></File><File path="bt.ico"></File><File path="bw.ico"></File><File path="by.ico"></File><File path="bz.ico"></File><File path="ca.ico"></File><File path="cc.ico"></File><File path="cd.ico"></File><File path="cf.ico"></File><File path="cg.ico"></File><File path="ch.ico"></File><File path="ci.ico"></File><File path="ck.ico"></File><File path="cl.ico"></File><File path="cm.ico"></File><File path="cn.ico"></File><File path="co.ico"></File><File path="cr.ico"></File><File path="cu.ico"></File><File path="cv.ico"></File><File path="cx.ico"></File><File path="cy.ico"></File><File path="cz.ico"></File><File path="de.ico"></File><File path="dj.ico"></File><File path="dk.ico"></File><File path="dm.ico"></File><File path="do.ico"></File><File path="dz.ico"></File><File path="ec.ico"></File><File path="ee.ico"></File><File path="eg.ico"></File><File path="eh.ico"></File><File path="er.ico"></File><File path="es.ico"></File><File path="et.ico"></File><File path="fi.ico"></File><File path="fj.ico"></File><File path="fk.ico"></File><File path="fm.ico"></File><File path="fo.ico"></File><File path="fr.ico"></File><File path="ga.ico"></File><File path="gb.ico"></File><File path="gd.ico"></File><File path="ge.ico"></File><File path="gg.ico"></File><File path="gh.ico"></File><File path="gi.ico"></File><File path="gk.ico"></File><File path="gl.ico"></File><File path="gm.ico"></File><File path="gn.ico"></File><File path="gp.ico"></File><File path="gq.ico"></File><File path="gr.ico"></File><File path="gs.ico"></File><File path="gt.ico"></File><File path="gu.ico"></File><File path="gw.ico"></File><File path="gy.ico"></File><File path="hk.ico"></File><File path="hn.ico"></File><File path="hr.ico"></File><File path="ht.ico"></File><File path="hu.ico"></File><File path="Icons.h"></File><File path="Icons.rc"></File><File path="id.ico"></File><File path="ie.ico"></File><File path="il.ico"></File><File path="im.ico"></File><File path="in.ico"></File><File path="io.ico"></File><File path="iq.ico"></File><File path="ir.ico"></File><File path="is.ico"></File><File path="it.ico"></File><File path="je.ico"></File><File path="jm.ico"></File><File path="jo.ico"></File><File path="jp.ico"></File><File path="ke.ico"></File><File path="kg.ico"></File><File path="kh.ico"></File><File path="ki.ico"></File><File path="km.ico"></File><File path="kn.ico"></File><File path="kp.ico"></File><File path="kr.ico"></File><File path="kw.ico"></File><File path="ky.ico"></File><File path="kz.ico"></File><File path="la.ico"></File><File path="lb.ico"></File><File path="lc.ico"></File><File path="li.ico"></File><File path="lk.ico"></File><File path="lr.ico"></File><File path="ls.ico"></File><File path="lt.ico"></File><File path="lu.ico"></File><File path="lv.ico"></File><File path="ly.ico"></File><File path="ma.ico"></File><File path="mc.ico"></File><File path="md.ico"></File><File path="me.ico"></File><File path="mg.ico"></File><File path="mh.ico"></File><File path="mk.ico"></File><File path="ml.ico"></File><File path="mm.ico"></File><File path="mn.ico"></File><File path="mo.ico"></File><File path="mp.ico"></File><File path="mq.ico"></File><File path="mr.ico"></File><File path="ms.ico"></File><File path="mt.ico"></File><File path="mu.ico"></File><File path="mv.ico"></File><File path="mw.ico"></File><File path="mx.ico"></File><File path="my.ico"></File><File path="mz.ico"></File><File path="na.ico"></File><File path="nc.ico"></File><File path="ne.ico"></File><File path="nf.ico"></File><File path="ng.ico"></File><File path="ni.ico"></File><File path="nl.ico"></File><File path="no.ico"></File><File path="not.ico"></File><File path="np.ico"></File><File path="nr.ico"></File><File path="nu.ico"></File><File path="nz.ico"></File><File path="om.ico"></File><File path="pa.ico"></File><File path="pe.ico"></File><File path="pf.ico"></File><File path="pg.ico"></File><File path="ph.ico"></File><File path="pk.ico"></File><File path="pl.ico"></File><File path="pm.ico"></File><File path="pn.ico"></File><File path="pr.ico"></File><File path="ps.ico"></File><File path="pt.ico"></File><File path="pw.ico"></File><File path="py.ico"></File><File path="qa.ico"></File><File path="ro.ico"></File><File path="rs.ico"></File><File path="ru.ico"></File><File path="rw.ico"></File><File path="sa.ico"></File><File path="sb.ico"></File><File path="sc.ico"></File><File path="sd.ico"></File><File path="se.ico"></File><File path="sg.ico"></File><File path="sh.ico"></File><File path="si.ico"></File><File path="sk.ico"></File><File path="sl.ico"></File><File path="sm.ico"></File><File path="sn.ico"></File><File path="so.ico"></File><File path="sr.ico"></File><File path="st.ico"></File><File path="sv.ico"></File><File path="sy.ico"></File><File path="sz.ico"></File><File path="tc.ico"></File><File path="td.ico"></File><File path="Template.rc"></File><File path="tf.ico"></File><File path="tg.ico"></File><File path="th.ico"></File><File path="tj.ico"></File><File path="tk.ico"></File><File path="tl.ico"></File><File path="tm.ico"></File><File path="tn.ico"></File><File path="to.ico"></File><File path="tr.ico"></File><File path="tt.ico"></File><File path="tv.ico"></File><File path="tw.ico"></File><File path="tz.ico"></File><File path="ua.ico"></File><File path="ug.ico"></File><File path="us.ico"></File><File path="uy.ico"></File><File path="uz.ico"></File><File path="va.ico"></File><File path="vc.ico"></File><File path="ve.ico"></File><File path="vg.ico"></File><File path="vi.ico"></File><File path="vn.ico"></File><File path="vu.ico"></File><File path="wf.ico"></File><File path="ws.ico"></File><File path="ye.ico"></File><File path="yu.ico"></File><File path="za.ico"></File><File path="zm.ico"></File><File path="zw.ico"></File></MagicFolder><File path="afxres.h"></File><File path="English.rtf"></File><File path="Halite.aps"></File><File path="Halite.ico"></File><File path="Halite.rc"></File><File path="Icons.rc"></File><File path="Manifest.xml"></File><File path="resource.h"></File><File path="Slovenian.rc.bak"></File><File path="toolbar.bmp"></File></MagicFolder><MagicFolder excludeFolders="CVS;.svn" filter="*.*" name="src" path="src\"><MagicFolder excludeFolders="CVS;.svn" filter="*.*" name="advtabs" path="advtabs\"><File path="Debug.cpp"></File><File path="Debug.hpp"></File><File path="Files.cpp"></File><File path="Files.hpp"></File><File path="Peers.cpp"></File><File path="Peers.hpp"></File><File path="ThemeTestDialog.hpp"></File><File path="Torrent.cpp"></File><File path="Torrent.hpp"></File><File path="Tracker.cpp"></File><File path="Tracker.hpp"></File><File path="TrackerAddDialog.hpp"></File><File path="TrackerListView.cpp"></File><File path="TrackerListView.hpp"></File></MagicFolder><MagicFolder excludeFolders="CVS;.svn" filter="*.*" name="global" path="global\"><File path="InheritEnum.hpp"></File><File path="ini.cpp"></File><File path="ini.hpp"></File><File path="ini_adapter.cpp"></File><File path="ini_adapter.hpp"></File><File path="logger.cpp"></File><File path="logger.hpp"></File><File path="string_conv.cpp"></File><File path="string_conv.hpp"></File><File path="tinyxml.cpp"></File><File path="tinyxml.hpp"></File><File path="TinyXml.rb"></File><File path="tinyxmlerror.cpp"></File><File path="tinyxmlparser.cpp"></File><File path="unicode.hpp"></File><File path="utf8.hpp"></File><File path="wtl_app.cpp"></File><File path="wtl_app.hpp"></File></MagicFolder><File path="AddTorrentDialog.hpp"></File><File path="AdvHaliteDialog.cpp"></File><File path="AdvHaliteDialog.hpp"></File><File path="AtlAutosizeDlg.h"></File><File path="ConfigOptions.cpp"></File><File path="ConfigOptions.hpp"></File><File path="CSSFileDialog.hpp"></File><File path="DdxEx.hpp"></File><File path="DebugDialog.hpp"></File><File path="DropFileTarget.h"></File><File path="halConfig.cpp"></File><File path="halConfig.hpp"></File><File path="halEvent.cpp"></File><File path="halEvent.hpp"></File><File path="Halite.cpp"></File><File path="Halite.hpp"></File><File path="HaliteDialog.cpp"></File><File path="HaliteDialog.hpp"></File><File path="HaliteDialogBase.hpp"></File><File path="HaliteEditCtrl.hpp"></File><File path="HaliteIni.hpp"></File><File path="HaliteListManager.hpp"></File><File path="HaliteListView.cpp"></File><File path="HaliteListView.hpp"></File><File path="HaliteListViewCtrl.hpp"></File><File path="HaliteSortListViewCtrl.hpp"></File><File path="HaliteTabCtrl.hpp"></File><File path="HaliteTabPage.hpp"></File><File path="HaliteUpdateLock.hpp"></File><File path="HaliteWindow.cpp"></File><File path="HaliteWindow.hpp"></File><File path="halTorrent.cpp"></File><File path="halTorrent.hpp"></File><File path="halTorrentInternal.hpp"></File><File path="halXmlRpc.cpp"></File><File path="halXmlRpc.hpp"></File><File path="NTray.cpp"></File><File path="NTray.hpp"></File><File path="ProgressDialog.hpp"></File><File path="SimpleHtml.h"></File><File path="SplashDialog.hpp"></File><File path="SSFileDialog.hpp"></File><File path="stdAfx.cpp"></File><File path="stdAfx.hpp"></File><File path="UxthemeWrapper.cpp"></File><File path="UxthemeWrapper.hpp"></File><File path="WinAPIMutex.hpp"></File><File path="WinAPIWaitableTimer.hpp"></File></MagicFolder><File path="Jamfile.v2"></File></Project> 
  • Halite.pnps

    r329 r331  
    1 <pd><ViewState><e p="Halite\src\advtabs" x="true"></e><e p="Halite" x="true"></e><e p="Halite\res" x="true"></e><e p="Halite\src" x="true"></e><e p="Halite\src\global" x="true"></e></ViewState></pd> 
     1<pd><ViewState><e p="Halite\src\advtabs" x="true"></e><e p="Halite" x="true"></e><e p="Halite\res" x="true"></e><e p="Halite\res\res24" x="false"></e><e p="Halite\src" x="true"></e><e p="Halite\src\global" x="true"></e></ViewState></pd> 
  • lang/Italian.txt

    r328 r331  
    1 "English" ---> "Italiano" 
     1"English" ---> "Italiano" 
    22"English.rtf" ---> "../lang/Italian.rtf" 
    33"MS Shell Dlg" --->  ???  
     
    77"msctls_progress32" --->  ???  
    88"Torrent connection limits:" ---> "Limiti connessioni torrent:" 
    9 "Torrent transfer rates (KB/s):" ---> "Velocità trasferimento torrent (KB/s):" 
     9"Torrent transfer rates (KB/s):" ---> "Velocità trasferimento torrent (KB/s):" 
    1010"Total" ---> "Totale" 
    1111"Up" --->  ???  
     
    3131"Distributed Hash Tables" --->  ???  
    3232"Port (UDP) : " ---> "Porta (UDP) :" 
    33 "(DHT will not apply to private torrents)" ---> "(il DHT non funzionerà per i torrents privati)" 
     33"(DHT will not apply to private torrents)" ---> "(il DHT non funzionerà per i torrents privati)" 
    3434"General Settings" ---> "Opzioni Generali" 
    3535"Limit the no. of half-open connections" ---> "Limita il n. di connessioni simultanee" 
     
    7979"Total max connections :" ---> "Numero massimo di connessioni" 
    8080"Total upload slots :" ---> "Slot di upload totali" 
    81 "Download Rate (KB/s) :" ---> "Velocità Download (KB/s) :" 
    82 "Upload Rate (KB/s) :" ---> "Velocità Upload (KB/s) :" 
     81"Download Rate (KB/s) :" ---> "Velocità Download (KB/s) :" 
     82"Upload Rate (KB/s) :" ---> "Velocità Upload (KB/s) :" 
    8383"Torrent Defaults" ---> "Limiti per file Torrent" 
    8484"These options set global maximums which will always be honoured." ---> "Queste opzioni definiscono i limiti massimi che saranno sempre rispettati." 
     
    8888"Prompt for alternate save folder." ---> "Consenti di scegliere una cartella alternativa." 
    8989"Halite shutting down..." ---> "Halite in chiusura...." 
    90 "It will take the BitTorrent session a moment to shutdown cleanly after which this message will disappear and the program will close." ---> "Ci vorrà qualche momento per la chiusura corretta della sessione BitTorrent, al termine della quale questo messaggio sparirà." 
     90"It will take the BitTorrent session a moment to shutdown cleanly after which this message will disappear and the program will close." ---> "Ci vorrà qualche momento per la chiusura corretta della sessione BitTorrent, al termine della quale questo messaggio sparirà." 
    9191"Show this message in future" ---> "Mostra messaggio in futuro" 
    9292"Create new torrent" ---> "Crea nuovo torrent" 
     
    113113"Use Compact Allocation." ---> "Usa Allocazione Compatta" 
    114114"Start Paused" ---> "Aggiungi in Pausa" 
    115 "Note. Compact Allocation is incompatible with File Selection" ---> "Nota: l'Allocazione Compatta è incompatibile con la Selezione File" 
     115"Note. Compact Allocation is incompatible with File Selection" ---> "Nota: l'Allocazione Compatta Ú incompatibile con la Selezione File" 
    116116"General" ---> "Generale" 
    117117"Allow only one instance to run." ---> "Consenti un solo avvio per volta" 
     
    129129"OK" --->  ???  
    130130"Tracker URL" ---> "URL Tracker" 
    131 "Tier" ---> "Priorità" 
     131"Tier" ---> "Priorità" 
    132132"_POPUP_" --->  ???  
    133133"Open &Halite" ---> "Apri &Halite" 
     
    141141"New" ---> "Nuovo" 
    142142"Edit" ---> "Modifica" 
    143 "Set as Primary" --->  "Seleziona come Primario"  
     143"Set as Primary" ---> "Seleziona come Primario" 
    144144"Delete" ---> "Elimina" 
    145145"StringFileInfo" --->  ???  
     
    166166"0000 DHT node(s)" --->  ???  
    167167"Filtering 0000000 ranges." ---> "Filtrando 0000000 intervalli." 
    168 "The BitTorrent session could not start. Try selecting another port in the settings." ---> "La sessione BitTorrent non si è avviata. Prova a selezionare un'altra porta nelle Opzioni." 
    169 "DHT session could not start. Try selecting another port in the settings." ---> "La sessione DHT non si è avviata. Prova a selezionare un'altra porta nelle Opzioni." 
     168"The BitTorrent session could not start. Try selecting another port in the settings." ---> "La sessione BitTorrent non si Ú avviata. Prova a selezionare un'altra porta nelle Opzioni." 
     169"DHT session could not start. Try selecting another port in the settings." ---> "La sessione DHT non si Ú avviata. Prova a selezionare un'altra porta nelle Opzioni." 
    170170"Select a directory to save the files to or cancel to not download torrent at all." ---> "Seleziona una directory in cui salvare i files, o annulla per non scaricare il torrent." 
    171 "" --->  ???  
     171"∞" --->  ???  
    172172"%1$.2fMB of %2$.2fMB" ---> "%1$.2fMB su %2$.2fMB" 
    173173"This Session Downloaded %1$.2fMB, Uploaded %2$.2fMB, Ratio %3$.2f." ---> "In questa Sessione: Scaricati %1$.2fMB, Inviati %2$.2fMB, Ratio %3$.2f." 
     
    189189"Files" --->  ???  
    190190"Logging" --->  ???  
    191 "An invalid encoding level, %1%, was passed as an encryption setting." ---> "Un livello di codifica non valido, %1%, è stato inserito nella configurazione di criptaggio." 
    192 "An invalid connection policy, %1%, was passed as an encryption setting." ---> "Un comportamento di connessione non valido, %1%, è stato inserito nella configurazione di criptaggio." 
     191"An invalid encoding level, %1%, was passed as an encryption setting." ---> "Un livello di codifica non valido, %1%, Ú stato inserito nella configurazione di criptaggio." 
     192"An invalid connection policy, %1%, was passed as an encryption setting." ---> "Un comportamento di connessione non valido, %1%, Ú stato inserito nella configurazione di criptaggio." 
    193193"Auto Sort" ---> "Ordina Automaticamente" 
    194194"Torrent Root" ---> "Cartella base del Torrent" 
     
    217217"Downloading Metadata" ---> "Scaricando Metadata" 
    218218"Name;Status;Progress;Download;Upload;Peers;Seeds;ETA;Copies;Tracker;Reannounce;Ratio;Total;Completed;Remaining;Downloaded;Uploaded;Active;Seeding;Start Time;Finish Time" ---> "Nome;Stato;Progresso;Download;Upload;Peers;Seeds;ETA;Copie;Tracker;Riannuncio;Ratio;Totali;Completati;Rimanenti;Scaricati;Inviati;Attivo;Seeding;Orario Inizio;Orario Fine" 
    219 "Time;Message;Severity" ---> "Orario;Messaggio;Gravità" 
    220 "Tracker;Tier" ---> "Tracker;Priorità" 
     219"Time;Message;Severity" ---> "Orario;Messaggio;Gravità" 
     220"Tracker;Tier" ---> "Tracker;Priorità" 
    221221"Peer;Country;Download;Upload;Type;Client" ---> "Peer;Nazione;Download;Upload;Tipo;Client" 
    222222"Peer;Country;Download;Upload;Type;Client;Status" ---> "Peer;Nazione;Download;Upload;Tipo;Client;Stato" 
    223 "Filename;Path;Size;Progress;Priority" ---> "Nome File;Destinazione;Dimensione;Progresso;Priorità" 
     223"Filename;Path;Size;Progress;Priority" ---> "Nome File;Destinazione;Dimensione;Progresso;Priorità" 
    224224"Don't download" ---> "Non scaricare" 
    225225"Normal" ---> "Normale" 
     
    230230"6" --->  ???  
    231231"Maximum" ---> "Massima" 
    232 "Set Priority" ---> "Priorità" 
     232"Set Priority" ---> "Priorità" 
    233233"Halite.ico" --->  ???  
    234234"toolbar.bmp" --->  ???  
  • src/advtabs/Files.cpp

    r330 r331  
    225225void AdvFilesDialog::doUiUpdate() 
    226226{ 
    227         hal::event().post(shared_ptr<hal::EventDetail>(new hal::EventDebug(hal::Event::info, (wformat(L"doUiUpdate %1%") % current_torrent_name_).str().c_str()))); 
     227//      hal::event().post(shared_ptr<hal::EventDetail>(new hal::EventDebug(hal::Event::info, (wformat(L"doUiUpdate %1%") % current_torrent_name_).str().c_str()))); 
    228228 
    229229        tree_.determineFocused(); 
     
    239239void AdvFilesDialog::uiUpdate(const hal::TorrentDetails& tD) 
    240240{ 
     241        list_.setFocused(focusedTorrent()); 
     242         
    241243        if (fileLinks_.empty() || !(focusedTorrent() && !focusedTorrent()->fileDetails().empty()))  
    242244        { 
  • src/advtabs/Files.hpp

    r314 r331  
    450450        TreeViewManager<FileTreeView> treeManager_; 
    451451         
    452         wstring current_torrent_name_; 
    453452        std::vector<FileLink> fileLinks_; 
    454453         
  • src/halTorrent.cpp

    r328 r331  
    66 
    77 
    8 #define HALITE_VERSION                                  0,2,9,326 
    9 #define HALITE_VERSION_STRING                   "v 0.2.9 dev 326" 
     8#define HALITE_VERSION                                  0,2,9,330 
     9#define HALITE_VERSION_STRING                   "v 0.2.9 dev 330" 
    1010 
    1111#define LBT_EVENT_TORRENT_FINISHED                                      80001 
  • src/halTorrent.hpp

    r319 r331  
    1111#include <set> 
    1212 
     13#include <boost/tuple/tuple.hpp> 
    1314#include <boost/signal.hpp> 
    1415#include <boost/optional.hpp> 
     
    128129public: 
    129130        TorrentDetail(std::wstring n, std::wstring f, std::wstring s, std::wstring cT, std::pair<float,float> sp=std::pair<float,float>(0,0), 
    130                         float c=0, float d=0, boost::int64_t tWD=0, boost::int64_t tW=0, boost::int64_t tU=0, boost::int64_t tpU=0, boost::int64_t tD=0, boost::int64_t tpD=0, int prs=0, int prsCnt=0, int sds=0, int sdsCnt=0,  float r=0,  
     131                        float c=0, float d=0, boost::int64_t tWD=0, boost::int64_t tW=0, boost::int64_t tU=0, boost::int64_t tpU=0, boost::int64_t tD=0, boost::int64_t tpD=0, boost::tuple<size_t, size_t, size_t, size_t> connections = boost::tuple<size_t, size_t, size_t, size_t>(0,0,0,0),  float r=0,  
    131132                        time_duration eta=boost::posix_time::seconds(0), time_duration uIn=boost::posix_time::seconds(0), 
    132133                        time_duration actve=boost::posix_time::seconds(0), time_duration seding=boost::posix_time::seconds(0), ptime srt=boost::posix_time::second_clock::universal_time(), ptime fin=boost::posix_time::second_clock::universal_time()) : 
     
    144145                totalDownloaded_(tD), 
    145146                totalPayloadDownloaded_(tpD), 
    146                 peers_(prs), 
    147                 connectedPeers_(prsCnt), 
    148                 seeds_(sds), 
    149                 connectedSeeds_(sdsCnt), 
     147                peers_(connections.get<0>()), 
     148                connectedPeers_(connections.get<1>()), 
     149                seeds_(connections.get<2>()), 
     150                connectedSeeds_(connections.get<3>()), 
    150151                ratio_(r), 
    151152                estimatedTimeLeft_(eta), 
  • src/halTorrentInternal.hpp

    r326 r331  
    3333#ifndef RC_INVOKED 
    3434 
     35#include <boost/tuple/tuple.hpp> 
    3536#include <boost/multi_index_container.hpp> 
    3637#include <boost/multi_index/ordered_index.hpp> 
     
    4748} 
    4849 
    49 BOOST_CLASS_VERSION(hal::TorrentInternal, 8) 
     50BOOST_CLASS_VERSION(hal::TorrentInternal, 9) 
    5051 
    5152namespace hal  
     
    214215                totalUploaded_(0), \ 
    215216                totalBase_(0), \ 
     217                progress_(0), \ 
    216218                startTime_(boost::posix_time::second_clock::universal_time()) 
    217219                 
     
    255257                return ratio_; 
    256258        } 
    257                  
     259         
    258260        void addToSession(bool paused = false) 
    259261        { 
     
    268270                         
    269271                        handle_ = the_session_->add_torrent(metadata_, dir, resumedata_, storage, paused); 
    270                                  
     272                         
    271273                        in_session_ = true; 
    272274                        if (paused) 
    273275                                state_ = TorrentDetail::torrent_paused;  
    274  
     276                         
    275277                        applySettings(); 
    276278                }        
     
    371373        const std::wstring& originalFilename() const { return originalFilename_; } 
    372374         
    373         const libtorrent::torrent_handle& handle() const { return handle_; } 
     375        const lbt::torrent_handle& handle() const { return handle_; } 
    374376 
    375377        void resetTrackers() 
     
    380382                        trackers_.clear(); 
    381383                } 
     384        } 
     385         
     386        void setTrackers(const std::vector<TrackerDetail>& trackerDetails) 
     387        { 
     388                trackers_.clear(); 
     389                trackers_.assign(trackerDetails.begin(), trackerDetails.end()); 
     390                 
     391                applyTrackers(); 
    382392        } 
    383393         
     
    395405                }                
    396406                return trackers_; 
    397         } 
    398          
    399         void setTrackers(const std::vector<TrackerDetail>& trackerDetails) 
    400         { 
    401                 trackers_.clear(); 
    402                 trackers_.assign(trackerDetails.begin(), trackerDetails.end()); 
    403                  
    404                 applyTrackers(); 
    405407        } 
    406408         
     
    485487                        ar & make_nvp("finishTime", finishTime_); 
    486488                } 
     489                if (version > 8) { 
     490                        ar & make_nvp("progress", progress_); 
     491                } 
    487492    } 
    488493         
     
    523528        std::vector<lbt::peer_info>& peers() { return peers_; } 
    524529         
    525         void updatePeers() 
     530        boost::tuple<size_t, size_t, size_t, size_t> updatePeers() 
    526531        { 
    527532                if (inSession()) 
    528533                        handle_.get_peer_info(peers_); 
    529                 else 
    530                         peers_.clear(); 
     534                 
     535                size_t totalPeers = 0; 
     536                size_t peersConnected = 0; 
     537                size_t totalSeeds = 0; 
     538                size_t seedsConnected = 0; 
     539                 
     540                foreach (lbt::peer_info& peer, peers_)  
     541                { 
     542                        float speedSum = peer.down_speed + peer.up_speed; 
     543                         
     544                        if (!(peer.flags & lbt::peer_info::seed)) 
     545                        { 
     546                                ++totalPeers; 
     547                                 
     548                                if (speedSum > 0) 
     549                                        ++peersConnected; 
     550                        } 
     551                        else 
     552                        { 
     553                                ++totalSeeds; 
     554                                 
     555                                if (speedSum > 0) 
     556                                        ++seedsConnected; 
     557                        } 
     558                }        
     559                 
     560                return boost::make_tuple(totalPeers, peersConnected, totalSeeds, seedsConnected); 
    531561        } 
    532562         
     
    534564        { 
    535565                if (inSession()) 
     566                { 
    536567                        foreach (lbt::peer_info peer, peers_)  
    537568                        { 
    538569                                peerDetails.push_back(peer); 
    539570                        }        
     571                } 
    540572        } 
    541573 
    542574        void getFileDetails(FileDetails& fileDetails) 
    543575        { 
    544                 if (inSession()) 
    545                 { 
    546                         lbt::torrent_info info = handle_.get_torrent_info(); 
     576                if (fileDetailsMemory_.empty()) 
     577                { 
     578                        lbt::torrent_info& info = infoMemory(); 
    547579                        std::vector<lbt::file_entry> files; 
    548580                         
    549581                        std::copy(info.begin_files(), info.end_files(),  
    550                                 std::back_inserter(files)); 
    551                          
    552                         std::vector<float> fileProgress;                         
    553                         handle_.file_progress(fileProgress); 
    554                          
     582                                std::back_inserter(files));                                      
     583                                 
    555584                        if (filePriorities_.size() != files.size()) 
    556585                        { 
     
    562591                        { 
    563592                                wstring fullPath = hal::from_utf8(files[i].path.string()); 
     593                                size_t size = static_cast<size_t>(files[i].size); 
    564594                                 
    565                                 fileDetails.push_back(FileDetail(fullPath, static_cast<size_t>(files[i].size), fileProgress[i], filePriorities_[i], i)); 
     595                                fileDetailsMemory_.push_back(FileDetail(fullPath, size, 0, filePriorities_[i], i)); 
     596                        }        
     597                }                
     598                 
     599                if (inSession()) 
     600                {                        
     601                        std::vector<float> fileProgress;                         
     602                        handle_.file_progress(fileProgress); 
     603                         
     604                        for(size_t i=0, e=fileDetailsMemory_.size(); i<e; ++i) 
     605                        { 
     606                                fileDetailsMemory_[i].progress =  fileProgress[i]; 
     607                                fileDetailsMemory_[i].priority =  filePriorities_[i]; 
    566608                        }                        
    567609                } 
     610                 
     611                fileDetails = fileDetailsMemory_; 
    568612        } 
    569613         
     
    579623                 
    580624                event().post(shared_ptr<EventDetail>(new EventMsg( 
    581                                         wformat(L"File: %1%, %2%.") % resumeFile % torrentFile))); 
     625                        wformat(L"File: %1%, %2%.") % resumeFile % torrentFile))); 
    582626                 
    583627                if (exists(resumeFile))  
     
    695739        } 
    696740         
     741        lbt::torrent_info& infoMemory() 
     742        { 
     743                if (!infoMemory_.is_valid()) infoMemory_ = lbt::torrent_info(metadata_); 
     744                 
     745                return infoMemory_; 
     746        } 
     747         
    697748        static libtorrent::session* the_session_; 
    698749         
     
    710761        std::wstring save_directory_; 
    711762        std::wstring originalFilename_; 
    712         libtorrent::torrent_handle handle_;      
    713          
    714         libtorrent::entry metadata_; 
    715         libtorrent::entry resumedata_; 
     763        lbt::torrent_handle handle_;     
     764         
     765        lbt::entry metadata_; 
     766        lbt::entry resumedata_; 
    716767         
    717768        std::wstring trackerUsername_;   
     
    736787        std::vector<int> filePriorities_; 
    737788         
     789        float progress_; 
     790         
     791        lbt::torrent_info infoMemory_; 
    738792        lbt::torrent_status statusMemory_; 
     793        FileDetails fileDetailsMemory_; 
    739794         
    740795        bool compactStorage_; 
     
    932987        { 
    933988                statusMemory_ = handle_.status(); 
     989                progress_ = statusMemory_.progress; 
     990        } 
     991        else 
     992        { 
     993                // Wipe these cause they don't make sense for a non-active torrent. 
     994                 
     995                statusMemory_.download_payload_rate = 0; 
     996                statusMemory_.upload_payload_rate = 0; 
     997                statusMemory_.next_announce = boost::posix_time::seconds(0);             
    934998        } 
    935999         
     
    10081072        }        
    10091073         
    1010         updatePeers(); 
    1011          
    1012         size_t totalPeers = 0; 
    1013         size_t peersConnected = 0; 
    1014         size_t totalSeeds = 0; 
    1015         size_t seedsConnected = 0; 
    1016          
    1017         foreach (lbt::peer_info peer, peers_)  
    1018         { 
    1019                 float speedSum = peer.down_speed + peer.up_speed; 
    1020                  
    1021                 if (!(peer.flags & lbt::peer_info::seed)) 
    1022                 { 
    1023                         ++totalPeers; 
    1024                          
    1025                         if (speedSum > 0) 
    1026                                 ++peersConnected; 
    1027                 } 
    1028                 else 
    1029                 { 
    1030                         ++totalSeeds; 
    1031                          
    1032                         if (speedSum > 0) 
    1033                                 ++seedsConnected; 
    1034                 } 
    1035         }                        
     1074        boost::tuple<size_t, size_t, size_t, size_t> connections = updatePeers();                
    10361075 
    10371076        return TorrentDetail_ptr(new TorrentDetail(name_, filename_, state, hal::from_utf8(statusMemory_.current_tracker),  
    10381077                pair<float, float>(statusMemory_.download_payload_rate, statusMemory_.upload_payload_rate), 
    1039                 statusMemory_.progress, statusMemory_.distributed_copies, statusMemory_.total_wanted_done, statusMemory_.total_wanted, uploaded_, payloadUploaded_, 
    1040                 downloaded_, payloadDownloaded_, totalPeers, peersConnected, totalSeeds, seedsConnected, ratio_, td, statusMemory_.next_announce, activeDuration_, seedingDuration_, startTime_, finishTime_)); 
     1078                progress_, statusMemory_.distributed_copies, statusMemory_.total_wanted_done, statusMemory_.total_wanted, uploaded_, payloadUploaded_, 
     1079                downloaded_, payloadDownloaded_, connections, ratio_, td, statusMemory_.next_announce, activeDuration_, seedingDuration_, startTime_, finishTime_)); 
    10411080 
    10421081        } 
Note: See TracChangeset for help on using the changeset viewer.