Re: [Question] Z-order management in Wayland

2014-08-01 Thread Jasper St. Pierre
Please stop bringing this up in unrelated threads. This is a warning. Do
not do it again.
On Aug 1, 2014 4:10 PM, "Bill Spitzak"  wrote:

> On 07/31/2014 07:27 PM, Carsten Haitzler (The Rasterman) wrote:
>
>  The most obvious thing that does not work is drag & drop.
>>>
>>
>> what has that got to do with a click raising or not? dnd is a separate
>> protocol
>> element with its own semantics.
>>
>
> You want to be able to drag out of a window without raising it. Otherwise
> it could raise and obscure the location you wish to drop at. Probably more
> important right now is that this is how Windows and OS/X work for drag &
> drop.
>
> This is not possible if sending the mouse-down (the one that will start
> the drag) raises the source window. It has nothing to do with the dnd
> protocol itself as all this happens before the first dnd request or event.
>
> Windows kludges around this by relying on synchronous operation, since the
> window manager is (in effect) running in a library in the same process. If
> no calls to start drag happen before the event handler for the mouse-down
> returns, it raises the window. This cannot be done on Wayland as it does
> not want to rely on synchronous behavior.
>
> In any case this is going to have to be fixed in xdg_shell. I did not
> realize until I did some more investigation of it how little has been done
> on developing xdg_shell. I suppose clients that use wl_shell can have
> unavoidable raise-on-click.
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-08-01 Thread Bill Spitzak

On 07/31/2014 07:27 PM, Carsten Haitzler (The Rasterman) wrote:


The most obvious thing that does not work is drag & drop.


what has that got to do with a click raising or not? dnd is a separate protocol
element with its own semantics.


You want to be able to drag out of a window without raising it. 
Otherwise it could raise and obscure the location you wish to drop at. 
Probably more important right now is that this is how Windows and OS/X 
work for drag & drop.


This is not possible if sending the mouse-down (the one that will start 
the drag) raises the source window. It has nothing to do with the dnd 
protocol itself as all this happens before the first dnd request or event.


Windows kludges around this by relying on synchronous operation, since 
the window manager is (in effect) running in a library in the same 
process. If no calls to start drag happen before the event handler for 
the mouse-down returns, it raises the window. This cannot be done on 
Wayland as it does not want to rely on synchronous behavior.


In any case this is going to have to be fixed in xdg_shell. I did not 
realize until I did some more investigation of it how little has been 
done on developing xdg_shell. I suppose clients that use wl_shell can 
have unavoidable raise-on-click.

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-08-01 Thread Manuel Bachmann
Yan,

"gl" comes from the mesa package, but has been disabled in the pure wayland
profile ("libGL.so" pulls "libX11.so"). My guess is that your gbs'
build.conf is not correct or up-to-date, as "gl" only appears if the "%with
x" macro is defined, while it is not in recent config files.  So you likely
have the good repo but a bad config file.

As this discussion is more Tizen-specific than Wayland-specific, would you
mind that we go further with private email, or -better- in the Tizen-IVI
maling list (i...@lists.tizen.org) ?

Regards,


2014-08-01 4:59 GMT+02:00 :

> Sure. We Tizen IVI tried 20140704.2 image and found this macro is enabled.
> But when we tried to build efl by GBS, we get the following error:
>
> efl:
>   nothing provides pkgconfig(gl)
>
> We are looking for the cause.
>
> Yan Wang
>
>
> > Hi Yan,
> >
> > "And I am not sure whether USE_XDG_SHELL macro is enabled in current
> > Tizen upstream."
> >
> > It is enabled by default. If you download a sufficiently recent snapshot
> > of
> > Tizen Common or IVI (I recommend from 2014/06/20 so you can have Weston
> > 1.5.0), and click on the "Minimize" button of a random EFL application,
> it
> > will in fact minimize the window with "xdg_surface_set_minimized()". It
> is
> > a good way to check if this macro was enabled.
> >
> > Regards,
> >
> >
> > 2014-07-31 10:57 GMT+02:00 :
> >
> >> Hi, Carsten,
> >>   Thanks for your comments.
> >>   I check efl code and I found
> >> _ecore_wl_window_cb_xdg_surface_active/deactivate is empty.
> >>   As your comments, we should add code into them and pop related Ecore
> >> event out. Is it right?
> >>   I could also find ecore_wl_window_raise() in ecore_wl_window.c. It
> >> shouldn't be used?
> >>   And I am not sure whether USE_XDG_SHELL macro is enabled in current
> >> Tizen upstream.
> >>
> >> Yan Wang
> >>
> >> > On Thu, 31 Jul 2014 01:02:33 -0700 (PDT) yan.w...@linux.intel.com
> >> said:
> >> >
> >> >> E.g. When we start a new application on mobile platform, previous
> >> running
> >> >> application could be hidden and paused to reduce power consuming and
> >> improve response speed. If we could adjust and get z-order status, we
> >> >> could callback application to sleep. And when user restart this
> >> application, we could just make this slept app waked up.
> >> >
> >> > you do NOT want to do this by raise/lower. even doing this in x11 is
> >> just
> >> > WRONG. in fact a good mobile wm setup would refuse to allow this.
> >> there
> >> is
> >> > a
> >> > netwm request "netwm activate". this requests the window is activated.
> >> this MAY
> >> > raise the window. it may switch desktop. it may de-iconify a window.
> >> it
> >> may
> >> > also place focus on the window... unless the wm decides that this is a
> >> bad
> >> > idea
> >> > right now.
> >> >
> >> > you do NOT want a raise/lower etc. in wayland. you want xdg shell and
> >> an
> >> activate request. the compositor after that decides what is best to do.
> >> >
> >> >> Yan Wang
> >> >> > There is currently no way to influence the stacking order of
> >> top-level
> >> >> > surfaces. Why do you need this?
> >> >> > On Jul 31, 2014 9:28 AM,  wrote:
> >> >> >
> >> >> >> Hi, All,
> >> >> >>I found X provides raise/lower APIs to manger window Z-order.
> >> But
> >> >> >> there
> >> >> >> isn't related APIs in Wayland/Weston.
> >> >> >>May it should be one design idea of Wayland in fact or I could
> >> >> >> achieve
> >> >> >> this  by current Wayland protocol?
> >> >> >>Thanks.
> >> >> >>
> >> >> >> Yan Wang
> >> >> >> ___
> >> >> >> wayland-devel mailing list
> >> >> >> wayland-devel@lists.freedesktop.org
> >> >> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >> >> >>
> >> >> > ___
> >> >> > wayland-devel mailing list
> >> >> > wayland-devel@lists.freedesktop.org
> >> >> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >> >> >
> >> >> ___
> >> >> wayland-devel mailing list
> >> >> wayland-devel@lists.freedesktop.org
> >> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >> >
> >> >
> >> > --
> >> > - Codito, ergo sum - "I code, therefore I am"
> >> --
> >> The Rasterman (Carsten Haitzler)ras...@rasterman.com
> >> >
> >> >
> >>
> >>
> >>
> >> ___
> >> wayland-devel mailing list
> >> wayland-devel@lists.freedesktop.org
> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >>
> >
> >
> >
> > --
> > Regards,
> >
> >
> >
> > *Manuel BACHMANN Tizen Project VANNES-FR*
> >
>
>


