Do not try to insert the input panel layer in the layer list when the
shell is locked in show_input_panels(). The layer will already be
insrted in resume_desktop() anyways.
https://bugs.freedesktop.org/show_bug.cgi?id=56543
Signed-off-by: Jan Arne Petersen <jpetersen@openismus.com>
Clicking outside popups closes them except in case of a shell grab
(move, resize or rotate), in which case we move the parent window away
from under the popup. Instead, just end the popup in those cases.
https://bugs.freedesktop.org/show_bug.cgi?id=55674
weston_surface_create() already inits the opaque region, so the second
init in create_black_surface() is logically wrong. Whether this was a
memory leak or not, depends on Pixman internals.
Fini before initing again.
Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
This fixes the bug where surface is above panel_layer
just after it is restored from fullscreen mode.
How to reproduce:
* move surface under panel
* set surface fullscreen
* restore surface to normal mode
When we fork a client and give one end of a socketpair, the credentials
on the socket fd comes back as ourselves. When that happens, do not kill
the process.
Also remove superfluous variables.
Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
Also make all the callers of weston_surface_assign_output() update the
transform instead. This makes sure that when the surface is assigned an
output its bouding box is valid.
This fixes a bug where a newly created surface would have a NULL output
assigned. This would cause weston_surface_schedule_repaint() to not
schedule a repaint, preventing the surface to be shown until something
else caused a repaint.
The workspace manager interface purpose is to provide clients with
control and knowledge about the current workspace state. Initially only
one function and one event exists; moving a surface and state updated
event. A workspace is represented as an index in a 1 dimensional array.
A client keeps track of the state by being broadcasted events when the
state changes, currently limited to current workspace or number of
workspaces available.
A client can send an asynchronous request to the manager asking to move
a surface to workspace identified by an index. It is up to the shell to
actually move it.
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
By default, Control + Shift + Up/Down will move the currently active
surface, if any, while changing to another workspace.
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
To avoid having a surface on a hidden workspace in focus always set the
focus (even to NULL) when restoring.
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
Draw the borders of all the triangles.
v1: original
v2: add keybinding to enable/disable fan debug (super-alt-space),
cycle colors to make it easier to see individual draws, and
redraw undamaged region to clean up previous frames debug
lines
Signed-off-by: Rob Clark <rob@ti.com>
This patch allows rotation and mirroring outputs for x11 and drm backends.
A new 'transform' key can be set in the [output] section. From the protocol:
"The flipped values correspond to an initial flip around a vertical axis
followed by rotation."
The transform key can be one of the following 8 strings:
normal
90
180
270
flipped
flipped-90
flipped-180
flipped-270
Replace all occurrences of workspace_damage_all_surfaces() with
weston_compositor_schedule_repaint(). This fixes a bug exposed by
982387011f where trying to switch workspaces while there are no
surfaces on the current workspace fails to start the animation.
Place the window in a random position on the output where the first seat with
a pointer is. When calculating the random position limit the range to the
area that would ensure that the whole surface is visible. If the surface is
larger than the output then the surface is placed at the origin of the
output.
This change is based on the good work of Scott Moreau <oreaus@gmail.com>
If a client sends a pong message out of the blue, we deref ping_timer
which is NULL and then crash. Unsolicited pong requests indicate that
something is wrong on the client, but the compositor should survide that.
This makes the separation between panels and input panels clearer and
prevents the (desktop) panel from removing existing input panels on
redraw.
The input panel layer is below the panel layer.
Since weston_surface_update_transform() was changed so it called
surface_damage_below() instead of surface_damage(), the trick of
clearing the surface damage did not work anymore.
Fix this by moving the repaint surface to a special plane before
calling update_transform. The move is made manually (as opposed to
calling weston_surface_move_to_plane()) to avoid the call to
weston_surface_damage_below(). The transform update causes the
damage to be added to this special plane, which is simply ignored.
After the geometry.dirty bit is clear, the surface is moved back to
the primary plane.
Input panel surfaces were kept in a list by using layer_link of
weston_surface. This was pretty hacky and resulted in the bug that
an input panel surface was not removed from the list if it was unmapped
at the time of destruction.
This patch wraps the surface in a new input_panel_surface struct and
properly handles destruction with a signal listener.
When the entire output is transformed or we're capturing the output
for screenshot or video, disable all output specific overlays
(drm planes, hw cursors etc) and move all surfaces into the primary
plane.
If the grab surface happens to be unresponsive, the busy cursor grab
will be started and that will cause the grab surface to receive focus,
which in turn leads to it being pingged again. Break the cycle by not
sending pings to it. If the shell is unresponsive it won't be able to
set the busy cursor anyway.
It does not get the correct panel height for now. The memeber of list
to read should be layer_link not link now.
Signed-off-by: Juan Zhao <juan.j.zhao@linux.intel.com>
We end up calling shell_configure_fullscreen() from activate(), where
surface->buffer may be NULL. Instead, call it on initial map and
first buffer attach after surface type change. Both code path
come from the surface->configure callback where surface->buffer is know
to be non-NULL.
https://bugs.freedesktop.org/show_bug.cgi?id=51678
With shell_surface.set_maximised the caller can provide an output to maximise
to or the default output will be used. With the corresponding configure we
should use the dimensions from the chosen output not the output the surface
was currently on.
Similarly when calculating the position for the window in the map() function
we should use the desired output again.
There is no need to assign shsurf->output to es->output since that happens in
the map() function later.