diff options
| author | Jonathan Bauer | 2011-03-08 11:12:46 +0100 |
|---|---|---|
| committer | Jonathan Bauer | 2011-03-08 11:12:46 +0100 |
| commit | a01ed9de193fc1d635200f8fae91c77d54921c62 (patch) | |
| tree | 4255fa4e77e2715610999d434162d95025b0a288 /src | |
| parent | . (diff) | |
| download | fbgui-a01ed9de193fc1d635200f8fae91c77d54921c62.tar.gz fbgui-a01ed9de193fc1d635200f8fae91c77d54921c62.tar.xz fbgui-a01ed9de193fc1d635200f8fae91c77d54921c62.zip | |
.
Diffstat (limited to 'src')
| -rw-r--r-- | src/DownloadManager.cpp | 1 | ||||
| -rw-r--r-- | src/javascriptInterface.cpp | 14 | ||||
| -rw-r--r-- | src/main.cpp | 7 |
3 files changed, 8 insertions, 14 deletions
diff --git a/src/DownloadManager.cpp b/src/DownloadManager.cpp index adda63e..00fbd7c 100644 --- a/src/DownloadManager.cpp +++ b/src/DownloadManager.cpp @@ -47,6 +47,7 @@ void DownloadManager::startNextDownload() QString tmp = url.path(); tmp.remove(0, tmp.lastIndexOf(QChar('/')) + 1); outfile.setFileName(downloadDirectory.path() + "/" + tmp); + if (debug) qDebug() << "DM: Absolute path: " << downloadDirectory.path() + "/" + tmp; if (outfile.exists()){ if (debug) qDebug() << "File already exists. Skipping: " << url.toString(); startNextDownload(); diff --git a/src/javascriptInterface.cpp b/src/javascriptInterface.cpp index 98efdb7..e93d325 100644 --- a/src/javascriptInterface.cpp +++ b/src/javascriptInterface.cpp @@ -21,17 +21,9 @@ javascriptInterface::~javascriptInterface() {} QString javascriptInterface::getSysInfo(QString info) { sysInfo si; - if (debug) qDebug() << "Requested info: " << info; - if (debug) qDebug() << "sysInfo output: " << si.getInfo(info); - if (info == QString("time")){ - return si.getInfo(info); - } - if (info == QString("mac")){ - return si.getInfo(info); - //return "MAC_ADDRESS"; - } - else - return "no value"; + if (debug) qDebug() << "Requested info: " << info << endl + << "sysInfo output: " << si.getInfo(info); + return si.getInfo(info); } //------------------------------------------------------------------------------------------------------- void javascriptInterface::attachToDOM() diff --git a/src/main.cpp b/src/main.cpp index ad60715..81e10dc 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -84,11 +84,12 @@ int main(int argc, char *argv[]) baseURL = DEFAULT_URL; if (clo.contains("downloadDir")) - downloadDirectory = QDir(clo.value("downloadDir")); + downloadDirectory = QDir(clo.value("downloadDir")); else if (confFileSettings.contains("default/downloadDirectory")) - downloadDirectory = QDir(confFileSettings.value("default/downloadDirectory").toString()); + downloadDirectory = QDir(confFileSettings.value("default/downloadDirectory").toString()); else - downloadDirectory = QDir("."); + downloadDirectory = QDir("."); + if (debug) qDebug() << "Downloads will be saved to: " << downloadDirectory.dirName(); // Start fbgui. fbgui gui(&app); gui.show(); |
