MCPcopy Create free account
hub / github.com/PenguLoader/PenguLoader / open_url

Method open_url

core/src/utils/shell.cc:8–19  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6#include <shellapi.h>
7
8void 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
21void shell::open_folder(const path &path)
22{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected