Use QUrl to get the profile file name

Cheaper than constructing a QFileInfo.
wilder
Ahmad Samir 4 years ago committed by Kurt Hindenburg
parent 124756f650
commit 1a93b0907c
  1. 4
      src/profile/ProfileManager.cpp

@ -436,11 +436,9 @@ void ProfileManager::saveDefaultProfile()
path = writer.getPath(_defaultProfile);
}
QFileInfo fileInfo(path);
KSharedConfigPtr appConfig = KSharedConfig::openConfig();
KConfigGroup group = appConfig->group("Desktop Entry");
group.writeEntry("DefaultProfile", fileInfo.fileName());
group.writeEntry("DefaultProfile", QUrl::fromLocalFile(path).fileName());
}
void ProfileManager::loadShortcuts()

Loading…
Cancel
Save