-- 
Regards,



*Manuel BACHMANN Tizen Project VANNES-FR*
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-08-01 Thread Pekka Paalanen
On Thu, 31 Jul 2014 17:21:15 +0900
Carsten Haitzler (The Rasterman)  wrote:

> On Thu, 31 Jul 2014 01:02:33 -0700 (PDT) yan.w...@linux.intel.com said:
> 
> > E.g. When we start a new application on mobile platform, previous running
> > application could be hidden and paused to reduce power consuming
> > and improve response speed. If we could adjust and get z-order status, we
> > could callback application to sleep. And when user restart this
> > application, we could just make this slept app waked up.
> 
> you do NOT want to do this by raise/lower. even doing this in x11 is just
> WRONG. in fact a good mobile wm setup would refuse to allow this. there is a
> netwm request "netwm activate". this requests the window is activated. this 
> MAY
> raise the window. it may switch desktop. it may de-iconify a window. it may
> also place focus on the window... unless the wm decides that this is a bad 
> idea
> right now.
> 
> you do NOT want a raise/lower etc. in wayland. you want xdg shell and an
> activate request. the compositor after that decides what is best to do.

Actually, for a mobile platform, you do not even want to use xdg_shell,
but a replacement that is designed specifically for mobile. Xdg_shell
is for desktops, and likely contains some useful features for mobile,
but also features that do not make sense on mobile. Mobile also may
want features that are never going to be in xdg_shell.

I know there is come controversy in this, as it means you need to patch
all toolkits/apps to use the replacement protocol, but it also means
those toolkits/apps get tailored so that they actually behave nicely on
mobile UIs.

Just to keep this in mind, if you find xdg_shell not ideal for your
non-desktop-like environment. Of course, nothing prevents you from
sticking to xdg_shell, if its semantics work well; less work for
everyone.


Thanks,
pq
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-08-01 Thread Pekka Paalanen
On Thu, 31 Jul 2014 01:20:32 -0700 (PDT)
yan.w...@linux.intel.com wrote:

> Yes. I also think so. But we may need the comments of Wayland maintainer
> about this design because it need change the compositor logic.

Already if a surface is not part of any output's repaint (i.e. is not
on any layer that is part of repaint), the frame callbacks will not be
sent.

So if you can put the surface on a layer that is not going for repaint,
it should already work. No changes in Weston core needed.

Then the apps need to realize they are not getting frame callbacks, and
do the necessary clean-ups, if simply stopping repaint is not enough.


Thanks,
pq

