| 932 | } |
| 933 | |
| 934 | bool registryValueExists(const QString& keyName, const QString& valueName) |
| 935 | { |
| 936 | auto key = openRegistryKey(HKEY_CURRENT_USER, keyName.toStdWString().c_str()); |
| 937 | |
| 938 | if (!key) { |
| 939 | return false; |
| 940 | } |
| 941 | |
| 942 | DWORD type = 0; |
| 943 | |
| 944 | auto r = ::RegQueryValueExW(key.get(), valueName.toStdWString().c_str(), nullptr, |
| 945 | &type, nullptr, nullptr); |
| 946 | |
| 947 | return (r == ERROR_SUCCESS); |
| 948 | } |
| 949 | |
| 950 | // returns the filename of the given process or the current one |
| 951 | // |
no test coverage detected