summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/theme.cpp16
-rw-r--r--src/gui/windows/minimap.cpp4
2 files changed, 10 insertions, 10 deletions
diff --git a/src/gui/theme.cpp b/src/gui/theme.cpp
index 96f09d324..0c3d80a50 100644
--- a/src/gui/theme.cpp
+++ b/src/gui/theme.cpp
@@ -65,8 +65,8 @@ static void initDefaultThemePath()
defaultThemePath = branding.getStringValue("guiThemePath");
logger->log("defaultThemePath: " + defaultThemePath);
- if (!defaultThemePath.empty() && VirtFs::isDirectory(
- defaultThemePath.c_str()))
+ if (!defaultThemePath.empty() &&
+ VirtFs::isDirectory(defaultThemePath))
{
return;
}
@@ -398,7 +398,7 @@ Skin *Theme::readSkin(const std::string &filename, const bool full)
return nullptr;
const std::string path = resolveThemePath(filename);
- if (!VirtFs::exists(path.c_str()))
+ if (!VirtFs::exists(path))
return nullptr;
XML::Document *const doc = Loader::getXml(path,
UseResman_true,
@@ -551,7 +551,7 @@ bool Theme::tryThemePath(const std::string &themeName)
if (!themeName.empty())
{
const std::string path = defaultThemePath + themeName;
- if (VirtFs::exists(path.c_str()))
+ if (VirtFs::exists(path))
{
mThemePath = path;
mThemeName = themeName;
@@ -583,8 +583,8 @@ void Theme::fillSoundsList(StringVect &list)
FOR_EACH (StringVectCIter, i, skins->names)
{
- if (!VirtFs::isDirectory((
- branding.getStringValue("systemsounds") + *i).c_str()))
+ if (!VirtFs::isDirectory((branding.getStringValue(
+ "systemsounds") + *i)))
{
std::string str = *i;
if (findCutLast(str, ".ogg"))
@@ -638,14 +638,14 @@ std::string Theme::resolveThemePath(const std::string &path)
if (file.find('/') != std::string::npos)
{
// Might be a valid path already
- if (VirtFs::exists(file.c_str()))
+ if (VirtFs::exists(file))
return path;
}
// Try the theme
file = getThemePath().append("/").append(file);
- if (VirtFs::exists(file.c_str()))
+ if (VirtFs::exists(file))
return getThemePath().append("/").append(path);
// Backup
diff --git a/src/gui/windows/minimap.cpp b/src/gui/windows/minimap.cpp
index ce316b1eb..f19fb2239 100644
--- a/src/gui/windows/minimap.cpp
+++ b/src/gui/windows/minimap.cpp
@@ -180,14 +180,14 @@ void Minimap::setMap(const Map *const map)
std::string minimapName = map->getProperty("minimap");
- if (minimapName.empty() && VirtFs::exists(tempname.c_str()))
+ if (minimapName.empty() && VirtFs::exists(tempname))
minimapName = tempname;
if (minimapName.empty())
{
tempname = std::string("graphics/minimaps/").append(
map->getFilename()).append(".png");
- if (VirtFs::exists(tempname.c_str()))
+ if (VirtFs::exists(tempname))
minimapName = tempname;
}