> > Sure. You can do this from your compositor. Weston has internal APIs known
> > as "layers", and these control stacking order. To pause the previous
> > application, you can stop calling the callback used from "frame". This
> > might require some extra work in compositor.c to not send the callbacks if
> > they're in a special "paused" layer, but it can be done.
> >
> >
> > On Thu, Jul 31, 2014 at 10:02 AM,  wrote:
> >
> >> E.g. When we start a new application on mobile platform, previous
> >> running
> >> application could be hidden and paused to reduce power consuming
> >> and improve response speed. If we could adjust and get z-order status,
> >> we
> >> could callback application to sleep. And when user restart this
> >> application, we could just make this slept app waked up.
> >>
> >> Yan Wang
> >>
> >> > There is currently no way to influence the stacking order of top-level
> >> > surfaces. Why do you need this?
> >> > On Jul 31, 2014 9:28 AM,  wrote:
> >> >
> >> >> Hi, All,
> >> >>I found X provides raise/lower APIs to manger window Z-order. But
> >> >> there
> >> >> isn't related APIs in Wayland/Weston.
> >> >>May it should be one design idea of Wayland in fact or I could
> >> >> achieve
> >> >> this  by current Wayland protocol?
> >> >>Thanks.
> >> >>
> >> >> Yan Wang
> >> >> ___
> >> >> wayland-devel mailing list
> >> >> wayland-devel@lists.freedesktop.org
> >> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >> >>
> >> > ___
> >> > wayland-devel mailing list
> >> > wayland-devel@lists.freedesktop.org
> >> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >> >
> >>
> >>
> >
> >
> > --
> >   Jasper
> > ___
> > wayland-devel mailing list
> > wayland-devel@lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >
> 
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread yan . wang
Need change gles20 -> glesv2.
please check the following:
https://review.tizen.org/gerrit/25247


> Sure. We Tizen IVI tried 20140704.2 image and found this macro is
enabled.
> But when we tried to build efl by GBS, we get the following error:
>
> efl:
>   nothing provides pkgconfig(gl)
>
> We are looking for the cause.
>
> Yan Wang
>
>
>> Hi Yan,
>> "And I am not sure whether USE_XDG_SHELL macro is enabled in current
Tizen upstream."
>> It is enabled by default. If you download a sufficiently recent
snapshot
>> of
>> Tizen Common or IVI (I recommend from 2014/06/20 so you can have Weston
1.5.0), and click on the "Minimize" button of a random EFL application,
it
>> will in fact minimize the window with "xdg_surface_set_minimized()". It is
>> a good way to check if this macro was enabled.
>> Regards,
>> 2014-07-31 10:57 GMT+02:00 :
>>> Hi, Carsten,
>>>   Thanks for your comments.
>>>   I check efl code and I found
>>> _ecore_wl_window_cb_xdg_surface_active/deactivate is empty.
>>>   As your comments, we should add code into them and pop related Ecore
>>> event out. Is it right?
>>>   I could also find ecore_wl_window_raise() in ecore_wl_window.c. It
>>> shouldn't be used?
>>>   And I am not sure whether USE_XDG_SHELL macro is enabled in current
>>> Tizen upstream.
>>> Yan Wang
>>> > On Thu, 31 Jul 2014 01:02:33 -0700 (PDT) yan.w...@linux.intel.com
>>> said:
>>> >
>>> >> E.g. When we start a new application on mobile platform, previous
>>> running
>>> >> application could be hidden and paused to reduce power consuming
and
>>> improve response speed. If we could adjust and get z-order status, we
>>> >> could callback application to sleep. And when user restart this
>>> application, we could just make this slept app waked up.
>>> >
>>> > you do NOT want to do this by raise/lower. even doing this in x11 is
>>> just
>>> > WRONG. in fact a good mobile wm setup would refuse to allow this.
>>> there
>>> is
>>> > a
>>> > netwm request "netwm activate". this requests the window is
>>> activated.
>>> this MAY
>>> > raise the window. it may switch desktop. it may de-iconify a window.
>>> it
>>> may
>>> > also place focus on the window... unless the wm decides that this is
>>> a
>>> bad
>>> > idea
>>> > right now.
>>> >
>>> > you do NOT want a raise/lower etc. in wayland. you want xdg shell
and
>>> an
>>> activate request. the compositor after that decides what is best to
do.
>>> >
>>> >> Yan Wang
>>> >> > There is currently no way to influence the stacking order of
>>> top-level
>>> >> > surfaces. Why do you need this?
>>> >> > On Jul 31, 2014 9:28 AM,  wrote:
>>> >> >
>>> >> >> Hi, All,
>>> >> >>I found X provides raise/lower APIs to manger window Z-order.
>>> But
>>> >> >> there
>>> >> >> isn't related APIs in Wayland/Weston.
>>> >> >>May it should be one design idea of Wayland in fact or I
could
>>> >> >> achieve
>>> >> >> this  by current Wayland protocol?
>>> >> >>Thanks.
>>> >> >>
>>> >> >> Yan Wang
>>> >> >> ___
>>> >> >> wayland-devel mailing list
>>> >> >> wayland-devel@lists.freedesktop.org
>>> >> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>>> >> >>
>>> >> > ___
>>> >> > wayland-devel mailing list
>>> >> > wayland-devel@lists.freedesktop.org
>>> >> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>>> >> >
>>> >> ___
>>> >> wayland-devel mailing list
>>> >> wayland-devel@lists.freedesktop.org
>>> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>>> >
>>> >
>>> > --
>>> > - Codito, ergo sum - "I code, therefore I am"
>>> --
>>> The Rasterman (Carsten Haitzler)ras...@rasterman.com
>>> >
>>> >
>>> ___
>>> wayland-devel mailing list
>>> wayland-devel@lists.freedesktop.org
>>> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>> --
>> Regards,
>> *Manuel BACHMANN Tizen Project VANNES-FR*
>
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>


