summaryrefslogtreecommitdiff
path: root/protocols/Weather
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-06-25 15:05:30 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-06-25 15:05:30 +0000
commited1449fa491e90197b78b64b52c70910f1736dd7 (patch)
tree208788e9ee24ec2bcd90a4f4d7a166a534baa53e /protocols/Weather
parent2a06d7b1dbe99233e078819c78956e346175b420 (diff)
dynamic fonts' options translation
git-svn-id: http://svn.miranda-ng.org/main/trunk@633 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Weather')
-rw-r--r--protocols/Weather/weather_mwin.cpp15
1 files changed, 5 insertions, 10 deletions
diff --git a/protocols/Weather/weather_mwin.cpp b/protocols/Weather/weather_mwin.cpp
index 4c43cc2afe..4e4fd125bd 100644
--- a/protocols/Weather/weather_mwin.cpp
+++ b/protocols/Weather/weather_mwin.cpp
@@ -373,19 +373,16 @@ void InitMwin(void)
}
{
- FontID fontid = {0};
ColourID colourid = {0};
- HDC hdc;
-
colourid.cbSize = sizeof(ColourID);
strcpy(colourid.dbSettingsGroup, WEATHERPROTONAME);
strcpy(colourid.setting, "ColorMwinFrame");
strcpy(colourid.name, "Frame Background");
strcpy(colourid.group, WEATHERPROTONAME);
colourid.defcolour = GetSysColor(COLOR_3DFACE);
+ ColourRegister(&colourid);
- CallService(MS_COLOUR_REGISTER, (WPARAM)&colourid, 0);
-
+ FontID fontid = {0};
fontid.cbSize = sizeof(FontID);
fontid.flags = FIDF_ALLOWREREGISTER | FIDF_DEFAULTVALID;
strcpy(fontid.dbSettingsGroup, WEATHERPROTONAME);
@@ -393,7 +390,7 @@ void InitMwin(void)
strcpy(fontid.name, "Frame Font");
strcpy(fontid.prefix, "fnt0");
- hdc = GetDC(NULL);
+ HDC hdc = GetDC(NULL);
fontid.deffontsettings.size = -13;
ReleaseDC(0, hdc);
@@ -401,14 +398,12 @@ void InitMwin(void)
strcpy(fontid.deffontsettings.szFace, "Verdana");
strcpy(fontid.backgroundGroup, WEATHERPROTONAME);
strcpy(fontid.backgroundName, "Frame Background");
-
- CallService(MS_FONT_REGISTER, (WPARAM)&fontid, 0);
+ FontRegister(&fontid);
fontid.deffontsettings.style = DBFONTF_BOLD;
strcpy(fontid.name, "Frame Title Font");
strcpy(fontid.prefix, "fnt1");
-
- CallService(MS_FONT_REGISTER, (WPARAM)&fontid, 0);
+ FontRegister(&fontid);
}
hContact = (HANDLE)CallService(MS_DB_CONTACT_FINDFIRST, 0, 0);