- Display torrent files in Web UI

This commit is contained in:
Christophe Dumez 2009-11-24 13:10:17 +00:00
parent 33d77ccf39
commit a9b49ea3e0
52 changed files with 1949 additions and 183 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 66 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 66 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 92 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 96 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 89 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 91 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 69 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 109 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 97 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 242 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 193 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 351 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 98 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 88 B

View file

@ -32,6 +32,7 @@
#include "eventmanager.h"
#include "bittorrent.h"
#include "misc.h"
#include "proplistdelegate.h"
#include "torrentpersistentdata.h"
#include <QDebug>
@ -89,6 +90,50 @@ QList<QVariantMap> EventManager::getPropTrackersInfo(QString hash) const {
return trackersInfo;
}
QList<QVariantMap> EventManager::getPropFilesInfo(QString hash) const {
QList<QVariantMap> files;
QTorrentHandle h = BTSession->getTorrentHandle(hash);
if(!h.is_valid()) return files;
std::vector<int> priorities = h.file_priorities();
std::vector<long long int> fp;
h.file_progress(fp);
torrent_info t = h.get_torrent_info();
torrent_info::file_iterator fi;
int i=0;
for(fi=t.begin_files(); fi != t.end_files(); fi++) {
QVariantMap file;
if(h.num_files() == 1) {
file["name"] = h.name();
} else {
QString path = QDir::cleanPath(misc::toQString(fi->path.string()));
QString name = path.split('/').last();
file["name"] = name;
}
file["size"] = misc::friendlyUnit((double)fi->size);
file["progress"] = fp[i]/(double)fi->size;
switch(priorities[i]) {
case IGNORED:
file["priority"] = tr("Ignored");
break;
case NORMAL:
file["priority"] = tr("Normal", "Normal (priority)");
break;
case HIGH:
file["priority"] = tr("High", "High (priority)");
break;
case MAXIMUM:
file["priority"] = tr("Maximum", "Maximum (priority)");
break;
default:
qDebug("Unhandled priority, setting NORMAL, priority was %d", priorities[i]);
file["priority"] = tr("Normal", "Normal (priority)");
}
files << file;
++i;
}
return files;
}
QVariantMap EventManager::getPropGeneralInfo(QString hash) const {
QVariantMap data;
QTorrentHandle h = BTSession->getTorrentHandle(hash);

View file

@ -53,6 +53,7 @@ class EventManager : public QObject
QList<QVariantMap> getEventList() const;
QVariantMap getPropGeneralInfo(QString hash) const;
QList<QVariantMap> getPropTrackersInfo(QString hash) const;
QList<QVariantMap> getPropFilesInfo(QString hash) const;
public slots:
void addedTorrent(QTorrentHandle& h);

View file

@ -102,7 +102,7 @@ void HttpConnection::write()
}
QString HttpConnection::translateDocument(QString data) {
std::string contexts[] = {"TransferListFiltersWidget", "TransferListWidget", "PropertiesWidget", "GUI", "MainWindow", "HttpServer", "confirmDeletionDlg", "TrackerList"};
std::string contexts[] = {"TransferListFiltersWidget", "TransferListWidget", "PropertiesWidget", "GUI", "MainWindow", "HttpServer", "confirmDeletionDlg", "TrackerList", "TorrentFilesModel"};
int i=0;
bool found = false;
do {
@ -117,7 +117,7 @@ QString HttpConnection::translateDocument(QString data) {
do {
translation = qApp->translate(contexts[context_index].c_str(), word.toLocal8Bit().data(), 0, QCoreApplication::UnicodeUTF8, 1);
++context_index;
}while(translation == word && context_index < 8);
}while(translation == word && context_index < 9);
//qDebug("Translation is %s", translation.toUtf8().data());
data = data.replace(i, regex.matchedLength(), translation);
i += translation.length();
@ -163,11 +163,15 @@ void HttpConnection::respond()
return;
}
if(list[1] == "propertiesTrackers") {
qDebug("Web UI asked for trackers");
QString hash = list[2];
respondTrackersPropertiesJson(hash);
return;
}
if(list[1] == "propertiesFiles") {
QString hash = list[2];
respondFilesPropertiesJson(hash);
return;
}
}
}
if (list[0] == "command")
@ -241,6 +245,15 @@ void HttpConnection::respondTrackersPropertiesJson(QString hash) {
write();
}
void HttpConnection::respondFilesPropertiesJson(QString hash) {
EventManager* manager = parent->eventManager();
QString string = json::toJson(manager->getPropFilesInfo(hash));
generator.setStatusLine(200, "OK");
generator.setContentTypeByExt("js");
generator.setMessage(string);
write();
}
void HttpConnection::respondCommand(QString command)
{

View file

@ -58,6 +58,7 @@ class HttpConnection : public QObject
void respondJson();
void respondGenPropertiesJson(QString hash);
void respondTrackersPropertiesJson(QString hash);
void respondFilesPropertiesJson(QString hash);
void respondCommand(QString command);
void respondNotFound();
void processDownloadedFile(QString, QString);

View file

@ -114,20 +114,6 @@
<file>Icons/flags/japan.png</file>
<file>Icons/flags/malaysia.png</file>
<file>Icons/flags/philippines.png</file>
<file>Icons/tree/Lplus.gif</file>
<file>Icons/tree/Tminus.gif</file>
<file>Icons/tree/Tplus.gif</file>
<file>Icons/tree/_open.gif</file>
<file>Icons/tree/plus.gif</file>
<file>Icons/tree/Rminus.gif</file>
<file>Icons/tree/Lminus.gif</file>
<file>Icons/tree/T.gif</file>
<file>Icons/tree/_closed.gif</file>
<file>Icons/tree/L.gif</file>
<file>Icons/tree/_doc.gif</file>
<file>Icons/tree/I.gif</file>
<file>Icons/tree/minus.gif</file>
<file>Icons/tree/Rplus.gif</file>
<file>Icons/oxygen/mail-queue.png</file>
<file>Icons/oxygen/view-refresh.png</file>
<file>Icons/oxygen/file.png</file>

View file

@ -1521,8 +1521,56 @@ Copyright © 2006 от Christophe Dumez&lt;br&gt;
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished">/с</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -4203,6 +4251,29 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished">Име</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Размер</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished">Изпълнение</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished">Предимство</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1273,8 +1273,56 @@ p, li { white-space: pre-wrap; }
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished">/s</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -3578,6 +3626,29 @@ Log:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished">Nom</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Mida</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished">Progrès</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1128,8 +1128,56 @@ Copyright © 2006 by Christophe Dumez&lt;br&gt;
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -3051,6 +3099,29 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished">Název</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Velikost</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished">Průběh</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished">Priorita</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1178,8 +1178,56 @@ Copyright © 2006 by Christophe Dumez&lt;br&gt;
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -3242,6 +3290,29 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished">Navn</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Størrelse</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished">Hentet</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1451,8 +1451,56 @@ qBittorrent beobachtet das Verzeichniss und starten den Download von vorhandenen
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -4174,6 +4222,29 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished">Priorität</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1544,8 +1544,56 @@ Copyright © 2006 από τον Christophe Dumez&lt;br&gt;
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished">/s</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -4293,6 +4341,29 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Μέγεθος</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished">Πρόοδος</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished">Προτεραιότητα</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -860,8 +860,56 @@ p, li { white-space: pre-wrap; }
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -2351,6 +2399,29 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1440,8 +1440,56 @@ p, li { white-space: pre-wrap; }
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -4121,6 +4169,29 @@ Log:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished">Nombre</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Tamaño</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished">Progreso</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished">Prioridad</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1325,8 +1325,56 @@ p, li { white-space: pre-wrap; }
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -3778,6 +3826,29 @@ Muutoshistoria:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished">Nimi</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Koko</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished">Edistyminen</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished">Prioriteetti</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1564,8 +1564,56 @@ Copyright © 2006 par Christophe DUMEZ&lt;br&gt;
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished">Fonctionne</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished">Mise à jour...</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished">Indisponible</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished">Pas encore contacté</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished">cette session</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished">/s</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished">Complet depuis %1</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished">%1 max</translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation>%1/s</translation>
@ -4381,6 +4429,29 @@ Changements:
<translation>Limite globale de la vitesse d&apos;envoi</translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished">Nom</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Taille</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished">Progression</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished">Priorité</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1368,8 +1368,56 @@ Copyright © 2006 by Christophe Dumez&lt;br&gt;
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -3603,6 +3651,29 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished">Név</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Méret</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished">Folyamat</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1424,8 +1424,56 @@ Copyright © 2006 by Christophe Dumez&lt;br&gt;
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -3978,6 +4026,29 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished">Nome</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Dimensione</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished">Priorità</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1340,8 +1340,56 @@ Copyright © 2006 by Christophe Dumez&lt;br&gt;
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -3545,6 +3593,29 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1479,8 +1479,56 @@ list:</source>
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -4195,6 +4243,29 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1200,8 +1200,56 @@ Copyright © 2006 av Christophe Dumez&lt;br&gt;
<context>
<name>EventManager</name>
<message>
<location filename="../eventmanager.cpp" line="110"/>
<location filename="../eventmanager.cpp" line="119"/>
<location filename="../eventmanager.cpp" line="62"/>
<location filename="../eventmanager.cpp" line="76"/>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="65"/>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="68"/>
<location filename="../eventmanager.cpp" line="79"/>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="70"/>
<location filename="../eventmanager.cpp" line="81"/>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="134"/>
<location filename="../eventmanager.cpp" line="135"/>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="139"/>
<location filename="../eventmanager.cpp" line="143"/>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="146"/>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="149"/>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../eventmanager.cpp" line="232"/>
<location filename="../eventmanager.cpp" line="241"/>
<source>%1/s</source>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
@ -3447,6 +3495,29 @@ Endringer:</translation>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Name</source>
<translation type="unfinished">Navn</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Size</source>
<translation type="unfinished">Størrelse</translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Progress</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../torrentfilesmodel.h" line="258"/>
<source>Priority</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1342,6 +1342,41 @@ p, li { white-space: pre-wrap; }
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished">/s</translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -3679,6 +3714,25 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished">Naam</translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished">Grootte</translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished">Voortgang</translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished">Prioriteit</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1310,6 +1310,41 @@ Wszystkie prawa zastrżeżone © 2006 Christophe Dumez&lt;br&gt;(new line)
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished">/s</translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -3710,6 +3745,25 @@ Zmiany:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished">Nazwa</translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished">Rozmiar</translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished">Postęp</translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished">Priorytet</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1264,6 +1264,41 @@ qBittorrent irá procurar no diretório e baixará automaticamente torrents pres
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -3682,6 +3717,25 @@ Log de mudanças:</translation>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished">Nome</translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished">Tamanho</translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished">Progresso</translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished">Prioridade</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1264,6 +1264,41 @@ qBittorrent irá procurar no diretório e baixará automaticamente torrents pres
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -3682,6 +3717,25 @@ Log de mudanças:</translation>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished">Nome</translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished">Tamanho</translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished">Progresso</translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished">Prioridade</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1262,6 +1262,41 @@ qBittorrent va monitoriza directoriul și va adăuga în lista de descărcare a
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -3523,6 +3558,25 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished">Nume</translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished">Capacitate</translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished">Progress</translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished">Prioritate</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1307,6 +1307,41 @@ p, li { white-space: pre-wrap; }
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished">эта сессия</translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished">/с</translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished">%1 макс</translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -3711,6 +3746,25 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished">Имя</translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished">Размер</translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished">Приоритет</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1268,6 +1268,41 @@ p, li { white-space: pre-wrap; }
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -3602,6 +3637,25 @@ Záznam zmien:</translation>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished">Priebeh</translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished">Priorita</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -887,6 +887,41 @@ p, li { white-space: pre-wrap; }
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -2433,6 +2468,25 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished">Namn</translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished">Storlek</translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished">Förlopp</translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished">Prioritet</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1293,6 +1293,41 @@ p, li { white-space: pre-wrap; }
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished">/s</translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -3673,6 +3708,25 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished">Boyut</translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished">İlerleme</translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished">Öncelik</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1214,6 +1214,41 @@ p, li { white-space: pre-wrap; }
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished">/с</translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -3543,6 +3578,25 @@ Changelog:
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished">Ім&apos;я</translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished">Розмір</translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished">Прогрес</translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished">Пріоритет</translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -1380,6 +1380,41 @@ wait...</comment>
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -3821,6 +3856,25 @@ reason: %2.</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -948,6 +948,41 @@ p, li { white-space: pre-wrap; }
<comment>e.g. 120 KiB/s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Updating...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not working</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Not contacted yet</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>this session</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>/s</source>
<comment>/second (i.e. per second)</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>Seeded for %1</source>
<comment>e.g. Seeded for 3m10s</comment>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 max</source>
<comment>e.g. 10 max</comment>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FeedDownloader</name>
@ -2532,6 +2567,25 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TorrentFilesModel</name>
<message>
<source>Name</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Size</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Progress</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Priority</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>TrackerList</name>
<message>

View file

@ -255,7 +255,7 @@ public:
TorrentFilesModel(QObject *parent=0): QAbstractItemModel(parent) {
files_index = 0;
QList<QVariant> rootData;
rootData << "Name" << "Size" << "Progress" << "Priority";
rootData << tr("Name") << tr("Size") << tr("Progress") << tr("Priority");
rootItem = new TreeItem(rootData);
}

View file

@ -18,7 +18,6 @@
<file>webui/scripts/excanvas-compressed.js</file>
<file>webui/scripts/mocha.js</file>
<file>webui/scripts/mocha-init.js</file>
<file>webui/scripts/tree.js</file>
<file>webui/scripts/mootools-1.2-core-yc.js</file>
<file>webui/scripts/mootools-1.2-more.js</file>
<file>webui/scripts/dynamicTable.js</file>

View file

@ -7,41 +7,49 @@
**************************************************************/
#properties #torrentFiles table,
#properties #trackers table,
#transferList table {
border: 1px solid #ccc;
width: 100%;
}
#properties #torrentFiles th,
#properties #trackers th,
#transferList th {
background-color: #eee;
padding: 4px;
}
#properties #torrentFiles tr,
#properties #trackers tr,
#transferList tr {
background-color: #fff;
padding: 4px;
}
#properties #torrentFiles tr.alt,
#properties #trackers tr.alt,
#transferList tr.alt {
background-color: #eee;
padding: 4px;
}
#properties #torrentFiles td,
#properties #trackers td,
#transferList td {
padding: 0 2px;
}
#properties #torrentFiles tr.selected,
#properties #trackers tr.selected,
#transferList tr.selected {
background-color: #354158;
color: #fff;
}
#properties #torrentFiles tr.over,
#properties #trackers tr.over,
#transferList tr.over {
background-color: #ee6600;

