mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Linux: Fix crashes on main window close (fixes issue #2831)
Call DesktopWindowTreeHostPlatform::Close after destroying CEF's X11 window so that objects owned by the WindowTreeHost (Compositor, X11Window, etc) are properly cleaned up.
This commit is contained in:
@ -161,6 +161,10 @@ void CefWindowX11::Close() {
|
|||||||
ev.xclient.data.l[0] = gfx::GetAtom(kWMDeleteWindow);
|
ev.xclient.data.l[0] = gfx::GetAtom(kWMDeleteWindow);
|
||||||
ev.xclient.data.l[1] = x11::CurrentTime;
|
ev.xclient.data.l[1] = x11::CurrentTime;
|
||||||
XSendEvent(xdisplay_, xwindow_, false, NoEventMask, &ev);
|
XSendEvent(xdisplay_, xwindow_, false, NoEventMask, &ev);
|
||||||
|
|
||||||
|
auto host = GetHost();
|
||||||
|
if (host)
|
||||||
|
host->Close();
|
||||||
}
|
}
|
||||||
|
|
||||||
void CefWindowX11::Show() {
|
void CefWindowX11::Show() {
|
||||||
|
Reference in New Issue
Block a user