___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread yan . wang
Sure. We Tizen IVI tried 20140704.2 image and found this macro is enabled.
But when we tried to build efl by GBS, we get the following error:

efl:
  nothing provides pkgconfig(gl)

We are looking for the cause.

Yan Wang


> Hi Yan,
>
> "And I am not sure whether USE_XDG_SHELL macro is enabled in current
> Tizen upstream."
>
> It is enabled by default. If you download a sufficiently recent snapshot
> of
> Tizen Common or IVI (I recommend from 2014/06/20 so you can have Weston
> 1.5.0), and click on the "Minimize" button of a random EFL application, it
> will in fact minimize the window with "xdg_surface_set_minimized()". It is
> a good way to check if this macro was enabled.
>
> Regards,
>
>
> 2014-07-31 10:57 GMT+02:00 :
>
>> Hi, Carsten,
>>   Thanks for your comments.
>>   I check efl code and I found
>> _ecore_wl_window_cb_xdg_surface_active/deactivate is empty.
>>   As your comments, we should add code into them and pop related Ecore
>> event out. Is it right?
>>   I could also find ecore_wl_window_raise() in ecore_wl_window.c. It
>> shouldn't be used?
>>   And I am not sure whether USE_XDG_SHELL macro is enabled in current
>> Tizen upstream.
>>
>> Yan Wang
>>
>> > On Thu, 31 Jul 2014 01:02:33 -0700 (PDT) yan.w...@linux.intel.com
>> said:
>> >
>> >> E.g. When we start a new application on mobile platform, previous
>> running
>> >> application could be hidden and paused to reduce power consuming and
>> improve response speed. If we could adjust and get z-order status, we
>> >> could callback application to sleep. And when user restart this
>> application, we could just make this slept app waked up.
>> >
>> > you do NOT want to do this by raise/lower. even doing this in x11 is
>> just
>> > WRONG. in fact a good mobile wm setup would refuse to allow this.
>> there
>> is
>> > a
>> > netwm request "netwm activate". this requests the window is activated.
>> this MAY
>> > raise the window. it may switch desktop. it may de-iconify a window.
>> it
>> may
>> > also place focus on the window... unless the wm decides that this is a
>> bad
>> > idea
>> > right now.
>> >
>> > you do NOT want a raise/lower etc. in wayland. you want xdg shell and
>> an
>> activate request. the compositor after that decides what is best to do.
>> >
>> >> Yan Wang
>> >> > There is currently no way to influence the stacking order of
>> top-level
>> >> > surfaces. Why do you need this?
>> >> > On Jul 31, 2014 9:28 AM,  wrote:
>> >> >
>> >> >> Hi, All,
>> >> >>I found X provides raise/lower APIs to manger window Z-order.
>> But
>> >> >> there
>> >> >> isn't related APIs in Wayland/Weston.
>> >> >>May it should be one design idea of Wayland in fact or I could
>> >> >> achieve
>> >> >> this  by current Wayland protocol?
>> >> >>Thanks.
>> >> >>
>> >> >> Yan Wang
>> >> >> ___
>> >> >> wayland-devel mailing list
>> >> >> wayland-devel@lists.freedesktop.org
>> >> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>> >> >>
>> >> > ___
>> >> > wayland-devel mailing list
>> >> > wayland-devel@lists.freedesktop.org
>> >> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>> >> >
>> >> ___
>> >> wayland-devel mailing list
>> >> wayland-devel@lists.freedesktop.org
>> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>> >
>> >
>> > --
>> > - Codito, ergo sum - "I code, therefore I am"
>> --
>> The Rasterman (Carsten Haitzler)ras...@rasterman.com
>> >
>> >
>>
>>
>>
>> ___
>> wayland-devel mailing list
>> wayland-devel@lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>>
>
>
>
> --
> Regards,
>
>
>
> *Manuel BACHMANN Tizen Project VANNES-FR*
>

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread The Rasterman
On Thu, 31 Jul 2014 15:44:40 -0700 Bill Spitzak  said:

> On 07/31/2014 03:21 PM, Carsten Haitzler (The Rasterman) wrote:
> 
> >> Wait a second, how is click-to-raise being done?
> >
> > not by the client - by the compositor. the client has no control over that.
> 
> That does not work. The client has to be able to decide whether a mouse 
> click will raise the window.

no it doesn't. it doesn't work like that in x11 and things work just fine. i've
been doing wm's and toolkits for a long time. wayland is well designed, if
perhaps a little spartan. :)

> The most obvious thing that does not work is drag & drop.

what has that got to do with a click raising or not? dnd is a separate protocol
element with its own semantics.

> It makes it impossible for a click to both raise the window and create a 
> floating window without blinking.

not so. :) as dnd is triggered on a DRAG = the mouse has MOVED beyond a
certain threshold beyond the place that the click happened - the creation of a
dnd icon is long after the click and the raise. this is precisely how it works
in x11 today - the click is intercepted by the wm with a passive grab and an
allow events to hand it on. that click may cause the wm to raise the window.
even the override-redirect window the client makes for dnd is fine...

in wayland dnd is a special thing and the compositor is directly involved

> And unless something MUCH more complicated than the current parent in 
> xdg_shell is used, it makes multiple-window software impossible. At 
> least a full Directed Acyclic Graph of multiple parents for every 
> surface is needed, though I really suspect an entire interpreted 
> language is needed to describe window stacking.
> 
> This has to be fixed or you are violating the "every frame is perfect" 
> design criteria for Wayland.

