Home » U++ Library support » TopWindow&PopUp, TrayIcon » Problems with CursorImage/Popups/Frames on X11
Re: Problems with CursorImage/Popups/Frames on X11 [message #13688 is a reply to message #13380] |
Tue, 22 January 2008 10:52  |
mrjt
Messages: 705 Registered: March 2007 Location: London
|
Contributor |
|
|
Well, turns out I was completely wrong and it *is* possible (at least on KDE) to implement X11 docking with native windows. You have to SetFocus on the window when it's moved so that X11 passes back focus when the move stops. It's pure luck that I did that *and* had an EventDump going at the same time 
However, during my studies I did find the solution to two of the problems I was having with using pop-ups as main windows.
1) CursorImage not working. In X11Wnd.cpp (ln. 590, SetMouseCursor) there is the following code:
Quote: | if(IsPopUp()) {
Ctrl *tw = GetTopWindow();
if(tw)
w = tw->GetWindow();
w = GetTopCtrl()->GetWindow();
}
| This effectively passes all CursorImage events to the owner of the pop-up, and commenting it out makes them work correctly. Presumably there is a good reason for this, but I can't think of a case where this would be necessary at the cost of breaking the behaviour of all other pop-ups. Could it be removed?
2) Popups not overlapping each other properly (not moving to foreground). This can be fixed by replacing line 192/192 in CtrlKbd.cpp (SetFocus0) with:
Quote: | Ptr<Ctrl> topctrl = GetTopCtrl();
Ptr<Ctrl> topwindow = topctrl->IsPopUp() ? topctrl : GetTopWindow();
| This is not a serious issue though, since you can manually call SetForground on the popup when it gets focus.
The only remaining problem is the managing of popups (which I thougt would be the easy bit )- ie hiding/showing in accordance to changing in window stacking order, minization etc. - I'm pretty sure you should do this using CirculateRequest/CirculateNotify, but I can't persuade X11 to send me the events even though the eventmask is correct.
I'm now much happier. Thanks for your help.
[Updated on: Tue, 22 January 2008 13:01] Report message to a moderator
|
|
|
 |
|
Problems with CursorImage/Popups/Frames on X11
By: mrjt on Fri, 30 November 2007 17:09
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mirek on Tue, 04 December 2007 15:24
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mrjt on Wed, 05 December 2007 17:00
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mrjt on Mon, 10 December 2007 17:37
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mirek on Mon, 10 December 2007 18:06
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mrjt on Mon, 10 December 2007 18:27
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mirek on Mon, 10 December 2007 18:49
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mrjt on Tue, 11 December 2007 12:45
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mirek on Sat, 29 December 2007 18:55
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mrjt on Thu, 03 January 2008 11:09
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mirek on Thu, 03 January 2008 18:01
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mrjt on Thu, 03 January 2008 18:29
|
 |
|
Re: Problems with CursorImage/Popups/Frames on X11
By: mrjt on Tue, 22 January 2008 10:52
|
Goto Forum:
Current Time: Sun Jun 08 08:04:54 CEST 2025
Total time taken to generate the page: 0.04369 seconds
|