View file

@ -16,7 +16,6 @@
<script type="text/javascript" src="scripts/progressbar.js"></script>
<script type="text/javascript" src="scripts/dynamicTable.js" charset="utf-8"></script>
<script type="text/javascript" src="scripts/client.js" charset="utf-8"></script>
<script type="text/javascript" src="scripts/tree.js" charset="utf-8"></script>
</head>
<body>
<div id="desktop">

View file

@ -1,12 +1,137 @@
<ul id="fileTree" class="tree">
<li class="folder f-open root"><span>Examples</span>
<ul>
<li class="doc"><span><a>Lorem Ipsum</a></span></li>
<li class="doc"><span><a>Zero7 - Crosses</a></span></li>
</ul>
</li>
</ul>
<span id="torrentFiles">
<table class="torrentTable" cellpadding="0" cellspacing="0">
<thead>
<tr>
<th>_(Name)</th>
<th>_(Size)</th>
<th style="width: 90px;">_(Progress)</th>
<th>_(Priority)</th>
</tr>
</thead>
<tbody id="filesTable"></tbody>
</table>
</span>
<script type="text/javascript">
buildTree('fileTree');
var filesDynTable = new Class ({
initialize: function(){
},
setup: function(table){
this.table = $(table);
this.rows = new Hash();
},
removeRow: function(id){
if(this.rows.has(id)) {
var tr = this.rows.get(id);
tr.dispose();
this.rows.erase(id);
return true;
}
return false;
},
removeAllRows: function() {
this.rows.each(function(tr, id) {
this.removeRow(id);
}.bind(this));
},
updateRow: function(tr, row){
var tds = tr.getElements('td');
for(var i=0; i<row.length; i++) {
if(i==2) {
tds[i].set('html', '');
tds[i].adopt(new ProgressBar(row[i].toFloat(), {width:80}));
} else {
tds[i].set('html', row[i]);
}
}
return true;
},
insertRow: function(id, row) {
if(this.rows.has(id)) {
var tr = this.rows.get(id);
this.updateRow(tr, row);
return;
}
//this.removeRow(id);
var tr = new Element('tr');
this.rows.set(id, tr);
for(var i=0; i<row.length; i++)
{
var td = new Element('td');
if(i==2) {
td.adopt(new ProgressBar(row[i].toFloat(), {width:80}));
} else {
td.set('html', row[i]);
}
td.injectInside(tr);
}
tr.injectInside(this.table);
},
});
var round1 = function(val){return Math.round(val*10)/10};
var waitingTorrentFiles=false;
var current_hash = "";
var loadTorrentFilesData = function() {
if(!$defined($('filesTable'))) {
// Tab changed
return;
}
var new_hash = myTable.getCurrentTorrentHash();
if(new_hash == "") {
fTable.removeAllRows();
loadTorrentFilesData.delay(1500);
return;
}
if(new_hash != current_hash) {
fTable.removeAllRows();
current_hash = new_hash;
}
var url = 'json/propertiesFiles/'+current_hash;
if (!waitingTorrentFiles) {
waitingTorrentFiles=true;
var request = new Request.JSON({
url: url,
method: 'get',
onFailure: function() {
$('error_div').set('html', 'qBittorrent client is not reachable');
waitingTorrentFiles=false;
loadTorrentFilesData.delay(2000);
},
onSuccess: function(files) {
$('error_div').set('html', '');
if(files){
// Update Trackers data
var i=0;
files.each(function(file){
var row = new Array();
row.length = 4;
row[0] = file.name;
row[1] = file.size;
row[2] = round1(file.progress*100);
row[3] = file.priority;
fTable.insertRow(i, row);
i++;
}.bind(this));
} else {
fTable.removeAllRows();
}
waitingTorrentFiles=false;
loadTorrentFilesData.delay(1500);
}
}).send();
}
}
fTable = new filesDynTable();
fTable.setup($('filesTable'));
// Initial loading
loadTorrentFilesData();
</script>