nope. when a drag starts an icon surface (to be dragged about) it given to the
compositor. the compositor can happily ensure that that surface is at the
correct x/y AND always above everything - like the mouse pointer. lok at the
start_drag protocol request. :)

-- 
- Codito, ergo sum - "I code, therefore I am" --
The Rasterman (Carsten Haitzler)ras...@rasterman.com

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread Daniel Stone
On Thursday, July 31, 2014, Bill Spitzak  wrote:
>
> That does not work. The client has to be able to decide whether a mouse
> click will raise the window.
>

You really don't need to tell us this every two weeks. We get the point.
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread Bill Spitzak

On 07/31/2014 03:21 PM, Carsten Haitzler (The Rasterman) wrote:


Wait a second, how is click-to-raise being done?


not by the client - by the compositor. the client has no control over that.


That does not work. The client has to be able to decide whether a mouse 
click will raise the window.


The most obvious thing that does not work is drag & drop.

It makes it impossible for a click to both raise the window and create a 
floating window without blinking.


And unless something MUCH more complicated than the current parent in 
xdg_shell is used, it makes multiple-window software impossible. At 
least a full Directed Acyclic Graph of multiple parents for every 
surface is needed, though I really suspect an entire interpreted 
language is needed to describe window stacking.


This has to be fixed or you are violating the "every frame is perfect" 
design criteria for Wayland.

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread The Rasterman
On Thu, 31 Jul 2014 11:17:46 -0700 Bill Spitzak  said:

> 
> 
> On 07/31/2014 12:30 AM, Jasper St. Pierre wrote:
> > There is currently no way to influence the stacking order of top-level
> > surfaces.
> 
> Wait a second, how is click-to-raise being done?

not by the client - by the compositor. the client has no control over that.


-- 
- Codito, ergo sum - "I code, therefore I am" --
The Rasterman (Carsten Haitzler)ras...@rasterman.com

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread Manuel Bachmann
Hi Yan,

"And I am not sure whether USE_XDG_SHELL macro is enabled in current
Tizen upstream."

It is enabled by default. If you download a sufficiently recent snapshot of
Tizen Common or IVI (I recommend from 2014/06/20 so you can have Weston
1.5.0), and click on the "Minimize" button of a random EFL application, it
will in fact minimize the window with "xdg_surface_set_minimized()". It is
a good way to check if this macro was enabled.

Regards,


2014-07-31 10:57 GMT+02:00 :

> Hi, Carsten,
>   Thanks for your comments.
>   I check efl code and I found
> _ecore_wl_window_cb_xdg_surface_active/deactivate is empty.
>   As your comments, we should add code into them and pop related Ecore
> event out. Is it right?
>   I could also find ecore_wl_window_raise() in ecore_wl_window.c. It
> shouldn't be used?
>   And I am not sure whether USE_XDG_SHELL macro is enabled in current
> Tizen upstream.
>
> Yan Wang
>
> > On Thu, 31 Jul 2014 01:02:33 -0700 (PDT) yan.w...@linux.intel.com said:
> >
> >> E.g. When we start a new application on mobile platform, previous
> running
> >> application could be hidden and paused to reduce power consuming and
> improve response speed. If we could adjust and get z-order status, we
> >> could callback application to sleep. And when user restart this
> application, we could just make this slept app waked up.
> >
> > you do NOT want to do this by raise/lower. even doing this in x11 is
> just
> > WRONG. in fact a good mobile wm setup would refuse to allow this. there
> is
> > a
> > netwm request "netwm activate". this requests the window is activated.
> this MAY
> > raise the window. it may switch desktop. it may de-iconify a window. it
> may
> > also place focus on the window... unless the wm decides that this is a
> bad
> > idea
> > right now.
> >
> > you do NOT want a raise/lower etc. in wayland. you want xdg shell and an
> activate request. the compositor after that decides what is best to do.
> >
> >> Yan Wang
> >> > There is currently no way to influence the stacking order of
> top-level
> >> > surfaces. Why do you need this?
> >> > On Jul 31, 2014 9:28 AM,  wrote:
> >> >
> >> >> Hi, All,
> >> >>I found X provides raise/lower APIs to manger window Z-order. But
> >> >> there
> >> >> isn't related APIs in Wayland/Weston.
> >> >>May it should be one design idea of Wayland in fact or I could
> >> >> achieve
> >> >> this  by current Wayland protocol?
> >> >>Thanks.
> >> >>
> >> >> Yan Wang
> >> >> ___
> >> >> wayland-devel mailing list
> >> >> wayland-devel@lists.freedesktop.org
> >> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >> >>
> >> > ___
> >> > wayland-devel mailing list
> >> > wayland-devel@lists.freedesktop.org
> >> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >> >
> >> ___
> >> wayland-devel mailing list
> >> wayland-devel@lists.freedesktop.org
> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >
> >
> > --
> > - Codito, ergo sum - "I code, therefore I am" --
> The Rasterman (Carsten Haitzler)ras...@rasterman.com
> >
> >
>
>
>
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>



-- 
Regards,



*Manuel BACHMANN Tizen Project VANNES-FR*
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread Bill Spitzak



