Re: [PATCH weston 3/4] ivi-shell: don't expilicitly assign outputs to views

2018-02-07 Thread Pekka Paalanen
On Wed, 7 Feb 2018 11:54:16 +
"Ucan, Emre (ADITG/ESB)"  wrote:

> Hi,
> 
> > -Original Message-
> > From: Pekka Paalanen [mailto:ppaala...@gmail.com]
> > Sent: Mittwoch, 7. Februar 2018 11:22
> > To: Ucan, Emre (ADITG/ESB)
> > Cc: wayland-devel@lists.freedesktop.org
> > Subject: Re: [PATCH weston 3/4] ivi-shell: don't expilicitly assign outputs 
> > to
> > views
> > 
> > On Fri, 26 Jan 2018 15:04:58 +0100
> > Emre Ucan  wrote:
> >   
> > > it is assigned in weston_view_assign_outputs
> > >
> > > Signed-off-by: Emre Ucan 
> > > ---
> > >  ivi-shell/ivi-layout.c | 4 
> > >  1 file changed, 4 deletions(-)
> > >
> > > diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
> > > index 3c52ce1..4799c25 100644
> > > --- a/ivi-shell/ivi-layout.c
> > > +++ b/ivi-shell/ivi-layout.c
> > > @@ -821,10 +821,6 @@ commit_screen_list(struct ivi_layout *layout)
> > >
> > >   weston_layer_entry_insert(&layout-
> > >layout_layer.view_list,
> > > &ivi_view->view-
> > >layer_link);
> > > -
> > > - ivi_view->view->output = iviscrn->output;  
> > 
> > Hi,
> > 
> > I understand the removal of this.
> >   
> > > - ivi_view->ivisurf->surface->is_mapped =  
> > true;  
> > > - ivi_view->view->is_mapped = true;  
> > 
> > However, I would think these are still necessary. Why are they not
> > necessary here?
> > 
> > I do not see any other place that would set is_mapped=true for the view
> > and the surface.  
> 
> Yes, you are right. They are necessary. It is weird for me that we
> have to set surface and view mappedness in shell plugin. A surface is
> mapped if it has a mapped view. A view is mapped if it is in the view
> list of the compositor. Shell plugin should not take care of this.

I suppose surface being mapped when it has a mapped view would mostly
work, except I'm unsure of the sub-surface implementation, which
dynamically creates and destroys views as necessary, and it is done
lazily only during repaints. The surface is_mapped is essentially
client-visible state, a surface must not become mapped or unmapped
without client action IIRC.

View being mapped when it is in the view list is not that simple
either. The main flat view list is not the authoritative view list, it
is derived state that is updated lazily. Views are primarily on
weston_layers, and weston_layers are in compositor's list. Layers can
be removed and added to the compositor list to hide/show groups of
surfaces (say, virtual desktops, perhaps). This again must not affect
the surface is_mapped. View is_mapped is purely compositor internal
state.

It is a mess, but I don't have good ideas to make it simpler.

> Anyway, I will send a new modified patch. Is it ok for you that I
> send an update only for this patch ?

Yes, please.


Thanks,
pq


pgpAFiN6mCmbP.pgp
Description: OpenPGP digital signature
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/wayland-devel


RE: [PATCH weston 3/4] ivi-shell: don't expilicitly assign outputs to views

2018-02-07 Thread Ucan, Emre (ADITG/ESB)
Hi,

> -Original Message-
> From: Pekka Paalanen [mailto:ppaala...@gmail.com]
> Sent: Mittwoch, 7. Februar 2018 11:22
> To: Ucan, Emre (ADITG/ESB)
> Cc: wayland-devel@lists.freedesktop.org
> Subject: Re: [PATCH weston 3/4] ivi-shell: don't expilicitly assign outputs to
> views
> 
> On Fri, 26 Jan 2018 15:04:58 +0100
> Emre Ucan  wrote:
> 
> > it is assigned in weston_view_assign_outputs
> >
> > Signed-off-by: Emre Ucan 
> > ---
> >  ivi-shell/ivi-layout.c | 4 
> >  1 file changed, 4 deletions(-)
> >
> > diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
> > index 3c52ce1..4799c25 100644
> > --- a/ivi-shell/ivi-layout.c
> > +++ b/ivi-shell/ivi-layout.c
> > @@ -821,10 +821,6 @@ commit_screen_list(struct ivi_layout *layout)
> >
> > weston_layer_entry_insert(&layout-
> >layout_layer.view_list,
> >   &ivi_view->view-
> >layer_link);
> > -
> > -   ivi_view->view->output = iviscrn->output;
> 
> Hi,
> 
> I understand the removal of this.
> 
> > -   ivi_view->ivisurf->surface->is_mapped =
> true;
> > -   ivi_view->view->is_mapped = true;
> 
> However, I would think these are still necessary. Why are they not
> necessary here?
> 
> I do not see any other place that would set is_mapped=true for the view
> and the surface.

Yes, you are right. They are necessary. It is weird for me that we have to set 
surface and view mappedness in shell plugin.
A surface is mapped if it has a mapped view. A view is mapped if it is in the 
view list of the compositor. Shell plugin should not take care of this.

Anyway, I will send a new modified patch. Is it ok for you that I send an 
update only for this patch ?

Best Regards,

Emre
> 
> > }
> > }
> > }
> 
> Thanks,
> pq
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [PATCH weston 3/4] ivi-shell: don't expilicitly assign outputs to views

2018-02-07 Thread Pekka Paalanen
On Fri, 26 Jan 2018 15:04:58 +0100
Emre Ucan  wrote:

> it is assigned in weston_view_assign_outputs
> 
> Signed-off-by: Emre Ucan 
> ---
>  ivi-shell/ivi-layout.c | 4 
>  1 file changed, 4 deletions(-)
> 
> diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
> index 3c52ce1..4799c25 100644
> --- a/ivi-shell/ivi-layout.c
> +++ b/ivi-shell/ivi-layout.c
> @@ -821,10 +821,6 @@ commit_screen_list(struct ivi_layout *layout)
>  
>   
> weston_layer_entry_insert(&layout->layout_layer.view_list,
> 
> &ivi_view->view->layer_link);
> -
> - ivi_view->view->output = iviscrn->output;

Hi,

I understand the removal of this.

> - ivi_view->ivisurf->surface->is_mapped = true;
> - ivi_view->view->is_mapped = true;

However, I would think these are still necessary. Why are they not
necessary here?

I do not see any other place that would set is_mapped=true for the view
and the surface.

>   }
>   }
>   }

Thanks,
pq


pgp8F8Ejq2ttX.pgp
Description: OpenPGP digital signature
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/wayland-devel


[PATCH weston 3/4] ivi-shell: don't expilicitly assign outputs to views

2018-01-26 Thread Emre Ucan
it is assigned in weston_view_assign_outputs

Signed-off-by: Emre Ucan 
---
 ivi-shell/ivi-layout.c | 4 
 1 file changed, 4 deletions(-)

diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
index 3c52ce1..4799c25 100644
--- a/ivi-shell/ivi-layout.c
+++ b/ivi-shell/ivi-layout.c
@@ -821,10 +821,6 @@ commit_screen_list(struct ivi_layout *layout)
 

weston_layer_entry_insert(&layout->layout_layer.view_list,
  
&ivi_view->view->layer_link);
-
-   ivi_view->view->output = iviscrn->output;
-   ivi_view->ivisurf->surface->is_mapped = true;
-   ivi_view->view->is_mapped = true;
}
}
}
-- 
2.7.4

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