View file

@ -1,124 +0,0 @@
/*
Script: Tree.js
Create folder trees.
Copyright:
Copyright (c) 2007-2008 Greg Houston, <http://greghoustondesign.com/>.
License:
MIT-style license.
*/
function buildTree(treeID){
$$('#'+treeID+' li.folder').each(function(folder){
var folderContents = folder.getChildren('ul');
var folderImage = new Element('img', {
'src': '../images/tree/_open.gif',
'width': 18,
'height': 18
}).inject(folder, 'top');
// Determine which open and close graphic each folder gets
if (folder.hasClass('root')) {
folder.minus = '../images/tree/Rminus.gif'
folder.plus = '../images/tree/Rplus.gif'
}
else
if (folder.getNext()) {
folder.minus = '../images/tree/Tminus.gif'
folder.plus = '../images/tree/Tplus.gif'
}
else {
folder.minus = '../images/tree/Lminus.gif'
folder.plus = '../images/tree/Lplus.gif'
}
var image = new Element('img', {
'src': folder.minus,
'width': 18,
'height': 18
}).addEvent('click', function(){
if (folder.hasClass('f-open')) {
image.setProperty('src', folder.plus);
folderImage.setProperty('src', '../images/tree/_closed.gif');
folderContents.each(function(el){
el.setStyle('display', 'none');
});
folder.removeClass('f-open');
}
else {
image.setProperty('src', folder.minus);
folderImage.setProperty('src', '../images/tree/_open.gif');
folderContents.each(function(el){
el.setStyle('display', 'block');
});
folder.addClass('f-open');
}
}).inject(folder, 'top');
if (!folder.hasClass('f-open')) {
image.setProperty('src', folder.plus);
folderContents.each(function(el){
el.setStyle('display', 'none');
});
folder.removeClass('f-open');
}
// Add connecting branches to each file node
folderContents.each(function(element){
var docs = element.getChildren('li.doc');
docs.each(function(el){
if (el == docs.getLast() && !el.getNext()) {
new Element('img', {
'src': '../images/tree/L.gif',
'width': 18,
'height': 18
}).inject(el.getElement('span'), 'before');
}
else {
new Element('img', {
'src': '../images/tree/T.gif',
'width': 18,
'height': 18
}).inject(el.getElement('span'), 'before');
}
});
});
});
// Add connecting branches to each node
$$('#'+treeID+' li').each(function(node){
node.getParents('li').each(function(parent){
if (parent.getNext()) {
new Element('img', {
'src': '../images/tree/I.gif',
'width': 18,
'height': 18
}).inject(node, 'top');
}
else {
new Element('img', {
'src': 'images/spacer.gif',
'width': 18,
'height': 18
}).inject(node, 'top');
}
});
});
$$('#'+treeID+' li.doc').each(function(el){
new Element('img', {
'src': '../images/tree/_doc.gif',
'width': 18,
'height': 18
}).inject(el.getElement('span'), 'before');
});
}