Browse Source

fix: Fix problem with unicode symbols on FreeBSD

Fix #4012
v1.7.1
Diadlo 9 years ago
parent
commit
6f155d4db8
No known key found for this signature in database
GPG Key ID: 5AF9F2E29107C727
  1. 9
      src/persistence/smileypack.cpp

9
src/persistence/smileypack.cpp

@ -83,7 +83,14 @@ QStringList SmileyPack::loadDefaultPaths() @@ -83,7 +83,14 @@ QStringList SmileyPack::loadDefaultPaths()
paths.append('.' + QDir::separator() + EMOTICONS_SUB_DIR);
// qTox exclusive emoticons
for(auto qtoxPath : QStandardPaths::standardLocations(QStandardPaths::DataLocation))
QStandardPaths::StandardLocation location;
#if (QT_VERSION >= QT_VERSION_CHECK(5, 4, 0))
location = QStandardPaths::AppDataLocation;
#else
#warning "Qt < 5.4.0 has a trouble with unicode symbols in path on few systems"
location = QStandardPaths::DataLocation;
#endif
for(auto qtoxPath : QStandardPaths::standardLocations(location))
{
qtoxPath += QDir::separator() + EMOTICONS_SUB_DIR;
if(!paths.contains(qtoxPath))

Loading…
Cancel
Save