Mon Sep 20 21:00:46 PDT 1999 Michael Jennings <mej@eterm.org>

Fixed a problem with sticky transparent Eterms not updating their
	background image.


SVN revision: 352
This commit is contained in:
Michael Jennings 1999-09-21 03:44:17 +00:00
parent 5f7d60b3b2
commit 23ae8eb96f
4 changed files with 16 additions and 9 deletions

View File

@ -2434,3 +2434,9 @@ Mon Sep 20 20:33:13 PDT 1999 Michael Jennings <mej@eterm.org>
and isn't now....
-------------------------------------------------------------------------------
Mon Sep 20 21:00:46 PDT 1999 Michael Jennings <mej@eterm.org>
Fixed a problem with sticky transparent Eterms not updating their
background image.
-------------------------------------------------------------------------------

View File

@ -230,12 +230,12 @@ handle_property_notify(event_t * ev)
D_EVENTS(("handle_property_notify(ev [0x%08x] on window 0x%08x)\n", ev, ev->xany.window));
if (background_is_trans()) {
if (ev->xany.window == TermWin.parent) {
if ((ev->xany.window == TermWin.parent) || (ev->xany.window == Xroot)) {
prop = XInternAtom(Xdisplay, "_WIN_WORKSPACE", True);
D_EVENTS(("handle_property_notify(): On %s. prop == 0x%08x, ev->xproperty.atom == 0x%08x\n", ((ev->xany.window == Xroot) ? "the root window" : "TermWin.parent"), (int) prop, (int) ev->xproperty.atom));
if ((prop == None) || (ev->xproperty.atom != prop)) {
return 0;
}
XSelectInput(Xdisplay, desktop_window, None);
if (desktop_pixmap != None) {
free_desktop_pixmap();
}
@ -244,10 +244,10 @@ handle_property_notify(event_t * ev)
FOREACH_IMAGE(if (image_mode_is(idx, MODE_TRANS)) {image_set_mode(idx, MODE_IMAGE); image_allow_mode(idx, ALLOW_IMAGE);});
return 1;
}
XSelectInput(Xdisplay, desktop_window, PropertyChangeMask);
redraw_all_images();
} else if (ev->xany.window == desktop_window) {
prop = XInternAtom(Xdisplay, "_XROOTPMAP_ID", True);
D_EVENTS(("handle_property_notify(): On TermWin.parent. prop == 0x%08x, ev->xproperty.atom == 0x%08x\n", (int) prop, (int) ev->xproperty.atom));
if ((prop == None) || (ev->xproperty.atom != prop)) {
return 0;
}

View File

@ -1048,7 +1048,7 @@ get_desktop_window(void)
if (prop == None && prop2 == None) {
return None;
}
if (desktop_window != None) {
if ((desktop_window != None) && (desktop_window != Xroot)) {
XSelectInput(Xdisplay, desktop_window, None);
}
@ -1067,17 +1067,17 @@ get_desktop_window(void)
}
if (prop != None) {
XGetWindowProperty(Xdisplay, w, prop, 0L, 1L, False, AnyPropertyType,
&type, &format, &length, &after, &data);
XGetWindowProperty(Xdisplay, w, prop, 0L, 1L, False, AnyPropertyType, &type, &format, &length, &after, &data);
} else if (prop2 != None) {
XGetWindowProperty(Xdisplay, w, prop2, 0L, 1L, False, AnyPropertyType,
&type, &format, &length, &after, &data);
XGetWindowProperty(Xdisplay, w, prop2, 0L, 1L, False, AnyPropertyType, &type, &format, &length, &after, &data);
} else {
continue;
}
if (type != None) {
D_PIXMAP((" Found desktop as window 0x%08x\n", w));
XSelectInput(Xdisplay, w, PropertyChangeMask);
if (w != Xroot) {
XSelectInput(Xdisplay, w, PropertyChangeMask);
}
return (desktop_window = w);
}
}

View File

@ -380,6 +380,7 @@ Create_Windows(int argc, char *argv[])
#endif
XSetWMProperties(Xdisplay, TermWin.parent, NULL, NULL, argv, argc, &szHint, &wmHint, &classHint);
XSelectInput(Xdisplay, Xroot, PropertyChangeMask);
XSelectInput(Xdisplay, TermWin.parent, (KeyPressMask | FocusChangeMask | StructureNotifyMask | VisibilityChangeMask | PropertyChangeMask));
if (mwmhints.flags) {
XChangeProperty(Xdisplay, TermWin.parent, prop, prop, 32, PropModeReplace, (unsigned char *) &mwmhints, PROP_MWM_HINTS_ELEMENTS);