gdk/quartz: Fix mixup in attributes usage creating window implementation
First, attributes can be NULL (which is always the case when calling gdk_window_ensure_native) so do not unconditionally dereference it. Then the window_type should be taken directly from the GdkWindow as in other backends (such as the X11 one for example). https://bugzilla.gnome.org/show_bug.cgi?id=744942
This commit is contained in:
		@ -818,7 +818,7 @@ _gdk_quartz_display_create_window_impl (GdkDisplay    *display,
 | 
			
		||||
 | 
			
		||||
  impl->view = NULL;
 | 
			
		||||
 | 
			
		||||
  switch (attributes->window_type)
 | 
			
		||||
  switch (window->window_type)
 | 
			
		||||
    {
 | 
			
		||||
    case GDK_WINDOW_TOPLEVEL:
 | 
			
		||||
    case GDK_WINDOW_TEMP:
 | 
			
		||||
@ -846,8 +846,9 @@ _gdk_quartz_display_create_window_impl (GdkDisplay    *display,
 | 
			
		||||
                                   window->width,
 | 
			
		||||
                                   window->height);
 | 
			
		||||
 | 
			
		||||
        if (attributes->window_type == GDK_WINDOW_TEMP ||
 | 
			
		||||
            attributes->type_hint == GDK_WINDOW_TYPE_HINT_SPLASHSCREEN)
 | 
			
		||||
        if (window->window_type == GDK_WINDOW_TEMP ||
 | 
			
		||||
            ((attributes_mask & GDK_WA_TYPE_HINT) &&
 | 
			
		||||
              attributes->type_hint == GDK_WINDOW_TYPE_HINT_SPLASHSCREEN))
 | 
			
		||||
          {
 | 
			
		||||
            style_mask = NSBorderlessWindowMask;
 | 
			
		||||
          }
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user