mirror of
https://github.com/Ryujinx/Opentk.git
synced 2025-01-03 17:35:32 +00:00
Fix x11 window creation. (#3)
This commit is contained in:
parent
24585a1066
commit
35102ddad9
|
@ -1323,12 +1323,12 @@ XF86VidModeGetGammaRampSize(
|
||||||
{
|
{
|
||||||
XSetWindowAttributes attr = attributes.Value;
|
XSetWindowAttributes attr = attributes.Value;
|
||||||
return XCreateWindow(display, parent, x, y, width, height, border_width, depth,
|
return XCreateWindow(display, parent, x, y, width, height, border_width, depth,
|
||||||
(int)@class, visual, (IntPtr)valuemask, &attr);
|
(int)@class, visual, (IntPtr)valuemask, (IntPtr)(&attr));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return XCreateWindow(display, parent, x, y, width, height, border_width, depth,
|
return XCreateWindow(display, parent, x, y, width, height, border_width, depth,
|
||||||
(int)@class, visual, (IntPtr)valuemask, null);
|
(int)@class, visual, (IntPtr)valuemask, (IntPtr)null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -65,7 +65,7 @@ namespace OpenTK.Platform.X11
|
||||||
public extern static IntPtr XSynchronize(IntPtr display, bool onoff);
|
public extern static IntPtr XSynchronize(IntPtr display, bool onoff);
|
||||||
|
|
||||||
[DllImport("libX11", EntryPoint = "XCreateWindow")]
|
[DllImport("libX11", EntryPoint = "XCreateWindow")]
|
||||||
public unsafe extern static IntPtr XCreateWindow(IntPtr display, IntPtr parent, int x, int y, int width, int height, int border_width, int depth, int xclass, IntPtr visual, IntPtr valuemask, XSetWindowAttributes* attributes);
|
public extern static IntPtr XCreateWindow(Display display, Window parent, int x, int y, int width, int height, int borderWidth, int depth, int xclass, IntPtr visual, IntPtr valueMask, IntPtr attributes);
|
||||||
|
|
||||||
[DllImport("libX11", EntryPoint = "XCreateSimpleWindow")]//, CLSCompliant(false)]
|
[DllImport("libX11", EntryPoint = "XCreateSimpleWindow")]//, CLSCompliant(false)]
|
||||||
public extern static IntPtr XCreateSimpleWindow(IntPtr display, IntPtr parent, int x, int y, int width, int height, int border_width, UIntPtr border, UIntPtr background);
|
public extern static IntPtr XCreateSimpleWindow(IntPtr display, IntPtr parent, int x, int y, int width, int height, int border_width, UIntPtr border, UIntPtr background);
|
||||||
|
|
Loading…
Reference in a new issue