On 07/31/2014 12:30 AM, Jasper St. Pierre wrote:

There is currently no way to influence the stacking order of top-level
surfaces.


Wait a second, how is click-to-raise being done?
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread The Rasterman
On Thu, 31 Jul 2014 01:57:44 -0700 (PDT) yan.w...@linux.intel.com said:

> Hi, Carsten,
>   Thanks for your comments.
>   I check efl code and I found
> _ecore_wl_window_cb_xdg_surface_active/deactivate is empty.
>   As your comments, we should add code into them and pop related Ecore
> event out. Is it right?

yes - i don't know if the xdg shell protocol does this request at the moment -
but ultimateley it should as this is part of xdg standards to begin with and is
the "right way". it's what apps etc. really want. not a raise or layer change.

>   I could also find ecore_wl_window_raise() in ecore_wl_window.c. It
> shouldn't be used?

it'll only end up having an effect between subsurfaces. it won't do what you
want.

>   And I am not sure whether USE_XDG_SHELL macro is enabled in current
> Tizen upstream.

i think not. i am not even sure about upstream atm - busy with lots of other
stuff and wayland work is understaffed.

> Yan Wang
> 
> > On Thu, 31 Jul 2014 01:02:33 -0700 (PDT) yan.w...@linux.intel.com said:
> >
> >> E.g. When we start a new application on mobile platform, previous running
> >> application could be hidden and paused to reduce power consuming and
> improve response speed. If we could adjust and get z-order status, we
> >> could callback application to sleep. And when user restart this
> application, we could just make this slept app waked up.
> >
> > you do NOT want to do this by raise/lower. even doing this in x11 is
> just
> > WRONG. in fact a good mobile wm setup would refuse to allow this. there
> is
> > a
> > netwm request "netwm activate". this requests the window is activated.
> this MAY
> > raise the window. it may switch desktop. it may de-iconify a window. it may
> > also place focus on the window... unless the wm decides that this is a
> bad
> > idea
> > right now.
> >
> > you do NOT want a raise/lower etc. in wayland. you want xdg shell and an
> activate request. the compositor after that decides what is best to do.
> >
> >> Yan Wang
> >> > There is currently no way to influence the stacking order of
> top-level
> >> > surfaces. Why do you need this?
> >> > On Jul 31, 2014 9:28 AM,  wrote:
> >> >
> >> >> Hi, All,
> >> >>I found X provides raise/lower APIs to manger window Z-order. But
> >> >> there
> >> >> isn't related APIs in Wayland/Weston.
> >> >>May it should be one design idea of Wayland in fact or I could
> >> >> achieve
> >> >> this  by current Wayland protocol?
> >> >>Thanks.
> >> >>
> >> >> Yan Wang
> >> >> ___
> >> >> wayland-devel mailing list
> >> >> wayland-devel@lists.freedesktop.org
> >> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >> >>
> >> > ___
> >> > wayland-devel mailing list
> >> > wayland-devel@lists.freedesktop.org
> >> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >> >
> >> ___
> >> wayland-devel mailing list
> >> wayland-devel@lists.freedesktop.org
> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >
> >
> > --
> > - Codito, ergo sum - "I code, therefore I am" --
> The Rasterman (Carsten Haitzler)ras...@rasterman.com
> >
> >
> 
> 
> 
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> 


-- 
- Codito, ergo sum - "I code, therefore I am" --
The Rasterman (Carsten Haitzler)ras...@rasterman.com

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread yan . wang
Hi, Carsten,
  Thanks for your comments.
  I check efl code and I found
_ecore_wl_window_cb_xdg_surface_active/deactivate is empty.
  As your comments, we should add code into them and pop related Ecore
event out. Is it right?
  I could also find ecore_wl_window_raise() in ecore_wl_window.c. It
shouldn't be used?
  And I am not sure whether USE_XDG_SHELL macro is enabled in current
Tizen upstream.

Yan Wang

> On Thu, 31 Jul 2014 01:02:33 -0700 (PDT) yan.w...@linux.intel.com said:
>
>> E.g. When we start a new application on mobile platform, previous running
>> application could be hidden and paused to reduce power consuming and
improve response speed. If we could adjust and get z-order status, we
>> could callback application to sleep. And when user restart this
application, we could just make this slept app waked up.
>
> you do NOT want to do this by raise/lower. even doing this in x11 is
just
> WRONG. in fact a good mobile wm setup would refuse to allow this. there
is
> a
> netwm request "netwm activate". this requests the window is activated.
this MAY
> raise the window. it may switch desktop. it may de-iconify a window. it may
> also place focus on the window... unless the wm decides that this is a
bad
> idea
> right now.
>
> you do NOT want a raise/lower etc. in wayland. you want xdg shell and an
activate request. the compositor after that decides what is best to do.
>
>> Yan Wang
>> > There is currently no way to influence the stacking order of
top-level
>> > surfaces. Why do you need this?
>> > On Jul 31, 2014 9:28 AM,  wrote:
>> >
>> >> Hi, All,
>> >>I found X provides raise/lower APIs to manger window Z-order. But
>> >> there
>> >> isn't related APIs in Wayland/Weston.
>> >>May it should be one design idea of Wayland in fact or I could
>> >> achieve
>> >> this  by current Wayland protocol?
>> >>Thanks.
>> >>
>> >> Yan Wang
>> >> ___
>> >> wayland-devel mailing list
>> >> wayland-devel@lists.freedesktop.org
>> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>> >>
>> > ___
>> > wayland-devel mailing list
>> > wayland-devel@lists.freedesktop.org
>> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>> >
>> ___
>> wayland-devel mailing list
>> wayland-devel@lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>
>
> --
> - Codito, ergo sum - "I code, therefore I am" --
The Rasterman (Carsten Haitzler)ras...@rasterman.com
>
>



