summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/MyDetails/mydetails_12.vcxproj8
-rw-r--r--plugins/MyDetails/src/Version.h8
-rw-r--r--plugins/MyDetails/src/commons.h8
-rw-r--r--plugins/MyDetails/src/data.cpp24
-rw-r--r--plugins/MyDetails/src/data.h4
-rw-r--r--plugins/MyDetails/src/frame.cpp244
-rw-r--r--plugins/MyDetails/src/frame.h4
-rw-r--r--plugins/MyDetails/src/mydetails.cpp22
-rw-r--r--plugins/MyDetails/src/options.cpp58
-rw-r--r--plugins/MyDetails/src/options.h6
-rw-r--r--plugins/MyDetails/src/services.cpp192
-rw-r--r--plugins/Utils/mir_dblists.cpp66
-rw-r--r--plugins/Utils/mir_dblists.h18
-rw-r--r--plugins/Utils/mir_options.cpp260
-rw-r--r--plugins/Utils/mir_options.h6
-rw-r--r--plugins/Utils/mir_smileys.cpp52
-rw-r--r--plugins/Utils/mir_smileys.h6
17 files changed, 491 insertions, 495 deletions
diff --git a/plugins/MyDetails/mydetails_12.vcxproj b/plugins/MyDetails/mydetails_12.vcxproj
index 190909cdc7..9e03b987b8 100644
--- a/plugins/MyDetails/mydetails_12.vcxproj
+++ b/plugins/MyDetails/mydetails_12.vcxproj
@@ -84,7 +84,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<PrecompiledHeader>Use</PrecompiledHeader>
<PrecompiledHeaderFile>commons.h</PrecompiledHeaderFile>
- <WarningLevel>Level3</WarningLevel>
+ <WarningLevel>Level4</WarningLevel>
<ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<Link>
@@ -114,7 +114,7 @@
<FunctionLevelLinking>true</FunctionLevelLinking>
<PrecompiledHeader>Use</PrecompiledHeader>
<PrecompiledHeaderFile>commons.h</PrecompiledHeaderFile>
- <WarningLevel>Level3</WarningLevel>
+ <WarningLevel>Level4</WarningLevel>
<ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<Link>
@@ -143,7 +143,7 @@
<BufferSecurityCheck>true</BufferSecurityCheck>
<PrecompiledHeader>Use</PrecompiledHeader>
<PrecompiledHeaderFile>commons.h</PrecompiledHeaderFile>
- <WarningLevel>Level3</WarningLevel>
+ <WarningLevel>Level4</WarningLevel>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
<ExceptionHandling>false</ExceptionHandling>
</ClCompile>
@@ -172,7 +172,7 @@
<BufferSecurityCheck>true</BufferSecurityCheck>
<PrecompiledHeader>Use</PrecompiledHeader>
<PrecompiledHeaderFile>commons.h</PrecompiledHeaderFile>
- <WarningLevel>Level3</WarningLevel>
+ <WarningLevel>Level4</WarningLevel>
<ExceptionHandling>false</ExceptionHandling>
</ClCompile>
<Link>
diff --git a/plugins/MyDetails/src/Version.h b/plugins/MyDetails/src/Version.h
index 5d948e087f..bcc3b87b42 100644
--- a/plugins/MyDetails/src/Version.h
+++ b/plugins/MyDetails/src/Version.h
@@ -7,8 +7,8 @@
#define __PLUGIN_NAME "My details"
#define __FILENAME "MyDetails.dll"
-#define __DESCRIPTION "Shows and allows you to edit your details for all protocols."
-#define __AUTHOR "Ricardo Pescuma Domenecci, Drugwash"
+#define __DESCRIPTION "Shows and allows you to edit your details for all protocols."
+#define __AUTHOR "Ricardo Pescuma Domenecci, Drugwash"
#define __AUTHOREMAIL ""
-#define __AUTHORWEB "http://miranda-ng.org/p/MyDetails/"
-#define __COPYRIGHT "© 2005-2008 Ricardo Pescuma Domenecci, Drugwash"
+#define __AUTHORWEB "http://miranda-ng.org/p/MyDetails/"
+#define __COPYRIGHT "© 2005-2008 Ricardo Pescuma Domenecci, Drugwash"
diff --git a/plugins/MyDetails/src/commons.h b/plugins/MyDetails/src/commons.h
index c779a189db..b18b58c210 100644
--- a/plugins/MyDetails/src/commons.h
+++ b/plugins/MyDetails/src/commons.h
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 2005 Ricardo Pescuma Domenecci
This is free software; you can redistribute it and/or
@@ -14,7 +14,7 @@ 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.
+Boston, MA 02111-1307, USA.
*/
@@ -67,8 +67,6 @@ Boston, MA 02111-1307, USA.
#define SETTING_DEFAULT_NICK "DefaultNick"
extern HINSTANCE hInst;
-extern long nickname_dialog_open;
-extern long status_msg_dialog_open;
extern bool g_bFramesExist, g_bAvsExist;
#define PS_GETMYNICKNAMEMAXLENGTH "/GetMyNicknameMaxLength"
@@ -87,7 +85,7 @@ static __inline int DRAW_TEXT(HDC hDC, LPCTSTR lpString, int nCount, LPRECT lpRe
{
if (!opts.replace_smileys)
return DrawText(hDC, lpString, nCount, lpRect, uFormat);
-
+
return Smileys_DrawText(hDC, lpString, nCount, lpRect, uFormat | (opts.resize_smileys ? DT_RESIZE_SMILEYS : 0),
opts.use_contact_list_smileys ? "clist" : protocol, NULL);
}
diff --git a/plugins/MyDetails/src/data.cpp b/plugins/MyDetails/src/data.cpp
index ca7c6069d9..8451c124d5 100644
--- a/plugins/MyDetails/src/data.cpp
+++ b/plugins/MyDetails/src/data.cpp
@@ -577,18 +577,18 @@ static char *StatusModeToDbSetting(int status, const char *suffix)
static char str[64];
switch (status) {
- case ID_STATUS_AWAY: prefix = "Away"; break;
- case ID_STATUS_NA: prefix = "Na"; break;
- case ID_STATUS_DND: prefix = "Dnd"; break;
- case ID_STATUS_OCCUPIED: prefix = "Occupied"; break;
- case ID_STATUS_FREECHAT: prefix = "FreeChat"; break;
- case ID_STATUS_ONLINE: prefix = "On"; break;
- case ID_STATUS_OFFLINE: prefix = "Off"; break;
- case ID_STATUS_INVISIBLE: prefix = "Inv"; break;
- case ID_STATUS_ONTHEPHONE: prefix = "Otp"; break;
- case ID_STATUS_OUTTOLUNCH: prefix = "Otl"; break;
- case ID_STATUS_IDLE: prefix = "Idl"; break;
- default: return NULL;
+ case ID_STATUS_AWAY: prefix = "Away"; break;
+ case ID_STATUS_NA: prefix = "Na"; break;
+ case ID_STATUS_DND: prefix = "Dnd"; break;
+ case ID_STATUS_OCCUPIED: prefix = "Occupied"; break;
+ case ID_STATUS_FREECHAT: prefix = "FreeChat"; break;
+ case ID_STATUS_ONLINE: prefix = "On"; break;
+ case ID_STATUS_OFFLINE: prefix = "Off"; break;
+ case ID_STATUS_INVISIBLE: prefix = "Inv"; break;
+ case ID_STATUS_ONTHEPHONE: prefix = "Otp"; break;
+ case ID_STATUS_OUTTOLUNCH: prefix = "Otl"; break;
+ case ID_STATUS_IDLE: prefix = "Idl"; break;
+ default: return NULL;
}
mir_strcpy(str, prefix);
mir_strcat(str, suffix);
diff --git a/plugins/MyDetails/src/data.h b/plugins/MyDetails/src/data.h
index 53bc6ade9d..2423da653d 100644
--- a/plugins/MyDetails/src/data.h
+++ b/plugins/MyDetails/src/data.h
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 2005 Ricardo Pescuma Domenecci
This is free software; you can redistribute it and/or
@@ -14,7 +14,7 @@ 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.
+Boston, MA 02111-1307, USA.
*/
diff --git a/plugins/MyDetails/src/frame.cpp b/plugins/MyDetails/src/frame.cpp
index 0ebffc15bf..e592404583 100644
--- a/plugins/MyDetails/src/frame.cpp
+++ b/plugins/MyDetails/src/frame.cpp
@@ -74,8 +74,8 @@ BYTE font_styles[] = { DBFONTF_BOLD, 0, 0, DBFONTF_ITALIC, DBFONTF_ITALIC };
COLORREF font_colors[] = { RGB(0, 0, 0), RGB(0, 0, 0), RGB(0, 0, 0), RGB(150, 150, 150), RGB(150, 150, 150) };
static ColourID
- bg_colour = { sizeof(bg_colour), LPGEN("My details"), LPGEN("Background"), MODULE_NAME, "BackgroundColor", 0, GetSysColor(COLOR_BTNFACE) },
- av_colour = { sizeof(av_colour), LPGEN("My details"), LPGEN("Avatar border"), MODULE_NAME, "AvatarBorderColor", 0, RGB(0, 0, 0) };
+bg_colour = { sizeof(bg_colour), LPGEN("My details"), LPGEN("Background"), MODULE_NAME, "BackgroundColor", 0, GetSysColor(COLOR_BTNFACE) },
+av_colour = { sizeof(av_colour), LPGEN("My details"), LPGEN("Avatar border"), MODULE_NAME, "AvatarBorderColor", 0, RGB(0, 0, 0) };
int CreateFrame();
void FixMainMenu();
@@ -191,7 +191,7 @@ void DeInitFrames()
DestroyWindow(hwnd_container);
}
-int ReloadFont(WPARAM wParam, LPARAM lParam)
+int ReloadFont(WPARAM, LPARAM)
{
for (int i = 0; i < NUM_FONTS; i++) {
if (hFont[i] != 0)
@@ -215,7 +215,7 @@ int ReloadColour(WPARAM, LPARAM)
return 0;
}
-int SmileyAddOptionsChangedHook(WPARAM wParam, LPARAM lParam)
+int SmileyAddOptionsChangedHook(WPARAM, LPARAM)
{
RefreshFrame();
return 0;
@@ -274,7 +274,7 @@ int CreateFrame()
hwnd_frame = CreateWindow(WINDOW_CLASS_NAME, TranslateT("My details"), WS_CHILD | WS_VISIBLE,
0, 0, 10, 10, (HWND)CallService(MS_CLUI_GETHWND, 0, 0), NULL, hInst, NULL);
- CLISTFrame Frame = {0};
+ CLISTFrame Frame = { 0 };
Frame.cbSize = sizeof(Frame);
Frame.tname = TranslateT("My details");
@@ -372,15 +372,15 @@ LRESULT CALLBACK FrameContainerWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LP
break;
case WM_SIZE:
- {
- HWND child = (HWND)GetWindowLongPtr(hwnd, GWLP_USERDATA);
- RECT r;
- GetClientRect(hwnd, &r);
+ {
+ HWND child = (HWND)GetWindowLongPtr(hwnd, GWLP_USERDATA);
+ RECT r;
+ GetClientRect(hwnd, &r);
- SetWindowPos(child, 0, r.left, r.top, r.right - r.left, r.bottom - r.top, SWP_NOZORDER | SWP_NOACTIVATE);
- InvalidateRect(child, NULL, TRUE);
- }
- return TRUE;
+ SetWindowPos(child, 0, r.left, r.top, r.right - r.left, r.bottom - r.top, SWP_NOZORDER | SWP_NOACTIVATE);
+ InvalidateRect(child, NULL, TRUE);
+ }
+ return TRUE;
case WM_CLOSE:
db_set_b(0, MODULE_NAME, SETTING_FRAME_VISIBLE, 0);
@@ -467,7 +467,7 @@ RECT GetRect(HDC hdc, RECT rc, SIZE s, UINT uFormat, int next_top, int text_left
// Make it fit inside original rc
r.top = max(next_top, r.top);
- r.bottom = min(rc.bottom, r.bottom);
+ r.bottom = min(rc.bottom, r.bottom);
r.left = max(text_left, r.left);
r.right = min(rc.right, r.right);
@@ -749,7 +749,7 @@ void CalcRectangles(HWND hwnd)
data->proto_rect = GetRect(hdc, tmp_r, proto->description, _T(""), proto, uFormat, next_top, tmp_text_left, false, true, false);
if (opts.show_protocol_cycle_button) {
- data->draw_proto_cycle= true;
+ data->draw_proto_cycle = true;
RECT prev = r;
prev.top = next_top;
@@ -1148,9 +1148,9 @@ void Draw(HWND hwnd, HDC hdc_orig)
adr.hTargetDC = hdc;
adr.rcDraw = data->img_rect;
adr.dwFlags = AVDRQ_OWNPIC | AVDRQ_HIDEBORDERONTRANSPARENCY
- | (opts.draw_avatar_border ? AVDRQ_DRAWBORDER : 0 )
- | (opts.draw_avatar_round_corner ? AVDRQ_ROUNDEDCORNER : 0 );
- adr.clrBorder = opts.draw_avatar_border_color;
+ | (opts.draw_avatar_border ? AVDRQ_DRAWBORDER : 0)
+ | (opts.draw_avatar_round_corner ? AVDRQ_ROUNDEDCORNER : 0);
+ adr.clrBorder = opts.draw_avatar_border_color;
adr.radius = round_radius;
adr.alpha = 255;
adr.szProto = proto->name;
@@ -1384,7 +1384,7 @@ void MakeHover(HWND hwnd, bool draw, bool *hover, POINT *p, RECT *r)
}
}
-void ShowGlobalStatusMenu(HWND hwnd, MyDetailsFrameData *data, Protocol *proto, POINT &p)
+void ShowGlobalStatusMenu(HWND hwnd, MyDetailsFrameData *data, POINT &p)
{
HMENU submenu = (HMENU)CallService(MS_CLIST_MENUGETSTATUS, 0, 0);
@@ -1408,7 +1408,7 @@ void ShowProtocolStatusMenu(HWND hwnd, MyDetailsFrameData *data, Protocol *proto
// Find the correct menu item
int count = GetMenuItemCount(menu);
for (int i = 0; i < count && submenu == NULL; i++) {
- MENUITEMINFO mii = {0};
+ MENUITEMINFO mii = { 0 };
mii.cbSize = sizeof(mii);
mii.fMask = MIIM_STRING;
@@ -1433,7 +1433,7 @@ void ShowProtocolStatusMenu(HWND hwnd, MyDetailsFrameData *data, Protocol *proto
if (submenu != NULL) {
p.x = (opts.draw_text_align_right ? data->status_rect.right : data->status_rect.left);
- p.y = data->status_rect.bottom + 1;
+ p.y = data->status_rect.bottom + 1;
ClientToScreen(hwnd, &p);
int ret = TrackPopupMenu(submenu, TPM_TOPALIGN | TPM_RIGHTBUTTON | TPM_RETURNCMD
@@ -1458,7 +1458,7 @@ void ShowProtocolStatusMenu(HWND hwnd, MyDetailsFrameData *data, Protocol *proto
RemoveMenu(submenu, i, MF_BYPOSITION);
p.x = (opts.draw_text_align_right ? data->status_rect.right : data->status_rect.left);
- p.y = data->status_rect.bottom + 1;
+ p.y = data->status_rect.bottom + 1;
ClientToScreen(hwnd, &p);
int ret = TrackPopupMenu(submenu, TPM_TOPALIGN | TPM_RIGHTBUTTON | TPM_RETURNCMD
@@ -1479,7 +1479,7 @@ void ShowListeningToMenu(HWND hwnd, MyDetailsFrameData *data, Protocol *proto, P
TCHAR tmp[128];
mir_sntprintf(tmp, SIZEOF(tmp), TranslateT("Enable listening to for %s"), proto->description);
- MENUITEMINFO mii = {0};
+ MENUITEMINFO mii = { 0 };
mii.cbSize = sizeof(mii);
mii.fMask = MIIM_ID | MIIM_TYPE | MIIM_STATE;
mii.fType = MFT_STRING;
@@ -1504,7 +1504,7 @@ void ShowListeningToMenu(HWND hwnd, MyDetailsFrameData *data, Protocol *proto, P
SetMenuItemInfo(submenu, ID_LISTENINGTOPOPUP_SENDLISTENINGTO, FALSE, &mii);
p.x = (opts.draw_text_align_right ? data->listening_to_rect.right : data->listening_to_rect.left);
- p.y = data->listening_to_rect.bottom + 1;
+ p.y = data->listening_to_rect.bottom + 1;
ClientToScreen(hwnd, &p);
int ret = TrackPopupMenu(submenu, TPM_TOPALIGN | TPM_RIGHTBUTTON | TPM_RETURNCMD
@@ -1529,47 +1529,47 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
switch (msg) {
case WM_CREATE:
- {
- data = new MyDetailsFrameData();
- memset(data, 0, sizeof(MyDetailsFrameData));
- SetWindowLongPtr(hwnd, GWLP_USERDATA, (LONG_PTR)data);
-
- data->recalc_rectangles = true;
- data->get_status_messages = false;
- data->showing_menu = false;
-
- data->protocol_number = db_get_w(NULL, "MyDetails", "ProtocolNumber", 0);
- if (data->protocol_number >= protocols->GetSize())
- data->protocol_number = 0;
-
- SetCycleTime(hwnd);
- SetStatusMessageRefreshTime(hwnd);
+ {
+ data = new MyDetailsFrameData();
+ memset(data, 0, sizeof(MyDetailsFrameData));
+ SetWindowLongPtr(hwnd, GWLP_USERDATA, (LONG_PTR)data);
- TRACKMOUSEEVENT tme;
- tme.cbSize = sizeof(TRACKMOUSEEVENT);
- tme.dwFlags = TME_HOVER | TME_LEAVE;
- tme.hwndTrack = hwnd;
- tme.dwHoverTime = HOVER_DEFAULT;
- TrackMouseEvent(&tme);
- }
- return TRUE;
+ data->recalc_rectangles = true;
+ data->get_status_messages = false;
+ data->showing_menu = false;
+
+ data->protocol_number = db_get_w(NULL, "MyDetails", "ProtocolNumber", 0);
+ if (data->protocol_number >= protocols->GetSize())
+ data->protocol_number = 0;
+
+ SetCycleTime(hwnd);
+ SetStatusMessageRefreshTime(hwnd);
+
+ TRACKMOUSEEVENT tme;
+ tme.cbSize = sizeof(TRACKMOUSEEVENT);
+ tme.dwFlags = TME_HOVER | TME_LEAVE;
+ tme.hwndTrack = hwnd;
+ tme.dwHoverTime = HOVER_DEFAULT;
+ TrackMouseEvent(&tme);
+ }
+ return TRUE;
case WM_PRINTCLIENT:
Draw(hwnd, (HDC)wParam);
return TRUE;
case WM_PAINT:
- {
- RECT r;
- if (GetUpdateRect(hwnd, &r, FALSE)) {
- PAINTSTRUCT ps;
+ {
+ RECT r;
+ if (GetUpdateRect(hwnd, &r, FALSE)) {
+ PAINTSTRUCT ps;
- HDC hdc = BeginPaint(hwnd, &ps);
- Draw(hwnd, hdc);
- EndPaint(hwnd, &ps);
- }
+ HDC hdc = BeginPaint(hwnd, &ps);
+ Draw(hwnd, hdc);
+ EndPaint(hwnd, &ps);
}
- return TRUE;
+ }
+ return TRUE;
case WM_SIZE:
data->recalc_rectangles = true;
@@ -1645,7 +1645,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
data->showing_menu = true;
if (opts.global_on_status)
- ShowGlobalStatusMenu(hwnd, data, proto, p);
+ ShowGlobalStatusMenu(hwnd, data, p);
else
ShowProtocolStatusMenu(hwnd, data, proto, p);
@@ -1661,7 +1661,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
HMENU menu = CreatePopupMenu();
- for (int i = protocols->GetSize() - 1; i >= 0 ; i--) {
+ for (int i = protocols->GetSize() - 1; i >= 0; i--) {
MENUITEMINFO mii = { sizeof(mii) };
mii.fMask = MIIM_ID | MIIM_TYPE;
mii.fType = MFT_STRING;
@@ -1681,7 +1681,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
p.x = data->proto_rect.right;
else
p.x = data->proto_rect.left;
- p.y = data->proto_rect.bottom + 1;
+ p.y = data->proto_rect.bottom + 1;
ClientToScreen(hwnd, &p);
int ret = TrackPopupMenu(menu, TPM_TOPALIGN | TPM_LEFTALIGN | TPM_RIGHTBUTTON | TPM_RETURNCMD, p.x, p.y, 0, hwnd, NULL);
@@ -1722,7 +1722,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
TCHAR tmp[128];
mir_sntprintf(tmp, SIZEOF(tmp), TranslateT("Set my avatar for %s..."), proto->description);
- MENUITEMINFO mii = {0};
+ MENUITEMINFO mii = { 0 };
mii.cbSize = sizeof(mii);
mii.fMask = MIIM_ID | MIIM_TYPE;
mii.fType = MFT_STRING;
@@ -1762,7 +1762,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
TCHAR tmp[128];
mir_sntprintf(tmp, SIZEOF(tmp), TranslateT("Set my nickname for %s..."), proto->description);
- MENUITEMINFO mii = {0};
+ MENUITEMINFO mii = { 0 };
mii.cbSize = sizeof(mii);
mii.fMask = MIIM_ID | MIIM_TYPE;
mii.fType = MFT_STRING;
@@ -1810,7 +1810,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
// Add this proto to menu
mir_sntprintf(tmp, SIZEOF(tmp), TranslateT("Set my status message for %s..."), proto->description);
- MENUITEMINFO mii = {0};
+ MENUITEMINFO mii = { 0 };
mii.cbSize = sizeof(mii);
mii.fMask = MIIM_ID | MIIM_TYPE;
mii.fType = MFT_STRING;
@@ -1830,7 +1830,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
mir_sntprintf(tmp, SIZEOF(tmp), TranslateT("Set my status message for %s..."),
CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, proto->status, GSMDF_TCHAR));
- MENUITEMINFO mii = {0};
+ MENUITEMINFO mii = { 0 };
mii.cbSize = sizeof(mii);
mii.fMask = MIIM_ID | MIIM_TYPE;
mii.fType = MFT_STRING;
@@ -1869,7 +1869,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
if (opts.global_on_status)
ShowProtocolStatusMenu(hwnd, data, proto, p);
else
- ShowGlobalStatusMenu(hwnd, data, proto, p);
+ ShowGlobalStatusMenu(hwnd, data, p);
}
// In listening to?
else if (data->draw_listening_to && InsideRect(&p, &data->listening_to_rect) && protocols->CanSetListeningTo())
@@ -1891,7 +1891,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
// Add this proto to menu
TCHAR tmp[128];
- MENUITEMINFO mii = {0};
+ MENUITEMINFO mii = { 0 };
mir_sntprintf(tmp, SIZEOF(tmp), TranslateT("Enable listening to for %s"), proto->description);
@@ -1939,7 +1939,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
mii.cch = (int)_tcslen(tmp);
mii.wID = 3;
- if ( !proto->CanSetStatusMsg()) {
+ if (!proto->CanSetStatusMsg()) {
mii.fMask |= MIIM_STATE;
mii.fState = MFS_DISABLED;
}
@@ -2057,14 +2057,14 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
case WM_NCMOUSELEAVE:
case WM_MOUSELEAVE:
- {
- TRACKMOUSEEVENT tme;
- tme.cbSize = sizeof(TRACKMOUSEEVENT);
- tme.dwFlags = TME_HOVER;
- tme.hwndTrack = hwnd;
- tme.dwHoverTime = HOVER_DEFAULT;
- TrackMouseEvent(&tme);
- }
+ {
+ TRACKMOUSEEVENT tme;
+ tme.cbSize = sizeof(TRACKMOUSEEVENT);
+ tme.dwFlags = TME_HOVER;
+ tme.hwndTrack = hwnd;
+ tme.dwHoverTime = HOVER_DEFAULT;
+ TrackMouseEvent(&tme);
+ }
case WM_NCMOUSEMOVE:
MakeHover(hwnd, data->draw_img, &data->mouse_over_img, NULL, NULL);
MakeHover(hwnd, data->draw_nick, &data->mouse_over_nick, NULL, NULL);
@@ -2075,14 +2075,14 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
break;
case WM_MOUSEHOVER:
- {
- TRACKMOUSEEVENT tme;
- tme.cbSize = sizeof(TRACKMOUSEEVENT);
- tme.dwFlags = TME_LEAVE;
- tme.hwndTrack = hwnd;
- tme.dwHoverTime = HOVER_DEFAULT;
- TrackMouseEvent(&tme);
- }
+ {
+ TRACKMOUSEEVENT tme;
+ tme.cbSize = sizeof(TRACKMOUSEEVENT);
+ tme.dwFlags = TME_LEAVE;
+ tme.hwndTrack = hwnd;
+ tme.dwHoverTime = HOVER_DEFAULT;
+ TrackMouseEvent(&tme);
+ }
case WM_MOUSEMOVE:
proto = protocols->Get(data->protocol_number);
if (proto != NULL) {
@@ -2097,38 +2097,36 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
break;
case WM_NOTIFY:
+ {
+ LPNMHDR lpnmhdr = (LPNMHDR)lParam;
+
+ switch (lpnmhdr->code) {
+ case TTN_GETDISPINFO:
{
- LPNMHDR lpnmhdr = (LPNMHDR)lParam;
-
- int i = (int)lpnmhdr->code;
-
- switch (lpnmhdr->code) {
- case TTN_GETDISPINFO:
- {
- MyDetailsFrameData *data = (MyDetailsFrameData *)GetWindowLongPtr(hwnd, GWLP_USERDATA);
- proto = protocols->Get(data->protocol_number);
-
- LPNMTTDISPINFO lpttd = (LPNMTTDISPINFO)lpnmhdr;
- SendMessage(lpnmhdr->hwndFrom, TTM_SETMAXTIPWIDTH, 0, 300);
-
- if (lpnmhdr->hwndFrom == data->nick_tt_hwnd)
- lpttd->lpszText = proto->nickname;
- else if (lpnmhdr->hwndFrom == data->status_tt_hwnd)
- lpttd->lpszText = proto->status_name;
- else if (lpnmhdr->hwndFrom == data->away_msg_tt_hwnd)
- lpttd->lpszText = proto->status_message;
- else if (lpnmhdr->hwndFrom == data->listening_to_tt_hwnd)
- lpttd->lpszText = proto->listening_to;
- else if (lpnmhdr->hwndFrom == data->next_proto_tt_hwnd)
- lpttd->lpszText = TranslateT("Show next account");
- else if (lpnmhdr->hwndFrom == data->prev_proto_tt_hwnd)
- lpttd->lpszText = TranslateT("Show previous account");
-
- return 0;
- }
- }
+ MyDetailsFrameData *data = (MyDetailsFrameData *)GetWindowLongPtr(hwnd, GWLP_USERDATA);
+ proto = protocols->Get(data->protocol_number);
+
+ LPNMTTDISPINFO lpttd = (LPNMTTDISPINFO)lpnmhdr;
+ SendMessage(lpnmhdr->hwndFrom, TTM_SETMAXTIPWIDTH, 0, 300);
+
+ if (lpnmhdr->hwndFrom == data->nick_tt_hwnd)
+ lpttd->lpszText = proto->nickname;
+ else if (lpnmhdr->hwndFrom == data->status_tt_hwnd)
+ lpttd->lpszText = proto->status_name;
+ else if (lpnmhdr->hwndFrom == data->away_msg_tt_hwnd)
+ lpttd->lpszText = proto->status_message;
+ else if (lpnmhdr->hwndFrom == data->listening_to_tt_hwnd)
+ lpttd->lpszText = proto->listening_to;
+ else if (lpnmhdr->hwndFrom == data->next_proto_tt_hwnd)
+ lpttd->lpszText = TranslateT("Show next account");
+ else if (lpnmhdr->hwndFrom == data->prev_proto_tt_hwnd)
+ lpttd->lpszText = TranslateT("Show previous account");
+
+ return 0;
}
- break;
+ }
+ }
+ break;
case WM_DESTROY:
KillTimer(hwnd, ID_FRAME_TIMER);
@@ -2138,7 +2136,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
delete data;
break;
- // Custom Messages //////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+ // Custom Messages //////////////////////////////////////////////////////////////////////////////////////////////////////////////////
case MWM_REFRESH:
KillTimer(hwnd, ID_RECALC_TIMER);
SetTimer(hwnd, ID_RECALC_TIMER, RECALC_TIME, NULL);
@@ -2192,7 +2190,7 @@ LRESULT CALLBACK FrameWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPar
return DefWindowProc(hwnd, msg, wParam, lParam);
}
-INT_PTR ShowHideFrameFunc(WPARAM wParam, LPARAM lParam)
+INT_PTR ShowHideFrameFunc(WPARAM, LPARAM)
{
if (g_bFramesExist)
CallService(MS_CLIST_FRAMES_SHFRAME, frame_id, 0);
@@ -2209,7 +2207,7 @@ INT_PTR ShowHideFrameFunc(WPARAM wParam, LPARAM lParam)
return 0;
}
-INT_PTR ShowFrameFunc(WPARAM wParam, LPARAM lParam)
+INT_PTR ShowFrameFunc(WPARAM, LPARAM)
{
if (g_bFramesExist) {
int flags = CallService(MS_CLIST_FRAMES_GETFRAMEOPTIONS, MAKEWPARAM(FO_FLAGS, frame_id), 0);
@@ -2228,7 +2226,7 @@ INT_PTR ShowFrameFunc(WPARAM wParam, LPARAM lParam)
}
-INT_PTR HideFrameFunc(WPARAM wParam, LPARAM lParam)
+INT_PTR HideFrameFunc(WPARAM, LPARAM)
{
if (g_bFramesExist) {
int flags = CallService(MS_CLIST_FRAMES_GETFRAMEOPTIONS, MAKEWPARAM(FO_FLAGS, frame_id), 0);
@@ -2324,7 +2322,7 @@ void SetStatusMessageRefreshTime(HWND hwnd)
SetTimer(hwnd, ID_STATUSMESSAGE_TIMER, opts.refresh_status_message_timer * 1000, NULL);
}
-INT_PTR PluginCommand_ShowNextProtocol(WPARAM wParam, LPARAM lParam)
+INT_PTR PluginCommand_ShowNextProtocol(WPARAM, LPARAM)
{
if (hwnd_frame == NULL)
return -1;
@@ -2346,7 +2344,7 @@ INT_PTR PluginCommand_ShowNextProtocol(WPARAM wParam, LPARAM lParam)
return 0;
}
-INT_PTR PluginCommand_ShowPreviousProtocol(WPARAM wParam, LPARAM lParam)
+INT_PTR PluginCommand_ShowPreviousProtocol(WPARAM, LPARAM)
{
if (hwnd_frame == NULL)
return -1;
@@ -2368,14 +2366,14 @@ INT_PTR PluginCommand_ShowPreviousProtocol(WPARAM wParam, LPARAM lParam)
return 0;
}
-INT_PTR PluginCommand_ShowProtocol(WPARAM wParam, LPARAM lParam)
+INT_PTR PluginCommand_ShowProtocol(WPARAM, LPARAM lParam)
{
char *proto = (char *)lParam;
if (proto == NULL)
return -1;
int proto_num = -1;
- for (int i = 0 ; i < protocols->GetSize(); i++) {
+ for (int i = 0; i < protocols->GetSize(); i++) {
if (_stricmp(protocols->Get(i)->name, proto) == 0) {
proto_num = i;
break;
@@ -2434,7 +2432,7 @@ int SettingsChangedHook(WPARAM wParam, LPARAM lParam)
return 0;
}
-int AvatarChangedHook(WPARAM wParam, LPARAM lParam)
+int AvatarChangedHook(WPARAM wParam, LPARAM)
{
if (hwnd_frame == NULL)
return 0;
@@ -2447,7 +2445,7 @@ int AvatarChangedHook(WPARAM wParam, LPARAM lParam)
return 0;
}
-int ProtoAckHook(WPARAM wParam, LPARAM lParam)
+int ProtoAckHook(WPARAM, LPARAM lParam)
{
if (hwnd_frame == NULL)
return 0;
@@ -2477,7 +2475,7 @@ int ProtoAckHook(WPARAM wParam, LPARAM lParam)
return 0;
}
-int ListeningtoEnableStateChangedHook(WPARAM wParam, LPARAM lParam)
+int ListeningtoEnableStateChangedHook(WPARAM wParam, LPARAM)
{
if (hwnd_frame == NULL)
return 0;
diff --git a/plugins/MyDetails/src/frame.h b/plugins/MyDetails/src/frame.h
index 4ed686571f..db60847c33 100644
--- a/plugins/MyDetails/src/frame.h
+++ b/plugins/MyDetails/src/frame.h
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 2005 Ricardo Pescuma Domenecci
This is free software; you can redistribute it and/or
@@ -14,7 +14,7 @@ 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.
+Boston, MA 02111-1307, USA.
*/
diff --git a/plugins/MyDetails/src/mydetails.cpp b/plugins/MyDetails/src/mydetails.cpp
index e67a2c5b8c..1bfb2b5c85 100644
--- a/plugins/MyDetails/src/mydetails.cpp
+++ b/plugins/MyDetails/src/mydetails.cpp
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 2005 Ricardo Pescuma Domenecci
This is free software; you can redistribute it and/or
@@ -14,7 +14,7 @@ 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.
+Boston, MA 02111-1307, USA.
*/
#include "commons.h"
@@ -26,7 +26,7 @@ bool g_bAvsExist;
// Plugin data ////////////////////////////////////////////////////////////////////////////////////
-PLUGININFOEX pluginInfo={
+PLUGININFOEX pluginInfo = {
sizeof(PLUGININFOEX),
__PLUGIN_NAME,
PLUGIN_MAKE_VERSION(__MAJOR_VERSION, __MINOR_VERSION, __RELEASE_NUM, __BUILD_NUM),
@@ -37,7 +37,7 @@ PLUGININFOEX pluginInfo={
__AUTHORWEB,
UNICODE_AWARE,
// {A82BAEB3-A33C-4036-B837-7803A5B6C2AB}
- {0xa82baeb3, 0xa33c, 0x4036, {0xb8, 0x37, 0x78, 0x3, 0xa5, 0xb6, 0xc2, 0xab}}
+ { 0xa82baeb3, 0xa33c, 0x4036, { 0xb8, 0x37, 0x78, 0x3, 0xa5, 0xb6, 0xc2, 0xab } }
};
static IconItem iconList[] =
@@ -49,36 +49,36 @@ static IconItem iconList[] =
// Functions //////////////////////////////////////////////////////////////////////////////////////
-BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
+BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD, LPVOID)
{
hInst = hinstDLL;
return TRUE;
}
-extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD mirandaVersion)
+extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD)
{
return &pluginInfo;
}
// Services ///////////////////////////////////////////////////////////////////////////////////////
-static INT_PTR Menu_SetMyAvatarUI(WPARAM wParam, LPARAM lParam)
+static INT_PTR Menu_SetMyAvatarUI(WPARAM, LPARAM)
{
return PluginCommand_SetMyAvatarUI(0, 0);
}
-static INT_PTR Menu_SetMyNicknameUI(WPARAM wParam, LPARAM lParam)
+static INT_PTR Menu_SetMyNicknameUI(WPARAM, LPARAM)
{
return PluginCommand_SetMyNicknameUI(0, 0);
}
-static INT_PTR Menu_SetMyStatusMessageUI(WPARAM wParam, LPARAM lParam)
+static INT_PTR Menu_SetMyStatusMessageUI(WPARAM, LPARAM)
{
return PluginCommand_SetMyStatusMessageUI(0, 0);
}
// Hook called after init
-static int MainInit(WPARAM wparam, LPARAM lparam)
+static int MainInit(WPARAM, LPARAM)
{
g_bAvsExist = ServiceExists(MS_AV_GETMYAVATAR) != 0;
g_bFramesExist = ServiceExists(MS_CLIST_FRAMES_ADDFRAME) != 0;
@@ -128,7 +128,7 @@ static int MainInit(WPARAM wparam, LPARAM lparam)
return 0;
}
-static int MainUninit(WPARAM wParam, LPARAM lParam)
+static int MainUninit(WPARAM, LPARAM)
{
DeInitFrames();
return 0;
diff --git a/plugins/MyDetails/src/options.cpp b/plugins/MyDetails/src/options.cpp
index c159ae5cab..650120ebba 100644
--- a/plugins/MyDetails/src/options.cpp
+++ b/plugins/MyDetails/src/options.cpp
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 2005 Ricardo Pescuma Domenecci
This is free software; you can redistribute it and/or
@@ -14,7 +14,7 @@ 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.
+Boston, MA 02111-1307, USA.
*/
@@ -27,33 +27,33 @@ Options opts;
// Functions //////////////////////////////////////////////////////////////////////////////////////
static OptPageControl pageControls[] = {
- { &opts.cycle_through_protocols, CONTROL_CHECKBOX, IDC_CYCLE_THROUGH_PROTOS, "CicleThroughtProtocols", (BYTE)1 },
- { &opts.seconds_to_show_protocol, CONTROL_SPIN, IDC_CYCLE_TIME, "CicleTime", (WORD)5, IDC_CYCLE_TIME_SPIN, (WORD)1, (WORD)255 },
- { &opts.draw_show_protocol_name, CONTROL_CHECKBOX, IDC_SHOW_PROTO_NAME, "ShowProtocolName", (BYTE)1 },
- { &opts.show_protocol_cycle_button, CONTROL_CHECKBOX, IDC_SHOW_CYCLE_PROTO_BUTTON, "ShowProtocolCycleButton", (BYTE)0 },
- { &opts.draw_text_rtl, CONTROL_CHECKBOX, IDC_TEXT_RTL, "TextRTL", (BYTE)0 },
- { &opts.draw_text_align_right, CONTROL_CHECKBOX, IDC_TEXT_ALIGN_RIGHT, "TextAlignRight", (BYTE)0 },
- { &opts.replace_smileys, CONTROL_CHECKBOX, IDC_REPLACE_SMILEYS, "ReplaceSmileys", (BYTE)1 },
- { &opts.resize_smileys, CONTROL_CHECKBOX, IDC_RESIZE_SMILEYS, "ResizeSmileys", (BYTE)0 },
- { &opts.use_contact_list_smileys, CONTROL_CHECKBOX, IDC_USE_CONTACT_LIST_SMILEYS, "UseContactListSmileys", (BYTE)0 },
- { &opts.global_on_avatar, CONTROL_CHECKBOX, IDC_GLOBAL_ON_AVATAR, "GlobalOnAvatar", (BYTE)0 },
- { &opts.global_on_nickname, CONTROL_CHECKBOX, IDC_GLOBAL_ON_NICKNAME, "GlobalOnNickname", (BYTE)0 },
- { &opts.global_on_status, CONTROL_CHECKBOX, IDC_GLOBAL_ON_STATUS, "GlobalOnStatus", (BYTE)0 },
- { &opts.global_on_status_message, CONTROL_CHECKBOX, IDC_GLOBAL_ON_STATUS_MESSAGE, "GlobalOnStatusMessage", (BYTE)0 },
- { &opts.draw_avatar_allow_to_grow, CONTROL_CHECKBOX, IDC_AVATAR_ALLOW_TO_GROW, "AvatarAllowToGrow", (BYTE)0 },
- { &opts.draw_avatar_custom_size, CONTROL_CHECKBOX, IDC_AVATAR_CUSTOM_SIZE_CHK, "AvatarCustomSize", (BYTE)0 },
- { &opts.draw_avatar_custom_size_pixels, CONTROL_SPIN, IDC_AVATAR_CUSTOM_SIZE, "AvatarCustomSizePixels", (WORD)30, IDC_AVATAR_CUSTOM_SIZE_SPIN, (WORD)1, (WORD)255 },
- { &opts.draw_avatar_border, CONTROL_CHECKBOX, IDC_AVATAR_DRAW_BORDER, "AvatarDrawBorders", (BYTE)0 },
- { &opts.draw_avatar_round_corner, CONTROL_CHECKBOX, IDC_AVATAR_ROUND_CORNERS, "AvatarRoundCorners", (BYTE)1 },
- { &opts.draw_avatar_use_custom_corner_size, CONTROL_CHECKBOX, IDC_AVATAR_CUSTOM_CORNER_SIZE_CHECK, "AvatarUseCustomCornerSize", (BYTE)0 },
- { &opts.draw_avatar_custom_corner_size, CONTROL_SPIN, IDC_AVATAR_CUSTOM_CORNER_SIZE, "AvatarCustomCornerSize", (WORD)4, IDC_AVATAR_CUSTOM_CORNER_SIZE_SPIN, (WORD)1, (WORD)255 },
- { &opts.use_avatar_space_to_draw_text, CONTROL_CHECKBOX, IDC_AVATAR_USE_FREE_SPACE, "AvatarUseFreeSpaceToDrawText", (BYTE)1 },
- { &opts.resize_frame, CONTROL_CHECKBOX, IDC_RESIZE_FRAME, "ResizeFrame", (BYTE)0 },
- { &opts.use_skinning, CONTROL_CHECKBOX, IDC_USE_SKINNING, "UseSkinning", (BYTE)0 },
- { &opts.borders[RIGHT], CONTROL_SPIN, IDC_BORDER_RIGHT, "BorderRight", (WORD)8, IDC_BORDER_RIGHT_SPIN, (WORD)0, (WORD)255 },
- { &opts.borders[LEFT], CONTROL_SPIN, IDC_BORDER_LEFT, "BorderLeft", (WORD)8, IDC_BORDER_LEFT_SPIN, (WORD)0, (WORD)255 },
- { &opts.borders[TOP], CONTROL_SPIN, IDC_BORDER_TOP, "BorderTop", (WORD)8, IDC_BORDER_TOP_SPIN, (WORD)0, (WORD)255 },
- { &opts.borders[BOTTOM], CONTROL_SPIN, IDC_BORDER_BOTTOM, "BorderBottom", (WORD)8, IDC_BORDER_BOTTOM_SPIN, (WORD)0, (WORD)255 },
+ { &opts.cycle_through_protocols, CONTROL_CHECKBOX, IDC_CYCLE_THROUGH_PROTOS, "CicleThroughtProtocols", (BYTE)1 },
+ { &opts.seconds_to_show_protocol, CONTROL_SPIN, IDC_CYCLE_TIME, "CicleTime", (WORD)5, IDC_CYCLE_TIME_SPIN, (WORD)1, (WORD)255 },
+ { &opts.draw_show_protocol_name, CONTROL_CHECKBOX, IDC_SHOW_PROTO_NAME, "ShowProtocolName", (BYTE)1 },
+ { &opts.show_protocol_cycle_button, CONTROL_CHECKBOX, IDC_SHOW_CYCLE_PROTO_BUTTON, "ShowProtocolCycleButton", (BYTE)0 },
+ { &opts.draw_text_rtl, CONTROL_CHECKBOX, IDC_TEXT_RTL, "TextRTL", (BYTE)0 },
+ { &opts.draw_text_align_right, CONTROL_CHECKBOX, IDC_TEXT_ALIGN_RIGHT, "TextAlignRight", (BYTE)0 },
+ { &opts.replace_smileys, CONTROL_CHECKBOX, IDC_REPLACE_SMILEYS, "ReplaceSmileys", (BYTE)1 },
+ { &opts.resize_smileys, CONTROL_CHECKBOX, IDC_RESIZE_SMILEYS, "ResizeSmileys", (BYTE)0 },
+ { &opts.use_contact_list_smileys, CONTROL_CHECKBOX, IDC_USE_CONTACT_LIST_SMILEYS, "UseContactListSmileys", (BYTE)0 },
+ { &opts.global_on_avatar, CONTROL_CHECKBOX, IDC_GLOBAL_ON_AVATAR, "GlobalOnAvatar", (BYTE)0 },
+ { &opts.global_on_nickname, CONTROL_CHECKBOX, IDC_GLOBAL_ON_NICKNAME, "GlobalOnNickname", (BYTE)0 },
+ { &opts.global_on_status, CONTROL_CHECKBOX, IDC_GLOBAL_ON_STATUS, "GlobalOnStatus", (BYTE)0 },
+ { &opts.global_on_status_message, CONTROL_CHECKBOX, IDC_GLOBAL_ON_STATUS_MESSAGE, "GlobalOnStatusMessage", (BYTE)0 },
+ { &opts.draw_avatar_allow_to_grow, CONTROL_CHECKBOX, IDC_AVATAR_ALLOW_TO_GROW, "AvatarAllowToGrow", (BYTE)0 },
+ { &opts.draw_avatar_custom_size, CONTROL_CHECKBOX, IDC_AVATAR_CUSTOM_SIZE_CHK, "AvatarCustomSize", (BYTE)0 },
+ { &opts.draw_avatar_custom_size_pixels, CONTROL_SPIN, IDC_AVATAR_CUSTOM_SIZE, "AvatarCustomSizePixels", (WORD)30, IDC_AVATAR_CUSTOM_SIZE_SPIN, (WORD)1, (WORD)255 },
+ { &opts.draw_avatar_border, CONTROL_CHECKBOX, IDC_AVATAR_DRAW_BORDER, "AvatarDrawBorders", (BYTE)0 },
+ { &opts.draw_avatar_round_corner, CONTROL_CHECKBOX, IDC_AVATAR_ROUND_CORNERS, "AvatarRoundCorners", (BYTE)1 },
+ { &opts.draw_avatar_use_custom_corner_size, CONTROL_CHECKBOX, IDC_AVATAR_CUSTOM_CORNER_SIZE_CHECK, "AvatarUseCustomCornerSize", (BYTE)0 },
+ { &opts.draw_avatar_custom_corner_size, CONTROL_SPIN, IDC_AVATAR_CUSTOM_CORNER_SIZE, "AvatarCustomCornerSize", (WORD)4, IDC_AVATAR_CUSTOM_CORNER_SIZE_SPIN, (WORD)1, (WORD)255 },
+ { &opts.use_avatar_space_to_draw_text, CONTROL_CHECKBOX, IDC_AVATAR_USE_FREE_SPACE, "AvatarUseFreeSpaceToDrawText", (BYTE)1 },
+ { &opts.resize_frame, CONTROL_CHECKBOX, IDC_RESIZE_FRAME, "ResizeFrame", (BYTE)0 },
+ { &opts.use_skinning, CONTROL_CHECKBOX, IDC_USE_SKINNING, "UseSkinning", (BYTE)0 },
+ { &opts.borders[RIGHT], CONTROL_SPIN, IDC_BORDER_RIGHT, "BorderRight", (WORD)8, IDC_BORDER_RIGHT_SPIN, (WORD)0, (WORD)255 },
+ { &opts.borders[LEFT], CONTROL_SPIN, IDC_BORDER_LEFT, "BorderLeft", (WORD)8, IDC_BORDER_LEFT_SPIN, (WORD)0, (WORD)255 },
+ { &opts.borders[TOP], CONTROL_SPIN, IDC_BORDER_TOP, "BorderTop", (WORD)8, IDC_BORDER_TOP_SPIN, (WORD)0, (WORD)255 },
+ { &opts.borders[BOTTOM], CONTROL_SPIN, IDC_BORDER_BOTTOM, "BorderBottom", (WORD)8, IDC_BORDER_BOTTOM_SPIN, (WORD)0, (WORD)255 },
};
diff --git a/plugins/MyDetails/src/options.h b/plugins/MyDetails/src/options.h
index 8e215e80e3..5dce0b8677 100644
--- a/plugins/MyDetails/src/options.h
+++ b/plugins/MyDetails/src/options.h
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 2005 Ricardo Pescuma Domenecci
This is free software; you can redistribute it and/or
@@ -14,7 +14,7 @@ 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.
+Boston, MA 02111-1307, USA.
*/
@@ -27,7 +27,7 @@ Boston, MA 02111-1307, USA.
#define BOTTOM 2
#define RIGHT 3
-struct Options
+struct Options
{
bool cycle_through_protocols;
int seconds_to_show_protocol;
diff --git a/plugins/MyDetails/src/services.cpp b/plugins/MyDetails/src/services.cpp
index c5a1798889..80de374451 100644
--- a/plugins/MyDetails/src/services.cpp
+++ b/plugins/MyDetails/src/services.cpp
@@ -29,7 +29,7 @@ static HWND hwndSetStatusMsg;
#define WMU_SETDATA (WM_USER + 1)
-static INT_PTR CALLBACK DlgProcSetNickname(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
+static INT_PTR CALLBACK DlgProcSetNickname(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM)
{
switch (msg) {
case WM_INITDIALOG:
@@ -38,72 +38,72 @@ static INT_PTR CALLBACK DlgProcSetNickname(HWND hwndDlg, UINT msg, WPARAM wParam
return TRUE;
case WMU_SETDATA:
- {
- int proto_num = (int)wParam;
+ {
+ int proto_num = (int)wParam;
- SetWindowLongPtr(hwndDlg, GWLP_USERDATA, proto_num);
+ SetWindowLongPtr(hwndDlg, GWLP_USERDATA, proto_num);
- if (proto_num == -1) {
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)LoadSkinnedIcon(SKINICON_OTHER_MIRANDA));
+ if (proto_num == -1) {
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)LoadSkinnedIcon(SKINICON_OTHER_MIRANDA));
- // All protos have the same nick?
- if (protocols->GetSize() > 0) {
- TCHAR *nick = protocols->Get(0)->nickname;
+ // All protos have the same nick?
+ if (protocols->GetSize() > 0) {
+ TCHAR *nick = protocols->Get(0)->nickname;
- bool foundDefNick = true;
- for (int i = 1; foundDefNick && i < protocols->GetSize(); i++) {
- if (_tcsicmp(protocols->Get(i)->nickname, nick) != 0) {
- foundDefNick = false;
- break;
- }
+ bool foundDefNick = true;
+ for (int i = 1; foundDefNick && i < protocols->GetSize(); i++) {
+ if (_tcsicmp(protocols->Get(i)->nickname, nick) != 0) {
+ foundDefNick = false;
+ break;
}
-
- if (foundDefNick)
- if (_tcsicmp(protocols->default_nick, nick) != 0)
- mir_tstrcpy(protocols->default_nick, nick);
}
- SetDlgItemText(hwndDlg, IDC_NICKNAME, protocols->default_nick);
- SendDlgItemMessage(hwndDlg, IDC_NICKNAME, EM_LIMITTEXT, MS_MYDETAILS_GETMYNICKNAME_BUFFER_SIZE, 0);
+ if (foundDefNick)
+ if (_tcsicmp(protocols->default_nick, nick) != 0)
+ mir_tstrcpy(protocols->default_nick, nick);
}
- else {
- Protocol *proto = protocols->Get(proto_num);
- TCHAR tmp[128];
- mir_sntprintf(tmp, SIZEOF(tmp), TranslateT("Set my nickname for %s"), proto->description);
+ SetDlgItemText(hwndDlg, IDC_NICKNAME, protocols->default_nick);
+ SendDlgItemMessage(hwndDlg, IDC_NICKNAME, EM_LIMITTEXT, MS_MYDETAILS_GETMYNICKNAME_BUFFER_SIZE, 0);
+ }
+ else {
+ Protocol *proto = protocols->Get(proto_num);
- SetWindowText(hwndDlg, tmp);
+ TCHAR tmp[128];
+ mir_sntprintf(tmp, SIZEOF(tmp), TranslateT("Set my nickname for %s"), proto->description);
- HICON hIcon = (HICON)CallProtoService(proto->name, PS_LOADICON, PLI_PROTOCOL, 0);
- if (hIcon != NULL) {
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)hIcon);
- DestroyIcon(hIcon);
- }
+ SetWindowText(hwndDlg, tmp);
- SetDlgItemText(hwndDlg, IDC_NICKNAME, proto->nickname);
- SendDlgItemMessage(hwndDlg, IDC_NICKNAME, EM_LIMITTEXT,
- min(MS_MYDETAILS_GETMYNICKNAME_BUFFER_SIZE, proto->GetNickMaxLength()), 0);
+ HICON hIcon = (HICON)CallProtoService(proto->name, PS_LOADICON, PLI_PROTOCOL, 0);
+ if (hIcon != NULL) {
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)hIcon);
+ DestroyIcon(hIcon);
}
- return TRUE;
+ SetDlgItemText(hwndDlg, IDC_NICKNAME, proto->nickname);
+ SendDlgItemMessage(hwndDlg, IDC_NICKNAME, EM_LIMITTEXT,
+ min(MS_MYDETAILS_GETMYNICKNAME_BUFFER_SIZE, proto->GetNickMaxLength()), 0);
}
+ return TRUE;
+ }
+
case WM_COMMAND:
switch (wParam) {
case IDOK:
- {
- TCHAR tmp[MS_MYDETAILS_GETMYNICKNAME_BUFFER_SIZE];
- GetDlgItemText(hwndDlg, IDC_NICKNAME, tmp, SIZEOF(tmp));
+ {
+ TCHAR tmp[MS_MYDETAILS_GETMYNICKNAME_BUFFER_SIZE];
+ GetDlgItemText(hwndDlg, IDC_NICKNAME, tmp, SIZEOF(tmp));
- LONG_PTR proto_num = GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
- if (proto_num == -1)
- protocols->SetNicks(tmp);
- else
- protocols->Get(proto_num)->SetNick(tmp);
+ LONG_PTR proto_num = GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
+ if (proto_num == -1)
+ protocols->SetNicks(tmp);
+ else
+ protocols->Get(proto_num)->SetNick(tmp);
- DestroyWindow(hwndDlg);
- break;
- }
+ DestroyWindow(hwndDlg);
+ break;
+ }
case IDCANCEL:
DestroyWindow(hwndDlg);
break;
@@ -122,14 +122,14 @@ static INT_PTR CALLBACK DlgProcSetNickname(HWND hwndDlg, UINT msg, WPARAM wParam
return FALSE;
}
-INT_PTR PluginCommand_SetMyNicknameUI(WPARAM wParam, LPARAM lParam)
+INT_PTR PluginCommand_SetMyNicknameUI(WPARAM, LPARAM lParam)
{
char *proto = (char *)lParam;
int proto_num = -1;
if (proto != NULL) {
int i;
- for (i = 0 ; i < protocols->GetSize() ; i++) {
+ for (i = 0; i < protocols->GetSize(); i++) {
if (_stricmp(protocols->Get(i)->name, proto) == 0) {
proto_num = i;
break;
@@ -154,7 +154,7 @@ INT_PTR PluginCommand_SetMyNicknameUI(WPARAM wParam, LPARAM lParam)
SetForegroundWindow(hwndSetNickname);
SetFocus(hwndSetNickname);
- ShowWindow(hwndSetNickname, SW_SHOW);
+ ShowWindow(hwndSetNickname, SW_SHOW);
return 0;
}
@@ -208,7 +208,7 @@ INT_PTR PluginCommand_GetMyNickname(WPARAM wParam, LPARAM lParam)
// Set avatar /////////////////////////////////////////////////////////////////////////////////////
-INT_PTR PluginCommand_SetMyAvatarUI(WPARAM wParam, LPARAM lParam)
+INT_PTR PluginCommand_SetMyAvatarUI(WPARAM, LPARAM lParam)
{
char *proto = (char *)lParam;
int proto_num = -1;
@@ -323,65 +323,65 @@ static INT_PTR CALLBACK DlgProcSetStatusMessage(HWND hwndDlg, UINT msg, WPARAM w
return TRUE;
case WMU_SETDATA:
- {
- SetStatusMessageData *data = (SetStatusMessageData *)malloc(sizeof(SetStatusMessageData));
- data->status = (int)wParam;
- data->proto_num = (int)lParam;
-
- SetWindowLongPtr(hwndDlg, GWLP_USERDATA, (LONG_PTR)data);
+ {
+ SetStatusMessageData *data = (SetStatusMessageData *)malloc(sizeof(SetStatusMessageData));
+ data->status = (int)wParam;
+ data->proto_num = (int)lParam;
- if (data->proto_num >= 0) {
- Protocol *proto = protocols->Get(data->proto_num);
+ SetWindowLongPtr(hwndDlg, GWLP_USERDATA, (LONG_PTR)data);
- HICON hIcon = (HICON)CallProtoService(proto->name, PS_LOADICON, PLI_PROTOCOL, 0);
- if (hIcon != NULL) {
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)hIcon);
- DestroyIcon(hIcon);
- }
-
- TCHAR title[256];
- mir_sntprintf(title, SIZEOF(title), TranslateT("Set my status message for %s"), proto->description);
- SetWindowText(hwndDlg, title);
+ if (data->proto_num >= 0) {
+ Protocol *proto = protocols->Get(data->proto_num);
- SetDlgItemText(hwndDlg, IDC_STATUSMESSAGE, proto->GetStatusMsg());
+ HICON hIcon = (HICON)CallProtoService(proto->name, PS_LOADICON, PLI_PROTOCOL, 0);
+ if (hIcon != NULL) {
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)hIcon);
+ DestroyIcon(hIcon);
}
- else if (data->status != 0) {
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)LoadSkinnedProtoIcon(NULL,data->status));
- TCHAR title[256];
- mir_sntprintf(title, SIZEOF(title), TranslateT("Set my status message for %s"),
- CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, data->status, GSMDF_TCHAR));
- SetWindowText(hwndDlg, title);
+ TCHAR title[256];
+ mir_sntprintf(title, SIZEOF(title), TranslateT("Set my status message for %s"), proto->description);
+ SetWindowText(hwndDlg, title);
- SetDlgItemText(hwndDlg, IDC_STATUSMESSAGE, protocols->GetDefaultStatusMsg(data->status));
- }
- else {
- SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)LoadSkinnedIcon(SKINICON_OTHER_MIRANDA));
+ SetDlgItemText(hwndDlg, IDC_STATUSMESSAGE, proto->GetStatusMsg());
+ }
+ else if (data->status != 0) {
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)LoadSkinnedProtoIcon(NULL, data->status));
- SetDlgItemText(hwndDlg, IDC_STATUSMESSAGE, protocols->GetDefaultStatusMsg());
- }
+ TCHAR title[256];
+ mir_sntprintf(title, SIZEOF(title), TranslateT("Set my status message for %s"),
+ CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, data->status, GSMDF_TCHAR));
+ SetWindowText(hwndDlg, title);
- return TRUE;
+ SetDlgItemText(hwndDlg, IDC_STATUSMESSAGE, protocols->GetDefaultStatusMsg(data->status));
}
+ else {
+ SendMessage(hwndDlg, WM_SETICON, ICON_BIG, (LPARAM)LoadSkinnedIcon(SKINICON_OTHER_MIRANDA));
+
+ SetDlgItemText(hwndDlg, IDC_STATUSMESSAGE, protocols->GetDefaultStatusMsg());
+ }
+
+ return TRUE;
+ }
case WM_COMMAND:
switch (wParam) {
case IDOK:
- {
- TCHAR tmp[MS_MYDETAILS_GETMYSTATUSMESSAGE_BUFFER_SIZE];
- GetDlgItemText(hwndDlg, IDC_STATUSMESSAGE, tmp, SIZEOF(tmp));
+ {
+ TCHAR tmp[MS_MYDETAILS_GETMYSTATUSMESSAGE_BUFFER_SIZE];
+ GetDlgItemText(hwndDlg, IDC_STATUSMESSAGE, tmp, SIZEOF(tmp));
- SetStatusMessageData *data = (SetStatusMessageData *)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
+ SetStatusMessageData *data = (SetStatusMessageData *)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
- if (data->proto_num >= 0)
- protocols->Get(data->proto_num)->SetStatusMsg(tmp);
- else if (data->status == 0)
- protocols->SetStatusMsgs(tmp);
- else
- protocols->SetStatusMsgs(data->status, tmp);
+ if (data->proto_num >= 0)
+ protocols->Get(data->proto_num)->SetStatusMsg(tmp);
+ else if (data->status == 0)
+ protocols->SetStatusMsgs(tmp);
+ else
+ protocols->SetStatusMsgs(data->status, tmp);
- DestroyWindow(hwndDlg);
- }
- break;
+ DestroyWindow(hwndDlg);
+ }
+ break;
case IDCANCEL:
DestroyWindow(hwndDlg);
@@ -452,7 +452,7 @@ INT_PTR PluginCommand_SetMyStatusMessageUI(WPARAM wParam, LPARAM lParam)
SetForegroundWindow(hwndSetStatusMsg);
SetFocus(hwndSetStatusMsg);
- ShowWindow(hwndSetStatusMsg, SW_SHOW);
+ ShowWindow(hwndSetStatusMsg, SW_SHOW);
return 0;
}
@@ -461,7 +461,7 @@ INT_PTR PluginCommand_SetMyStatusMessageUI(WPARAM wParam, LPARAM lParam)
}
-INT_PTR PluginCommand_CycleThroughtProtocols(WPARAM wParam, LPARAM lParam)
+INT_PTR PluginCommand_CycleThroughtProtocols(WPARAM wParam, LPARAM)
{
db_set_b(NULL, "MyDetails", "CicleThroughtProtocols", (BYTE)wParam);
diff --git a/plugins/Utils/mir_dblists.cpp b/plugins/Utils/mir_dblists.cpp
index 83917d0c7c..eb2a46dd81 100644
--- a/plugins/Utils/mir_dblists.cpp
+++ b/plugins/Utils/mir_dblists.cpp
@@ -26,55 +26,55 @@ Boston, MA 02111-1307, USA.
#include <m_system.h>
-void List_DestroyFreeContents( SortedList* p_list )
+void List_DestroyFreeContents(SortedList* p_list)
{
- if ( p_list == NULL )
+ if (p_list == NULL)
return;
- if ( p_list->items != NULL )
+ if (p_list->items != NULL)
{
int i;
- for ( i = 0 ; i < p_list->realCount ; i++ )
+ for (i = 0; i < p_list->realCount; i++)
{
- if ( p_list->items[i] != NULL )
+ if (p_list->items[i] != NULL)
{
- mir_free( p_list->items[i] );
+ mir_free(p_list->items[i]);
}
}
}
- List_Destroy( p_list );
+ List_Destroy(p_list);
}
-int List_Append( SortedList* p_list, void* p_value )
+int List_Append(SortedList* p_list, void* p_value)
{
- return List_Insert( p_list, p_value, p_list->realCount );
+ return List_Insert(p_list, p_value, p_list->realCount);
}
-int List_InsertOrdered( SortedList* p_list, void* p_value )
+int List_InsertOrdered(SortedList* p_list, void* p_value)
{
int index;
- List_GetIndex( p_list, p_value, &index );
- List_Insert( p_list, p_value, index );
+ List_GetIndex(p_list, p_value, &index);
+ List_Insert(p_list, p_value, index);
return index;
}
-int List_RemoveByValue( SortedList* p_list, void* p_value )
+int List_RemoveByValue(SortedList* p_list, void* p_value)
{
int ret = 0;
- if ( p_list->items != NULL )
+ if (p_list->items != NULL)
{
int i;
- for ( i = p_list->realCount - 1 ; i >= 0 ; i-- )
+ for (i = p_list->realCount - 1; i >= 0; i--)
{
- if ( p_list->items[ i ] == p_value )
- ret += List_Remove( p_list, i );
+ if (p_list->items[i] == p_value)
+ ret += List_Remove(p_list, i);
}
}
@@ -82,19 +82,19 @@ int List_RemoveByValue( SortedList* p_list, void* p_value )
}
-int List_RemoveByValueFreeContents( SortedList* p_list, void* p_value )
+int List_RemoveByValueFreeContents(SortedList* p_list, void* p_value)
{
int ret = 0;
- if ( p_list->items != NULL )
+ if (p_list->items != NULL)
{
int i;
- for ( i = p_list->realCount - 1 ; i >= 0 ; i-- )
+ for (i = p_list->realCount - 1; i >= 0; i--)
{
- if ( p_list->items[ i ] == p_value )
+ if (p_list->items[i] == p_value)
{
- mir_free( p_list->items[ i ] );
- ret += List_Remove( p_list, i );
+ mir_free(p_list->items[i]);
+ ret += List_Remove(p_list, i);
}
}
}
@@ -103,36 +103,36 @@ int List_RemoveByValueFreeContents( SortedList* p_list, void* p_value )
}
-void List_Push( SortedList* p_list, void* p_value )
+void List_Push(SortedList* p_list, void* p_value)
{
- List_Insert( p_list, p_value, p_list->realCount );
+ List_Insert(p_list, p_value, p_list->realCount);
}
-void* List_Pop( SortedList* p_list )
+void* List_Pop(SortedList* p_list)
{
void *ret;
- if ( p_list->realCount <= 0 )
+ if (p_list->realCount <= 0)
return NULL;
- ret = p_list->items[ p_list->realCount - 1 ];
- List_Remove( p_list, p_list->realCount - 1 );
+ ret = p_list->items[p_list->realCount - 1];
+ List_Remove(p_list, p_list->realCount - 1);
return ret;
}
-void* List_Peek( SortedList* p_list )
+void* List_Peek(SortedList* p_list)
{
- if ( p_list->realCount <= 0 )
+ if (p_list->realCount <= 0)
return NULL;
- return p_list->items[ p_list->realCount - 1 ];
+ return p_list->items[p_list->realCount - 1];
}
-BOOL List_HasItens( SortedList* p_list )
+BOOL List_HasItens(SortedList* p_list)
{
return p_list->realCount > 0;
} \ No newline at end of file
diff --git a/plugins/Utils/mir_dblists.h b/plugins/Utils/mir_dblists.h
index f9a5092327..23b93b6a39 100644
--- a/plugins/Utils/mir_dblists.h
+++ b/plugins/Utils/mir_dblists.h
@@ -27,19 +27,19 @@ Boston, MA 02111-1307, USA.
// Need to be called on ME_SYSTEM_MODULESLOADED
-BOOL List_HasItens( SortedList* p_list );
+BOOL List_HasItens(SortedList* p_list);
-void List_DestroyFreeContents( SortedList* );
-int List_RemoveByValue( SortedList*, void* );
-int List_RemoveByValueFreeContents( SortedList*, void* );
+void List_DestroyFreeContents(SortedList*);
+int List_RemoveByValue(SortedList*, void*);
+int List_RemoveByValueFreeContents(SortedList*, void*);
-int List_Append( SortedList*, void* );
-int List_InsertOrdered( SortedList*, void* );
+int List_Append(SortedList*, void*);
+int List_InsertOrdered(SortedList*, void*);
// Theese work on the end of the list
-void List_Push( SortedList* p_list, void* p_value );
-void* List_Pop( SortedList* p_list );
-void* List_Peek( SortedList* p_list );
+void List_Push(SortedList* p_list, void* p_value);
+void* List_Pop(SortedList* p_list);
+void* List_Peek(SortedList* p_list);
diff --git a/plugins/Utils/mir_options.cpp b/plugins/Utils/mir_options.cpp
index 5f0d6748cc..12b2d5466d 100644
--- a/plugins/Utils/mir_options.cpp
+++ b/plugins/Utils/mir_options.cpp
@@ -14,7 +14,7 @@ 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.
+Boston, MA 02111-1307, USA.
*/
#include <windows.h>
@@ -190,51 +190,51 @@ INT_PTR CALLBACK SaveOptsDlgProc(OptPageControl *controls, int controlsSize, cha
break;
case CONTROL_PROTOCOL_LIST:
- {
- // Fill list view
- HWND hwndProtocols = GetDlgItem(hwndDlg, ctrl->nID);
- LVCOLUMN lvc;
- LVITEM lvi;
-
- ListView_SetExtendedListViewStyle(hwndProtocols, LVS_EX_CHECKBOXES);
+ {
+ // Fill list view
+ HWND hwndProtocols = GetDlgItem(hwndDlg, ctrl->nID);
+ LVCOLUMN lvc;
+ LVITEM lvi;
- memset(&lvc, 0, sizeof(lvc));
- lvc.mask = LVCF_FMT;
- lvc.fmt = LVCFMT_IMAGE | LVCFMT_LEFT;
- ListView_InsertColumn(hwndProtocols, 0, &lvc);
+ ListView_SetExtendedListViewStyle(hwndProtocols, LVS_EX_CHECKBOXES);
- memset(&lvi, 0, sizeof(lvi));
- lvi.mask = LVIF_TEXT | LVIF_PARAM;
- lvi.iSubItem = 0;
- lvi.iItem = 1000;
+ memset(&lvc, 0, sizeof(lvc));
+ lvc.mask = LVCF_FMT;
+ lvc.fmt = LVCFMT_IMAGE | LVCFMT_LEFT;
+ ListView_InsertColumn(hwndProtocols, 0, &lvc);
- int count;
- PROTOACCOUNT **protos;
- ProtoEnumAccounts(&count, &protos);
+ memset(&lvi, 0, sizeof(lvi));
+ lvi.mask = LVIF_TEXT | LVIF_PARAM;
+ lvi.iSubItem = 0;
+ lvi.iItem = 1000;
- for (int i = 0; i < count; i++) {
- PROTOACCOUNT *p = protos[i];
- if (p->szModuleName == NULL || p->szModuleName[0] == '\0')
- continue;
+ int count;
+ PROTOACCOUNT **protos;
+ ProtoEnumAccounts(&count, &protos);
- if (ctrl->allowProtocol != NULL && !ctrl->allowProtocol(p->szModuleName))
- continue;
+ for (int i = 0; i < count; i++) {
+ PROTOACCOUNT *p = protos[i];
+ if (p->szModuleName == NULL || p->szModuleName[0] == '\0')
+ continue;
- char *setting = (char *)mir_alloc(128 * sizeof(char));
- mir_snprintf(setting, 128, ctrl->setting, p->szModuleName);
+ if (ctrl->allowProtocol != NULL && !ctrl->allowProtocol(p->szModuleName))
+ continue;
- BOOL show = (BOOL)db_get_b(NULL, module, setting, ctrl->dwDefValue);
+ char *setting = (char *)mir_alloc(128 * sizeof(char));
+ mir_snprintf(setting, 128, ctrl->setting, p->szModuleName);
- lvi.lParam = (LPARAM)setting;
- lvi.pszText = p->tszAccountName;
- lvi.iItem = ListView_InsertItem(hwndProtocols, &lvi);
- ListView_SetItemState(hwndProtocols, lvi.iItem, INDEXTOSTATEIMAGEMASK(show ? 2 : 1), LVIS_STATEIMAGEMASK);
- }
+ BOOL show = (BOOL)db_get_b(NULL, module, setting, ctrl->dwDefValue);
- ListView_SetColumnWidth(hwndProtocols, 0, LVSCW_AUTOSIZE);
- ListView_Arrange(hwndProtocols, LVA_ALIGNLEFT | LVA_ALIGNTOP);
+ lvi.lParam = (LPARAM)setting;
+ lvi.pszText = p->tszAccountName;
+ lvi.iItem = ListView_InsertItem(hwndProtocols, &lvi);
+ ListView_SetItemState(hwndProtocols, lvi.iItem, INDEXTOSTATEIMAGEMASK(show ? 2 : 1), LVIS_STATEIMAGEMASK);
}
- break;
+
+ ListView_SetColumnWidth(hwndProtocols, 0, LVSCW_AUTOSIZE);
+ ListView_Arrange(hwndProtocols, LVA_ALIGNLEFT | LVA_ALIGNTOP);
+ }
+ break;
case CONTROL_TEXT:
SetDlgItemText(hwndDlg, ctrl->nID, MyDBGetContactSettingTString(NULL, module, ctrl->setting, tmp, 1024, ctrl->tszDefValue == NULL ? NULL : TranslateTS(ctrl->tszDefValue)));
@@ -308,122 +308,122 @@ INT_PTR CALLBACK SaveOptsDlgProc(OptPageControl *controls, int controlsSize, cha
break;
case WM_NOTIFY:
- {
- LPNMHDR lpnmhdr = (LPNMHDR)lParam;
- if (lpnmhdr->idFrom == 0 && lpnmhdr->code == PSN_APPLY) {
- for (int i = 0; i < controlsSize; i++) {
- OptPageControl *ctrl = &controls[i];
+ {
+ LPNMHDR lpnmhdr = (LPNMHDR)lParam;
+ if (lpnmhdr->idFrom == 0 && lpnmhdr->code == PSN_APPLY) {
+ for (int i = 0; i < controlsSize; i++) {
+ OptPageControl *ctrl = &controls[i];
- if (GetDlgItem(hwndDlg, ctrl->nID) == NULL)
- continue;
+ if (GetDlgItem(hwndDlg, ctrl->nID) == NULL)
+ continue;
- switch (ctrl->type) {
- case CONTROL_CHECKBOX:
- db_set_b(NULL, module, ctrl->setting, (BYTE)IsDlgButtonChecked(hwndDlg, ctrl->nID));
- break;
+ switch (ctrl->type) {
+ case CONTROL_CHECKBOX:
+ db_set_b(NULL, module, ctrl->setting, (BYTE)IsDlgButtonChecked(hwndDlg, ctrl->nID));
+ break;
- case CONTROL_SPIN:
- db_set_w(NULL, module, ctrl->setting, (WORD)SendDlgItemMessage(hwndDlg, ctrl->nIDSpin, UDM_GETPOS, 0, 0));
- break;
+ case CONTROL_SPIN:
+ db_set_w(NULL, module, ctrl->setting, (WORD)SendDlgItemMessage(hwndDlg, ctrl->nIDSpin, UDM_GETPOS, 0, 0));
+ break;
- case CONTROL_COLOR:
- db_set_dw(NULL, module, ctrl->setting, (DWORD)SendDlgItemMessage(hwndDlg, ctrl->nID, CPM_GETCOLOUR, 0, 0));
- break;
+ case CONTROL_COLOR:
+ db_set_dw(NULL, module, ctrl->setting, (DWORD)SendDlgItemMessage(hwndDlg, ctrl->nID, CPM_GETCOLOUR, 0, 0));
+ break;
- case CONTROL_RADIO:
- if (IsDlgButtonChecked(hwndDlg, ctrl->nID))
- db_set_w(NULL, module, ctrl->setting, (BYTE)ctrl->value);
- break;
+ case CONTROL_RADIO:
+ if (IsDlgButtonChecked(hwndDlg, ctrl->nID))
+ db_set_w(NULL, module, ctrl->setting, (BYTE)ctrl->value);
+ break;
- case CONTROL_COMBO:
- db_set_w(NULL, module, ctrl->setting, (WORD)SendDlgItemMessage(hwndDlg, ctrl->nID, CB_GETCURSEL, 0, 0));
- break;
+ case CONTROL_COMBO:
+ db_set_w(NULL, module, ctrl->setting, (WORD)SendDlgItemMessage(hwndDlg, ctrl->nID, CB_GETCURSEL, 0, 0));
+ break;
- case CONTROL_PROTOCOL_LIST:
- {
- LVITEM lvi = { 0 };
- HWND hwndProtocols = GetDlgItem(hwndDlg, ctrl->nID);
- int i;
+ case CONTROL_PROTOCOL_LIST:
+ {
+ LVITEM lvi = { 0 };
+ HWND hwndProtocols = GetDlgItem(hwndDlg, ctrl->nID);
+ int i;
- lvi.mask = (UINT)LVIF_PARAM;
+ lvi.mask = (UINT)LVIF_PARAM;
- for (i = 0; i < ListView_GetItemCount(hwndProtocols); i++) {
- lvi.iItem = i;
- ListView_GetItem(hwndProtocols, &lvi);
+ for (i = 0; i < ListView_GetItemCount(hwndProtocols); i++) {
+ lvi.iItem = i;
+ ListView_GetItem(hwndProtocols, &lvi);
- char *setting = (char *)lvi.lParam;
- db_set_b(NULL, module, setting, (BYTE)ListView_GetCheckState(hwndProtocols, i));
- }
+ char *setting = (char *)lvi.lParam;
+ db_set_b(NULL, module, setting, (BYTE)ListView_GetCheckState(hwndProtocols, i));
}
- break;
+ }
+ break;
- case CONTROL_TEXT:
- {
- TCHAR tmp[1024];
- GetDlgItemText(hwndDlg, ctrl->nID, tmp, SIZEOF(tmp));
- db_set_ts(NULL, module, ctrl->setting, tmp);
- }
- break;
-
- case CONTROL_INT:
- {
- BOOL trans;
- int val = GetDlgItemInt(hwndDlg, ctrl->nID, &trans, ctrl->min <= 0);
- if (!trans)
- val = ctrl->dwDefValue;
- if (ctrl->max != 0)
- val = min(val, ctrl->max);
- if (ctrl->min != 0)
- val = max(val, ctrl->min);
- db_set_dw(NULL, module, ctrl->setting, val);
- }
- break;
- case CONTROL_FILE:
- {
- TCHAR tmp[1024];
- GetDlgItemText(hwndDlg, ctrl->nID, tmp, SIZEOF(tmp));
- TCHAR rel[1024];
- PathToRelative(rel, 1024, tmp);
- db_set_ts(NULL, module, ctrl->setting, rel);
- }
- break;
- case CONTROL_COMBO_TEXT:
- {
- TCHAR tmp[1024];
- GetDlgItemText(hwndDlg, ctrl->nID, tmp, SIZEOF(tmp));
- db_set_ts(NULL, module, ctrl->setting, tmp);
- }
- break;
- case CONTROL_COMBO_ITEMDATA:
- {
- int sel = SendDlgItemMessage(hwndDlg, ctrl->nID, CB_GETCURSEL, 0, 0);
- db_set_ts(NULL, module, ctrl->setting, (TCHAR *)SendDlgItemMessage(hwndDlg, ctrl->nID, CB_GETITEMDATA, (WPARAM)sel, 0));
- }
- break;
- }
+ case CONTROL_TEXT:
+ {
+ TCHAR tmp[1024];
+ GetDlgItemText(hwndDlg, ctrl->nID, tmp, SIZEOF(tmp));
+ db_set_ts(NULL, module, ctrl->setting, tmp);
+ }
+ break;
- LoadOpt(ctrl, module);
+ case CONTROL_INT:
+ {
+ BOOL trans;
+ int val = GetDlgItemInt(hwndDlg, ctrl->nID, &trans, ctrl->min <= 0);
+ if (!trans)
+ val = ctrl->dwDefValue;
+ if (ctrl->max != 0)
+ val = min(val, ctrl->max);
+ if (ctrl->min != 0)
+ val = max(val, ctrl->min);
+ db_set_dw(NULL, module, ctrl->setting, val);
+ }
+ break;
+ case CONTROL_FILE:
+ {
+ TCHAR tmp[1024];
+ GetDlgItemText(hwndDlg, ctrl->nID, tmp, SIZEOF(tmp));
+ TCHAR rel[1024];
+ PathToRelative(rel, 1024, tmp);
+ db_set_ts(NULL, module, ctrl->setting, rel);
+ }
+ break;
+ case CONTROL_COMBO_TEXT:
+ {
+ TCHAR tmp[1024];
+ GetDlgItemText(hwndDlg, ctrl->nID, tmp, SIZEOF(tmp));
+ db_set_ts(NULL, module, ctrl->setting, tmp);
+ }
+ break;
+ case CONTROL_COMBO_ITEMDATA:
+ {
+ int sel = SendDlgItemMessage(hwndDlg, ctrl->nID, CB_GETCURSEL, 0, 0);
+ db_set_ts(NULL, module, ctrl->setting, (TCHAR *)SendDlgItemMessage(hwndDlg, ctrl->nID, CB_GETITEMDATA, (WPARAM)sel, 0));
+ }
+ break;
}
- return TRUE;
+ LoadOpt(ctrl, module);
}
- else if (lpnmhdr->idFrom != 0 && lpnmhdr->code == LVN_ITEMCHANGED) {
- // Changed for protocols
- for (int i = 0; i < controlsSize; i++) {
- OptPageControl *ctrl = &controls[i];
- if (ctrl->type == CONTROL_PROTOCOL_LIST && ctrl->nID == lpnmhdr->idFrom) {
- NMLISTVIEW *nmlv = (NMLISTVIEW *)lParam;
+ return TRUE;
+ }
+ else if (lpnmhdr->idFrom != 0 && lpnmhdr->code == LVN_ITEMCHANGED) {
+ // Changed for protocols
+ for (int i = 0; i < controlsSize; i++) {
+ OptPageControl *ctrl = &controls[i];
- if (IsWindowVisible(GetDlgItem(hwndDlg, ctrl->nID)) && ((nmlv->uNewState ^ nmlv->uOldState) & LVIS_STATEIMAGEMASK))
- SendMessage(GetParent(hwndDlg), PSM_CHANGED, 0, 0);
+ if (ctrl->type == CONTROL_PROTOCOL_LIST && ctrl->nID == lpnmhdr->idFrom) {
+ NMLISTVIEW *nmlv = (NMLISTVIEW *)lParam;
- break;
- }
+ if (IsWindowVisible(GetDlgItem(hwndDlg, ctrl->nID)) && ((nmlv->uNewState ^ nmlv->uOldState) & LVIS_STATEIMAGEMASK))
+ SendMessage(GetParent(hwndDlg), PSM_CHANGED, 0, 0);
+
+ break;
}
}
}
- break;
+ }
+ break;
case WM_DESTROY:
for (int i = 0; i < controlsSize; i++) {
diff --git a/plugins/Utils/mir_options.h b/plugins/Utils/mir_options.h
index 5a41c3c0dc..842d154e3a 100644
--- a/plugins/Utils/mir_options.h
+++ b/plugins/Utils/mir_options.h
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 2005-2009 Ricardo Pescuma Domenecci
This is free software; you can redistribute it and/or
@@ -14,7 +14,7 @@ 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.
+Boston, MA 02111-1307, USA.
*/
@@ -37,7 +37,7 @@ Boston, MA 02111-1307, USA.
#define CONTROL_INT 10 // Stored as DWORD
-typedef BOOL (* FPAllowProtocol) (const char *proto);
+typedef BOOL(*FPAllowProtocol) (const char *proto);
typedef struct {
void *var;
diff --git a/plugins/Utils/mir_smileys.cpp b/plugins/Utils/mir_smileys.cpp
index fc321c0a56..ab5f666668 100644
--- a/plugins/Utils/mir_smileys.cpp
+++ b/plugins/Utils/mir_smileys.cpp
@@ -52,11 +52,11 @@ typedef struct
};
};
}
- TextPiece;
+TextPiece;
SortedList * ReplaceSmileys(const TCHAR *text, int text_size, const char *protocol, int *max_smiley_height);
void DrawTextSmiley(HDC hdcMem, RECT free_rc, const TCHAR *szText, int len, SortedList *plText, UINT uTextFormat, int max_smiley_height);
-void DestroySmileyList( SortedList* p_list );
+void DestroySmileyList(SortedList* p_list);
SIZE GetTextSize(HDC hdcMem, const TCHAR *szText, SortedList *plText, UINT uTextFormat, int max_smiley_height);
// Functions
@@ -80,7 +80,7 @@ int InitContactListSmileys()
SmileysParseInfo Smileys_PreParse(const TCHAR* lpString, int nCount, const char *protocol)
{
- SmileysParseInfo info = (SmileysParseInfo) mir_calloc(sizeof(_SmileysParseInfo));
+ SmileysParseInfo info = (SmileysParseInfo)mir_calloc(sizeof(_SmileysParseInfo));
info->pieces = ReplaceSmileys(lpString, nCount, protocol, &info->max_height);
@@ -112,7 +112,7 @@ int skin_DrawText(HDC hDC, LPCTSTR lpString, int nCount, LPRECT lpRect, UINT uFo
}
int skin_DrawIconEx(HDC hdc, int xLeft, int yTop, HICON hIcon, int cxWidth, int cyWidth,
- UINT istepIfAniCur, HBRUSH hbrFlickerFreeDraw, UINT diFlags)
+ UINT istepIfAniCur, HBRUSH hbrFlickerFreeDraw, UINT diFlags)
{
if (ServiceExists(MS_SKINENG_DRAWICONEXFIX))
return mod_DrawIconEx_helper(hdc, xLeft, yTop, hIcon, cxWidth, cyWidth, istepIfAniCur, hbrFlickerFreeDraw, diFlags);
@@ -158,7 +158,7 @@ int Smileys_DrawText(HDC hDC, LPCTSTR lpString, int nCount, LPRECT lpRect, UINT
else
{
// Clipping rgn
- HRGN oldRgn = CreateRectRgn(0,0,1,1);
+ HRGN oldRgn = CreateRectRgn(0, 0, 1, 1);
if (GetClipRgn(hDC, oldRgn) != 1)
{
DeleteObject(oldRgn);
@@ -217,7 +217,7 @@ SIZE GetTextSize(HDC hdcMem, const TCHAR *szText, SortedList *plText, UINT uText
text_size.cx = 0;
}
else {
- RECT text_rc = {0, 0, 0x7FFFFFFF, 0x7FFFFFFF};
+ RECT text_rc = { 0, 0, 0x7FFFFFFF, 0x7FFFFFFF };
// Always need cy...
DrawText(hdcMem, szText, -1, &text_rc, DT_CALCRECT | uTextFormat);
@@ -226,17 +226,17 @@ SIZE GetTextSize(HDC hdcMem, const TCHAR *szText, SortedList *plText, UINT uText
if (plText == NULL)
text_size.cx = text_rc.right - text_rc.left;
else {
- if ( !(uTextFormat & DT_RESIZE_SMILEYS))
+ if (!(uTextFormat & DT_RESIZE_SMILEYS))
text_size.cy = max(text_size.cy, max_smiley_height);
text_size.cx = 0;
// See each item of list
for (int i = 0; i < plText->realCount; i++) {
- TextPiece *piece = (TextPiece *) plText->items[i];
+ TextPiece *piece = (TextPiece *)plText->items[i];
if (piece->type == TEXT_PIECE_TYPE_TEXT) {
- RECT text_rc = {0, 0, 0x7FFFFFFF, 0x7FFFFFFF};
+ RECT text_rc = { 0, 0, 0x7FFFFFFF, 0x7FFFFFFF };
DrawText(hdcMem, &szText[piece->start_pos], piece->len, &text_rc, DT_CALCRECT | uTextFormat);
text_size.cx = text_size.cx + text_rc.right - text_rc.left;
@@ -245,7 +245,7 @@ SIZE GetTextSize(HDC hdcMem, const TCHAR *szText, SortedList *plText, UINT uText
double factor;
if ((uTextFormat & DT_RESIZE_SMILEYS) && piece->smiley_height > text_size.cy)
- factor = text_size.cy / (double) piece->smiley_height;
+ factor = text_size.cy / (double)piece->smiley_height;
else
factor = 1;
@@ -293,7 +293,7 @@ void DrawTextSmiley(HDC hdcMem, RECT free_rc, const TCHAR *szText, int len, Sort
// Draw text and smileys
for (; i < plText->realCount && i >= 0 && pos_x < free_rc.right - free_rc.left && len > 0; i += (uTextFormat & DT_RTLREADING ? -1 : 1))
{
- TextPiece *piece = (TextPiece *) plText->items[i];
+ TextPiece *piece = (TextPiece *)plText->items[i];
RECT text_rc = free_rc;
if (uTextFormat & DT_RTLREADING)
@@ -330,7 +330,7 @@ void DrawTextSmiley(HDC hdcMem, RECT free_rc, const TCHAR *szText, int len, Sort
if ((uTextFormat & DT_RESIZE_SMILEYS) && piece->smiley_height > row_height)
{
- factor = row_height / (double) piece->smiley_height;
+ factor = row_height / (double)piece->smiley_height;
}
else
{
@@ -338,7 +338,7 @@ void DrawTextSmiley(HDC hdcMem, RECT free_rc, const TCHAR *szText, int len, Sort
}
if (uTextFormat & DT_RTLREADING)
- text_rc.left = max(text_rc.right - (LONG) (piece->smiley_width * factor), text_rc.left);
+ text_rc.left = max(text_rc.right - (LONG)(piece->smiley_width * factor), text_rc.left);
if ((LONG)(piece->smiley_width * factor) <= text_rc.right - text_rc.left)
{
@@ -361,19 +361,19 @@ void DrawTextSmiley(HDC hdcMem, RECT free_rc, const TCHAR *szText, int len, Sort
}
-void DestroySmileyList( SortedList* p_list )
+void DestroySmileyList(SortedList* p_list)
{
- if ( p_list == NULL )
+ if (p_list == NULL)
return;
- if ( p_list->items != NULL )
+ if (p_list->items != NULL)
{
int i;
- for ( i = 0 ; i < p_list->realCount ; i++ )
+ for (i = 0; i < p_list->realCount; i++)
{
- TextPiece *piece = (TextPiece *) p_list->items[i];
+ TextPiece *piece = (TextPiece *)p_list->items[i];
- if ( piece != NULL )
+ if (piece != NULL)
{
if (piece->type == TEXT_PIECE_TYPE_SMILEY)
DestroyIcon(piece->smiley);
@@ -383,7 +383,7 @@ void DestroySmileyList( SortedList* p_list )
}
}
- List_Destroy( p_list );
+ List_Destroy(p_list);
}
@@ -401,7 +401,7 @@ SortedList * ReplaceSmileys(const TCHAR *text, int text_size, const char *protoc
sp.Protocolname = protocol;
sp.str = (TCHAR*)text;
sp.flag = SAFL_TCHAR;
- SMADD_BATCHPARSERES *spres = (SMADD_BATCHPARSERES *) CallService(MS_SMILEYADD_BATCHPARSE, 0, (LPARAM)&sp);
+ SMADD_BATCHPARSERES *spres = (SMADD_BATCHPARSERES *)CallService(MS_SMILEYADD_BATCHPARSE, 0, (LPARAM)&sp);
if (spres == NULL)
// Did not find a simley
return NULL;
@@ -410,7 +410,7 @@ SortedList * ReplaceSmileys(const TCHAR *text, int text_size, const char *protoc
SortedList *plText = List_Create(0, 10);
const TCHAR *next_text_pos = text;
- const TCHAR *last_text_pos = _tcsninc(text, text_size);
+ const TCHAR *last_text_pos = _tcsninc(text, text_size);
for (unsigned int i = 0; i < sp.numSmileys; i++) {
TCHAR* start = _tcsninc(text, spres[i].startChar);
@@ -419,7 +419,7 @@ SortedList * ReplaceSmileys(const TCHAR *text, int text_size, const char *protoc
if (spres[i].hIcon != NULL) { // For defective smileypacks
// Add text
if (start > next_text_pos) {
- TextPiece *piece = (TextPiece *) mir_calloc(sizeof(TextPiece));
+ TextPiece *piece = (TextPiece *)mir_calloc(sizeof(TextPiece));
piece->type = TEXT_PIECE_TYPE_TEXT;
piece->start_pos = next_text_pos - text;
@@ -432,7 +432,7 @@ SortedList * ReplaceSmileys(const TCHAR *text, int text_size, const char *protoc
{
BITMAP bm;
ICONINFO icon;
- TextPiece *piece = (TextPiece *) mir_calloc(sizeof(TextPiece));
+ TextPiece *piece = (TextPiece *)mir_calloc(sizeof(TextPiece));
piece->type = TEXT_PIECE_TYPE_SMILEY;
piece->len = end - start;
@@ -442,7 +442,7 @@ SortedList * ReplaceSmileys(const TCHAR *text, int text_size, const char *protoc
piece->smiley_height = 16;
if (GetIconInfo(piece->smiley, &icon))
{
- if (GetObject(icon.hbmColor,sizeof(BITMAP),&bm))
+ if (GetObject(icon.hbmColor, sizeof(BITMAP), &bm))
{
piece->smiley_width = bm.bmWidth;
piece->smiley_height = bm.bmHeight;
@@ -464,7 +464,7 @@ SortedList * ReplaceSmileys(const TCHAR *text, int text_size, const char *protoc
// Add rest of text
if (last_text_pos > next_text_pos)
{
- TextPiece *piece = (TextPiece *) mir_calloc(sizeof(TextPiece));
+ TextPiece *piece = (TextPiece *)mir_calloc(sizeof(TextPiece));
piece->type = TEXT_PIECE_TYPE_TEXT;
piece->start_pos = next_text_pos - text;
diff --git a/plugins/Utils/mir_smileys.h b/plugins/Utils/mir_smileys.h
index 8b3b2a504b..fe130bbc6a 100644
--- a/plugins/Utils/mir_smileys.h
+++ b/plugins/Utils/mir_smileys.h
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 2005 Ricardo Pescuma Domenecci
This is free software; you can redistribute it and/or
@@ -14,7 +14,7 @@ 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.
+Boston, MA 02111-1307, USA.
*/
@@ -41,7 +41,7 @@ typedef struct _SmileysParseInfo
{
SortedList *pieces;
int max_height;
-} * SmileysParseInfo;
+} *SmileysParseInfo;
SmileysParseInfo Smileys_PreParse(LPCSTR lpString, int nCount, const char *protocol);
void Smileys_FreeParse(SmileysParseInfo parseInfo);