private void WakeUp() { Services.Logger.LogWindowingSystemEvent("Received wake up call."); if (!_windows.Any()) { Services.Logger.LogWindowingSystemEvent("No windows to wake. Request skipped."); return; } var connection = Xlib.XOpenDisplay(null); IntPtr ev = Marshal.AllocHGlobal(24 * sizeof(long)); try { var msg = new X11.XClientMessageEvent() { message_type = X11.Atom.None, window = _windows[0].XWindow, display = connection, type = (int)X11.Event.ClientMessage, format = 32 }; Marshal.StructureToPtr(msg, ev, false); X11.Status status = Xlib.XSendEvent(connection, _windows[0].XWindow, true, 0, ev); Services.Logger.LogWindowingSystemEvent("Message to XOrg sent. Status - {0}", status); } finally { Marshal.FreeHGlobal(ev); Xlib.XCloseDisplay(connection); } }
public void Dispose() { Services.Logger.LogWindowingSystemEvent("Disposing platform..."); Xlib.XCloseDisplay(Display); }