mirror of
https://github.com/OpenMW/openmw.git
synced 2025-03-01 00:39:43 +00:00
Use dedicated function to convert QString to std::filesystem::path
I noticed this while reviewing something else and trying to find the function to recommend using it.
This commit is contained in:
parent
e575c25278
commit
f757ac642a
1 changed files with 1 additions and 3 deletions
|
@ -258,9 +258,7 @@ void Launcher::DataFilesPage::populateFileViews(const QString& contentModelName)
|
|||
}
|
||||
|
||||
// deactivate data-local and global data directory: they are always included
|
||||
const auto tmp = currentDir.toUtf8();
|
||||
if (currentDir == mDataLocal
|
||||
|| std::filesystem::path(Misc::StringUtils::stringToU8String(tmp)) == globalDataDir)
|
||||
if (currentDir == mDataLocal || Files::pathFromQString(currentDir) == globalDataDir)
|
||||
{
|
||||
auto flags = item->flags();
|
||||
item->setFlags(flags & ~(Qt::ItemIsDragEnabled | Qt::ItemIsDropEnabled | Qt::ItemIsEnabled));
|
||||
|
|
Loading…
Reference in a new issue