|
|
@ -52,11 +52,14 @@ namespace Avalonia.X11 |
|
|
|
|
|
|
|
|
XInitThreads(); |
|
|
XInitThreads(); |
|
|
Display = XOpenDisplay(IntPtr.Zero); |
|
|
Display = XOpenDisplay(IntPtr.Zero); |
|
|
|
|
|
if (Display == IntPtr.Zero) |
|
|
|
|
|
throw new Exception("XOpenDisplay failed"); |
|
|
DeferredDisplay = XOpenDisplay(IntPtr.Zero); |
|
|
DeferredDisplay = XOpenDisplay(IntPtr.Zero); |
|
|
|
|
|
if (DeferredDisplay == IntPtr.Zero) |
|
|
|
|
|
throw new Exception("XOpenDisplay failed"); |
|
|
|
|
|
|
|
|
OrphanedWindow = XCreateSimpleWindow(Display, XDefaultRootWindow(Display), 0, 0, 1, 1, 0, IntPtr.Zero, |
|
|
OrphanedWindow = XCreateSimpleWindow(Display, XDefaultRootWindow(Display), 0, 0, 1, 1, 0, IntPtr.Zero, |
|
|
IntPtr.Zero); |
|
|
IntPtr.Zero); |
|
|
if (Display == IntPtr.Zero) |
|
|
|
|
|
throw new Exception("XOpenDisplay failed"); |
|
|
|
|
|
XError.Init(); |
|
|
XError.Init(); |
|
|
|
|
|
|
|
|
Info = new X11Info(Display, DeferredDisplay, useXim); |
|
|
Info = new X11Info(Display, DeferredDisplay, useXim); |
|
|
|