diff options
author | Tobias Weimer <wishmaster51@googlemail.com> | 2014-04-21 17:39:45 +0000 |
---|---|---|
committer | Tobias Weimer <wishmaster51@googlemail.com> | 2014-04-21 17:39:45 +0000 |
commit | c13392f8596e858110dc4c61fbdf1d41e47cc8a9 (patch) | |
tree | 7eb5a3790ce4069393addff302d24306a496a04e /plugins/Popup/src/font.cpp | |
parent | d1851afba0e105ab2b0c7e8ad5e72a4dfbc5dd71 (diff) |
- Added lParam to POPUPCLASS
- Removed MS_POPUP_ISSECONDLINESHOWN
- Support for mutating popups in Facebook
git-svn-id: http://svn.miranda-ng.org/main/trunk@9021 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Popup/src/font.cpp')
-rw-r--r-- | plugins/Popup/src/font.cpp | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/plugins/Popup/src/font.cpp b/plugins/Popup/src/font.cpp index fca4c1cf12..df6e1640ca 100644 --- a/plugins/Popup/src/font.cpp +++ b/plugins/Popup/src/font.cpp @@ -34,35 +34,35 @@ void InitFonts() { fid.flags = FIDF_DEFAULTVALID;
fid.deffontsettings.charset = DEFAULT_CHARSET;
fid.deffontsettings.size = -11;
- lstrcpy(fid.backgroundGroup,_T(PU_FNT_AND_COLOR));
- lstrcpy(fid.backgroundName,_T(PU_COL_BACK_NAME));
- lstrcpy(fid.deffontsettings.szFace, _T("Tahoma"));
+ lstrcpyn(fid.backgroundGroup,_T(PU_FNT_AND_COLOR), SIZEOF(fid.backgroundGroup));
+ lstrcpyn(fid.backgroundName,PU_COL_BACK_NAME, SIZEOF(fid.backgroundName));
+ lstrcpyn(fid.deffontsettings.szFace, _T("Tahoma"), SIZEOF(fid.deffontsettings.szFace));
- lstrcpy(fid.name, _T(PU_FNT_NAME_TITLE));
+ lstrcpyn(fid.name, PU_FNT_NAME_TITLE, SIZEOF(fid.name));
mir_snprintf(fid.prefix, sizeof(fid.prefix), PU_FNT_PREFIX, PU_FNT_NAME_TITLE);
fid.deffontsettings.style = DBFONTF_BOLD;
fid.deffontsettings.colour = RGB(0,0,0);
FontRegisterT(&fid);
- lstrcpy(fid.name, _T(PU_FNT_NAME_CLOCK));
+ lstrcpyn(fid.name, PU_FNT_NAME_CLOCK, SIZEOF(fid.name));
mir_snprintf(fid.prefix, sizeof(fid.prefix), PU_FNT_PREFIX, PU_FNT_NAME_CLOCK);
//fid.deffontsettings.style = DBFONTF_BOLD;
//fid.deffontsettings.colour = RGB(0,0,0);
FontRegisterT(&fid);
- lstrcpy(fid.name, _T(PU_FNT_NAME_TEXT));
+ lstrcpyn(fid.name, PU_FNT_NAME_TEXT, SIZEOF(fid.name));
mir_snprintf(fid.prefix, sizeof(fid.prefix), PU_FNT_PREFIX, PU_FNT_NAME_TEXT);
fid.deffontsettings.style = 0;
//fid.deffontsettings.colour = RGB(0,0,0);
FontRegisterT(&fid);
- lstrcpy(fid.name, _T("Action"));
+ lstrcpyn(fid.name, _T("Action"), SIZEOF(fid.name));
mir_snprintf(fid.prefix, sizeof(fid.prefix), PU_FNT_PREFIX, "Action");
//fid.deffontsettings.style = 0;
fid.deffontsettings.colour = RGB(0,0,255);
FontRegisterT(&fid);
- lstrcpy(fid.name, LPGENT("Hovered Action"));
+ lstrcpyn(fid.name, LPGENT("Hovered Action"), SIZEOF(fid.name));
mir_snprintf(fid.prefix, sizeof(fid.prefix), PU_FNT_PREFIX, "Hovered Action");
fid.deffontsettings.style = DBFONTF_UNDERLINE;
//fid.deffontsettings.colour = RGB(0,0,255);
@@ -70,16 +70,16 @@ void InitFonts() { ColourIDT cid = {0};
cid.cbSize = sizeof(ColourIDT);
- lstrcpy(cid.group, _T(PU_FNT_AND_COLOR));
- strcpy(cid.dbSettingsGroup, PU_FNT_AND_COLOR_DB);
+ lstrcpyn(cid.group, _T(PU_FNT_AND_COLOR), SIZEOF(cid.group));
+ strncpy(cid.dbSettingsGroup, PU_FNT_AND_COLOR_DB, SIZEOF(cid.dbSettingsGroup));
- lstrcpy(cid.name, _T(PU_COL_BACK_NAME));
- strcpy(cid.setting, PU_COL_BACK_SETTING);
+ lstrcpyn(cid.name, PU_COL_BACK_NAME, SIZEOF(cid.name));
+ strncpy(cid.setting, PU_COL_BACK_SETTING, SIZEOF(cid.setting));
cid.defcolour = SETTING_BACKCOLOUR_DEFAULT;
ColourRegisterT(&cid);
- lstrcpy(cid.name, _T(PU_COL_AVAT_NAME));
- strcpy(cid.setting, PU_COL_AVAT_SETTING);
+ lstrcpyn(cid.name, PU_COL_AVAT_NAME, SIZEOF(cid.name));
+ strncpy(cid.setting, PU_COL_AVAT_SETTING, SIZEOF(cid.setting));
cid.defcolour = SETTING_TEXTCOLOUR_DEFAULT;
ColourRegisterT(&cid);
@@ -98,36 +98,36 @@ void ReloadFonts() LOGFONT lf = {0};
FontIDT fid = {0};
fid.cbSize = sizeof(FontIDT);
- lstrcpy(fid.group, _T(PU_FNT_AND_COLOR));
+ lstrcpyn(fid.group, _T(PU_FNT_AND_COLOR),SIZEOF(fid.name));
- lstrcpy(fid.name, _T(PU_FNT_NAME_TITLE));
+ lstrcpyn(fid.name, PU_FNT_NAME_TITLE,SIZEOF(fid.name));
fonts.clTitle = (COLORREF)CallService(MS_FONT_GETT, (WPARAM)&fid, (LPARAM)&lf);
fonts.title = CreateFontIndirect(&lf);
- lstrcpy(fid.name, LPGENT("Clock"));
+ lstrcpyn(fid.name, LPGENT("Clock"),SIZEOF(fid.name));
fonts.clClock = (COLORREF)CallService(MS_FONT_GETT, (WPARAM)&fid, (LPARAM)&lf);
fonts.clock = CreateFontIndirect(&lf);
- lstrcpy(fid.name, _T(PU_FNT_NAME_TEXT));
+ lstrcpyn(fid.name, PU_FNT_NAME_TEXT,SIZEOF(fid.name));
fonts.clText = (COLORREF)CallService(MS_FONT_GETT, (WPARAM)&fid, (LPARAM)&lf);
fonts.text = CreateFontIndirect(&lf);
- lstrcpy(fid.name, _T("Action"));
+ lstrcpyn(fid.name, LPGENT("Action"),SIZEOF(fid.name));
fonts.clAction = (COLORREF)CallService(MS_FONT_GETT, (WPARAM)&fid, (LPARAM)&lf);
fonts.action = CreateFontIndirect(&lf);
- lstrcpy(fid.name, LPGENT("Hovered Action"));
+ lstrcpyn(fid.name, LPGENT("Hovered Action"),SIZEOF(fid.name));
fonts.clActionHover = (COLORREF)CallService(MS_FONT_GETT, (WPARAM)&fid, (LPARAM)&lf);
fonts.actionHover = CreateFontIndirect(&lf);
ColourIDT cid = {0};
cid.cbSize = sizeof(ColourIDT);
- lstrcpy(cid.group, _T(PU_FNT_AND_COLOR));
- lstrcpy(cid.name, _T(PU_COL_BACK_NAME));
+ lstrcpyn(cid.group, _T(PU_FNT_AND_COLOR),SIZEOF(cid.group));
+ lstrcpyn(cid.name, PU_COL_BACK_NAME,SIZEOF(cid.name));
fonts.clBack = (COLORREF)CallService(MS_COLOUR_GETT, (WPARAM)&cid, (LPARAM)&lf);
- lstrcpy(cid.group, _T(PU_FNT_AND_COLOR));
- lstrcpy(cid.name, _T(PU_COL_AVAT_NAME));
+ lstrcpyn(cid.group, _T(PU_FNT_AND_COLOR),SIZEOF(cid.group));
+ lstrcpyn(cid.name, PU_COL_AVAT_NAME,SIZEOF(cid.name));
fonts.clAvatarBorder = (COLORREF)CallService(MS_COLOUR_GETT, (WPARAM)&cid, (LPARAM)&lf);
//update class popupps(only temp at this point, must rework)
|