aboutsummaryrefslogtreecommitdiff
path: root/c/ext.cpp
diff options
context:
space:
mode:
authorJohn Ankarström <john@ankarstrom.se>2022-08-25 03:28:05 +0200
committerJohn Ankarström <john@ankarstrom.se>2022-08-25 03:28:05 +0200
commit160b5ac92a846038372225ab79e29166fd152949 (patch)
treeada5441269dbd13f57479180bcafe60cc6fa7525 /c/ext.cpp
parent158e54f071a3b2b41e6105fc3064ce8297fe532a (diff)
downloadEpisodeBrowser-160b5ac92a846038372225ab79e29166fd152949.tar.gz
Fix MSVC compatibility.
Diffstat (limited to 'c/ext.cpp')
-rw-r--r--c/ext.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/c/ext.cpp b/c/ext.cpp
index 04ab096..d8f3eb9 100644
--- a/c/ext.cpp
+++ b/c/ext.cpp
@@ -8,7 +8,7 @@ extern CfgA& g_cfg;
extern FileView<ElvDataA> g_fvElv;
extern FileView<DlvDataA> g_fvDlv;
-void OpenOnline(int iEp)
+bool OpenOnline(int iEp)
{
wchar_t url[sizeof(g_cfg.url)+4];
Swprintf(url, L"%s%d", g_cfg.url, iEp);
@@ -16,9 +16,10 @@ void OpenOnline(int iEp)
ShellExecute(nullptr, L"open", url, nullptr, nullptr, SW_SHOWNORMAL));
if (r <= 32)
throw Win32Error();
+ return true;
}
-void OpenWiki(int iEp)
+bool OpenWiki(int iEp)
{
const DlvDataA& d = g_fvDlv.At(iEp-1);
wchar_t url[sizeof(d.wiki)+35];
@@ -27,6 +28,7 @@ void OpenWiki(int iEp)
ShellExecute(nullptr, L"open", url, nullptr, nullptr, SW_SHOWNORMAL));
if (r <= 32)
throw Win32Error();
+ return true;
}
static inline bool MatchFileName(wchar_t (&file)[MAX_PATH], const wchar_t* const siEp) noexcept