mirror of
https://github.com/minetest/irrlicht.git
synced 2024-12-25 02:00:30 +01:00
SIrrlichtCreationParameters::IgnoreInput set to false works again on X11.
Thanks @ Victor Gaydov for report + patch + very good test cases! (bug #401) This had been broken since Irrlicht 1.6 The reason was that Irrlicht 1.6 wanted to ensure Irrlicht renders to given parent window instead of creating a child window in the parent window. That still works, but only with SIrrlichtCreationParameters::IgnoreInput set to true. Added a few comments about further improvements as rendering to the given parent Window is likely also possible for this case, but that will need more work. git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6237 dfc29bdd-3216-0410-991c-e03cc46cb475
This commit is contained in:
parent
4cebe6fbde
commit
feb3d07466
@ -1,5 +1,8 @@
|
||||
--------------------------
|
||||
Changes in 1.9 (not yet released)
|
||||
- SIrrlichtCreationParameters::IgnoreInput set to false works again on X11.
|
||||
Thanks @ Victor Gaydov for report + patch + very good test cases! (bug #401)
|
||||
This had been broken since Irrlicht 1.6
|
||||
- Add steer parameter to CSceneNodeAnimatorFollowSpline which allows rotating node toward direction of movement.
|
||||
Thanks @ Bate for the patch (patch #175)
|
||||
- Add a workaround for XWarpPointer bug that causes mouse to jump when users have set a Coordinate Transformation Matrix for their mouse on X11.
|
||||
|
@ -522,12 +522,25 @@ bool CIrrDeviceLinux::createWindow()
|
||||
XWindow = (Window)CreationParams.WindowId;
|
||||
if (!CreationParams.IgnoreInput)
|
||||
{
|
||||
XCreateWindow(XDisplay,
|
||||
// Note: This might be further improved by using a InputOnly window instead of InputOutput.
|
||||
// I think then it should be possible to render into the given parent window instead of
|
||||
// creating a child-window.
|
||||
// That could also be a third option for IgnoreInput in the CreationParams.
|
||||
// But we need another window variable then and have to split input/output in
|
||||
// the rest of the device code.
|
||||
// Also... this does possibly leak.
|
||||
Window child_window = XCreateWindow(XDisplay,
|
||||
XWindow,
|
||||
0, 0, Width, Height, 0, VisualInfo->depth,
|
||||
InputOutput, VisualInfo->visual,
|
||||
CWBorderPixel | CWColormap | CWEventMask,
|
||||
&WndAttributes);
|
||||
|
||||
// do not forget to map new window
|
||||
XMapWindow(XDisplay, child_window);
|
||||
|
||||
// overwrite device window id
|
||||
XWindow = child_window;
|
||||
}
|
||||
XWindowAttributes wa;
|
||||
XGetWindowAttributes(XDisplay, XWindow, &wa);
|
||||
|
Loading…
Reference in New Issue
Block a user