summaryrefslogtreecommitdiff
path: root/alf/alf.h
diff options
context:
space:
mode:
Diffstat (limited to 'alf/alf.h')
-rw-r--r--alf/alf.h45
1 files changed, 45 insertions, 0 deletions
diff --git a/alf/alf.h b/alf/alf.h
index 6140e60..8969ee1 100644
--- a/alf/alf.h
+++ b/alf/alf.h
@@ -160,6 +160,15 @@ ALF_ReAlloc(void *ptr, SIZE_T nmemb, SIZE_T size);
void
ALF_Free(const void *p);
+TCHAR *
+ALF_StrDup(const TCHAR *psz);
+
+TCHAR *
+ALF_StrOrIntresourceDup(const TCHAR *psz);
+
+void
+ALF_StrOrIntresourceFree(const TCHAR *psz);
+
COLORREF
ALF_ColorToGdi(ALFColor color);
@@ -611,6 +620,42 @@ ALF_LoadIcon(HINSTANCE hinst, const TCHAR *name, int cx, int cy);
SIZE
ALF_IconSize(HICON icon);
+// custom message box
+HWND
+ALF_MessageDlg_Create(HWND owner);
+
+void
+ALF_MessageDlg_SetCaption(HWND msg, const TCHAR *caption);
+
+void
+ALF_MessageDlg_SetText(HWND msg, const TCHAR *text);
+
+void
+ALF_MessageDlg_SetIcon(HWND msg, HINSTANCE hinst, const TCHAR *name);
+
+void
+ALF_MessageDlg_AddButton(HWND msg, WORD id, const TCHAR *text);
+
+WORD
+ALF_MessageDlg_Run(HWND msg);
+
+// message box shortcuts
+void
+ALF_MessageDlg_Error(HWND owner, const TCHAR *text, const TCHAR *caption, const TCHAR *okBtnText);
+
+void
+ALF_MessageDlg_Warning(HWND owner, const TCHAR *text, const TCHAR *caption, const TCHAR *okBtnText);
+
+void
+ALF_MessageDlg_Information(HWND owner, const TCHAR *text, const TCHAR *caption, const TCHAR *okBtnText);
+
+WORD // IDOK or IDCANCEL
+ALF_MessageDlg_Confirm(HWND owner, const TCHAR *text, const TCHAR *caption, const TCHAR *okBtnText, const TCHAR *cancelBtnText);
+
+// like ALF_MessageDlg_Confirm, but shows an exclamation icon and preselects the cancel button
+WORD
+ALF_MessageDlg_ConfirmDanger(HWND owner, const TCHAR *text, const TCHAR *caption, const TCHAR *okBtnText, const TCHAR *cancelBtnText);
+
#ifdef __cplusplus
} // extern C