Commit dfc850c7 authored by Vitaly Lipatov's avatar Vitaly Lipatov

commit 12.5.1 upon wine-1.6

parent 556e2c89
......@@ -1306,10 +1306,12 @@ static inline WORD get_mac_code_page( const FT_SfntName *name )
static int match_name_table_language( const FT_SfntName *name, LANGID lang )
{
LANGID name_lang;
int res = 0;
switch (name->platform_id)
{
case TT_PLATFORM_MICROSOFT:
res += 5; /* prefer the Microsoft name */
switch (name->encoding_id)
{
case TT_MS_ID_UNICODE_CS:
......@@ -1326,6 +1328,7 @@ static int match_name_table_language( const FT_SfntName *name, LANGID lang )
name_lang = mac_langid_table[name->language_id];
break;
case TT_PLATFORM_APPLE_UNICODE:
res += 2; /* prefer Unicode encodings */
switch (name->encoding_id)
{
case TT_APPLE_ID_DEFAULT:
......@@ -1341,10 +1344,10 @@ static int match_name_table_language( const FT_SfntName *name, LANGID lang )
default:
return 0;
}
if (name_lang == lang) return 3;
if (PRIMARYLANGID( name_lang ) == PRIMARYLANGID( lang )) return 2;
if (name_lang == MAKELANGID( LANG_ENGLISH, SUBLANG_DEFAULT )) return 1;
return 0;
if (name_lang == lang) res += 30;
else if (PRIMARYLANGID( name_lang ) == PRIMARYLANGID( lang )) res += 20;
else if (name_lang == MAKELANGID( LANG_ENGLISH, SUBLANG_DEFAULT )) res += 10;
return res;
}
static WCHAR *copy_name_table_string( const FT_SfntName *name )
......
......@@ -116,6 +116,12 @@ typedef struct
LONG ref;
} cache_entry;
static const tid_t schema_cache_se_tids[] = {
IXMLDOMSchemaCollection_tid,
IXMLDOMSchemaCollection2_tid,
NULL_tid
};
/* datatypes lookup stuff
* generated with help from gperf */
#define DT_MIN_STR_LEN 2
......@@ -1105,6 +1111,10 @@ static HRESULT WINAPI schema_cache_QueryInterface(IXMLDOMSchemaCollection2* ifac
{
return *ppvObject ? S_OK : E_NOINTERFACE;
}
else if(IsEqualGUID( riid, &IID_ISupportErrorInfo ))
{
return node_create_supporterrorinfo(schema_cache_se_tids, ppvObject);
}
else
{
FIXME("interface %s not implemented\n", debugstr_guid(riid));
......
......@@ -10712,6 +10712,7 @@ static void test_supporterrorinfo(void)
&IID_IXMLDOMDocument2, &IID_IXMLDOMDocument3 };
const supporterror_t *ptr = supporterror_test;
ISupportErrorInfo *errorinfo, *info2;
IXMLDOMSchemaCollection *schemacache;
IXMLDOMNamedNodeMap *map, *map2;
IXMLDOMDocument *doc;
IXMLDOMElement *elem;
......@@ -10838,6 +10839,20 @@ static void test_supporterrorinfo(void)
IXMLDOMElement_Release(elem);
IXMLDOMDocument_Release(doc);
/* IXMLDOMSchemaCollection */
hr = CoCreateInstance(&CLSID_XMLSchemaCache, NULL, CLSCTX_INPROC_SERVER, &IID_IXMLDOMSchemaCollection, (void**)&schemacache);
ok(hr == S_OK, "failed to create schema collection, 0x%08x\n", hr);
hr = IXMLDOMSchemaCollection_QueryInterface(schemacache, &IID_ISupportErrorInfo, (void**)&errorinfo);
ok(hr == S_OK, "got 0x%08x\n", hr);
hr = ISupportErrorInfo_InterfaceSupportsErrorInfo(errorinfo, &IID_IXMLDOMSchemaCollection);
ok(hr == S_OK, "got 0x%08x\n", hr);
ISupportErrorInfo_Release(errorinfo);
IXMLDOMSchemaCollection_Release(schemacache);
free_bstrs();
}
......
......@@ -4922,7 +4922,7 @@ HRESULT CDECL wined3d_get_device_caps(const struct wined3d *wined3d, UINT adapte
caps->MaxUserClipPlanes = vertex_caps.max_user_clip_planes;
caps->MaxActiveLights = vertex_caps.max_active_lights;
if (cxgames_hacks.max_vertex_blend_matrices && vertex_caps.max_vertex_blend_matrices == 1)
if (cxgames_hacks.max_vertex_blend_matrices && vertex_caps.max_vertex_blend_matrices <= 1)
caps->MaxVertexBlendMatrices = cxgames_hacks.max_vertex_blend_matrices;
else
caps->MaxVertexBlendMatrices = vertex_caps.max_vertex_blend_matrices;
......
......@@ -1026,67 +1026,11 @@ static inline void fix_generic_modifiers_by_device(NSUInteger* modifiers)
- (void) makeFocused:(BOOL)activate
{
WineApplicationController* controller = [WineApplicationController sharedController];
NSArray* screens;
WineWindow* front;
BOOL wasVisible = [self isVisible];
[controller transformProcessToForeground];
/* If a borderless window is offscreen, orderFront: won't move
it onscreen like it would for a titled window. Do that ourselves. */
screens = [NSScreen screens];
if (!([self styleMask] & NSTitledWindowMask) && ![self isOrderedIn] &&
!frame_intersects_screens([self frame], screens))
{
NSScreen* primaryScreen = [screens objectAtIndex:0];
NSRect frame = [primaryScreen frame];
[self setFrameTopLeftPoint:NSMakePoint(NSMinX(frame), NSMaxY(frame))];
frame = [self constrainFrameRect:[self frame] toScreen:primaryScreen];
[self setFrame:frame display:YES];
[self updateColorSpace];
}
if (activate)
[NSApp activateIgnoringOtherApps:YES];
NSDisableScreenUpdates();
if (latentParentWindow)
{
if ([latentParentWindow level] > [self level])
[self setLevel:[latentParentWindow level]];
[latentParentWindow addChildWindow:self ordered:NSWindowAbove];
self.latentParentWindow = nil;
}
front = [controller frontWineWindow];
if (front && [self level] < [front level])
[self setLevel:[front level]];
[self orderFront:nil];
if (!wasVisible && fullscreen && [self isOnActiveSpace])
[controller updateFullscreenWindows];
[controller adjustWindowLevels];
if (pendingMinimize)
{
ignore_windowMiniaturize = TRUE;
[self miniaturize:nil];
pendingMinimize = FALSE;
}
NSEnableScreenUpdates();
[self orderBelow:nil orAbove:nil activate:activate];
causing_becomeKeyWindow = TRUE;
[self makeKeyWindow];
causing_becomeKeyWindow = FALSE;
if (![self isExcludedFromWindowsMenu])
[NSApp addWindowsItem:self title:[self title] filename:NO];
/* Cocoa may adjust the frame when the window is ordered onto the screen.
Generate a frame-changed event just in case. The back end will ignore
it if nothing actually changed. */
[self windowDidResize:nil];
}
- (void) postKey:(uint16_t)keyCode
......
......@@ -911,12 +911,14 @@ void macdrv_mouse_scroll(HWND hwnd, const macdrv_event *event)
event->mouse_scroll.x, event->mouse_scroll.y,
event->mouse_scroll.time_ms, (GetTickCount() - event->mouse_scroll.time_ms));
send_mouse_input(hwnd, event->window, MOUSEEVENTF_WHEEL | MOUSEEVENTF_ABSOLUTE | MOUSEEVENTF_MOVE,
event->mouse_scroll.x, event->mouse_scroll.y,
event->mouse_scroll.y_scroll, FALSE, event->mouse_scroll.time_ms);
send_mouse_input(hwnd, event->window, MOUSEEVENTF_HWHEEL | MOUSEEVENTF_ABSOLUTE | MOUSEEVENTF_MOVE,
event->mouse_scroll.x, event->mouse_scroll.y,
event->mouse_scroll.x_scroll, FALSE, event->mouse_scroll.time_ms);
if (event->mouse_scroll.y_scroll)
send_mouse_input(hwnd, event->window, MOUSEEVENTF_WHEEL | MOUSEEVENTF_ABSOLUTE | MOUSEEVENTF_MOVE,
event->mouse_scroll.x, event->mouse_scroll.y,
event->mouse_scroll.y_scroll, FALSE, event->mouse_scroll.time_ms);
if (event->mouse_scroll.x_scroll)
send_mouse_input(hwnd, event->window, MOUSEEVENTF_HWHEEL | MOUSEEVENTF_ABSOLUTE | MOUSEEVENTF_MOVE,
event->mouse_scroll.x, event->mouse_scroll.y,
event->mouse_scroll.x_scroll, FALSE, event->mouse_scroll.time_ms);
}
......
No preview for this file type
......@@ -758,6 +758,9 @@ static void apple_override_bundle_name( int argc, char *argv[] )
new_bundle_name = argv[1];
if ((p = strrchr(new_bundle_name, '\\'))) new_bundle_name = p + 1;
if ((p = strrchr(new_bundle_name, '/'))) new_bundle_name = p + 1;
if (strspn(new_bundle_name, "0123456789abcdefABCDEF") == 32 &&
new_bundle_name[32] == '.')
new_bundle_name += 33;
if ((p = strrchr(new_bundle_name, '.')) && p != new_bundle_name)
new_bundle_name_len = p - new_bundle_name;
else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment