winemac: Don't accidentally clear Cocoa window style mask bits.

This commit is contained in:
Ken Thomases 2013-10-08 02:21:27 -05:00 committed by Alexandre Julliard
parent dd59ab26fe
commit bdcb8138fe
1 changed files with 3 additions and 1 deletions

View File

@ -569,8 +569,10 @@ - (void) adjustFeaturesForState
- (void) setWindowFeatures:(const struct macdrv_window_features*)wf - (void) setWindowFeatures:(const struct macdrv_window_features*)wf
{ {
static const NSUInteger usedStyles = NSTitledWindowMask | NSClosableWindowMask | NSMiniaturizableWindowMask |
NSResizableWindowMask | NSUtilityWindowMask | NSBorderlessWindowMask;
NSUInteger currentStyle = [self styleMask]; NSUInteger currentStyle = [self styleMask];
NSUInteger newStyle = style_mask_for_features(wf); NSUInteger newStyle = style_mask_for_features(wf) | (currentStyle & ~usedStyles);
if (newStyle != currentStyle) if (newStyle != currentStyle)
{ {