[haiku-commits] Re: r38473 - haiku/trunk/src/servers/app

  • From: "Clemens Zeidler" <clemens.zeidler@xxxxxxxxxxxxxx>
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Wed, 01 Sep 2010 12:46:43 +1200

Am 31.08.2010, 20:28 Uhr, schrieb Stephan Assmus <superstippi@xxxxxx>:


This breaks a lot of concepts in the app_server; you can't just let the
user decide where the window should appear - you have to make sure
certain constraints are met with respect to subset windows. That's what
Window::Backmost() takes care of. You must not remove that.
Furthermore, the existence of "behindOf" does not mean that the window
actually roses even after your changes - in this case, you would now
repaint much more than needed.
IOW please revert again.

When reading the patch, I figured as much, but it's between the lines and a clear example of too little comments or explainations in the code. I think what Clemens tries to do should still be made possible. Even with the constraints taken care of, it should be possible to mess with the window order in a deterministic way, and that means SendBehind() can actually raise a window too. But I don't think the computation of the dirty region, or rather the region that is still clean, was anywhere near complete after the change.

Best regards,
-Stephan


Ok maybe I should introduce a ChangeWindowLayer(Window* window, Window* before) method? This function can be called from ActivateWindow and SendWindowBehind and take care of rising and lower all modal windows and their subsets.

Did I miss something or SendWindowBehind() do not handle the case when behindOf is behind all subset windows? In this case the window would be send to the very back because Backmost() will not find any subset windows and the subset windows would stay on top.

So what should be the behavior of SendWindowBehind? Here my idea which is not the current implementation:
- If behindOf == NULL send it to the back
- else send it behind behindOf
- if the window is a modal window send the subset behind the modal window
- only lower the window (why not rise? e.g. if you want two floating window to stay in the same layer, what I want to do in SAT)

Axel could you specify it a bit more? I'm a bit confused...

Regards,
        Clemens

Other related posts: