| 45 | |
| 46 | |
| 47 | void QtHelpPlugin::readConfig() |
| 48 | { |
| 49 | QStringList iconList, nameList, pathList, ghnsList; |
| 50 | QString searchDir; |
| 51 | qtHelpReadConfig(iconList, nameList, pathList, ghnsList, searchDir, m_loadSystemQtDoc); |
| 52 | |
| 53 | // Make all .qch file paths read from config absolute as required by loadQtHelpProvider(). |
| 54 | for (auto& path : pathList) { |
| 55 | path = QFileInfo{path}.absoluteFilePath(); |
| 56 | } |
| 57 | // Pass an absolute path searchDir to searchHelpDirectory() so that it appends absolute paths to pathList. |
| 58 | searchDir = QFileInfo{searchDir}.absoluteFilePath(); |
| 59 | |
| 60 | searchHelpDirectory(pathList, nameList, iconList, searchDir); |
| 61 | loadQtHelpProvider(pathList, nameList, iconList); |
| 62 | removeUnusedHelpCollectionFiles(); |
| 63 | |
| 64 | loadQtDocumentation(m_loadSystemQtDoc); |
| 65 | |
| 66 | emit changedProvidersList(); |
| 67 | |
| 68 | m_initializationDone |= ReadConfig; |
| 69 | } |
| 70 | |
| 71 | void QtHelpPlugin::loadQtDocumentation(bool loadQtDoc) |
| 72 | { |