___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread The Rasterman
On Thu, 31 Jul 2014 01:02:33 -0700 (PDT) yan.w...@linux.intel.com said:

> E.g. When we start a new application on mobile platform, previous running
> application could be hidden and paused to reduce power consuming
> and improve response speed. If we could adjust and get z-order status, we
> could callback application to sleep. And when user restart this
> application, we could just make this slept app waked up.

you do NOT want to do this by raise/lower. even doing this in x11 is just
WRONG. in fact a good mobile wm setup would refuse to allow this. there is a
netwm request "netwm activate". this requests the window is activated. this MAY
raise the window. it may switch desktop. it may de-iconify a window. it may
also place focus on the window... unless the wm decides that this is a bad idea
right now.

you do NOT want a raise/lower etc. in wayland. you want xdg shell and an
activate request. the compositor after that decides what is best to do.

> Yan Wang
> 
> > There is currently no way to influence the stacking order of top-level
> > surfaces. Why do you need this?
> > On Jul 31, 2014 9:28 AM,  wrote:
> >
> >> Hi, All,
> >>I found X provides raise/lower APIs to manger window Z-order. But
> >> there
> >> isn't related APIs in Wayland/Weston.
> >>May it should be one design idea of Wayland in fact or I could
> >> achieve
> >> this  by current Wayland protocol?
> >>Thanks.
> >>
> >> Yan Wang
> >> ___
> >> wayland-devel mailing list
> >> wayland-devel@lists.freedesktop.org
> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >>
> > ___
> > wayland-devel mailing list
> > wayland-devel@lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >
> 
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> 


-- 
- Codito, ergo sum - "I code, therefore I am" --
The Rasterman (Carsten Haitzler)ras...@rasterman.com

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


RE: [Question] Z-order management in Wayland

2014-07-31 Thread yan . wang
Thanks. I will check it.

Yan Wang

> Yan,
>
> No way to change order of top-level surfaces in current Wayland
> protocol.
> If you want to do it, you can extend protocol by yourself and implement
> own shell loaded on Weston.
>
> One example is http://projects.genivi.org/wayland-ivi-extension/.
> There is a similar use case in In-vehicle Infotainment system regarding
> consumption of power.
>
>> -Original Message-
>> From: wayland-devel
>> [mailto:wayland-devel-boun...@lists.freedesktop.org] On Behalf Of
>> yan.w...@linux.intel.com
>> Sent: Thursday, July 31, 2014 5:03 PM
>> To: Jasper St. Pierre
>> Cc: yan.w...@linux.intel.com; wayland-devel@lists.freedesktop.org
>> Subject: Re: [Question] Z-order management in Wayland
>>
>> E.g. When we start a new application on mobile platform, previous
> running
>> application could be hidden and paused to reduce power consuming and
>> improve response speed. If we could adjust and get z-order status, we
>> could callback application to sleep. And when user restart this
>> application, we could just make this slept app waked up.
>>
>> Yan Wang
>>
>> > There is currently no way to influence the stacking order of
> top-level
>> > surfaces. Why do you need this?
>> > On Jul 31, 2014 9:28 AM,  wrote:
>> >
>> >> Hi, All,
>> >>I found X provides raise/lower APIs to manger window Z-order.
> But
>> >> there isn't related APIs in Wayland/Weston.
>> >>May it should be one design idea of Wayland in fact or I could
>> >> achieve this  by current Wayland protocol?
>> >>Thanks.
>> >>
>> >> Yan Wang
>> >> ___
>> >> wayland-devel mailing list
>> >> wayland-devel@lists.freedesktop.org
>> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>> >>
>> > ___
>> > wayland-devel mailing list
>> > wayland-devel@lists.freedesktop.org
>> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>> >
>>
>> ___
>> wayland-devel mailing list
>> wayland-devel@lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread yan . wang
Yes. I also think so. But we may need the comments of Wayland maintainer
about this design because it need change the compositor logic.

Yan Wang

> Sure. You can do this from your compositor. Weston has internal APIs known
> as "layers", and these control stacking order. To pause the previous
> application, you can stop calling the callback used from "frame". This
> might require some extra work in compositor.c to not send the callbacks if
> they're in a special "paused" layer, but it can be done.
>
>
> On Thu, Jul 31, 2014 at 10:02 AM,  wrote:
>
>> E.g. When we start a new application on mobile platform, previous
>> running
>> application could be hidden and paused to reduce power consuming
>> and improve response speed. If we could adjust and get z-order status,
>> we
>> could callback application to sleep. And when user restart this
>> application, we could just make this slept app waked up.
>>
>> Yan Wang
>>
>> > There is currently no way to influence the stacking order of top-level
>> > surfaces. Why do you need this?
>> > On Jul 31, 2014 9:28 AM,  wrote:
>> >
>> >> Hi, All,
>> >>I found X provides raise/lower APIs to manger window Z-order. But
>> >> there
>> >> isn't related APIs in Wayland/Weston.
>> >>May it should be one design idea of Wayland in fact or I could
>> >> achieve
>> >> this  by current Wayland protocol?
>> >>Thanks.
>> >>
>> >> Yan Wang
>> >> ___
>> >> wayland-devel mailing list
>> >> wayland-devel@lists.freedesktop.org
>> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>> >>
>> > ___
>> > wayland-devel mailing list
>> > wayland-devel@lists.freedesktop.org
>> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>> >
>>
>>
>
>
> --
>   Jasper
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


