linuxdcpp-team team mailing list archive
-
linuxdcpp-team team
-
Mailing list archive
-
Message #01225
[Branch ~linuxdcpp-team/linuxdcpp/trunk] Rev 373: Bring dead code back to life
------------------------------------------------------------
revno: 373
committer: Steven Sheehy <steven.sheehy@xxxxxxxxx>
branch nick: trunk
timestamp: Sat 2010-05-29 22:15:23 -0500
message:
Bring dead code back to life
modified:
linux/mainwindow.cc
linux/mainwindow.hh
linux/transfers.cc
linux/transfers.hh
--
lp:linuxdcpp
https://code.launchpad.net/~linuxdcpp-team/linuxdcpp/trunk
Your team LinuxDC++ Team is subscribed to branch lp:linuxdcpp.
To unsubscribe from this branch go to https://code.launchpad.net/~linuxdcpp-team/linuxdcpp/trunk/+edit-subscription
=== modified file 'linux/mainwindow.cc'
--- linux/mainwindow.cc 2010-05-23 20:08:42 +0000
+++ linux/mainwindow.cc 2010-05-30 03:15:23 +0000
@@ -1292,20 +1292,6 @@
WulforManager::get()->dispatchGuiFunc(func);
}
-string MainWindow::getFilename_client(Transfer *t)
-{
- string filename;
-
- if (t->getType() == Transfer::TYPE_FULL_LIST || t->getType() == Transfer::TYPE_PARTIAL_LIST)
- filename = _("File list");
- else if (t->getType() == Transfer::TYPE_TREE)
- filename = _("TTH: ") + Util::getFileName(t->getPath());
- else
- filename = Util::getFileName(t->getPath());
-
- return filename;
-}
-
void MainWindow::createIPCPipe()
{
const string pipepath = WulforUtil::getPipePath();
=== modified file 'linux/mainwindow.hh'
--- linux/mainwindow.hh 2010-05-22 14:23:56 +0000
+++ linux/mainwindow.hh 2010-05-30 03:15:23 +0000
@@ -142,7 +142,6 @@
void autoConnect_client();
void startSocket_client();
void refreshFileList_client();
- std::string getFilename_client(dcpp::Transfer *t);
// Client callbacks
virtual void on(dcpp::LogManagerListener::Message, time_t t, const std::string &m) throw();
=== modified file 'linux/transfers.cc'
--- linux/transfers.cc 2010-05-22 14:23:56 +0000
+++ linux/transfers.cc 2010-05-30 03:15:23 +0000
@@ -828,12 +828,7 @@
double percent = 0.0;
params["CID"] = user->getCID().toBase32();
- if (tr->getType() == Transfer::TYPE_FULL_LIST || tr->getType() == Transfer::TYPE_PARTIAL_LIST)
- params["Filename"] = _("File list");
- else if (tr->getType() == Transfer::TYPE_TREE)
- params["Filename"] = _("TTH: ") + Util::getFileName(tr->getPath());
- else
- params["Filename"] = Util::getFileName(tr->getPath());
+ params["Filename"] = getFileName_client(tr);
params["User"] = WulforUtil::getNicks(user);
params["Hub Name"] = WulforUtil::getHubNames(user); //TODO Get specific hub name
params["Path"] = Util::getFilePath(tr->getPath());
@@ -849,6 +844,16 @@
params["Hub URL"] = tr->getUserConnection().getHubUrl();
}
+string Transfers::getFileName_client(Transfer *t)
+{
+ if (t->getType() == Transfer::TYPE_FULL_LIST || t->getType() == Transfer::TYPE_PARTIAL_LIST)
+ return _("File list");
+ else if (t->getType() == Transfer::TYPE_TREE)
+ return _("TTH: ") + Util::getFileName(t->getPath());
+ else
+ return Util::getFileName(t->getPath());
+}
+
void Transfers::on(DownloadManagerListener::Requesting, Download* dl) throw()
{
StringMap params;
=== modified file 'linux/transfers.hh'
--- linux/transfers.hh 2009-08-15 04:40:26 +0000
+++ linux/transfers.hh 2010-05-30 03:15:23 +0000
@@ -79,6 +79,7 @@
// Client functions
void getParams_client(dcpp::StringMap& params, dcpp::ConnectionQueueItem* cqi);
void getParams_client(dcpp::StringMap& params, dcpp::Transfer* transfer);
+ std::string getFileName_client(dcpp::Transfer *t);
void getFileList_client(std::string cid, std::string hubUrl);
void matchQueue_client(std::string cid, std::string hubUrl);
void addFavoriteUser_client(std::string cid);