diff options
author | John Ankarström <john@ankarstrom.se> | 2022-08-09 21:49:18 +0200 |
---|---|---|
committer | John Ankarström <john@ankarstrom.se> | 2022-08-09 21:49:18 +0200 |
commit | 805cc4cec440525629758af918d50a850209ec0b (patch) | |
tree | 570077b7091020c899a1160523b7aba0523d3ed9 /c/win.h | |
parent | df2ccebabb5af3b304ba8220e4c9364f8fd9f830 (diff) | |
download | EpisodeBrowser-805cc4cec440525629758af918d50a850209ec0b.tar.gz |
Add WithNextWindow function.
I'm not sure if this clarifies or complicates the control flow. My
hope is the former.
Diffstat (limited to 'c/win.h')
-rw-r--r-- | c/win.h | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -4,10 +4,12 @@ #include <optional> #include <windows.h> +/* Run given procedure at creation of next window. */ +void WithNextWindow(void (*proc)(HWND)); /* Display message box centered in main window. */ int EBMessageBox(const wchar_t* wszText, const wchar_t* wszCaption, UINT uType); /* Retrieve mouse position relative to given window's client area. */ -int GetRelativeCursorPos(HWND hWnd, POINT* pt); +int GetRelativeCursorPos(HWND hWnd, POINT* pt) noexcept; /* Cached values from GetSystemMetrics. */ template <int I> auto Metric = GetSystemMetrics(I); |