Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(964)

Side by Side Diff: third_party/WebKit/WebCore/platform/graphics/win/SimpleFontDataWin.cpp

Issue 21184: WebKit merge 40722:40785 (part 1) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 11 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 SelectObject(hdc, oldFont); 84 SelectObject(hdc, oldFont);
85 ReleaseDC(0, hdc); 85 ReleaseDC(0, hdc);
86 86
87 return; 87 return;
88 } 88 }
89 89
90 void SimpleFontData::platformCommonDestroy() 90 void SimpleFontData::platformCommonDestroy()
91 { 91 {
92 // We don't hash this on Win32, so it's effectively owned by us. 92 // We don't hash this on Win32, so it's effectively owned by us.
93 delete m_smallCapsFontData; 93 delete m_smallCapsFontData;
94 m_smallCapsFontData = 0;
94 95
95 ScriptFreeCache(&m_scriptCache); 96 ScriptFreeCache(&m_scriptCache);
96 delete m_scriptFontProperties; 97 delete m_scriptFontProperties;
97 } 98 }
98 99
99 SimpleFontData* SimpleFontData::smallCapsFontData(const FontDescription& fontDes cription) const 100 SimpleFontData* SimpleFontData::smallCapsFontData(const FontDescription& fontDes cription) const
100 { 101 {
101 if (!m_smallCapsFontData) { 102 if (!m_smallCapsFontData) {
102 float smallCapsHeight = cSmallCapsFontSizeMultiplier * m_font.size(); 103 float smallCapsHeight = cSmallCapsFontSizeMultiplier * m_font.size();
103 if (isCustomFont()) { 104 if (isCustomFont()) {
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
197 SelectObject(dc, m_font.hfont()); 198 SelectObject(dc, m_font.hfont());
198 ScriptGetFontProperties(dc, scriptCache(), m_scriptFontProperties); 199 ScriptGetFontProperties(dc, scriptCache(), m_scriptFontProperties);
199 RestoreDC(dc, -1); 200 RestoreDC(dc, -1);
200 ReleaseDC(0, dc); 201 ReleaseDC(0, dc);
201 } 202 }
202 } 203 }
203 return m_scriptFontProperties; 204 return m_scriptFontProperties;
204 } 205 }
205 206
206 } 207 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698