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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
|
{
Copyright (C) 2006 Ricardo Pescuma Domenecci, Nightwish
This is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This 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
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this file; see the file license.txt. If
not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA.
}
{$IFNDEF M_ACC}
{$DEFINE M_ACC}
const
AVATAR_CONTROL_CLASS = 'MAvatarControlClass'; // Class of the control
{
Sets the contact that this avatar represents. This invalidates
a previous call of AVATAR_SETPROTCOL.
wParam = not used
lParam = (HANDLE) hContact
Usage: SendMessage(hwnd, AVATAR_SETCONTACT, 0, (LPARAM) hContact);
Only works on AVATAR_CONTROL_CLASS controls
}
AVATAR_SETCONTACT = WM_USER+1;
{
Sets the user protocol that this avatar represents. This invalidates
a previous call of AVATAR_SETCONTACT.
wParam = not used
lParam = (AnsiChar *) protcol name
Usage: SendMessage(hwnd, AVATAR_SETPROTOCOL, 0, (LPARAM) "MSN");
Only works on AVATAR_CONTROL_CLASS controls
}
AVATAR_SETPROTOCOL = WM_USER+2;
{
Sets the background color of thr control
Default: transparent
wParam = not used
lParam = (COLORREF) color or -1 to transparent
Usage: SendMessage(hwnd, AVATAR_SETBKGCOLOR, 0, (LPARAM) RGB(0,0,0));
Only works on AVATAR_CONTROL_CLASS controls
}
AVATAR_SETBKGCOLOR = WM_USER+3;
{
Sets the control border color
Default: no border
wParam = not used
lParam = (COLORREF) color or -1 to no border
Usage: SendMessage(hwnd, AVATAR_SETBKGCOLOR, 0, (LPARAM) RGB(0,0,0));
Only works on AVATAR_CONTROL_CLASS controls
}
AVATAR_SETBORDERCOLOR = WM_USER+4;
{
Sets the avatar border color
Default: no border
wParam = not used
lParam = (COLORREF) color or -1 to no border
Usage: SendMessage(hwnd, AVATAR_SETBKGCOLOR, 0, (LPARAM) RGB(0,0,0));
Only works on AVATAR_CONTROL_CLASS controls
}
AVATAR_SETAVATARBORDERCOLOR = WM_USER+5;
{
Sets the radius of the round corner of the avatar
Default: 0
wParam = not used
lParam = (int) radius or 0 to not use round corners
Usage: SendMessage(hwnd, AVATAR_SETAVATARROUNDCORNERRADIUS, 0, 4);
Only works on AVATAR_CONTROL_CLASS controls
}
AVATAR_SETAVATARROUNDCORNERRADIUS = WM_USER+6;
{
Sets the text to be shown if no avatar is set. The font can be set using WM_SETFONT.
Default: ""
wParam = not used
lParam = (AnsiChar *) text (it will be translated) - max 128 chars
Usage: SendMessage(hwnd, AVATAR_SETNOAVATARTEXT, 0, (LPARAM) "Contact has no avatar");
Only works on AVATAR_CONTROL_CLASS controls
}
AVATAR_SETNOAVATARTEXT = WM_USER+7;
{
Sets if the hidden setting must be respected and hidden avatars shouldn't be draw
Default: TRUE
wParam = not used
lParam = (BOOL) respect?
Usage: SendMessage(hwnd, AVATAR_RESPECTHIDDEN, 0, (LPARAM) FALSE);
Only works on AVATAR_CONTROL_CLASS controls
}
AVATAR_RESPECTHIDDEN = WM_USER+8;
{
Get the space inside the control that is really beeing used to display the avatar (the rest
is filled with background color). Set both to 0 if no avatar exists.
wParam = (int *) width
lParam = (int *) height
Usage: SendMessage(hwnd, AVATAR_GETUSEDSPACE, (WPARAM) &width, (LPARAM) &height);
Only works on AVATAR_CONTROL_CLASS controls
}
AVATAR_GETUSEDSPACE = WM_USER+9;
{
Sets if the avatar will be resized when its smaller then the control size
Default: TRUE
wParam = not used
lParam = (BOOL) TRUE or FALSE
Usage: SendMessage(hwnd, AVATAR_SETRESIZEIFSMALLER, 0, (LPARAM) FALSE);
Only works on AVATAR_CONTROL_CLASS controls
}
AVATAR_SETRESIZEIFSMALLER = WM_USER+10;
{
tell acc to paint avatar on aero surface (must draw with alpha channel, not using BitBlt()
wParam = not used
lParam = (BOOL) TRUE -> enable, FALSE -> disable
}
AVATAR_SETAEROCOMPATDRAWING = WM_USER+11;
// Set to the parent throught WM_NOTIFY to notify when the avatar shown has changed
NM_AVATAR_CHANGED = -200;
{$ENDIF}
|