Dne 27.8.2011 00:33, Petr Gajdůšek napsal(a):
> Here is the corrected patch if you haven't corrected it self.
> 

I guess another solution will be in pdfscreenshot_event_filter() to check
if DestroyNotify is already in the queue and do not set the property, if it is.

Something like

if (ev->type == MapNotify) {
        XEvent queued_ev;
        if (XCheckTypedWindowEvent(ev->xmap.display, ev->xmap.window, 
DestroyNotify, &queued_ev)) {
                XPutBackEvent(ev->xmap.display, &queued_ev);
        } else {
                XTextProperty supported;
                XStringListToTextProperty(&supported_str, 1, &supported);
                XSetTextProperty(ev->xmap.display,
                        ev->xmap.window,
                        &supported,
                        gdk_x11_atom_to_xatom(pdfscreenshot_atom));
        }
else {
...

But I am not sure if it will prevent all BadWindow errors.

-- 
Cheers
Petr Gajdůšek



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to