Fix premature DC release
svn path=/branches/gtk-2-10/; revision=17621
This commit is contained in:
@@ -466,12 +466,15 @@ sys_font_to_pango_font (XpThemeClass klazz, XpThemeFont type, char *buf,
|
||||
{
|
||||
pt_size = -MulDiv (lf.lfHeight, 72,
|
||||
GetDeviceCaps (hDC, LOGPIXELSY));
|
||||
ReleaseDC (hwnd, hDC);
|
||||
}
|
||||
else
|
||||
pt_size = 10;
|
||||
|
||||
font = get_family_name (&lf, hDC);
|
||||
|
||||
if (hDC)
|
||||
ReleaseDC (hwnd, hDC);
|
||||
|
||||
if(!(font && *font))
|
||||
return NULL;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user