mutter:wip/surface-content

Last commit made on 2014-02-19
Get this branch:
git clone -b wip/surface-content https://git.launchpad.net/mutter

Branch merges

Branch information

Name:
wip/surface-content
Repository:
lp:mutter

Recent commits

2210c30... by Jasper St. Pierre

window-actor: Split into two subclasses of MetaSurfaceActor

The rendering logic before was somewhat complex. We had three independent
cases to take into account when doing rendering:

  * X11 compositor. In this case, we're a traditional X11 compositor,
    not a Wayland compositor. We use XCompositeNameWindowPixmap to get
    the backing pixmap for the window, and deal with the COMPOSITE
    extension messiness.

    In this case, meta_is_wayland_compositor() is FALSE.

  * Wayland clients. In this case, we're a Wayland compositor managing
    Wayland surfaces. The rendering for this is fairly straightforward,
    as Cogl handles most of the complexity with EGL and SHM buffers...
    Wayland clients give us the input and opaque regions through
    wl_surface.

    In this case, meta_is_wayland_compositor() is TRUE and
    priv->window->client_type == META_WINDOW_CLIENT_TYPE_WAYLAND.

  * XWayland clients. In this case, we're a Wayland compositor, like
    above, and XWayland hands us Wayland surfaces. XWayland handles
    the COMPOSITE extension messiness for us, and hands us a buffer
    like any other Wayland client. We have to fetch the input and
    opaque regions from the X11 window ourselves.

    In this case, meta_is_wayland_compositor() is TRUE and
    priv->window->client_type == META_WINDOW_CLIENT_TYPE_X11.

We now split the rendering logic into two subclasses, which are:

  * MetaSurfaceActorX11, which handles the X11 compositor case, in that
    it uses XCompositeNameWindowPixmap to get the backing pixmap, and
    deal with all the COMPOSITE extension messiness.

  * MetaSurfaceActorWayland, which handles the Wayland compositor case
    for both native Wayland clients and XWayland clients. XWayland handles
    COMPOSITE for us, and handles pushing a surface over through the
    xf86-video-wayland DDX.

Frame sync is still in MetaWindowActor, as it needs to work for both the
X11 compositor and XWayland client cases. When Wayland's video display
protocol lands, this will need to be significantly overhauled, as it would
have to work for any wl_surface, including subsurfaces, so we would need
surface-level discretion.

https://bugzilla.gnome.org/show_bug.cgi?id=720631

6b98ac3... by Jasper St. Pierre

window-actor: Kill off needs_pixmap

It's mostly equivalent to the case where we've already detached
the pixmap, *except* for the x11_size_changed case. We can simply
detach the pixmap at the time the window changes size, though.

13ddd36... by Jasper St. Pierre

window-actor: Don't queue a redraw when queueing a new pixmap

We guarantee ourselves that a valid pixmap will appear any time
that the window is painted. The window actor will be scheduled
for a repaint if it's added / removed from the scene graph, like
during construction, if the size changes, or if we receive damage,
which are the existing use cases where this function is called.

So, I can't see any reason that we queue a redraw in here.

17462c2... by Marek Chalupa <email address hidden>

pointer/keyboard: fix setting focus

Set focus to NULL after using the variable

c964ef4... by Jasper St. Pierre

window-actor: Fix build

I'm bad.

0dccc44... by Jasper St. Pierre

window-actor: Kill off a nonsensical edge case

We can never have a window actor that represents either the X root
window or the stage window, so it doesn't make sense to bail out
early in case we do.

I'd imagine that this came from a much earlier version of the code
where the compositor was much separate and had its own MapNotify
handling.

48f7232... by Jasper St. Pierre

pointer: Don't send modifiers on mouse enter

I talked to Kristian about this. It should be enough to simply
send it when we activate the surface and give it keyboard focus.

ff5867e... by Jasper St. Pierre

pointer: Make the code here a bit clearer

a5d950f... by Jasper St. Pierre

pointer/keyboard: Fix focus setting once again

Yet another large-scale restructuring... this is some messy code.

7615d17... by Jasper St. Pierre

wayland: Tie activate / deactivate to appears-focused

... rather than actual focus. This makes things behave better.