mirror of
https://github.com/gnustep/libs-back.git
synced 2025-02-23 20:01:22 +00:00
Fix for w32 backends (ordering windows)
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/trunk@18365 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
81dc2376f4
commit
47c37caf62
5 changed files with 18 additions and 3 deletions
|
@ -1,9 +1,12 @@
|
||||||
2004-01-10 Adam Fedor <fedor@gnu.org>
|
2004-01-10 Adam Fedor <fedor@gnu.org>
|
||||||
|
|
||||||
* Source/x11/XGServerWindow.m ([XGServer -orderwindow:::]):
|
* Source/x11/XGServerWindow.m ([XGServer -orderwindow:::]):
|
||||||
When orderWin == 0, make sure the window does not go in front
|
When otherWin == 0, make sure the window does not go in front
|
||||||
of the current key window.
|
of the current key window.
|
||||||
|
|
||||||
|
* Source/win32/WIN32Server.m ([WIN -orderwindow:op:otherWin:winNum]):
|
||||||
|
Allow otherWin < 0.
|
||||||
|
|
||||||
2004-01-10 16:25 Alexander Malmberg <alexander@malmberg.org>
|
2004-01-10 16:25 Alexander Malmberg <alexander@malmberg.org>
|
||||||
|
|
||||||
* Source/art/blit.m: Replace uses DI_16_B5G5R5A1 and DI_16_B5G6R5
|
* Source/art/blit.m: Replace uses DI_16_B5G5R5A1 and DI_16_B5G6R5
|
||||||
|
|
|
@ -76,6 +76,7 @@ struct XGGeneric {
|
||||||
long currentFocusWindow;
|
long currentFocusWindow;
|
||||||
long desiredFocusWindow;
|
long desiredFocusWindow;
|
||||||
unsigned long focusRequestNumber;
|
unsigned long focusRequestNumber;
|
||||||
|
unsigned long desiredOrderedWindow;
|
||||||
unsigned char lMouse;
|
unsigned char lMouse;
|
||||||
unsigned char mMouse;
|
unsigned char mMouse;
|
||||||
unsigned char rMouse;
|
unsigned char rMouse;
|
||||||
|
|
|
@ -447,8 +447,10 @@ DWORD windowStyleForGSStyle(unsigned int style)
|
||||||
SWP_NOSIZE | SWP_NOMOVE);
|
SWP_NOSIZE | SWP_NOMOVE);
|
||||||
break;
|
break;
|
||||||
case NSWindowAbove:
|
case NSWindowAbove:
|
||||||
if (otherWin == 0)
|
if (otherWin <= 0)
|
||||||
{
|
{
|
||||||
|
/* FIXME: Need to find the current key window (otherWin == 0
|
||||||
|
means keep the window below the current key.) */
|
||||||
otherWin = winNum;
|
otherWin = winNum;
|
||||||
winNum = (int)HWND_TOP;
|
winNum = (int)HWND_TOP;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1300,6 +1300,12 @@ static inline int check_modifier (XEvent *xEvent, KeyCode key_code)
|
||||||
NSDebugLLog(@"Focus", @"Key window is already %d", key_num);
|
NSDebugLLog(@"Focus", @"Key window is already %d", key_num);
|
||||||
[GSServerForWindow(key_win) setinputfocus: key_num];
|
[GSServerForWindow(key_win) setinputfocus: key_num];
|
||||||
}
|
}
|
||||||
|
else if (generic.desiredOrderedWindow == cWin->number)
|
||||||
|
{
|
||||||
|
/* We just want to order the window, not give it focus */
|
||||||
|
NSDebugLLog(@"Focus", @"Ignoring focus request");
|
||||||
|
generic.desiredOrderedWindow = 0;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
NSPoint eventLocation;
|
NSPoint eventLocation;
|
||||||
|
|
|
@ -1575,8 +1575,10 @@ NSDebugLLog(@"Frame", @"X2O %d, %@, %@", win->number,
|
||||||
if (op != NSWindowOut && window->map_state != IsViewable)
|
if (op != NSWindowOut && window->map_state != IsViewable)
|
||||||
{
|
{
|
||||||
XMoveWindow(dpy, window->ident, window->siz_hints.x,
|
XMoveWindow(dpy, window->ident, window->siz_hints.x,
|
||||||
window->siz_hints.y);
|
window->siz_hints.y);
|
||||||
setNormalHints(dpy, window);
|
setNormalHints(dpy, window);
|
||||||
|
/* Set this to ignore any take focus events for this window */
|
||||||
|
generic.desiredOrderedWindow = winNum;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (op)
|
switch (op)
|
||||||
|
@ -2351,6 +2353,7 @@ NSDebugLLog(@"Frame", @"X2O %d, %@, %@", win->number,
|
||||||
NSDebugLLog(@"Focus", @"Setting focus to %d", window->number);
|
NSDebugLLog(@"Focus", @"Setting focus to %d", window->number);
|
||||||
generic.desiredFocusWindow = win;
|
generic.desiredFocusWindow = win;
|
||||||
generic.focusRequestNumber = XNextRequest(dpy);
|
generic.focusRequestNumber = XNextRequest(dpy);
|
||||||
|
generic.desiredOrderedWindow = 0;
|
||||||
XSetInputFocus(dpy, window->ident, RevertToParent, generic.lastTime);
|
XSetInputFocus(dpy, window->ident, RevertToParent, generic.lastTime);
|
||||||
[inputServer ximFocusICWindow: window];
|
[inputServer ximFocusICWindow: window];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue