QStringList QWinSettingsPrivate::children(const QString &uKey, ChildSpec spec) const { NameSet result; QString rKey = escapedKey(uKey); for (int i = 0; i < regList.size(); ++i) { HKEY parent_handle = regList.at(i).handle(); if (parent_handle == 0) continue; HKEY handle = openKey(parent_handle, KEY_READ, rKey); if (handle == 0) continue; if (spec == AllKeys) { NameSet keys; allKeys(handle, QLatin1String(""), &keys); mergeKeySets(&result, keys); } else { // ChildGroups or ChildKeys QStringList names = childKeysOrGroups(handle, spec); mergeKeySets(&result, names); } RegCloseKey(handle); if (!fallbacks) return result.keys(); } return result.keys(); }