RE: [Question] Z-order management in Wayland

2014-07-31 Thread Tanibata, Nobuhiko (ADITJ/SWG)
Yan, 

No way to change order of top-level surfaces in current Wayland
protocol.
If you want to do it, you can extend protocol by yourself and implement
own shell loaded on Weston.

One example is http://projects.genivi.org/wayland-ivi-extension/.
There is a similar use case in In-vehicle Infotainment system regarding
consumption of power.

> -Original Message-
> From: wayland-devel
> [mailto:wayland-devel-boun...@lists.freedesktop.org] On Behalf Of
> yan.w...@linux.intel.com
> Sent: Thursday, July 31, 2014 5:03 PM
> To: Jasper St. Pierre
> Cc: yan.w...@linux.intel.com; wayland-devel@lists.freedesktop.org
> Subject: Re: [Question] Z-order management in Wayland
> 
> E.g. When we start a new application on mobile platform, previous
running
> application could be hidden and paused to reduce power consuming and
> improve response speed. If we could adjust and get z-order status, we
> could callback application to sleep. And when user restart this
> application, we could just make this slept app waked up.
> 
> Yan Wang
> 
> > There is currently no way to influence the stacking order of
top-level
> > surfaces. Why do you need this?
> > On Jul 31, 2014 9:28 AM,  wrote:
> >
> >> Hi, All,
> >>I found X provides raise/lower APIs to manger window Z-order.
But
> >> there isn't related APIs in Wayland/Weston.
> >>May it should be one design idea of Wayland in fact or I could
> >> achieve this  by current Wayland protocol?
> >>Thanks.
> >>
> >> Yan Wang
> >> ___
> >> wayland-devel mailing list
> >> wayland-devel@lists.freedesktop.org
> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >>
> > ___
> > wayland-devel mailing list
> > wayland-devel@lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >
> 
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread Jasper St. Pierre
Sure. You can do this from your compositor. Weston has internal APIs known
as "layers", and these control stacking order. To pause the previous
application, you can stop calling the callback used from "frame". This
might require some extra work in compositor.c to not send the callbacks if
they're in a special "paused" layer, but it can be done.


On Thu, Jul 31, 2014 at 10:02 AM,  wrote:

> E.g. When we start a new application on mobile platform, previous running
> application could be hidden and paused to reduce power consuming
> and improve response speed. If we could adjust and get z-order status, we
> could callback application to sleep. And when user restart this
> application, we could just make this slept app waked up.
>
> Yan Wang
>
> > There is currently no way to influence the stacking order of top-level
> > surfaces. Why do you need this?
> > On Jul 31, 2014 9:28 AM,  wrote:
> >
> >> Hi, All,
> >>I found X provides raise/lower APIs to manger window Z-order. But
> >> there
> >> isn't related APIs in Wayland/Weston.
> >>May it should be one design idea of Wayland in fact or I could
> >> achieve
> >> this  by current Wayland protocol?
> >>Thanks.
> >>
> >> Yan Wang
> >> ___
> >> wayland-devel mailing list
> >> wayland-devel@lists.freedesktop.org
> >> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >>
> > ___
> > wayland-devel mailing list
> > wayland-devel@lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >
>
>


-- 
  Jasper
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread yan . wang
E.g. When we start a new application on mobile platform, previous running
application could be hidden and paused to reduce power consuming
and improve response speed. If we could adjust and get z-order status, we
could callback application to sleep. And when user restart this
application, we could just make this slept app waked up.

Yan Wang

> There is currently no way to influence the stacking order of top-level
> surfaces. Why do you need this?
> On Jul 31, 2014 9:28 AM,  wrote:
>
>> Hi, All,
>>I found X provides raise/lower APIs to manger window Z-order. But
>> there
>> isn't related APIs in Wayland/Weston.
>>May it should be one design idea of Wayland in fact or I could
>> achieve
>> this  by current Wayland protocol?
>>Thanks.
>>
>> Yan Wang
>> ___
>> wayland-devel mailing list
>> wayland-devel@lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>>
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [Question] Z-order management in Wayland

2014-07-31 Thread Jasper St. Pierre
There is currently no way to influence the stacking order of top-level
surfaces. Why do you need this?
On Jul 31, 2014 9:28 AM,  wrote:

> Hi, All,
>I found X provides raise/lower APIs to manger window Z-order. But there
> isn't related APIs in Wayland/Weston.
>May it should be one design idea of Wayland in fact or I could achieve
> this  by current Wayland protocol?
>Thanks.
>
> Yan Wang
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
>
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel