From 22b84cc6cd304133f84a2c357608354d9e4474e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20T=C5=AFma?= Date: Fri, 18 Dec 2015 22:48:11 +0100 Subject: [PATCH] Revert "Code cleanup" This reverts commit ba9319d7f6b5098004f2c5356390e1329891d8a3. --- src/map.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/map.cpp b/src/map.cpp index ca7deb19..6d0cffa3 100644 --- a/src/map.cpp +++ b/src/map.cpp @@ -4,7 +4,7 @@ #include "ll.h" #include "config.h" #include "map.h" -#include + Map::Map(const QString &name, const QString &url) { @@ -14,10 +14,10 @@ Map::Map(const QString &name, const QString &url) connect(&Downloader::instance(), SIGNAL(finished()), this, SLOT(emitLoaded())); - QString path = QString(TILES_DIR"/") + _name; -qDebug() << path; - if (!QDir::home().mkpath(path)) - fprintf(stderr, "Error creating tiles dir: %s\n", qPrintable(path)); + if (!QDir::home().mkpath(QString(TILES_DIR"/%1").arg(_name))) + fprintf(stderr, "Error creating tiles dir: %s\n", + qPrintable(QDir::home().absolutePath() + QString("/"TILES_DIR"/%1") + .arg(_name))); } void Map::emitLoaded()