| 6 | #include <shellapi.h> |
| 7 | |
| 8 | void shell::open_url(const char *url) |
| 9 | { |
| 10 | static decltype(&ShellExecuteA) pShellExecuteA = nullptr; |
| 11 | |
| 12 | if (!pShellExecuteA) { |
| 13 | HMODULE shell32 = LoadLibraryA("shell32.dll"); |
| 14 | (LPVOID &)pShellExecuteA = GetProcAddress(shell32, "ShellExecuteA"); |
| 15 | } |
| 16 | |
| 17 | if (pShellExecuteA) |
| 18 | pShellExecuteA(NULL, "open", url, NULL, NULL, SW_SHOWNORMAL); |
| 19 | } |
| 20 | |
| 21 | void shell::open_folder(const path &path) |
| 22 | { |
nothing calls this directly
no outgoing calls
no test coverage detected