Improvement: Change in client window lookup & wintype detection

- Revert to WM_STATE for client window lookup, as WM_CLASS is
  unreliable, either, but set the client window of an override-redirect
  window to itself.

- Conform to EWMH to make assumptions about window types when
  _NET_WM_WINDOW_TYPE is not available.

- Remove determine_wintype() and completely rely on client window for
  window type detection.
This commit is contained in:
Richard Grenville
2012-10-02 21:46:37 +08:00
parent c7ca3454ee
commit f95093358e
2 changed files with 28 additions and 35 deletions

View File

@ -631,8 +631,7 @@ solid_picture(Display *dpy, Bool argb, double a,
static inline bool is_normal_win(const win *w) {
return (WINTYPE_NORMAL == w->window_type
|| WINTYPE_UTILITY == w->window_type
|| WINTYPE_UNKNOWN == w->window_type);
|| WINTYPE_UTILITY == w->window_type);
}
/**
@ -761,9 +760,6 @@ repair_win(Display *dpy, win *w);
static wintype
get_wintype_prop(Display * dpy, Window w);
static wintype
determine_wintype(Display *dpy, Window w);
static void
map_win(Display *dpy, Window id,
unsigned long sequence, Bool fade,