Nikolay Sivov : dwrite: Remove GetFaceNames() hack for simulated case.
Alexandre Julliard
julliard at wine.codeweavers.com
Thu Sep 3 07:34:27 CDT 2015
Module: wine
Branch: master
Commit: 7581b11d2b01fd01c4f56778218e98bafa74358f
URL: http://source.winehq.org/git/wine.git/?a=commit;h=7581b11d2b01fd01c4f56778218e98bafa74358f
Author: Nikolay Sivov <nsivov at codeweavers.com>
Date: Thu Sep 3 07:36:25 2015 +0300
dwrite: Remove GetFaceNames() hack for simulated case.
---
dlls/dwrite/font.c | 40 +---------------------------------------
1 file changed, 1 insertion(+), 39 deletions(-)
diff --git a/dlls/dwrite/font.c b/dlls/dwrite/font.c
index 3daab79..0970f3a 100644
--- a/dlls/dwrite/font.c
+++ b/dlls/dwrite/font.c
@@ -1240,47 +1240,9 @@ static BOOL WINAPI dwritefont_IsSymbolFont(IDWriteFont2 *iface)
static HRESULT WINAPI dwritefont_GetFaceNames(IDWriteFont2 *iface, IDWriteLocalizedStrings **names)
{
- static const WCHAR boldobliqueW[] = {'B','o','l','d',' ','O','b','l','i','q','u','e',0};
-
struct dwrite_font *This = impl_from_IDWriteFont2(iface);
- IDWriteLocalizedStrings *strings;
- const WCHAR *name;
- HRESULT hr;
-
TRACE("(%p)->(%p)\n", This, names);
-
- *names = NULL;
-
- if (This->data->simulations == DWRITE_FONT_SIMULATIONS_NONE)
- return clone_localizedstring(This->data->names, names);
-
- switch (This->data->simulations) {
- case DWRITE_FONT_SIMULATIONS_BOLD|DWRITE_FONT_SIMULATIONS_OBLIQUE:
- name = boldobliqueW;
- break;
- case DWRITE_FONT_SIMULATIONS_BOLD:
- name = boldW;
- break;
- case DWRITE_FONT_SIMULATIONS_OBLIQUE:
- name = obliqueW;
- break;
- default:
- ERR("unknown simulations %d\n", This->data->simulations);
- return E_FAIL;
- }
-
- hr = create_localizedstrings(&strings);
- if (FAILED(hr)) return hr;
-
- hr = add_localizedstring(strings, enusW, name);
- if (FAILED(hr)) {
- IDWriteLocalizedStrings_Release(strings);
- return hr;
- }
-
- *names = strings;
-
- return S_OK;
+ return clone_localizedstring(This->data->names, names);
}
static HRESULT WINAPI dwritefont_GetInformationalStrings(IDWriteFont2 *iface,
More information about the wine-cvs
mailing list