summaryrefslogtreecommitdiff
path: root/plugins/UserInfoEx/src/dlg_msgbox.h
blob: 4f2185907752fb012ea1012970e8b1d42b040ee4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
/*
UserinfoEx plugin for Miranda NG

Copyright:
© 2012-23 Miranda NG team (https://miranda-ng.org)
© 2006-10 DeathAxe, Yasnovidyashii, Merlin, K. Romanov, Kreol

This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/

#ifndef _SVC_DLG_INCLUDED_
#define _SVC_DLG_INCLUDED_ 1

#define MB_YESALLNO				0x00000007L
#define MB_TYPE(p)				((p)&MB_TYPEMASK)

/*
valid predefined icon values
*/
#define MB_ICON_NONE			0x00000000L //	 0 - no icon
#define MB_ICON_ERROR			0x00000010L //	16 - error icon
#define MB_ICON_QUESTION		0x00000020L //	32 - question mark
#define MB_ICON_WARNING			0x00000030L //	48 - warning
#define MB_ICON_INFO			0x00000040L //	64 - info
#define MB_ICON_OTHER			0x00000080L // 240 - use icon _MSGBOX->hiMsg
#define MB_ICON_INDEX(p)		(((p)&MB_ICONMASK)>>4)

/*
flags
*/
#define MB_INFOBAR				0x00000100L
#define MB_NOPOPUP				0x00000200L
#define MB_CUSTOMCOLOR			0x00000300L

struct MSGBOX
{
	UINT     cbSize;        // size of this structure
	UINT     uType;         // parameters
	HICON    hiLogo;        // right upper icon of the info bar
	HICON    hiMsg;         // icon left next to the message text
	LPTSTR   ptszTitle;
	LPTSTR   ptszInfoText;
	LPTSTR   ptszMsg;
	HWND     hParent;	      // parent window for the messagebox
	COLORREF colorBack;     // valid if MB_CUSTOMCOLOR is set
	COLORREF colorText;     // valid if MB_CUSTOMCOLOR is set
};

INT_PTR CALLBACK	MsgBox(HWND hParent, UINT uType, LPCTSTR pszTitle, LPCTSTR pszInfo, LPCTSTR pszFormat, ...);
INT_PTR CALLBACK	MsgErr(HWND hParent, LPCTSTR pszFormat, ...);
INT_PTR				MsgBoxService(WPARAM wParam, LPARAM lParam);

LRESULT CALLBACK	PopupProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);

#endif /* _SVC_DLG_INCLUDED_ */