summaryrefslogtreecommitdiff
path: root/plugins/TabSRMM
diff options
context:
space:
mode:
authorKirill Volinsky <mataes2007@gmail.com>2013-04-06 18:14:22 +0000
committerKirill Volinsky <mataes2007@gmail.com>2013-04-06 18:14:22 +0000
commit2b6daaf2b6282c18722bb33285093fe1e551a676 (patch)
tree08ce5eb1dd7ef8c69155e523b487e30ca843ec11 /plugins/TabSRMM
parent118997e456852a1e20ef3146298a87409cdbd85a (diff)
small cleanup
git-svn-id: http://svn.miranda-ng.org/main/trunk@4345 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/TabSRMM')
-rw-r--r--plugins/TabSRMM/src/chat/options.cpp42
1 files changed, 20 insertions, 22 deletions
diff --git a/plugins/TabSRMM/src/chat/options.cpp b/plugins/TabSRMM/src/chat/options.cpp
index 6011d8a194..5ee517ae48 100644
--- a/plugins/TabSRMM/src/chat/options.cpp
+++ b/plugins/TabSRMM/src/chat/options.cpp
@@ -787,16 +787,16 @@ void RegisterFontServiceFonts() {
strncpy(fid.dbSettingsGroup, FONTMODULE, SIZEOF(fid.dbSettingsGroup));
strncpy(cid.dbSettingsGroup, FONTMODULE, SIZEOF(fid.dbSettingsGroup));
- for (int i=0; i < (sizeof(_clrs) / sizeof(_clrs[0])); i++) {
+ for (int i = 0; i < SIZEOF(_clrs); i++) {
cid.order = _clrs[i].order;
_tcsncpy(cid.group, _clrs[i].tszGroup, SIZEOF(fid.group));
- _tcsncpy(cid.name, _clrs[i].tszName, SIZEOF(cid.name));
- strncpy(cid.setting, _clrs[i].szSetting, SIZEOF(cid.setting));
- if (_clrs[i].def & 0xff000000)
- cid.defcolour = GetSysColor(_clrs[i].def & 0x000000ff);
- else
- cid.defcolour = _clrs[i].def;
- ColourRegisterT(&cid);
+ _tcsncpy(cid.name, _clrs[i].tszName, SIZEOF(cid.name));
+ strncpy(cid.setting, _clrs[i].szSetting, SIZEOF(cid.setting));
+ if (_clrs[i].def & 0xff000000)
+ cid.defcolour = GetSysColor(_clrs[i].def & 0x000000ff);
+ else
+ cid.defcolour = _clrs[i].def;
+ ColourRegisterT(&cid);
}
strncpy(cid.dbSettingsGroup, SRMSGMOD_T, SIZEOF(fid.dbSettingsGroup));
@@ -804,17 +804,17 @@ void RegisterFontServiceFonts() {
/*
* text and background colors for tabs
*/
- for (int i=0; i < (sizeof(_tabclrs) / sizeof(_tabclrs[0])); i++) {
+ for (int i = 0; i < SIZEOF(_tabclrs); i++) {
cid.order = _tabclrs[i].order;
_tcsncpy(cid.group, _tabclrs[i].tszGroup, SIZEOF(fid.group));
- _tcsncpy(cid.name, _tabclrs[i].tszName, SIZEOF(cid.name));
- strncpy(cid.setting, _tabclrs[i].szSetting, SIZEOF(cid.setting));
- if (_tabclrs[i].def & 0xff000000)
- cid.defcolour = GetSysColor(_tabclrs[i].def & 0x000000ff);
- else
- cid.defcolour = _tabclrs[i].def;
-
- ColourRegisterT(&cid);
+ _tcsncpy(cid.name, _tabclrs[i].tszName, SIZEOF(cid.name));
+ strncpy(cid.setting, _tabclrs[i].szSetting, SIZEOF(cid.setting));
+ if (_tabclrs[i].def & 0xff000000)
+ cid.defcolour = GetSysColor(_tabclrs[i].def & 0x000000ff);
+ else
+ cid.defcolour = _tabclrs[i].def;
+
+ ColourRegisterT(&cid);
}
}
@@ -981,9 +981,9 @@ INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM
ofn.lpstrDefExt = _T("log");
GetOpenFileName(&ofn);
break;
- }
+ }
- case IDC_FONTCHOOSE: {
+ case IDC_FONTCHOOSE: {
TCHAR tszDirectory[MAX_PATH];
LPITEMIDLIST idList;
LPMALLOC psMalloc;
@@ -998,7 +998,6 @@ INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM
bi.lpfn = BrowseCallbackProc;
bi.lParam = (LPARAM)tszDirectory;
-
idList = SHBrowseForFolder(&bi);
if (idList) {
const TCHAR *szUserDir = M->getUserDir();
@@ -1011,7 +1010,7 @@ INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM
psMalloc->Release();
}
break;
- }
+ }
case IDC_LOGGING:
if (PluginConfig.m_chat_enabled) {
@@ -1402,7 +1401,6 @@ int OptionsInit(void)
return 0;
}
-
int OptionsUnInit(void)
{
FreeGlobalSettings();