Compare commits

...

957 Commits

Author SHA1 Message Date
34f5be726d Bump version to 3.30.0
Update NEWS.
2018-09-04 00:05:51 +02:00
b53707f8c4 Update Croatian translation 2018-09-02 16:40:57 +00:00
d9294e4eb0 Updated Danish translation 2018-09-01 18:46:09 +02:00
94f8acc8fe Updated Vietnamese translation
Signed-off-by: Trần Ngọc Quân <vnwildman@gmail.com>
2018-09-01 08:30:06 +07:00
4841c1b13e Update Latvian translation 2018-08-31 17:56:20 +00:00
1e00cd290d Update Hungarian translation 2018-08-31 13:05:10 +00:00
3daa2d2751 Update Galician translation 2018-08-29 22:24:03 +00:00
444af437a0 Bump version to 3.29.92
Update NEWS.
2018-08-29 18:42:02 +02:00
eebcf98284 Updated Czech translation 2018-08-29 07:30:18 +02:00
7d973ac538 Updated Czech translation 2018-08-29 07:29:26 +02:00
0ada04089c Update Brazilian Portuguese translation 2018-08-28 23:00:01 +00:00
85284acb00 clutter/x11: Implement keycode lookup from keysyms on virtual key devices
Unfortunately XKeysymToKeycode() falls short in that it coalesces keysyms
into keycodes pertaining to the first level (i.e. lowercase). Add a
ClutterKeymapX11 method (much alike its GdkKeymap counterpart) to look up
all matches for the given keysym.

Two other helper methods have been added so the virtual device can fetch
the current keyboard group, and latch modifiers for key emission. Combining
all this, the virtual device is now able to handle keycodes in further
levels.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/135
2018-08-28 12:22:52 +02:00
388d065699 Update Swedish translation 2018-08-27 22:56:25 +00:00
e191c21e04 window/wayland: Don't recursive indefinitely when updating monitor
When we update the main monitor, there is a rule that makes it so that
popup windows use the same main monitor as their parent. In the commit
f4d07caa38 the call that updates and
fetches the main monitor of the toplevel accidentally changed to update
from itself, causing a indefinite recursion eventually resulting in a
crash.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/279
2018-08-27 17:49:52 +02:00
5376c31a33 window: Keep windows with placement rule attached to parent
A window placed using a placement rule should keep that relative
position even if the parent window moves, as the position tied to the
parent window, not to the stage. Thus, if the parent window moves, the
child window should move with it.

In the implementation in this commit, the constraints engine is not
used when repositioning the children; the window is simply positioned
according to the effective placement rule that was derived from the
initial constraining, as the a xdg_popup at the moment cannot move
(relative its parent) after being mapped.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/274
2018-08-27 12:15:06 +00:00
ca5b27baf5 wayland/gtk-shell: Handle requests after toplevel was unmanaged
As with xdg-toplevel, a gtk-surface can be unmanaged by the compositor
without the client knowing about it, meaning the client may still send
updates and make requests. Handle this gracefully by ignoring them. The
client needs to reset all the state anyway, if it wants to remap the
same surface.

https://gitlab.gnome.org/GNOME/mutter/issues/240
2018-08-27 11:43:53 +00:00
64df627688 wayland/legacy-xdg-shell: Handle requests after toplevel was unmanaged
As with xdg-toplevel proper, a legacy xdg-toplevel can be unmanaged by
the compositor without the client knowing about it, meaning the client
may still send updates and make requests. Handle this gracefully by
ignoring them. The client needs to reassign the surface the legacy
xdg-toplevel role again, if it wants to remap the same surface, meaning
all state would be reset anyway.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/240
2018-08-27 11:43:53 +00:00
a740f50cd7 wayland/legacy-xdg-shell: Cache frame callbacks if toplevel is unmanaged
A toplevel window can be unmanaged without the client knowing it (e.g. a
modal dialog being unmapped together with its parent. When this has
happened, take frame callbacks queued on a commit and cache them on the
generic surface queue. If the toplevel is to be remapped because the
surface was reassigned the toplevel role, the cached frame callbacks
will be queued on the surface actor and dispatched accordingly.

https://gitlab.gnome.org/GNOME/mutter/issues/240
2018-08-27 11:43:53 +00:00
5fd0f62a62 wayland/xdg-shell: Handle requests after toplevel was unmanaged
A window can be unmanaged without asking the client to do it, for
example as a side effect of a parent window being unmanaged, if the
child window was a attached dialog.

This means that the client might still make requests post updates to it
after that it was unmapped. Handle this gracefully by NULL-checking the
surface's MetaWindow pointer. We're not loosing any state due to this,
as if the client wants to map the same surface again, it needs to either
reassign it the toplevel role, or reset the xdg-toplevel, both resulting
in all state being lost anyway.

https://gitlab.gnome.org/GNOME/mutter/issues/240
2018-08-27 11:43:53 +00:00
80d420ff43 wayland/xdg-shell: Cache frame callbacks if toplevel is unmanaged
A toplevel window can be unmanaged without the client knowing it (e.g. a
modal dialog being unmapped together with its parent. When this has
happened, take frame callbacks queued on a commit and cache them on the
generic surface queue. If the toplevel is to be remapped, either because
the surface was reassigned the toplevel role, or if it was reset and
remapped, the cached frame callbacks will be queued on the surface actor
and dispatched accordingly.

https://gitlab.gnome.org/GNOME/mutter/issues/240
2018-08-27 11:43:53 +00:00
407d62943c wayland/xdg-shell: Cache pending frame callbacks on popup reset
A popup can be reset, and when that happens, window and actor are
destroyed, and won't be created again unless it is reassigned the
popup role.

If a client queued frame callbacks when resetting a popup, the frame
callbacks would be left in the pending state, as they were not queued on
the actor, meaning we'd hit an assert about the frame callbacks not
being handled. Fix this by caching them on the MetaWaylandSurface, so
that they either are cleaned up on destruction, or queued on the actor
would the surface be re-assigned the popup role.

https://gitlab.gnome.org/GNOME/mutter/issues/240
2018-08-27 11:43:53 +00:00
0ace58d05f wayland/surface: Add API to cache frame callbacks
Sometimes it may be useful for roles to put callbacks in the generic
surface frame callback queue. The surface frame callback queue will
either eventually be processed on the next surface role assignment that
places the frame callbacks in a role specific queue, processed at some
other point in time by a role, or cleaned up on surface destruction.

https://gitlab.gnome.org/GNOME/mutter/issues/240
2018-08-27 11:43:53 +00:00
d791710197 wayland/xdg-shell: Queue frame callbacks on new actor after resetting
When a xdg-toplevel is reset, the window and actor are recreated, and
all state is cleared. When this happened, we earlied out from the
xdg-toplevel commit handler, which would mean that if the client had
queued frame callbacks when resetting, they'd be left in the pending
commit state, later hitting an assert as they were not handled.

Fix this by queuing the frame callbacks no the new actor, so that they
are emitted whenever the actor is eventually painted.

https://gitlab.gnome.org/GNOME/mutter/issues/240
2018-08-27 11:43:53 +00:00
b30c907ef9 wayland: Use geometry_scale on opaque regions
This was done for input regions in commit 718a89eb2f (Thanks Jonas
for the archaeology!) but opaque regions follow the same scaling.
This brings less evident issues as opaque regions are just used for
culling optimizations.
2018-08-27 08:38:13 +00:00
784a774d9c wayland: Fix input/opaque regions calculation on hidpi
Commit 6a92c6f83 unintendedly broke input/opaque region calculations
on hidpi. Most visible side effect is that clicking is only allowed
in the upper-left quarter of windows.

The surface coordinates are returned in logical unscaled buffer
size. We're however interested in actor coordinates (thus real
pixels) here.

As it is a bit of a detour how the scale to be applied is calculated,
refactor a meta_wayland_actor_surface_get_geometry_scale() function
that we can use it here, and use it consistently for surface size and
the given regions.
2018-08-27 08:38:12 +00:00
8d3e053059 window: Force update monitor on hot plugs
Commit a3da4b8d5b changed updating of
window monitors to always use take affect when it was done from a
non-user operation. This could cause feed back loops when a non-user
driven operation would trigger the changing of a monitor, which itself
would trigger changing of the monitor again due to a window scale
change.

The reason for the change, was that when the window monitor changed due
to a hot plug, if it didn't actually change, eventually the window
monitor pointer would be pointing to freed memory.

Instead of force updating the monitor on all non-user operations, just
do it on hot plugs. This allows for the feedback loop preventing logic
to still do what its supposed to do, without risking dangling pointers
on hot plugs.

Related: https://gitlab.gnome.org/GNOME/mutter/issues/189
Closes: https://gitlab.gnome.org/GNOME/mutter/issues/192
2018-08-27 08:33:00 +00:00
f4d07caa38 window: Pass flag to meta_window_update_monitor() instead of bool
The bool determines whether the call was directly from a user operation
or not. To add more state into the call without having to add more
boolenas, change the boolean to a flag (so far with 'none' and 'user-op'
as possible values). No functional changes were made.

https://gitlab.gnome.org/GNOME/mutter/issues/192
2018-08-27 08:33:00 +00:00
8a6d502e68 Update Italian translation 2018-08-27 07:58:58 +00:00
b6c2eec487 Update Indonesian translation 2018-08-26 13:51:06 +00:00
093aa086af Update Korean translation 2018-08-26 03:59:00 +00:00
ebafc256a0 renderer/native: Check calculated transform when creating view
The "backends: Move MetaOutput::crtc field into private struct"
accidentally changed the view transform calculation code to assume that
"MetaCrtc::transform" corresponds to the transform of the CRTC; so is
not the case yet; one must calculate the transform from the logical
monitor, and check whether it is supported by the CRTC using
meta_monitor_manager_is_transform_handled(). This commit restores the
old behaviour that doesn't use MetaCrtc::transform when calculating the
view transform.

Fixes: https://gitlab.gnome.org/GNOME/mutter/issues/216
2018-08-24 11:51:36 +00:00
aaed7c9a4f clutter: Set can_show_preedit flag on ClutterText
It is certainly able to visualize preedit text inline, so it must
announce itself as such.
2018-08-23 20:03:51 +00:00
fa8930817e clutter: Refactor ClutterText IM focus in into separate function
A just focused ClutterInputFocus must set itself up correctly on
all situations. Refactor this into a function, so it can be used
for the case where a ClutterText gets editable while focused.
2018-08-23 20:03:51 +00:00
e741adb82e backends/x11: Only free cursor if it was created successfully
XcursorLibraryLoadCursor can return 'None' if the current cursor theme
is missing the requested icon. If XFreeCursor is then called on this
cursor, it generates a BadCursor error causing gnome-shell to crash.

Fixes https://gitlab.gnome.org/GNOME/mutter/issues/254
2018-08-21 16:39:41 +02:00
deb541ef5a monitor-manager-kms: Check if GPUs can have outputs
We need a way for mutter to exit if no available GPUs are going to work.
For example if gdm starts gnome-shell and we're using a DRM driver that
doesn't work with KMS then we should exit so that GDM can try with Xorg,
rather than operating in headless mode.

Related: https://gitlab.gnome.org/GNOME/mutter/issues/223
2018-08-21 13:16:22 +00:00
29cc526e2e gpu-kms: Handle drmModeGetResources() failing
Avoid dereferencing the NULL return value if it fails. We still create
the MetaGpu, but we treat it as if it has no outputs.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/223
2018-08-21 13:16:21 +00:00
6a92c6f83f wayland/actor-surface: Intersect input/opaque region with surface region
As per specification

> The compositor ignores the parts of the input region that
> fall outside of the surface.

> The compositor ignores the parts of the opaque region that
> fall outside of the surface

This fixes culling problems under certain conditions.
2018-08-21 12:24:02 +02:00
b8340f1355 clutter-text: Avoid clipping the wrong framebuffer
`ClutterText` painting for editable single_line_mode actors like `StEntry`
is always clipped by:

`cogl_framebuffer_push_rectangle_clip (fb, 0, 0, alloc_width, alloc_height)`

So it's difficult to get the rectangle wrong. However in cases where the
target framebuffer has changed (`cogl_push_framebuffer`) such as when
updating `ClutterOffscreenEffect` we had the wrong old value of `fb`. And
so would be clipping the wrong framebuffer, effectively not clipping at all.
2018-08-20 18:07:32 +00:00
c7db234c11 wayland/xdg-shell: Intersect set geometry with subsurface tree geometry
Currently xdg-shell applies a geometry set with set_window_geometry
unconditionally. But the specification requires:

> When applied, the effective window geometry will be
> the set window geometry clamped to the bounding rectangle of the
> combined geometry of the surface of the xdg_surface and the
> associated subsurfaces.

This is especially important to implement viewporter and
transformation.
2018-08-20 14:37:10 +00:00
db22c13c4f wayland: Use surface size helper functions
Use meta_wayland_surface_get_width / meta_wayland_surface_get_width
to determine the size of a surface.
2018-08-20 14:37:10 +00:00
ad864083f9 wayland/surface: Add get_width() and get_height() helper functions
With viewporter / transformations it get's more complicated to
figure out the dimensions of a surface. Bundle it in this helper-
functions.
2018-08-20 14:37:09 +00:00
5f99eeb926 Bump version to 3.29.91
Update NEWS.
2018-08-20 15:28:24 +02:00
e1513b6b00 clutter/x11: Detect auto-repeated key events
Detect auto-repeated key events using the XIKeyRepeat flag.
2018-08-20 10:16:33 +00:00
0cc3cd62ba keybindings: Ignore auto-repeat events for some keybindings
Detect auto-repeat events in process_event and ignore them if the
keybinding has the META_KEY_BINDING_IGNORE_AUTOREPEAT flag.

Fixes: gnome-shell#373
2018-08-20 10:16:33 +00:00
0f40541bb2 clutter/enum: Add CLUTTER_EVENT_FLAG_REPEATED for auto-repeated events 2018-08-20 10:16:33 +00:00
db604dda89 Update British English translation 2018-08-19 16:46:41 +00:00
21ce6f96f1 wayland/keyboard: Create a separate keymap shm file per resource
By using the shm file when sending the keymap to all clients, we
effectively allows any client to change the keymap, as any client has
the ability to change the content of the file. Sending a read-only file
descriptor, or making the file itself read-only before unlinking, can
be worked around by the client by using chmod(2) and open(2) on
/proc/<pid>/<fd>.

Using memfd could potentially solve this issue, but as the usage of
mmap with MAP_SHARED is wide spread among clients, such a change can
not be introduced without causing wide spread compatibility issues.

So, to avoid allowing clients to interfere with each other, create a
separate shm file for each wl_keyboard resource when sending the
keymap. We could eventually do this per client, but in most cases,
there will only be one wl_keyboard resource per client anyway.

https://bugzilla.gnome.org/show_bug.cgi?id=784206
2018-08-17 16:34:05 +02:00
323a806d35 wayland/keyboard: Indentation fix 2018-08-17 16:34:05 +02:00
84ac28cbee Update Friulian translation 2018-08-17 03:49:35 +00:00
2860adcf65 Update MSGID_BUGS_ADDRESS in po/Makevars 2018-08-16 20:23:26 +02:00
2dbacfa8d6 wayland/keyboard: Accept key down serial after key up for popups
If a client maps a popup in response to a key-down event, but the
mapping doesn't occur until after the user has already released the same
button, we'd immediately dismiss the popup. This is problematic, as one
often presses and releases a key quite quickly, meaning any popup mapped
on key-down are likely to be dismissed.

Avoid this race condition by accepting serials for key down events, if
the most recent key-up event had the same keycode.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/180
2018-08-15 08:51:14 +00:00
85e5b160ee wayland: Implement text-input from wayland-protocols
This protocol supersedes the internal gtk_text_input protocol that
was in place. Functionally it is very similar, with just some more
verbosity in both ways (text_change_cause, .done event), and some
improvements wrt the pre-edit text styling.
2018-08-14 15:43:21 +00:00
9510fbcbac wayland: Make gtk-text-input "legacy"
It is superseded by zwp_text_input_v3.
2018-08-14 15:43:21 +00:00
7c06e21e5a idle-monitor: Store either 1 or 0 in the inhibited gboolean
Wrap the flag checking in !!(..) to make sure we always either store
TRUE or FALSE in the gboolean.
2018-08-14 15:14:05 +00:00
1bfa20929b backends/x11: Improve grab-device clock updates
meta_backend_x11_grab_device is performing X server clock comparison
using the MAX macro, which comes down to a simple greater-than.

Use XSERVER_TIME_IS_BEFORE, which is a better macro for X server
clock comparisons, as it accounts for 32-bit wrap-around.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/174
2018-08-13 21:00:33 +02:00
bafc43ca26 Update Turkish translation 2018-08-12 10:20:43 +00:00
d37528f693 Update Chinese (Taiwan) translation 2018-08-12 10:18:57 +00:00
37eeda0320 Revert "gpu-kms: Handle drmModeGetResources() failing"
This reverts commit acf70a3561
2018-08-10 16:31:03 +00:00
acf70a3561 gpu-kms: Handle drmModeGetResources() failing
Avoid dereferencing the NULL return value if it fails. We still create
the MetaGpu, but we treat it as if it has no outputs.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/223
2018-08-10 16:35:17 +01:00
24aef44baf virtual-input/evdev: Translate from button internal codes to evdev
Sending button events to a ClutterVirtualInputDevice, the API expects
button codes to be of the internal clutter type. The evdev
implementation incorrectly assumed it was already prepared evdev event
codes, which was not the case. Fix the evdev implementation to translate
from the internal representation to evdev before passing it along to
ClutterSeatEvdev.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/190
2018-08-09 13:04:07 +00:00
f7af32a3ea renderer/native: Fallback to non-planar API if gbm_bo_get_handle_for_plane fails
Commit c0d9b08ef9 replaced the old GBM API calls
with the multi-plane GBM API. However, the call to gbm_bo_get_handle_for_plane
fails for some DRI drivers (in particular i915). Due to missing error checks,
the subsequent call to drmModeAddFB[2] fails and the screen output locks up.

This commit adds the missing error checks and falls back to the old GBM API
(non-planar) if necessary.

v5: test success of gbm_bo_get_handle_for_plane instead of errno

This commit adopts solution proposed by Daniel van Vugt to check the return
value of gbm_bo_get_handle_for_plane on plane 0 and fall back to old
non-planar method if the call fails. This removes the errno check (for
ENOSYS) that could abort if mesa ever sets a different value.

Related to: https://gitlab.gnome.org/GNOME/mutter/issues/127
2018-08-09 12:36:34 +00:00
252dd52439 wayland: Clean up xwayland grabs even if surface is gone
If the surface is gone before `meta_xwayland_keyboard_grab_end()` is
called, we would bail out early leaving an empty grab, which will cause
a segfault as soon as a key is pressed later on.

Make sure we clean up the keyboard grab even if the surface is gone.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/255
2018-08-06 11:22:51 +00:00
c216397974 Update libpipewire requirements
PipeWire 0.2.2+ now provides libpipewire-0.2 and not libpipewire-0.1 anymore
2018-08-06 10:05:36 +02:00
841dc09d21 Updated Lithuanian translation 2018-08-05 23:42:47 +03:00
192b7887c3 Update Polish translation 2018-08-04 20:09:59 +02:00
1fd8fe65c5 Update German translation 2018-08-04 18:00:54 +00:00
a87c447b72 Updated Slovenian translation 2018-08-03 17:23:46 +02:00
c624fcbb8b Updated Slovenian translation 2018-08-03 12:13:42 +02:00
b393f3d540 clutter/actor: Inherit clone branch depth from parent
Children added to a parent after that parent (or its ancestors)
have already been cloned now inherit the clone branch depth of
the parent. Otherwise `clutter_actor_is_in_clone_paint` on the child
could return FALSE when it should have been returning TRUE.
2018-08-01 11:53:10 +08:00
3e3bc3e67f Bump version to 3.29.90
Update NEWS.
2018-08-01 02:44:57 +02:00
11d5e00003 plugin: Add back prototypes to META_PLUGIN_DECLARE()
G_DEFINE_DYNAMIC_TYPE() doesn't include those, so they are still
needed.
2018-08-01 02:44:57 +02:00
f0c9c25cf8 wayland-private: Make display_name non-const
The string used to point to memory owned by libwayland-server, but
with the ability to override the display name, we took over ownership
by copying the string as necessary.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/176
2018-07-31 23:40:01 +02:00
7fdaf7721c Don't cast free function passed to g_clear_pointer
The function is intentionally provided as macro to not require a
cast. Recently the macro was improved to check that the passed in
pointer matches the free function, so the cast to GDestroyNotify
is now even harmful.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/176
2018-07-31 23:40:01 +02:00
c403785d36 Stop using g_type_class_add_private()
It is now deprecated in favor of the G_ADD_PRIVATE() macro (usually
called via G_DEFINE_WITH_PRIVATE()).

https://gitlab.gnome.org/GNOME/mutter/merge_requests/176
2018-07-31 23:40:01 +02:00
4fe594bf9c clutter: Stop using g_type_class_add_private()
It is now deprecated in favor of the G_ADD_PRIVATE() macro (usually
called via G_DEFINE_WITH_PRIVATE()).

https://gitlab.gnome.org/GNOME/mutter/merge_requests/176
2018-07-31 23:40:01 +02:00
ec451b4674 plugin: Add META_DECLARE_PLUGIN_WITH_CODE() variant
Thanks to G_DEFINE_DYNAMIC_TYPE_EXTENDED(), this is a trivial addition that
will allow using G_IMPLEMENT_INTERFACE_DYNAMIC() or G_ADD_PRIVATE_DYNAMIC()
when declaring a plugin.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/176
2018-07-31 23:40:01 +02:00
43eb724b94 plugin: Simplify META_PLUGIN_DECLARE() macro
It's mostly boilerplate that G_DEFINE_DYNAMIC_TYPE() can take care
of, so use that internally.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/176
2018-07-31 23:40:01 +02:00
3d75b48d50 prefs: Remove override system
With the support for per-desktop default values in GSettings, we
no longer need the mutter-specific override mechanism.

https://bugzilla.gnome.org/show_bug.cgi?id=786496
2018-07-31 18:38:53 +00:00
4d465eac08 monitor: Use current monitor mode to check whether active
For historical reasons meta_monitor_is_active() checked whether it is
active by checking whether the main output have a CRTC assigned and
whether that CRTC has a current mode. At a later point, the MetaMonitor
got its own mode abstraction (MetaMonitorMode), but
meta_monitor_is_active() was never updated to use this.

An issue with checking the main output's CRTC state is that, if there is
some CRTC mode combination that for some reason isn't properly detected
by the MetaMonitorMode abstraction (e.g. some tiling configuration not
yet handled), meta_monitor_is_active() would return TRUE, even though no
(abstracted) mode was set. This would cause confusion here and there,
leading to NULL pointer dereferences due to the assumption that if a
monitor is active, it has an active mode.

Instead, change meta_monitor_is_active() to directly check the current
monitor mode, and log a warning if the main output still happen to have
a CRTC with a mode assigned to it. This way, when an not undrestood CRTC
mode combination is encountered, instead of dereferencing NULL pointers,
simply assume the monitor is not active, which means that it will not be
managed or rendered by mutter at all.

https://gitlab.gnome.org/GNOME/mutter/issues/130
2018-07-31 13:37:03 +02:00
db5abbb225 wayland: Remove unused GList *l 2018-07-31 11:47:51 +08:00
eb0865fe11 Add README.md
The welcome page on Gitlab is pretty boring for mutter. Improve that a
bit by adding a README file with some basic introduction.

Fixes: https://gitlab.gnome.org/GNOME/mutter/issues/245
2018-07-30 21:58:59 +02:00
e283cd7b91 tests: Add "closed-transient" test
When a transient window is destroyed, the expected behavior is that
focus is passed to the ancestor if possible. This was broken for
quite a while until the previous commit, so add a test case to make
sure it doesn't happen again.

https://gitlab.gnome.org/GNOME/mutter/issues/15
2018-07-30 17:48:42 +00:00
d99442d6e6 window: Explicitly exclude unmanaging window from focus again
Since commit b3b9d9e16 we no longer have to pass the unmanaging window
to make sure we don't try to focus it again, however the parameter also
influences the focus policy by giving ancestors preference over the normal
stack order.

https://gitlab.gnome.org/GNOME/mutter/issues/15
2018-07-30 17:48:40 +00:00
148da24f95 window: Don't refuse to move focus to the grab window
We refuse to move focus while a grab operation is in place. While this
generally makes sense, there's no reason why the window that owns the
grab shouldn't be given the regular input focus as well - we pretty
much assume that the grab window is also the focus window anyway.

In fact there's a strong reason for allowing the focus change here:
If the grab window isn't the focus window, it probably has a modal
transient that is focused instead, and a likely reason for the focus
request is that the transient is being unmanaged and we must move
the focus elsewhere.

https://gitlab.gnome.org/GNOME/mutter/issues/15
2018-07-30 17:48:39 +00:00
649c26e05a monitor-manager: Filter out low screen resolutions
Avoid exporting through org.gnome.Mutter.DisplayConfig.GetCurrentState
excessively-low screen resolutions setting both a minimum width and a minimum
height. GetCurrentState is e.g. used by Gnome Control Center to build a list of
selectable resolutions.

Fixes: https://bugzilla.gnome.org/show_bug.cgi?id=793223
2018-07-30 15:57:31 +02:00
48eaa36d41 wayland: Nullify monitor resources when updating outputs
If a client asks for xdg-output before we have set the output's logical
monitor, we would end up crashing with a NULL pointer dereference.

Make sure we clear the resource's user data when marking an output as
inert on monitor change so that we don't end up with a Wayland output
without a logical monitor.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/194
2018-07-30 09:22:12 +02:00
6e953e2725 native/gpu: Handle drmModeSetCrtc() failing gracefully
If drmModeSetCrtc() is called with no fb, mode or connectors for some
CRTC it may still fail, and we should handle that gracefully instead of
assuming it failed to set a non-disabled state.

Closes https://gitlab.gnome.org/GNOME/mutter/issues/70
2018-07-25 07:49:52 +00:00
3e357bd36f fixed typo 2018-07-24 13:16:36 +00:00
a3da4b8d5b window/wayland: Always update monitor for non-user ops
meta_window_wayland_update_main_monitor() would skip the monitor update
if the difference in scale between the old and the new monitor would
cause another monitor change.

While this is suitable when the monitor change results from a user
interactively moving the surface between monitors of different scales,
this can leave dangling pointers to freed monitors when this is
triggered by a change of monitor configuration.

Make sure we update the monitor unconditionally if not from a user
operation.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/189
2018-07-24 10:44:49 +02:00
0f43f86341 Updated French translation 2018-07-24 10:22:29 +02:00
d30a78767d Updated Spanish translation 2018-07-23 12:52:05 +02:00
5f37369adb Add remote access controller API
Add API to let GNOME Shell have the ability to get notified about remote
access sessions (remote desktop, remote control and screen cast), and
with a way to close them.

This is done by adding an abstraction above the remote desktop and
screen cast session objects, to avoid exposing their objects to outside
of mutter. Doing that would result in external parts holding references
to the objects, complicating their lifetimes. By using separate wrapper
objects, we avoid this issue all together.
2018-07-20 16:49:49 +02:00
c6691afa38 cogl: Fix cogl_frame_info_get_frame_counter docs
The docs previously suggested that `cogl_frame_info_get_frame_counter`
returned a timestamp of an unknown clock ID. That's not correct. The
cogl source code shows that it does and must use the same clock as
`cogl_get_clock_time`.

Related to https://gitlab.gnome.org/GNOME/mutter/issues/131
2018-07-20 15:48:56 +08:00
ff5d561ca6 build: Bump libpipewire requirement
After commit 0407a8b33d, we require the recently released 0.2 version.
2018-07-18 18:19:13 +02:00
5ac7109aaa Bump version to 3.29.4
Update NEWS.
2018-07-18 17:36:45 +02:00
7749f4d983 tests: Add the "parent_exported" test
This test aims at checking that the transient relationship set using the
xdg-foreign API is respected by mutter and that no crash occurs, such as
the one in issue !174.

Note: the crash from issue !174 occurs only if "attach_modal_dialogs" is
set, so one has to change that default value to "true" to be able to
trigger the crash:

    gsettings set org.gnome.mutter attach-modal-dialogs true

Related: https://gitlab.gnome.org/GNOME/mutter/issues/174
2018-07-18 14:31:38 +02:00
22aea3dc67 tests: Fix usage message for "set_parent"
"set_parent" usage message was referring to "menu" which is not a valid
command.
2018-07-18 14:30:51 +02:00
3d5784342d tests: Add "set_parent_exported" command
Add a "set_parent_exported" command to test the xdg-foreign support, so
that we can add a test which uses the GDK API for exported window:

  `gdk_wayland_window_set_transient_for_exported()`

That will allow to detect if transient is applied correctly between
foreign windows and detect possible crashes such as issue !174.

Related: https://gitlab.gnome.org/GNOME/mutter/issues/174
2018-07-18 14:30:40 +02:00
fa9e330f2c backend: Remove direct upower-glib usage
Monitor whether UPower is running ourselves. That allows us to keep the
same value for "lid-is-closed" throughout the process of UPower
restarting, preventing unwanted monitor re-configuration through the process.

Fixes another screen black out when UPower restarts and the laptop lid
is closed.
2018-07-18 10:17:37 +00:00
951219650f backend: Move lid-is-closed handling to MetaBackend
Rather than handle UpClient in both MetaBackend (to reset the idletime
when the lid is opened), and in MetaMonitorManager and
MetaMonitorConfigManager (to turn the screen under the lid on/off
depending on its status), move the ability to get the lid status from
UPower or mock it in one place, in MetaBackend.
2018-07-18 10:17:36 +00:00
49b23c7490 monitor-manager: Cache the last known value of "lid-is-closed"
Restarting UPower will make every property of UpClient emit a "notify"
signal (as a GDBusProxy would). Avoid mutter reconfiguring the displays
when upower restarts by caching the last known value of "lid-is-closed"
and only reconfiguring the displays if it actually changed.

This fixes a black out of the screen when UPower restarts.
2018-07-18 10:17:35 +00:00
644a618fb1 monitor-manager: Don't throw an error if UPower isn't running
Don't try to connect to a UpClient signal if creating the client failed,
because UPower isn't running for example.
2018-07-18 10:17:34 +00:00
1e3ac3cf2c backends/native: Remove unused upower-glib header
Wasn't removed in 657417a.
2018-07-18 10:17:34 +00:00
658c373580 Update Romanian translation 2018-07-17 18:26:47 +00:00
6d12d2eac2 tests: Move window-shown verification to test-runner
Previously we relied on the test-client to make sure that a window was
shown. For X11, we did not need to do anything, but for Wayland we had
to make sure we had drawn the first frame, otherwise mutter wouldn't
have a buffer making the window not showable.

Doing it this way doesn't work anymore however, since the 'after-paint'
event will be emitted even if we didn't actually paint anything. This is
the case with current Gtk under Wayland, where we won't draw until the
compositor has configured the surface. In effect, this mean we'll get a
dummy after-paint emission before the first frame is actually painted.

Instead, move the verification that a "show" command has completed by
having the test-runner wait for a "shown" signal on the window, which is
emitted in the end of meta_window_show(). This requires an additional
call to gdk_display_sync() in the test-client after creating the window,
to make sure that the window creation vents has been received in the
compositor.
2018-07-17 16:30:18 +02:00
356cad094b stack-tracker: Don't sort O-R's under guard window on top
As of "stack-tracker: Keep override redirect windows on top"
(e3d5bc077d), we always sorted all
override redirect on top of regular windows, as so is expected by
regular override redirect windows. This had an unwanted consequence,
however, which is that we should still not sort such override redirect
windows on top if they are behind the guard window, as that'd result in
windows hidden behind it now getting restacked anyway.

Fix this by only sorting the override redirect windows that are found
above the guard window on top. This fixes the override-redirect stacking
test.
2018-07-17 16:30:18 +02:00
161d2540e6 ClutterActor: Preserve valid paint volumes till the next relayout/repaint
Cuts down approximately all paint volume calculations when there's
windows that redraw frequently, but don't move.

https://bugzilla.gnome.org/show_bug.cgi?id=782344
2018-07-13 11:42:28 +00:00
94f4009882 compositor: Add get_paint_volume() implementation to MetaSurfaceActor
The special ::pick implementation there makes clutter fall into paths
that do require a get_paint_volume() implementation, or an infinite
area will be used.

Providing a paint volume here is easier on the invalidation mechanism.
2018-07-13 11:42:28 +00:00
ec8138773a compositor: Do not optimize obscured areas away in paint volumes
This optimization was presumably added before Clutter was able to
invalidate selected regions of an actor. Paint volumes are supposed
to be invariable as long as the actor conditions don't change.
Stacking of other actors shouldn't affect the paint volume, so it's
actually wrong to optimize those areas away here.
2018-07-13 11:42:28 +00:00
041be7c565 screen-cast-src: Allow negotiating the framerate
The framerate for screen cast sources was set to variable within 1 FPS
and the framerate of the monitor being screen casted. This meant that if
the sink didn't match the framerate (e.g. had a lower max framerate),
the formats would not match and a stream would not be established.

Allow letting the sink clamp the framerate range by setting it as
'unset', allowing it to be negotiated.
2018-07-13 08:59:14 +00:00
0407a8b33d screen-cast-src: Port to pipewire master
The PipeWire master branch saw some backports from the work branch,
including API changes making the 0.1 series more aligned with future
plans. Make mutter use the new API. This is needed to avoid dead locks
that existed in the older version.
2018-07-12 20:25:40 +00:00
912a6f5e3f contraints: Do not constrain modals without parent
xdg-foreign clears the `transient_for` of a modal dialog when its
imported parent is destroyed, which would later cause a crash in
`constrain_modal_dialog()` because the transient `NULL`.

So in case a modal dialog has no parent, do not try to constrain it
against its parent.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/174
2018-07-10 16:51:50 +02:00
89162a90aa launcher: First check if we are in a login session
For mutter developers we still want to support running from a VT, which
will be in a different login session.

Fixes #218
2018-07-10 08:43:35 +00:00
90a68f3118 Bump version to 3.29.3
Update NEWS.
2018-07-09 18:37:32 +02:00
951fb03a7c build: Fix distcheck
The test fix in commit 859bea629b broke distcheck, probably because
abs_srcdir is prefixed with a relative $BUILDROOT. Hopefully this is
the last autotools breakage before switching to meson, so don't
bother investigating too much ...
2018-07-09 18:37:32 +02:00
4837ea3434 meta-launcher: Find the current user's graphical session, not the pid's
If we're started by systemd --user, we might not be in the same session,
but this is nevertheless the one we are interested in.
2018-07-07 14:12:29 +01:00
3fbeeb9072 backends/x11: Force-update cursor when theme or size changed
Force update the cursor renderer after theme or size changes; otherwise
we'll be stuck with the old theme and/or size until something else
triggers resetting of the cursor.
2018-07-06 19:54:46 +02:00
0ca3526627 display: Make meta_display_get_workspace_manager() introspectable
So that it can be reached from Javascript.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:54:46 +02:00
5b8c8a4114 display: Remove replaced signals
MetaDisplay still had workspace signals, but nothing emitted them,
meaning we wouldn't get warnings if handlers were added there instead
of to MetaWorkspaceManager.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:54:46 +02:00
f635876eac x11: Open window decoration X11 connection earlier
If we wait with opening the X11 window decoration GDK connection, we
might end up with a terminated X11 server before we finish
initializing, depending on the things happening after spawning Xwayland
and before opening the MetaX11Dispaly. In gnome-shell, this involves
e.g. creating a couple of temporary X11 connections, and on disconnect,
if they happen to be the last client, the X server will terminate
itself.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:54:46 +02:00
1caaf0cd1e display: Export meta_display_close()
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:17 +02:00
e2464660bc x11-display: Set the correct default Xcursor theme size
Under Xorg the cursor size preference was pre-scaled originating from
gtk, while with Wayland it came directly from GSettings remaining
unscaled. Under Xwayland this caused the X11 display code to set the
wrong size with HiDPI configurations, which was often later overridden
by the equivalent code in gtk, but not always.

Fix this by always having the cursor size preference unscaled, scaling
the size correctly where it's used, depending on how it's used.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:17 +02:00
81c1c70c0a Move workspace related code from MetaDisplay to MetaWorkspaceManager
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:17 +02:00
e05cd6009a Add MetaWorkspaceManager skeleton
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:17 +02:00
390314adfb Rename errors.[ch] to meta-x11-errors.[ch]
Also rename meta_error_trap_* to meta_x11_error_trap_* and
move meta-x11-errors.c to src/x11

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:17 +02:00
2ac7afe8a9 remote-desktop: Remove unnecessary include
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:17 +02:00
d5c5669f2a Add --no-x11 flag so mutter wayland can be started without X11
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:17 +02:00
e8171ccdc1 Use MetaMonitorManager insted of MetaDisplay where possible
This drops display's monitors-changed signal and makes all
the code rely on MetaMonitorManager.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:17 +02:00
43f9cd537e Fix XDND handling to work without GDK and MetaX11Display
This fixes mutter --nested --wayland without X11

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
d4c4d6e64d Split GDK initialization from MetaUI
Get rid of the deprecated gdk_display_get_default_screen ()

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
89727aa747 xwayland: Destroy selection bridge windows before closing X11 display
Listen to the "x11-display-closing" signal so we can destroy the X11
selection bridge related windows before the X11 display is gone.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
de5e7a7175 Don't use gtk_settings callback to set shell_shows_app_menu
GTK+ won't be initialized if X11 is not available

Instead, when setting gtk-shell-shows-app-menu,
meta_prefs_set_show_fallback_app_menu should be
called as well.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
e6b885210c Make stack tracker work without X11
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
9f1ab1c3af Move workarea hint setting to MetaX11Display
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
9333a6da75 Make bell and libstartup-notification bits work without X11
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
8adab02757 Make workspace management work without X11
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
14d8aec4b8 prefs: Allow no-op listener removal
Allow removing a prefs handler that was already removed. This allows us
to remove prefs from the dispose function without having to keep track
of it in every place.
2018-07-06 19:47:16 +02:00
8e7e1eeef5 Prepare for making MetaX11Display conditional
- Stop using CurrentTime, introduce META_CURRENT_TIME
- Use g_get_monotonic_time () instead of relying on an
  X server running and making roundtrip to it

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
0a8ae8417c Get rid of MetaScreen
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
1d5e37050d Stop using MetaScreen where it is unnecessary
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
b7c3dada81 Move workspace handling to MetaDisplay and MetaX11Display
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
d79ffd3976 Move UI and key grabs to MetaX11Display
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
6458139c04 Move mouse window tracking to MetaDisplay
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
82307dd694 Move xinerama management to MetaX11Display
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
e1c67a1824 Move monitor management API to MetaDisplay
This includes changing various users to use MetaDisplay directly, who
used MetaScreen only for this before.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
68f261e8e2 Move rest of non-X11 specific objects from MetaScreen
This moves following objects from MetaScreen to MetaDisplay

- workareas_later and in_fullscreen_later signals and functions
- startup_sequences signals and functions
- tile_preview functions

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
1530f27513 Move X11 event, icon cache and property handling to MetaX11Display
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
05899596d1 Move X11 helper windows and xprops to MetaX11Display
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
98d912ba5f Move stack tracking and guard_window outside of MetaScreen
Move stack, stack_tracker to MetaDisplay guard_window to MetaX11Display

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
9e5ea8def4 Move groups and window/group prop hooks to MetaX11Display
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
722c975aca Move alarm and xids management to MetaX11Display
https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
937a9853cd Unmanage compositor and windows when closing display
Instead of unmanaging when closing the display, which is closed when
closing the screen, unmanage them directly from meta_display_close().

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
cd8f4259be Move screen size and cursor setting to MetaDisplay
Split X11 specific parts into MetaX11Display. This also required
changing MetaScreen to stop listening to any signals by itself, but
instead relying on MetaDisplay forwarding them. This was to ensure the
ordering. MetaDisplay listens to both the internal and external
monitors-changed signal so that it can pass the external one via the
redundant MetaDisplay(prev MetaScreen)::monitors-changed.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
c64d5ad8af Move X11 extension queries to MetaX11Display
Also split extension queries into their own functions

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
dacc041d0c Switch meta_error_trap functions to MetaX11Display
They are X11 specific functions, used for X11 code. They have been
improved per jadahl's suggestion to use gdk_x11_lookup_xdisplay and
gdk_x11_display_error_trap_* functions, instead of current code.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
18779109de Start populating MetaX11Display
- Moved xdisplay, name and various atoms from MetaDisplay
- Moved xroot, screen_name, default_depth and default_xvisual
  from MetaScreen

- Moved some X11 specific functions from screen.c and display.c
  to meta-x11-display.c

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
522f9b4c38 display: Emit signals when opening and closing X11 display
This is needed so that other parts can initialize and deinitialize X11
dependent functionality.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
3d2b9a3a69 Add MetaX11Display skeleton
Also reorder meta_display_open () and meta_display_close ()
to sort X11 and non-X11 specific members.

https://bugzilla.gnome.org/show_bug.cgi?id=759538
2018-07-06 19:47:16 +02:00
15fa7816bd configure.ac: Bump libmutter API version to 3 2018-07-06 19:47:16 +02:00
6621a9b5a0 tests: Add missing monitors config XML file
Lid switch test, but lid-switch.xml was not added, making it fail due to
theh file not being found.
2018-07-04 10:07:30 +00:00
04e411c2c0 compositor: Remove dead code: META_DISABLE_MIPMAPS
Seems to have been unused for quite some time.
2018-07-04 11:08:49 +08:00
859bea629b tests: use abs_srcdir to refer to metatest files
These files are used to run mutter-test tools and using relative
paths won't work if the builddir doesn't match the srcdir.

This won't affect their installation (in case the build option is passed)
2018-06-29 22:20:34 +02:00
cbc783108e tests: run mutter-test tools with G_TEST_* env variables
Set test srcdir and builddir to the absolute paths
2018-06-29 22:20:34 +02:00
2383801f7b Update Friulian translation 2018-06-29 13:33:53 +00:00
8626c69c2f window: Return -1 if meta_window_get_monitor is called on an unmanaged window
As opposed to crashing. In this case, letting the caller deal with
it is the best policy, since this is public API.

https://bugzilla.gnome.org/show_bug.cgi?id=788834
2018-06-28 16:24:07 +00:00
768ec15ea0 backends: Add logical monitor -> monitor -> output -> crtc ref chain
Make it so that each logical monitor has a reference to all the
monitors that are assigned to it.

All monitors has a reference to each output that belongs to it.

Each output has a reference to any CRTC it has been assigned.

https://bugzilla.gnome.org/show_bug.cgi?id=786929
2018-06-28 13:42:15 +02:00
1200182d70 backends: Move MetaOutput::crtc field into private struct
No functional changes. This is only done so that changes to reference
counting can done more reliably.

https://bugzilla.gnome.org/show_bug.cgi?id=786929
2018-06-28 13:42:15 +02:00
d9c18fd5bb monitor-manager: Add back warning messages
For some reason "backends: Remove X11 idle-monitor backend" removed
unrelated warning messages for when generated monitor configurations
that should work didn't, which also made the unit tests fail.

This commit adds them back, which also makes the tests pass again.
2018-06-28 11:23:39 +00:00
54709c16b5 wayland: Realize dmabuf buffers before trying to attach them
Commit 22723ca37 moved buffer realization to
meta_wayland_surface_commit() so that it wouldn't be part of
meta_wayland_buffer_attach().

However, creation of dmabuf buffers would call into
meta_wayland_buffer_attach() directly without realizing the buffer
first. attach() would then fail and mutter would effectively shut down
any clients using the zwp_linux_dmabuf protocol (note that if such
client was Xwayland, mutter itself would shut down as well).

Add the missing bit in order to make zwp_linux_dmabuf protocol work
again.
2018-06-21 21:47:05 +02:00
8da95b17f5 Update Romanian translation 2018-06-17 19:38:55 +00:00
d535c1eb6d Update Catalan translation 2018-06-17 10:31:36 +02:00
435b3c4bdb wayland: Create EGLStream-backed buffers through wl_eglstream_controller
One of the current limitations of EGLStreams is that there's no way to
resize a surface consumer without re-creating the entire stream.

Therefore, while resizing, clients will send wl_surface::attach requests
so the compositor can re-create its endpoint of the stream, but no
buffer will be available actually. If we proceed with the rest of the
attach operation we'll be presenting an empty buffer.

In order to fix this, a separate wl_eglstream_controller protocol has
been introduced that clients can use to request a stream re-creation
without overloading wl_surface::attach for that purpose.

This change adds the required logic to create the corresponding
wl_eglstream_controller global interface that clients can bind to.

Whenever a client requests a stream to be created, we just need to
create and realize the new EGLStream buffer. The same buffer resource
will be given at a later time to wl_surface::attach, whenever new
content is made available by the application, so we can proceed to
acquire the stream buffer and update the surface state.

https://bugzilla.gnome.org/show_bug.cgi?id=782575
2018-06-15 13:45:29 -07:00
22723ca371 wayland: Always realize buffers at surface commit time
Clients using EGLStream-backed buffers will expect the stream to be
functional after wl_surface::attach(). That means the compositor-side
stream must be created and a consumer attached to it.

To resolve the above, this change realizes buffers even when the attach
operation is deferred (e.g. synchronized subsurfaces).

https://bugzilla.gnome.org/show_bug.cgi?id=782575
2018-06-15 13:45:25 -07:00
edd3634bb5 wayland-buffer: Create EGLStream texture at buffer_realize time
When dealing with synchronized subsurfaces, we defer buffer attachments
until the parent surface state is applied.

That causes interaction issues with EGLStream backed buffers, as the
client expects the compositor-side stream to be functional after it
requests a wl_surface::attach.

By allowing the compositor to realize buffers without attaching them, we
could resolve the issue above if we define a realized EGLStream buffer
as a functional EGLStream (EGLStream + attached consumer).

This change moves the texture consumer creation part from the attach
function to the realize one.

https://bugzilla.gnome.org/show_bug.cgi?id=782575
2018-06-15 13:42:43 -07:00
1bf2eb95b5 renderer/native: Choose first EGL config for non-GBM backends
Commit 712ec30cd9 added the logic to only
choose EGL configs that match the GBM_FORMAT_XRGB8888 pixel format.
However, there won't be any EGL config satisfying such criteria for
non-GBM backends, such as EGLDevice.

This change will let us choose the first EGL config for the EGLDevice
backend, while still forcing GBM_FORMAT_XRGB8888 configs for the GBM
one.

Related to: https://gitlab.gnome.org/GNOME/mutter/issues/2
2018-06-15 19:43:04 +00:00
516fb524cb cursor-render/native: Realize hw cursor lazilly
Where to realize a hardware cursor depends on where on the screen it
will be displayed. For example it only needs buffers for the cursor
plane on a certain GPU if it overlaps with a monitor that is connected
said GPU.

Previously, we were too eager with uploading the cursor plane buffers,
which in effect resulted in the secondary GPU always being woken up
when changing the cursor, even though the cursor plane would actually
never be set unless the pointer cursor was moved to a monitor connected
to the secondary GPU. These wake-ups caused noticable stuttering; thus
by uploading the buffers more lazilly, the stuttering is avoided.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:56 +00:00
596b30096d cursor-renderer/native: Don't trigger redraw when cursor hidden
When a cursor is hidden, the native backend will properly hide the HW
cursor sprite as well, but it would communicate this as if the cursor
was not handled by the backend, while in fact it still was. This caused
the generic cursor rendering layer to queue a redraw.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:56 +00:00
7412794c66 cursor-renderer/native: Update hw state via generic update path
When force-updating the HW state we might end up with a situation where
the HW cursor is no longer usable. If this would happen, we'd before
this commit not trigger the fallback paths using a GL texture.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:55 +00:00
ad22b3f098 backend/native: Remove unnecessary cursor renderer update
It is already handled by the monitor-updated-internal signal handler in
meta-cursor-renderer-native.c, which will always be called indirectly
by resuming the monitor manager.

While at it, remove a useless comment.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:55 +00:00
206634e0ed cursor-renderer: Rename update_cursor function
Call it meta_cursor_renderer_update_cursor. This avoids confusing it
with the update_cursor MetaCursorRendererClass vfunc when navigating
the file.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:55 +00:00
ea05d2af49 cursor-renderer/native: Let the backend realize cursor sprite itself
It knows better when it's needed. For now, just do it just as before,
before drawing. Eventually, we can conditionalize where to realize
depending on the cursor sprite position.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:55 +00:00
6c7c566c6c cursor-renderer/native: Fix Xcursor image loading error handling
Check the return value whether there was an error, and change to
g_warning to warn while at it.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:54 +00:00
b596cf97ee cursor-renderer/native: Rename frame scheduling helper function
The function conditionally schedules a cursor animation frame, so
rename it to make that clearer.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:54 +00:00
9dcf9782b6 cursor-renderer: Centralize hw cursor realization paths
Use a common entry point into the cursor renderer implementations HW
cursor realization paths for all cursor sprite types. This is in
preparation for realizing at more strategic times.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:53 +00:00
0f519ffb05 cursor-renderer/native: Various whitespace fixes
https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:53 +00:00
42c78bd41f cursor-renderer/native: Fetch instead of pass wl_buffer when realizing
This is the next step in centralizing the cursor sprite hw sprite
realization paths.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:53 +00:00
b702c0fa5c cursor-renderer/native: Shorten some helper function names
Purely a cosmetic change, making a couple of unnecessarily long function
name shorter.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:53 +00:00
c80fd487f1 cursor-renderer: Fetch instead of pass Xcursor image when realizing
The end goal here is to being able to realize at any point in time
through a single API, so start by moving state into the cursor sprite
implementation.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:52 +00:00
817c8e568c wayland: Add wl_surface backed cursor sprite implementation
This removes the last use of the non-abstract form of MetaCursorSprite
usage.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:52 +00:00
b7e9388906 wayland/cursor-surface: Remove unnecessary NULL check
The priv->cursor_sprite is created on init() and destroyed on dispose()
so it will never be NULL when updating the cursor sprite texture.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:52 +00:00
b8336633a7 cursor-tracker: Split out XFIXES cursor code into cursor sprite type
Remove some X11 compositing manager specific code from the general
purpose cursor tracker into a new MetaCursorSprite based special
purpose XFIXES cursor sprite.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:51 +00:00
3c538d4a92 backends/cursor: Move out Xcursor functionality into own type
Introduce a new type MetaCursorSpriteXcursor that is a MetaCursorSprite
implementation backed by Xcursor images. A plain MetaCursorSprite can
still be created "bare bone", but must be manually provided with a
texture. These usages will eventually be wrapped into new
MetaCursorSprite types while turning MetaCursorSprite into an abstract
type.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:51 +00:00
2fc978ca9d backends/cursor: Rename X11 cursor creation function
It was prefixed with meta_cursor_, but it took a X11 Display, so update
the naming. Eventually it should be duplicated depending if it's a
frontend X11 connection call or a backend X11 connection call and moved
to the corresponding layers, but let's just do this minor cleanup for
now.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:51 +00:00
10dfc67dad backends/cursor: Minor whitespace cleanup
https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:50 +00:00
9ebcb719a1 backends/cursor: Clean up includes
Some were unnecessary, some were added even though not strictly needed.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:50 +00:00
2a20df0c50 backends/cursor: Make MetaCursorSprite derivable
This makes it possible to move out backing store specific code (such as
Xcursor handling) to separate units, while also making it easier to add
more types).

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:50 +00:00
d3441f7577 backends/cursor: Remove 'meta_' prefix from variable name
https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:49 +00:00
65c02e26db backends/cursor: Change variable name from 'self' to 'sprite'
This makes it somewhat more descriptive.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:49 +00:00
50ff9d4c71 wayland: Rename cursor role types
Rename the two cursor role types according to the convention used by the
other roles. This means that MetaWaylandSurfaceRoleCursor was renamed to
MetaWaylandCursorSurface, and MetaWaylandSurfaceRoleTabletCursor was
renamed to MetaWaylandTabletCursorSurface. The corresponding filenames
were renamed accordingly too.

https://gitlab.gnome.org/GNOME/mutter/issues/77
2018-06-15 19:09:49 +00:00
a3269dde95 idle-monitor: NULL check cached InhibitedActions property variant
We might not have a cached "InhibitedActions" property available for us,
so do as elsewhere in this file and NULL check before processing it.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/130
2018-06-14 17:52:11 +02:00
f2dea5d139 renderer-native: Remove no_add_fb2
drmModeAddFB2 allows userspace to specify a real format enum on
non-ancient kernels, as an improvement over the legacy drmModeAddFB
which derives format from a fixed depth/bpp mapping.

As an optimisation, Weston used to decide at the first failure of
drmModeAddFB2 that the ioctl was unavailable: as non-existent DRM
ioctls return -EINVAL rather than -ENOSYS or similar, bad parameters are
not distinguishable from the ioctl not being present.

Mutter has also implemented the same optimisation for dumb framebuffers,
which potentially papers over errors for the gain of avoiding one ioctl
which will rapidly fail on ancient kernels. Remove the optimisation and
always use AddFB2 where possible.

Closes: #14
2018-06-14 15:25:31 +00:00
3649795108 wayland: Detach MetaWaylandActorSurface from its actor on dispose
And ensure the actor is no longer reactive even though it might live longer
because of close effects, GCs, and whatnot. This ensures the actor is not
eligible for pointer picking within the destruction of its surface.

Closes: #188
2018-06-14 14:05:10 +02:00
36b9551f92 Update Chinese (Taiwan) translation 2018-06-13 08:36:21 +00:00
6abe4703c7 core: Hide close dialog before destroying
The MetaCloseDialog implementation object may stay artifically alive
for a longer period. This was usually fine till gnome-shell commit
b03bcc85aad, as the check_alive() timeout will keep running even
though the window went unmanaged/destroyed, leading to crashes.

In order to fix this, forcibly hide the dialog if it is visible and
the window is being unmanaged, so the timeout is stopped in time.
2018-06-08 17:41:34 +02:00
69ca584168 wayland: Handle get_subsurface() with a role-less parent surface
The order of role creation is undetermined, so we can't account that
the parent surface will have a role (and an actor) at the time of
creating the wl_subsurface role for a child surface.

So we must do it both ways, add the subsurface as a child on
get_subsurface() if the parent already got a role, and lazily add
child subsurface actors to the current one if the parent surface got
it at a later point.

Related: #132
2018-06-08 17:31:25 +02:00
8ee14a7cb7 renderer/native: Also wrap flip closures for EGLStreams
When using the EGLStream backend, the MetaRendererNative passed a
GClosure to KMS when using EGLStreams, but KMS flip callback event
handler in meta-gpu-kms.c expected a closure wrapped in a closure
container, meaning it'd instead crash when using EGLStreams. Make the
flip handler get what it expects also when using EGLStreams by wrapping
the flip closure in the container before handing it over to EGL.

https://bugzilla.gnome.org/show_bug.cgi?id=790316
2018-06-07 22:14:05 +02:00
909dbafd67 settings: Remove confused comment
It got lost, lets help it find the way out.
2018-06-07 12:57:52 +00:00
d5203f170e Make screen cast and remote desktop non-experimental
It's time to make this feature more accessible by not requiring editing
an array in gsettings.
2018-06-07 12:57:51 +00:00
2a45b7de7c clutter-input-device-xi2: Check for null group_modes before unref 2018-06-07 12:54:56 +01:00
62c67be4c8 clutter-actor: Fix uninitialized matrix multiply
`modelview` is uninitialized and the `apply` function just multiplies it.
What we really want is to initialize `modelview` so replace `apply` with
`get`.

Who knows what bugs this may have caused...
2018-05-31 15:43:27 +08:00
0332b7394e renderer-native: Don't crash if the FB surface can't be locked 2018-05-29 22:13:03 +00:00
15f41c9f68 device-manager-evdev: Add main seat to seats by default
Treat the main seat as other seats, so we don't have to handle it differently
in specific places. This was already the case before when a real device
was plugged before the startup, but not applied when hotplugging a device.
2018-05-29 10:35:51 +00:00
2a38601b42 device-manager-evdev: Free the main seat on finalize 2018-05-29 10:35:51 +00:00
d7bdc1591f device-manager-evdev: Set and unset the stage for the main seat too
When no input devices are available on startup the device manager might be fast
enough to be constructed so that no default stage is set yet, and thus when
main seat virtual devices are created they won't have a proper stage set.
If then we plug a real device, the events that an input manager could generate
won't be associated to any stage and thus won't be processed.

We need then ensure that when we update the stage for the device manager we
(un)associate it also to the main seat devices.
2018-05-29 10:35:51 +00:00
bd36764b4d wayland: Don't reset input focus on text commit
Preedit text can be active even after text commit. Resetting the input
focus will lead to unintended commit of the preedit text.

https://gitlab.gnome.org/GNOME/mutter/issues/152

Closes: #152
2018-05-26 18:58:42 +09:00
473bf38753 frames: Allow for unknown mouse buttons
Commit 47131b1d ("frames: Handle touch events") introduced an assert to
make sure that all mouse button actions are handled in mutter.

However, mice can have a more than 5 buttons, so simply ignore the
"other" actions instead of aborting.

Fixes: https://gitlab.gnome.org/GNOME/mutter/issues/160
2018-05-25 09:20:36 +00:00
f7747e4d4f Bump version to 3.29.2
Update NEWS.
2018-05-24 17:12:55 +02:00
e8dc2acfca Update Chinese (China) translation 2018-05-21 16:18:26 +00:00
cf734999fb wayland: Compare geometries after chaining up
After 20176d03, the Wayland backend only synchronizes with the
compositor after a geometry was set, and it was different from
the current geometry.

That commit was mistakenly comparing the geometry before chaining
up, which would yield a false negative on the case where the
client didn't call set_geometry() before commit().

Fix that by caching the old geometry locally, chain up (and thus
apply the new geometry rectangle), then comparing the old and
current geometry rectangles.

Fixes https://gitlab.gnome.org/GNOME/mutter/issues/150
2018-05-18 13:09:10 +00:00
c9c3283540 shaped-texture: Disable mipmapping during animation
This avoids overwhelming the GPU with trying to update mipmaps at a high
rate. Because doing so could easily cause a reduction in the compositor
frame rate and thus actually reduce visual quality.

In the case of a window that is constantly animating in the overview,
this reduces mutter's render time by around 20%-30%.
2018-05-18 16:45:26 +08:00
d2a8cdfd7c Update Galician translation 2018-05-15 22:33:40 +00:00
3e85ac8131 clutter-device-evdev: Get devices from main seat if no real seat is set
In devices such as ARM boards there could be no input devices connected on
startup, leading to a crash when we try to process artificial events that
could be queued (as gnome-shell does when syncing pointer).

Those events still should refer to a device and, in case we don't have one
provided by libinput we should still return the core devices defined in the
main seat.
2018-05-15 12:09:59 +01:00
5f83d9a5c8 clutter-seat-evdev: Add function to get device by id 2018-05-15 12:05:39 +01:00
ac20bf2000 frames: Handle touch events
This is just done on wayland as it'll break horribly on X11, we let
this happen through pointer emulated events in XISelectEvents evmask
instead.

Some things had to be made slightly more generic to accomodate touch
events. The MetaFrames shall lock onto a single touch at a time, we
don't allow crazy stuff like multi-window drag nor multi-edge resizes.

https://bugzilla.gnome.org/show_bug.cgi?id=770185
2018-05-14 17:11:57 +01:00
3561082aba frames: Make 1st button/motion handlers take generic events
This will ease handling of touch events through these same handlers.

https://bugzilla.gnome.org/show_bug.cgi?id=770185
2018-05-14 13:44:03 +01:00
e34c330f66 build: Adjust to filename changes
The meta-stage and meta-window-group headers got split into a public
and private part, but the Makefiles still reference the old files.
2018-05-07 22:41:01 +02:00
7655e09d00 build: Introspect some more types
While MetaStage, MetaWindowGroup and MetaDBusDisplayConfigSkeleton don't
appear explicitly in the public API, their gtypes are still exposed via
meta_get_stage_for_screen(), meta_get_*window_group_for_screen() and
MetaMonitorManager's parent type. Newer versions of gjs will warn about
undefined properties if it encounters a gtype without introspection
information, so expose those types to shut up the warnings.

https://bugzilla.gnome.org/show_bug.cgi?id=781471
2018-05-07 21:44:47 +02:00
be069fb8ae window-group: Remove undefined function declaration
Ever since the function has been made public, its name has been
meta_actor_is_untransformed() ...

https://bugzilla.gnome.org/show_bug.cgi?id=781471
2018-05-07 21:44:47 +02:00
a30166a547 clutter: Don't reference invalid pc in gir
Cally is built into clutter itself rather than exposed as a separate
library.

https://bugzilla.gnome.org/show_bug.cgi?id=781471
2018-05-07 21:44:47 +02:00
0f9c6aef99 screen-cast: Handle PipeWire errors more gracefully
Various code assumed PipeWire function calls would never fail. Some can
actually fail for real reasons, and some currently can only fail due to
OOM situations, but we should still not assume that will always be the
case.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/102
2018-05-07 19:24:47 +00:00
332d55f7f6 wayland/xdg-foreign: Fix child surface validation check
The role type should be either an xdg-shell toplevel, or a
xdg-shell unstable v6 toplevel.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/138
2018-05-07 19:16:40 +00:00
98d7024288 wayland/xdg-foreign: Send immediate destroy event to correct resource
The destroyed signal that was emitted if an imported surface was not
available when created, for example if the handle was invalid or
already unexported, was emitted on the wrong resource.
2018-05-07 19:16:39 +00:00
82564772dc build: Don't fail immediately when logind is missing
We require logind for the native backend, but the backend itself is
optional. However since commit 06c357d78, we will always throw an
error if neither logind nor elogind are available, even when the
backend is disabled.

As we still support "auto" - that is, whether the native backend is
enabled depends on whether its dependencies are available - the
easiest option is to make sure we always include either elogind or
libsystemd in the dependency check rather than erring out explicitly
if neither is found.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/96
2018-05-07 19:50:20 +02:00
33c2a38ff7 main: Fix typo 2018-05-04 20:15:33 +02:00
52fdd24467 wayland: avoid a crash in is_effectively_synchronized()
To check if a subsurface is effectively synchronized, we walk the
subsurface hierarchy to look for a non-subsurface parent or a subsurface
being synchronized.

However, when client is closing, the parent surface might already be
gone, in which case we end up with a surface being NULL which causes a
NULL pointer dereference and a crash.

Check if the parent surface is NULL to avoid the crash, and consider
it's already synchronized if it is NULL to avoid further updates.

Fixes: https://gitlab.gnome.org/GNOME/mutter/issues/124
2018-05-03 11:39:33 +02:00
2319cd9c40 idle-monitor: Don't try to auto-start SessionManager
The interface is provided by gnome-session and not activatable.

https://gitlab.gnome.org/GNOME/mutter/issues/134
2018-04-30 13:55:41 +00:00
3b4319a87c Update Romanian translation 2018-04-30 05:56:32 +00:00
20176d0395 wayland: Check if state and size changed before calling move_resize()
The current implementation of the XdgSurface v6 protocol does not check
if the window changed before calling meta_window_wayland_move_resize().

The problem with this approach is that calling this function is a costly
operation since we enter the compositor side. In GNOME Shell case, it is
in JavaScript, which triggers a GJS trampoline. Calling this function on
every mouse movement is naturally as terrible as it could be - and is
exactly what happens now.

This commit adds the necessary checks to only call move_resize() when
the window actually changed, or when it needs to be updated.

https://bugzilla.gnome.org/show_bug.cgi?id=780292
Issue: #78
2018-04-25 23:33:41 -03:00
762a3f89a9 wayland: Add function to query if window needs move or resize
This will be used by the next commit to determine when a window
geometry change should be ignored or not. Normally, it would be
enough to just check if the position and sizes changed.

The position, in this case, is relative to the client buffer, not
the global position. But because it is not global, there is one,
admitedly unlikely, situation where the window state is updated
while the client size and relative positions don't change.

One can trigger this by e.g. tiling the window to the half-left of
the monitor, then immediately tile it to half-right. In this case,
the window didn't change, just it's state, but nonetheless we need
to notify the compositor and run the full move/resize routines.

When that case happens, though, the MetaWindowWayland is tracking
the pending state change or a move. And this is what we need to
expose.

https://bugzilla.gnome.org/show_bug.cgi?id=780292
Issue: #78
2018-04-25 21:55:05 -03:00
822c2666f5 window: Let implementations finish state changes
In the old, synchronous X.org world, we could assume that
a state change always meant a synchronizing the window
geometry right after. After firing an operation that
would change the window state, such as maximizing or
tiling the window,

With Wayland, however, this is not valid anymore, since
Wayland is asynchronous. In this scenario, we call
meta_window_move_resize_internal() twice: when the user
executes an state-changing operation, and when the server
ACKs this operation. This breaks the previous assumptions,
and as a consequence, it breaks the GNOME Shell animations
in Wayland.

The solution is giving the MetaWindow control over the time
when the window geometry is synchronized with the compositor.
That is done by introducing a new result flag. Wayland asks
for a compositor sync after receiving an ACK from the server,
while X11 asks for it right away.

Fixes #78
2018-04-25 21:55:05 -03:00
b412e6c493 Bump version to 3.29.1
Update NEWS.
2018-04-25 20:25:43 +02:00
ae26cd0774 native: Restore previous EGL state after blitting onto secondary GPU
Before we just set it to "none", but this was not enough since various
calls will depend on not just the context being active, but the main
rendering surface.

Fixes https://gitlab.gnome.org/GNOME/mutter/issues/21
2018-04-25 17:22:24 +02:00
3104d697c0 cogl: Do not unref a NULL object
Add return-if-fail statement to avoid deferencing NULL object
2018-04-25 09:03:58 +00:00
0b3a1c9c31 monitor-manager: Find active monitor when deriving global scale
When deriving the global scale directly from the current hardware state
(as done when using the X11 backend) we are inspecting the logical
state they had prior to the most recent hot plug. That means that a
primary monitor might have been disabled, and a new primary monitor may
not have been assigned yet.

Stop assuming a primary monitor has an active mode before having
reconstructed the logical state by finding some active monitor if the
old primary monitor was disabled. This avoids a crash when trying to
derive the global scale from a disabled monitor.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/130
2018-04-25 10:50:50 +02:00
423c5f8e77 wayland: Let IM events go through
These paths implicitly relied on the forwarded IM key events having
a source_device backed by a real HW device. This assumption is no
longer held true since commit b5328c977.

Explicitly check the INPUT_METHOD flag so they are handled as they
should despite not being "real HW" events.
2018-04-24 23:48:01 +02:00
3bbff94878 backend: Don't center the pointers on monitor changes
As a follow up to the patch from a95cbd0a, we need to make sure
that the pointer is out of the way as well when monitors changed,
since that's the event that will prevail in some cases. Besides,
this is also consistent with what the code before a95cbd0a was,
which initialized the pointer position in the same way both in
this case and in the real_post_init() function.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/157
2018-04-24 21:58:38 +01:00
4ef886f51e wayland: Avoid actor updates non actor_surface role wl_surface.commit
We used to maintain an actor for cursors, even though we would possibly
use hw overlays or even some other overlay actor for those. This happens
no more, so check whether we are dealing with an actor-backed surface role
before fiddling with it.
2018-04-23 21:31:19 +02:00
22485ba36f wayland: Refactor surface actor into MetaWaylandActorSurface
All surface roles that do need a backing actor inherit from this
class, it makes sense to move actor management there. This also
means the MetaWaylandActorSurface is in charge of emitting
::geometry-changed on the MetaWaylandSurface.
2018-04-23 21:31:19 +02:00
8df2a1452c wayland: Notify actively of xwayland window/surface associations
Instead of scheduling a meta_later, keep track of the unassociated
windows, and look for matches as soon as the MetaWaylandSurface is
created on our side.

This will ensure the surface is given the Xwayland role before receiving
the first wl_surface.commit.
2018-04-23 21:31:19 +02:00
b12c92e206 wayland: Add MetaWaylandSurface::geometry-changed signal
Abstract this instead of having callers connect to notify:: signals
on the surface actor.
2018-04-23 21:31:19 +02:00
70036429bd wayland: Abstract access to the actor corresponding to a wl_surface
The actor itself will be shuffled around, abstract all external
access to it behind a function to make that easier later on.
2018-04-23 12:24:46 +02:00
44502be560 wayland: Do not reset frame list when merging pending state
In the synchronized subsurface case, the destination list may
contain other elements from previous wl_surface.commit calls.
Resetting the list will leave those dangling frame callbacks
that will lead to invalid writes when those get to be destroyed
(eg. on client shutdown).
2018-04-22 00:52:48 +02:00
8cf42cd06c clutter: Plug minor leak
clutter_stage_manager_list_stages() returns a copied list, which
should be freed.
2018-04-22 00:52:19 +02:00
b5328c977e clutter: Set slave=master in IM forwarded key events
The fix is twofold. On one hand, it makes sense not to relate IM (nor
any other) generated events to a HW device. On the other hand, if we
are unfortunate that an IM event is in flight when we are switching
to another TTY, it may arrive at a time when the source device is no
longer existent.
2018-04-22 00:52:05 +02:00
4339b23dd0 theme, frames: Use surface device scale instead of cairo_scale
Gtk now is caching the themed cairo surfaces, then as per
commit gtk@e36b629c the surface device scale is used to figure
out the current paint scaling.

Without this when using background-image's for window buttons
the -gtk-scaled icons isn't properly resized.

Fixes #99
2018-04-20 14:38:57 +00:00
a95cbd0aca backends: Don't center the pointer on initialization
Centering the pointer at startup causes undesired behaviour if
it ends up hovering over reactive elements, that might react
to that positioning, causing confusion. This is the case of
the login dialog when a list of different users is shown, as
centering the pointer at startup in that case will get the
user in the center of the screen pre-selected, which is not
the expected behaviour (i.e. pre-selecting the first one).

Fix this by simply moving the pointer out of the way, close
to the bottom-right corner, during initialization.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/157
2018-04-18 19:14:26 +00:00
6df2b7af55 clutter/evdev: Don't ignore CAPS lock as modifier
Mark CAPS lock as a modifier (as it should) so that when using XKB
options to change the default behaviour of CAPS lock, the new assigned
key can by used as a sticky key as well.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/112
2018-04-18 17:07:21 +02:00
c01b099dbd clutter/evdev: ignore injected events from IM
Input method can inject key events, which leads to multiple reported key
press/release events for a single user action.

Ignore those events as this confuses keyboard accessibility.
2018-04-18 17:07:21 +02:00
2d80fd02e7 xwayland: Don't abort if Xwayland crashes
Right now if Xwayland crashes, we crash, too.

On some level that makes sense, since we're supposed to control the
lifecycle of Xwayland, and by it crashing we've lost that control.

But practically speaking, the knock-on crash adds noise to the logs,
bug trackers, and retrace servers that only makes debugging harder.
And the crash isn't something mutter can "fix", since it's
ultimately from a bug in Xwayland anyway.

This commit makes mutter exit instead of crash if Xwayland goes away
unexpectedly.
2018-04-17 11:14:00 -04:00
bb65854065 xwayland: use g_autoptr for GError in xserver_died
Right now we explicitly g_clear_error any error we find, but that
makes it tricky to return early from the function, which a
subsequent commit will want to to do.

This commit switches GError to use g_autoptr so the error clearing
happens automatically.
2018-04-17 11:14:00 -04:00
bc05e49eba gpu-kms: Return NULL, not FALSE
Another small mistake spotted while working on #77. This
function returns a pointer, thus we should return NULL,
not FALSE.

Issue: #77
2018-04-16 16:30:21 +02:00
773b8384fa monitor-manager-kms: Don't add GPU if it fails
This is a small mistake spotted while working on a solution
for #77. When a GPU fails to initialize, we're adding them
anyway, which might have pretty bad consequences when trying
to use these NULL GPUs.

Issue: #77
2018-04-16 16:30:21 +02:00
7fdac6d310 monitor-manager-kms: Use g_autoptr for error
A minor code cleanup.
2018-04-16 16:30:21 +02:00
f6cd87734d native: Disable the use of KMS modifiers by default
Make it re-enable:able by a hidden "experimental feature". To enable, add
"kms-modifiers" to the org.gnome.mutter.experimental-features GSettings entry.
2018-04-16 16:29:38 +02:00
01a0fa9437 idle-monitor: Add ResetIdletime API, for testing purposes
The ResetIdletime API can be used instead of an "XTest" binary to
programmatically reset the idle time, as if the user pressed a button on
a keyboard.

This is necessary since we stopped using the XSync extension to monitor
idletimes, as it didn't consider inhibitors as busy, and mutter's
clutter code ignores "Core Events" as generated by XTest.

This patch will require minimal changes to gnome-settings-daemon's power
test suite so that "key press" idletime resets are triggered through
this D-Bus interface rather than through XTest and a roundtrip through
the X server.

https://bugzilla.gnome.org/show_bug.cgi?id=705942
2018-04-16 13:28:03 +02:00
657417a578 backend: Reset idle when lid is opened or resuming from suspend
There's no particular reason for this code to only ever be triggered on
Wayland, and allows removing X11-specific work-arounds from
gnome-settings-daemon.

See https://bugs.freedesktop.org/show_bug.cgi?id=59576

https://bugzilla.gnome.org/show_bug.cgi?id=705942
2018-04-16 13:28:03 +02:00
4af00ae296 idle-monitor: Take idle inhibition into account
Take idle inhibitions into account for when to fire idle watches as
requested by OS components.

This should stop gnome-session and gnome-settings-daemon considering
the session idle when they have been inhibited for longer than their
timeout, for example to avoid the screensaver activating, or the
computer suspending after watching a film.

https://bugzilla.gnome.org/show_bug.cgi?id=705942
2018-04-16 13:28:03 +02:00
84e575be77 x11: Allow XTest and core events to reset idletime
Now that we've removed the X11 specific backend of the idle monitor,
add back a cut-down version of it for the explicit purpose of being
told about idle time resets when XTest events are used.

XTest events are usually used by test suites and remote display software
to inject events into an X11 session. We should consider somebody moving
the mouse remotely to be just as "active" as somebody moving it locally.

https://bugzilla.gnome.org/show_bug.cgi?id=705942
2018-04-16 13:28:03 +02:00
7945ee5beb backends: Remove X11 idle-monitor backend
And use the old "native" backend for both X11 and Wayland. This will
allow us to share fixes between implementations without having to delve
into the XSync X11 extension code.

https://bugzilla.gnome.org/show_bug.cgi?id=705942
2018-04-16 13:28:03 +02:00
b6f5bab212 wayland: Plug surface pending state contents leak
When moving the pending state of an effectively synchronized subsurface
so it is applied together with the parent, perform a merge of the source
MetaWaylandPendingState into the destination one, instead of simply
overwriting the struct.

The other approach had 2 kind of leaks, one that would happen everytime
a wl_surface.commit happens on a sync subsurface (both surface/buffer
damage regions are leaked). The other more unlikely one would apply on
the rest of pending state data, happening whenever the compositor gets
>1 wl_surface.commit calls on the subsurface before the parent surface
gets its own.

The function has also been renamed to use the more descriptive "merge"
term.

Related: gnome-shell#64
2018-04-12 23:35:20 +02:00
5ad34e0efb monitor-manager: fix output ids returned by GetResources
Output ID is set equal to 'i' later in the loop. But 'i' was never
incremented, so all outputs were getting the same ID (equal to
the number of CRTCs, because 'i' was reused from the previous loop).


(cherry picked from commit 23c3f8bb18)
2018-04-11 17:57:25 +00:00
a1c34aad09 Updated Slovenian translation 2018-04-10 17:58:55 +02:00
98dfd5b887 screen-cast: Fix compile error
Credit goes to gcc for finding this typo.
2018-04-10 13:02:51 +02:00
17a745bf81 wayland: update enter/leave output after effects
Compositor effects change the actor size and position, which can lead to
inconsistent output enter/leave notifications, leaving clients' surfaces
without any output set.

Update output enter/leave notifications after all compositor effects are
completed so that we give clients accurate output location.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/104
2018-04-09 10:19:26 +02:00
85bbd82ae8 window-actor: add new signal "effects-completed"
When using plugins, the effects will affect the MetaWindowActor size
and position.

Add a new signal "effects-completed" wired to the corresponding
MetaWindowActor which is emitted when all effects are completed so that
derived objects can be notified when all effects are completed and use
the actual size and position.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/104
2018-04-09 10:19:26 +02:00
deda7a5235 theme: Scale titlebar spacing when computing x
The value is not scaled by default so it needs to be adjusted
depending on the window scaling, as it's done in other places.

Fixes: #87
2018-04-03 20:27:21 +00:00
96141e28f9 theme: add ".appmenu" class to the appmenu button
So it does gtk headerbar, so mutter should do.
2018-04-03 20:16:15 +00:00
e6109cfc22 renderer-native: Fall back to non-modifier GBM surfaces
If we attempt GBM surface allocation with a set of modifiers but the
allocation fails, fall back to non-modifier allocations. This fixes
startup on Pineview-based Atom systems, where KMS provides us a set of
modifiers but the GBM implementation doesn't support modifier use.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/84
2018-04-03 18:17:04 +00:00
3684f6b0ac clutter: Apply input hints/purpose on ClutterTextInputFocus focus in
And make the ClutterText-level properties independent from the input
focus, as those properties can be set anytime, not just when the
ClutterText actor is focused.

https://gitlab.gnome.org/GNOME/mutter/issues/66

Closes: #66
2018-04-03 14:55:17 +00:00
31b5059068 input-settings: Fix a typo in tap-and-drag setting 2018-03-29 09:51:32 -05:00
ebff7fd7f4 cursor-renderer-native: take rotation into account
Rotating an output would show duplicate cursors when the pointer is
located over an area which would be within the output if not rotated.

Make sure to swap the width/height of the output when rotated.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/85
2018-03-29 06:34:37 +00:00
6e415353e3 renderer-native: Swap then await earlier flips.
Rendering the next frame (which mostly happens as part of the flush done
in swap buffers) is a task that the GPU can complete independently of
the CPU having to wait for previous page flips. So reverse their order
to get the GPU started earlier, with the aim of greater GPU-CPU
parallelism.
2018-03-29 13:35:59 +08:00
67917db45f wayland: Use cursor position in logical monitor
When using two monitors size by side with different scales, once the
cursor moves from one output to another one, its size changes based on
the scale of the given output.

Changing the size of the cursor can cause the cursor area to change
output again if the hotspot is not exactly at the top left corner of the
area, causing the texture of the cursor to change, which will trigger
another output change, so on and so forth causing continuous surface
enter/leave event which flood the clients and eventually kill them.

Change the logic to use only the actual cursor position to determine if
its on the given logical monitor, so that it remains immune to scale
changes induced by output scale differences.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/83
2018-03-23 15:12:37 +01:00
8286557a05 clutter: Avoid unnecessary relayouts in ClutterText
We can save an unnecessary relayout if the required size to fully draw the text
is equal to the currently allocated size after the underlying text buffer or
attributes that only affect the PangoLayout have changed.
2018-03-22 21:21:43 +01:00
63e2c0329f window: Fix a small memory leak 2018-03-21 21:16:23 -03:00
06c357d781 mutter: allow building with elogind
This commit allows building mutter with elogind, which is
systemd-logind extracted into a standalone package. This
allows using mutter with its native-backend ( and consequently
wayland ) enabled on distros which use init systems other than
systemd.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/46
2018-03-21 21:42:37 +01:00
2f260edf19 cogl: Read pixels as per the stored format
By the looks of it, commit 95e9fa10ef was taping over an Intel DRI bug
that would make it return post-swizzling pixel data on glReadPixels().
There's been reports over time of that commit resulting in wrong colors
on other drivers, and lately Mesa >17.3 started showing the same symptoms
on Intel.

But texture swizzling works by changing parameters before fragment shaders
and reading pixels from an already drawn FBO/texture doesn't involve those.
This should thus use pixel_format_to_gl_with_target(), which will result in
correctly requesting the same pixel format than the underlying texture,
while still considering it BGRA for the upper layers in the swizzling case.

https://gitlab.gnome.org/GNOME/mutter/issues/72

Closes: #72
2018-03-21 18:45:20 +00:00
a5fd9a6e2f main: Fix build when native backend is disabled 2018-03-21 13:14:51 +00:00
4e6114b14d configure: Don't declare functions in AC_TRY_LINK and AC_TRY_COMPILE
https://bugzilla.gnome.org/show_bug.cgi?id=792717
2018-03-21 13:14:50 +00:00
65630d6310 build: Use portable sed syntax in src/Makefile.am
Replace non-portable \+ with \{, \} to avoid build failure on systems
not using GNU sed.

https://bugzilla.gnome.org/show_bug.cgi?id=792280
2018-03-21 13:14:50 +00:00
b8a81128e0 Fix some spelling errors
https://gitlab.gnome.org/GNOME/mutter/merge_requests/45
2018-03-21 13:22:35 +08:00
19e55b9a8c Added Slovenian translation 2018-03-20 22:39:36 +01:00
9ea9352c93 Update Slovak translation 2018-03-17 20:53:06 +00:00
817a76a7f5 wayland: Add parentheses around logical AND
As "suggested" by gcc and -Werror. Introduced by commit cb40049ec.
2018-03-16 16:59:14 +01:00
cb40049ec1 wayland: Ignore IM/synthetic key events when updating XKB state
This state tracks hardware devices' state, thus shouldn't be triggered by
events that were emulated/forwarded by the IM. Those may include modifiers
and would result in xkb_state being doubly set, and possibly stuck.

https://gitlab.gnome.org/GNOME/mutter/issues/74

Closes: #74
2018-03-15 18:44:07 +01:00
481e87032c clutter: Give the ClutterTextInputFocus a first stab at handling key events
Actor keybindings were dispatched in an earlier return path, which means
the IM doesn't get to see certain key events. Flip the order around so the
IM has an opportunity to handle all keypresses.

https://gitlab.gnome.org/GNOME/mutter/issues/65

Closes: #65
2018-03-13 20:00:10 +00:00
bf5ac39d46 Update Turkish translation 2018-03-13 17:15:33 +00:00
47856d9701 Bump version to 3.28.0
Update NEWS.
2018-03-12 19:45:19 +01:00
06429b12e2 Update Estonian translation 2018-03-12 17:29:38 +00:00
419fb81d40 wayland: Fix wrong condition in xdg_exporter.export
Commit d714a94d9 added support for stable xdg-shell surfaces while
preserving old unstable zxdg-shell v6 ones, but committed a mistake
in checking for both in the xdg_exporter.export error condition
paths. We want to check that the surface is neither of both.

https://gitlab.gnome.org/GNOME/mutter/issues/63

Closes: #63
2018-03-12 17:15:07 +00:00
f1bbe5c251 Update Swedish translation 2018-03-11 20:28:03 +00:00
27fef44d48 Update Chinese (Taiwan) translation 2018-03-10 12:20:08 +00:00
00b8ca7aeb Revert "window: Raise and lower tile match in tandem"
Raising and lowering windows in tandem without a proper grouping
mechanism ended up being more annoying than functional.

This reverts commit e76a0f564c.
2018-03-09 20:13:14 +01:00
675d429ba0 Updated Danish translation 2018-03-07 22:37:47 +01:00
f4d754c934 Updated Czech translation 2018-03-07 19:33:55 +01:00
8ae79182c1 Bump version to 3.27.92
Update NEWS.
2018-03-05 20:01:34 +01:00
712ec30cd9 renderer/native: Force EGL config pixel format
We just arbitrarily chose the first EGL config matching the passed
attributes, but we then assumed we always got GBM_FORMAT_XRGB8888. That
was not a correct assumption. Instead, make sure we always pick the
format we expect.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/2
2018-03-05 15:42:27 +00:00
7a41483ea0 egl: Fail first config choosing when no results
If there was no matching config, fail to find the first one.

https://gitlab.gnome.org/GNOME/mutter/issues/2
2018-03-05 15:42:27 +00:00
b4d642be52 egl: Rename EGL simple config chooser
It just picked the first config, so name it accordingly.

https://gitlab.gnome.org/GNOME/mutter/issues/2
2018-03-05 15:42:26 +00:00
0bf0e5780c clutter/x11: Communicate proper group/mode on pad events.
So we can trigger actions for the right mode.

https://gitlab.gnome.org/GNOME/mutter/issues/48

Closes: #48
2018-03-03 16:07:24 +00:00
d7c5e57134 clutter/x11: Implement missing ClutterInputDevice pad vmethods
Use libwacom to be able to find out modes, groups and button roles on
pad devices.

https://gitlab.gnome.org/GNOME/mutter/issues/48

Closes: #48
2018-03-03 16:07:23 +00:00
67bf936ef8 theme: Fix icon scaling
When painting the titlebar, button icons that aren't available in the
desired size need to be scaled. However the current code inverses the
scale factor, with the result that the adjusted icons are much worse
than the original icons, whoops.

This went unnoticed for a long time given that most icons are availa-
ble in the desired 16x16 size, and the most likely exceptions - window
icons - are not shown by default.

https://gitlab.gnome.org/GNOME/mutter/issues/23
2018-03-03 15:48:35 +00:00
15b7b40ea8 Update Galician translation 2018-03-03 13:18:53 +00:00
81bff3eba6 Updated Lithuanian translation 2018-03-03 13:37:54 +02:00
da3fd8f7fb Updated French translation 2018-03-03 11:19:13 +01:00
6e125d9d04 Update Dutch translation 2018-03-01 18:56:38 +00:00
80705018f9 Update Scottish Gaelic translation
(cherry picked from commit 543d031a55)
2018-03-01 10:46:47 +00:00
f39dacd451 Update German translation 2018-02-27 20:02:50 +00:00
33c070cdd5 backends/x11: Plug a leak 2018-02-27 14:10:04 +01:00
8d2f794bd3 clutter/x11: Plug a leak 2018-02-27 14:09:48 +01:00
1458dc394a build: Fix build with older versions of wayland-protocols
Instead of bailing out when a seemingly random file is missing, require
the version of wayland-protocols that includes the source to create that
built file.

Introduced in d714a94
2018-02-27 11:18:15 +01:00
c93877abb5 Update Italian translation 2018-02-26 07:58:26 +00:00
ef0efc9589 Update Latvian translation 2018-02-25 13:47:46 +00:00
09cdf39b68 Update Korean translation 2018-02-24 08:05:34 +00:00
a6ccbbfe68 Update Hungarian translation 2018-02-23 22:54:11 +00:00
e502adfa04 remote-desktop, screen-cast: Add version number to D-Bus APIs
In order to let applications gracefully handle version mismatches, add
a version property to the APIs. Also add a warning on the APIs that
these are not meant for public consumption.
2018-02-23 19:33:31 +08:00
8dd377da38 remote-desktop: Add support for discovering supported device types
This is so that application will not try to send touch events when
touch is not supported.
2018-02-23 19:33:31 +08:00
03a12f9458 remote-desktop: Add touch screen event support 2018-02-23 19:33:31 +08:00
061f69f2a2 remote-desktop: Fix absolute pointer motion coordinates
If the coordinates was for a stream not at the stage position (0, 0),
they'd be incorrect. Fix this by correctly translating the coordinates
according to the stream position.
2018-02-23 19:33:31 +08:00
4d5e1f690d screen-cast-stream: Add API to transform relative coordinates
Will be used to translate stream local coordinates to stage coordinates.
2018-02-23 19:33:31 +08:00
f3203f0330 screen-cast-session: Add API to get stream from object path
Will be needed by the remote desktop session to translate stream local
input coordinates.
2018-02-23 19:33:31 +08:00
d27e6921d6 remote-desktop: Add relative pointer motion event support
Relative pointer motions are assumed to be pre-accelerated.
2018-02-23 19:33:31 +08:00
c459ad7932 remote-desktop: Add smooth scroll event support 2018-02-23 19:33:31 +08:00
5ee825c081 remote-desktop: Add keyboard keycode event support
Keyboard keycode events will act as a physical keyboard thus depend on
the active keyboard layout.
2018-02-23 19:33:31 +08:00
1ead513b66 remote-desktop: Support multiple axis steps at once
Just call the corresponding clutter API once for each step.
2018-02-23 19:33:31 +08:00
9ed236bd67 remote-desktop: Fix notify axis input validity check
The check was inverted; allowed axis are 0 and 1, not the other way
around.
2018-02-23 19:33:31 +08:00
a1517cae1c clutter/device-manager: Add way to check virtual device support
This is needed so that mutter can let applications using the remote
desktop API to know whether touch screens are supported.
2018-02-23 19:33:31 +08:00
542502be53 clutter/x11: Add pointer motion support to virtual devices
As the other virtual input event delivery mechanisms, this also uses
the XTEST protocol.
2018-02-23 19:33:31 +08:00
203a0b37ed clutter: Add smooth scroll and touch API to virtual devices
So far only implemented on the evdev backend,as X11 doesn't support touch
devices nor smooth scrolling via XTEST.
2018-02-23 19:33:31 +08:00
b6477a826d clutter/evdev: Don't treat device touch slots as seat slots
IF two touch devices have colliding touch point IDs they'd interfere on
the seat. To avoid this, always allocate a seat wide slot for each
device wide slot, but don't use device slots directly in the seat.
2018-02-23 19:33:31 +08:00
95adc45b71 clutter/evdev: Move touch notification to seat 2018-02-23 19:24:07 +08:00
f20daf567d clutter: Silence gtk-doc warning 2018-02-23 19:24:07 +08:00
4345906663 wayland: Define abstract role types as actually abstract
They should not be instantiated by themself, only as actual roles.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 19:07:49 +08:00
d714a94d97 wayland: Add support for stable xdg-shell
This commit adds support for xdg_shell (the stable version). This was
done by first copying the old xdg-shell unstable v6 implementation into
a separate .c .h file pair (including various symbol renaming) then
porting the old xdg-shell unstable v6 implementation to the new stable
version.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:53 +08:00
514c7028f4 wayland: Use helper to set shell surface window
The helper deals with updating the surface output state.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:50 +08:00
44624736c5 wayland: Push actor state instead of itself pulling
Make the Wayland objects push the state relevant to their role to the
MetaSurfaceActor instead of MetaSurfaceActorWayland pulling the state
from the associated surface.

This makes the relationship between the actor and the objects that
constructs it more clear; the actor is a drawable that the protocol
objects control, not the other way around.

This will make it easier to "detach" a surface actor from a surface,
which is necessary when unmapping a window while the underlying surface
is yet to be destroyed and potentially reused.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:47 +08:00
0162cdf8ef surface-actor/wayland: Minor style fixes
https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:45 +08:00
7e17dd0098 xwayland: Base Xwayland surface role object on the actor role
The Xwayland role uses a MetaSurfaceActorWayland just so lets share
logic related to it. As a side effect, wl_surface.enter/leave starts
working for Xwayland surfaces.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:42 +08:00
704b73b041 wayland: Restructure surface role building blocks code
This commit moves out non-core wl_surface related code into separate
code units, while renaming types to fit a common scheme. The changes
done are:

 * ClutterActor based surface roles built upon
   MetaWalyandSurfaceRoleActorSurface. This object has been renamed to
   MetaWaylandActorSurface and related functionality has moved into
   meta-wayland-actor-surface.c.

 * The code related to roles backed by a MetaWindow (i.e. built upon
   MetaWaylandShellSurface) was moved into meta-wayland-shell-surface.c

 * The majority of subsurface related code was moved into into
   meta-wayland-subsurface.c and the object was renamed
   MetaWaylandSubsurface.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:40 +08:00
bd5e36cf0e wayland/surface: Stop using deprecated g_object_newv
Replace it with g_object_new_with_properties. This fixes a warning
about using deprecated API.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:38 +08:00
dbf56e24cb wayland/xdg-shell: Minor cosmetic cleanups
https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:36 +08:00
0371897e22 wayland/xdg-shell: Standardize xdg_positioner Wayland vfunc naming
Use the convention [interface]_[request] (..) used elsewhere in the
file.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:34 +08:00
cc5fe05c4d wayland/xdg-shell: Standardize object class interface vfunc names
Follow the convention that MetaSomeObject's class vfuncs should be
named meta_some_object_said_vfunc.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:28 +08:00
d8f13f6b4c wayland: Shorten MetaWaylandSurfaceRoleShellSurface name
It was annoyingly long, so rename it to MetaWaylandShellSurface.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:25 +08:00
a2959510e5 .gitignore: Add more things to ignore
Various protocol files had not been added.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/5
https://bugzilla.gnome.org/show_bug.cgi?id=791938
2018-02-23 18:57:16 +08:00
c8fbd4bee8 src/Makefile.am: Remove redundant generation rules
https://bugzilla.gnome.org/show_bug.cgi?id=792203
2018-02-23 18:52:58 +08:00
d5631f793e Update Galician translation 2018-02-23 00:50:09 +00:00
d4d160a186 Update Serbian Latin translation 2018-02-22 13:03:55 +00:00
4719c3f31e Update Serbian translation 2018-02-22 13:02:35 +00:00
1f5a2d6029 Updated Spanish translation 2018-02-22 12:40:22 +01:00
19bf4cf4f8 x11: Do not discard shape region for undecorated windows
mutter would discard the shape region set by the client if its matches
the entire client area in meta_window_x11_update_shape_region().

However, if the window is later resized (maximized or other), the
compositor will fail to update the shape region properly for undecorated
windows because the shape region was discarded, which causes black areas
to appear in place of the updated areas.

If the client window is undecorated, keep the shape region even if when
it matches the client area.

https://gitlab.gnome.org/GNOME/mutter/issues/27

Closes: #27
2018-02-22 08:02:01 +00:00
6f59e4858e renderer/native: Don't use modifiers to import linear DMA buffer
When the buffer modifier is DRM_FORMAT_MOD_LINEAR, we can use the
old code path. That means not specifying any modifier parameter.

It was an issue when the primary GPU was creating a linear GBM surface
and that a secondary GPU (not supporting modifiers) was trying to
import it. It was failing because the driver could not use the
import_modifiers extension even though it could in theory easily
import the buffer.

https://gitlab.gnome.org/GNOME/mutter/issues/18
2018-02-22 14:01:48 +08:00
aec85281ba native/renderer: Retrieve the right modifiers set for each GPU
We were retrieving the supported KMS modifiers for all GPUs even
though what we really need to intersect between these sets of
modifiers:

1) KMS supported modifiers for primary GPU if the GPU is used for
   scanout;

2) EGL supported modifiers for secondary GPUs (different than the
   primary GPU used for rendering);

3) GBM supported modifiers when creating the surface (already
   taken care of by gbm_surface_create_with_modifiers());

https://gitlab.gnome.org/GNOME/mutter/issues/18
2018-02-22 14:01:48 +08:00
b22875aae9 renderer/native: Use the right EGL image parameters for extra planes
There was a typo for modifier parameter of planes 1 & 2.

https://gitlab.gnome.org/GNOME/mutter/issues/18
2018-02-22 14:01:48 +08:00
962712ddc2 configure.ac: Bump API version number
Better late then never.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/6
2018-02-21 23:52:32 +08:00
de29627855 Bump version to 3.27.91
Update NEWS.
2018-02-21 01:09:22 +01:00
54dcff3aa2 backends: Monitor changes in active tools' settings
So the changes can be instantly applied while the tool is in proximity.
Before we would just do it on proximity-in, which doesn't provide a
good look&feel while modifying the tool settings in g-c-c.

https://gitlab.gnome.org/GNOME/mutter/issues/38

Closes: #38
2018-02-19 17:15:26 +01:00
bcd5882081 clutter: Check the ClutterTextInputFocus has focus before filtering events
Checking correct state is responsibility of the ClutterInputFocus user, and
it is indeed possible to get a focused ClutterText while its
ClutterInputFocus didn't get itself focused (eg. lack of IM).

https://gitlab.gnome.org/GNOME/mutter/issues/36

Closes: #36
2018-02-18 15:22:13 +01:00
69f56578a3 build: Fix distcheck
Missing protocol XML in wayland_protocols/EXTRA_DIST.

https://gitlab.gnome.org/GNOME/mutter/issues/35

Closes: #35
2018-02-18 12:32:04 +01:00
c00e092456 Update Croatian translation 2018-02-17 15:01:10 +00:00
a8cee14417 Update Brazilian Portuguese translation 2018-02-16 17:05:45 +00:00
8a89b0007c Update Galician translation 2018-02-14 22:46:11 +00:00
6934b83f44 wayland: Avoid clutter_input_focus method calls when unfocused
If text_input_enable() is called when there no active IM (eg. running plain
mutter), some ClutterInputFocus method calls that are not allowed while
unfocused will end up called, triggering critical warnings.

If there is no IM return early here, all other calls are superfluous then.
2018-02-12 14:44:30 +01:00
37aab9280a clutter/text: Be more pervasive at updating input method state
More concretely, ensure preedit text goes away after commit/focus_out,
and update cursor position right after focus_in.
2018-02-12 14:44:30 +01:00
49e8bc8a52 Update Indonesian translation 2018-02-10 15:04:22 +00:00
abd6b7affd Change naming of GParmSpec enum id string for naming consistency
GParamSpec enum string usually follows "PROP_" prefix and PROP_LAST is used
for last PROP string.

https://gitlab.gnome.org/GNOME/mutter/issues/28

Closes: #28
2018-02-10 13:49:14 +01:00
748223b896 cogl-texture: Remove unused function
Commit d8f2f583e6 removed the only caller.
2018-02-09 14:01:12 +01:00
c75eac27a8 wayland: Handle NULL event node/vendor/product on tablet methods
We currently don't handle NULLs on these correctly, yet they can be
so when running nested. Just refrain from sending those wp_tablet(_pad)
events in that case.
2018-02-09 13:39:15 +01:00
ac502c921d backends/x11: wacom pressure curve is a 32-bit property
The property has been 32 bits since around 2011 and has not changed, mutter
expects it to be 8 bits. The mismatch causes change_property to never
actually change the property.

https://gitlab.gnome.org/GNOME/mutter/issues/26

Closes: #26
2018-02-09 12:28:56 +01:00
134765c634 Update Polish translation 2018-02-08 02:08:46 +01:00
5149d6eb40 wayland: Fix handling of INCR transactions
The window checks in the XPropertyEvent handler were wrong both
ways, so transfers would be left stale after the first chunk was
dealt with.

https://gitlab.gnome.org/GNOME/mutter/issues/1

Closes: #1
2018-02-07 19:29:28 +01:00
006cdac531 wayland: Use read_all() when reading wayland selections
Plain input stream read() calls don't provide hard guarantees about
the number of bytes read, but the async method callback sort of
relies on bytes being less than requested only when reaching the
end of the transmitted data. If that happens mid transfer, that
doesn't bode well.

This is actually the behavior of g_input_stream_read_all(), so
switch to using it.
2018-02-07 19:29:28 +01:00
61bc1a7d6f clutter/x11: Remove video memory purge API
Clutter doesn't handle it anyway, and mutter now creates the
CoglRenderer object itself so we don't need this API anymore.

https://bugzilla.gnome.org/show_bug.cgi?id=739178
2018-02-07 11:04:51 +08:00
86ab3878e7 renderer/x11: Enable GPU memory purge error extension if available
This was done by the clutter X11 backend before prior to introducing
MetaRenderer, but during that work, enabling of said extension was lost.
Let's turn it on again.

https://bugzilla.gnome.org/show_bug.cgi?id=739178
2018-02-07 11:04:07 +08:00
f2d0e5021a cogl/x11/renderer: Silence introspection warning
We don't introspect CoglRenderer, so we shouldn't introspect API using it
either.

https://bugzilla.gnome.org/show_bug.cgi?id=739178
2018-02-07 11:03:42 +08:00
6d8286614f Update Friulian translation 2018-02-06 21:44:19 +00:00
70fcf745b8 main: Add --x11 command line argument
This is in order to force running as a X11 window manager/compositing
manager. Useful for debugging and other cases where the automatic
detection does not work as expected.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/15
2018-02-06 03:14:52 +00:00
589e999049 wayland: Do not fail on stalled .X11-unix entries
If for whatever reason, there are stalled files in /tmp/.X11-unix/ the
bind() to the abstract socket will succeed but not the bind() to the
to the UNIX socket.

This causes gnome-shell/mutter to fail because it cannot start Xwayland
(while it could actually, by using a different display).

In case of failure to bind to the UNIX socket, try the next display
instead of failing, to avoid stalled entries in /tmp/.X11-unix.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/13
2018-02-05 11:36:19 +00:00
d8f2f583e6 cogl-texture: refuse downloading textures in cogl_texture_get_data() on GLES
On drivers that do not support glGetTexImage2D (i.e. on GLES),
cogl_texture_get_data() has a "feature" that allows it to download
texture data by rendering the texture on an intermediate framebuffer
object and then reading back the data from there. However, this
feature requires the user to have previously set an "active"
framebuffer object in the context, which makes this very tricky
because it is not clear to the developer that he needs to do that
in order for some code to work on GLES (of course it works on
desktop GL, so nobody notices...) and additionally the code actually
crashes if an active fbo is not set!

This patch basically removes this feature in order to prevent
the crash and is in line with how this code has evolved in cogl-2.0:
https://git.gnome.org/browse/cogl/commit/?id=6d6a277b8e9a63a8268046e5258877ba94a1da5b

https://bugzilla.gnome.org/show_bug.cgi?id=789961
2018-02-05 11:22:36 +00:00
db866eb052 wayland: send shortcut inhibit “active” event
The shortcut inhibitor protocol states that the “active” event should be
sent every time compositor shortcuts are inhibited on behalf of the
surface.

However, mutter would send that event only if the surface is focused,
which might not be the case if focus is on a shell surface.

Send the “active” event unconditionally to match the protocol
definition.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/10
2018-02-05 09:06:49 +00:00
d092e913d6 gpu-kms: Don't add outputs without modes
There seems to be a kernel race when one disconnects an external
monitor connected to a DisplayPort via a USB-C adapter. The race
results in a connector being reported as connected, but without any
modes supported.

This had the side effect that we tried to set a preferred mode to
the first listed mode, but as no modes were available, we instead tried
to dereference the first element of a NULL array, causing a
segmentation fault.

Mitigate this by skipping adding output if no supported modes are
advertised and the output doesn't support scaling, while moving the
fallback path for calculating a preferred output mode to after possibly
adding the common modes, to avoid the unvolentary NULL dereference.

https://bugzilla.gnome.org/show_bug.cgi?id=789501
2018-02-05 10:38:54 +08:00
6147be3dff Update Indonesian translation 2018-02-04 12:28:55 +00:00
57f55d486d backends/x11: Preserve XI1 XDevice throughout ClutterInputDevice lifetime
Opening and closing the device may result into XI2 grabs being cut short,
resulting into pad buttons being rendered ineffective, and other possible
misbehaviors. This is an XInput flaw that fell in the gap between XI1 and
XI2, and has no easy fix. It pays us for mixing both versions, I guess...

Work this around by keeping the XI1 XDevice attached to the
ClutterInputDevice, this way it will live long enough that this is not
a concern.

Investigation of this bug was mostly carried by Peter Hutterer, I'm just
the executing hand.

https://gitlab.gnome.org/GNOME/mutter/issues/7

Closes: #7
2018-02-01 11:02:01 +01:00
6be56de140 backends/x11: Fix time-comparison bug causing hang
A comparison in translate_device_event() does not account for the fact
that X's clock wraps about every 49.7 days.  When triggered, this causes
an unresponsive GUI.

Replace simple less-than comparison with XSERVER_TIME_IS_BEFORE macro,
which accounts for the wrapping of X's clock.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/12
2018-02-01 15:34:12 +08:00
206ca43c91 wayland: No need to check for keyboard
meta_wayland_compositor_is_shortcuts_inhibited() does not need to check
if the provided source is an actual keyboard.

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/8
2018-01-31 16:04:20 +01:00
f8f1bcfa9e backends: Add support for Wacom stylus tertiary-button-action
The tertiary-button-action (see bug 790028) is a place for g-c-c to store
the action which should be performed when a stylus' third button is pressed.
Pressing this button is signaled as a BTN_STYLUS3 event from the kernel or
X11 button 8.

https://bugzilla.gnome.org/show_bug.cgi?id=790033
2018-01-30 19:28:02 +01:00
91df801ffb clutter/evdev: Add support for BTN_STYLUS3
BTN_STYLUS3 is defined by the Linux 4.15 kernel and is sent when the
third button on a stylus is pressed. At the moment, only Wacom's "Pro
Pen 3D" has three stylus buttons. Pressing this button triggers a button
8 event to be sent under X11, so we use the same mapping here.

https://bugzilla.gnome.org/show_bug.cgi?id=790033
2018-01-30 19:28:02 +01:00
97f142d1cc x11/window: Mark restored workspace as “set”
When a window's workspace is not NULL, on_all_workspace should be FALSE.
Similarly, when on_all_workspace is TRUE, the window workspace should be
NULL.

This is an assumption in multiple places in the code, including when
setting the workspace state, the window is either added or removed from
all workspaces only if the window's workspace is NULL.

This rule is initially enforced at creation in _meta_window_shared_new()
when a initial workspace is set. However, when the initial workspace is
set from the session info, the initial workspace is not marked as “set”
which leads to an assertion failure when unmanaging windows, because the
window is not removed from all the workspaces.

When applying the session info to a window, mark the workspace as “set”.

https://gitlab.gnome.org/GNOME/mutter/issues/4

Closes: #4
2018-01-30 10:08:58 +01:00
5ea3a4ecbb Update Hungarian translation 2018-01-26 20:48:01 +00:00
fbd5a74a0b session: use initial workspace if no workspace set
Having “on_all_workspaces_requested” FALSE on a window does not imply a
workspace is set.

If the X11 window is placed on a secondary monitor while workspaces
applies on primary monitor only  (“workspaces-only-on-primary” set) then
“on_all_workspaces_requested” is FALSE while “on_all_workspaces“ is TRUE
and the associated workspace is NULL, leading to a crash when saving the
gnome-shell/mutter session.

So if no workspace is set, use the “initial_workspace” instead to avoid
a NULL pointer dereference.

https://bugzilla.gnome.org/show_bug.cgi?id=792818
2018-01-25 10:47:44 +01:00
58bb61e161 clutter/stage: Set framebuffer state directly
clutter_set_viewport always operates on the draw fb, but
mutter sometimes has an offscreen fb it uses instead.

This commit uses the non-deprecated, clutter_framebuffer_set_viewport
function, which takes an explicit fb argument.

Closes: https://gitlab.gnome.org/GNOME/mutter/merge_requests/2
2018-01-25 11:41:54 +08:00
dbd053020a settings: Avoid warning when clearing xwayland grab access lists
On the first run, they are NULL, so don't try to free them.

https://bugzilla.gnome.org/show_bug.cgi?id=792853
2018-01-25 11:40:03 +08:00
c063d43be8 screen-cast: Update to pipewire 0.1.8 API
Remove per micro version code, the API changed too much to keep both in
place.

https://bugzilla.gnome.org/show_bug.cgi?id=792854
2018-01-25 11:40:03 +08:00
35b77a61c8 Merge branch 'wip/fmuellner/clean-up-shortcut-settings' into 'master'
Clean up shortcut settings

See merge request GNOME/mutter!1
2018-01-24 21:11:27 +00:00
32547d2eff data: Don't expose window shading shortcut
GTK+ doesn't support shading of client-side decorated windows, and likely
never will (not least because shading is conceptually questionable if the
app customizes the titlebar), and neither do other CSD implementations like
Chromium's. A shortcut that only works with a decreasing number of windows
is more confusing than helpful, so don't expose it.

https://bugzilla.gnome.org/show_bug.cgi?id=645460
2018-01-24 19:09:27 +01:00
dc37ee2782 data: Don't expose horizontal workspace keybindings to Settings
Given that GNOME has used a vertical workspace layout ever since 3.0,
allowing users to assign keyboard shortcuts for horizontal workspace
navigation isn't useful at all, as rightfully pointed out by Bastien
Nocera.

https://bugzilla.gnome.org/show_bug.cgi?id=645460
2018-01-24 19:09:27 +01:00
371e5df568 remote-desktop-session: Don't always warn about axis steps
The condition for warning was wrong, causing it to always warn no
matter the input.

https://bugzilla.gnome.org/show_bug.cgi?id=792062
2018-01-24 12:15:27 +08:00
cc4e007148 renderer/native: Create GBM surfaces with modifiers
Now that we have the list of supported modifiers from the monitor
manager (via the CRTCs to the primary planes), we can use this to inform
EGL it can use those modifiers to allocate the GBM surface with. Doing
so allows us to use tiling and compression for our scanout surfaces.

This requires the Mesa commit in:
Mesa 10.3 (08264e5dad4df448e7718e782ad9077902089a07) or
Mesa 10.2.7 (55d28925e6109a4afd61f109e845a8a51bd17652).
Otherwise Mesa closes the fd behind our back and re-importing will fail.
See FDO bug #76188 for details.

https://bugzilla.gnome.org/show_bug.cgi?id=785779
2018-01-24 11:42:30 +08:00
c0d9b08ef9 renderer/native: Use modifier-aware GBM API
Newer versions of GBM support buffer modifiers, including multi-plane
buffers. Use this new API to explicitly pull the information from GBM,
and feed it to drmModeAddFB2WithModifiers.

https://bugzilla.gnome.org/show_bug.cgi?id=785779
2018-01-24 11:39:01 +08:00
d99cd279d2 renderer/native: Use drmModeAddFB2 where available
drmModeAddFB2 allows specifying multiple planes, as well as directly
specifying the format, rather than relying on a depth/bpp -> format
mapping.

https://bugzilla.gnome.org/show_bug.cgi?id=785779
2018-01-24 11:35:07 +08:00
d670a1aa78 crtc/kms: Add parsing for IN_FORMATS property
The KMS IN_FORMATS blob property contains a structure defining which
format/modifier combinations are supported for each plane. Use this to
extract a list of acceptable modifiers to use for the primary plane for
XRGB8888, so we can ask EGL to allocate tiled/compressed buffers for
scanout when available.

https://bugzilla.gnome.org/show_bug.cgi?id=785779
2018-01-24 11:33:40 +08:00
76b396846d monitor: Set MINIMUM_LOGICAL_HEIGHT to 480
Using 800x600 as minimum logical size is very 4:3 thinking, while a lot of
modern devices are 16:9. The specific reason for this commit is to allow
1.5 scaling at mini-laptops (clamshell devices) with e.g. a 5.5"
1280x720 screen. Given that this device has a keyboard, one obviously
is not holding it very close to ones eyes and at 220 dpi that means the text
is too small at scale 1.0. For one real world example of such a device see:
https://en.wikipedia.org/wiki/GPD_Win

https://bugzilla.gnome.org/show_bug.cgi?id=792765
2018-01-23 11:07:04 +08:00
bd0105ba8d Update Esperanto translation 2018-01-22 19:14:18 +00:00
6dcce19932 Don't attempt to get monitor geometry on non-existent monitors
https://bugzilla.gnome.org/show_bug.cgi?id=788834
2018-01-21 14:41:48 +01:00
cc40a885ef Update POTFILES.skip 2018-01-18 16:32:36 +01:00
513c278077 clutter: Make ClutterText request toggling the input panel
So gnome-shell is able to show the OSK for it.
2018-01-18 16:20:45 +01:00
ac8ee9a08c clutter: Add clutter_text_has_preedit()
This function returns TRUE if there is any preedit going on. This method
will be useful in gnome-shell where similar checks are performed on
StIMText actors.
2018-01-18 16:20:45 +01:00
952c1fefa2 clutter: Add input-purpose/hint properties to ClutterText
So those properties can be changed or queried within shell UI.
2018-01-18 16:20:45 +01:00
18b8f9bfed wayland: Bolt MetaWaylandTextInput in.
Offer the text-input interface global, so it can be used by clients. The
MetaWaylandSeat will also let MetaWaylandTextInput intercept key events
before the keyboard interface handles those.
2018-01-18 16:20:45 +01:00
f08417b618 wayland: Let IM-processed key events go through MetaWaylandKeyboard
Those have the "synthetic" flag as set by Clutter guts, but should be
processed anyway. Perhaps a "key-repeat" flat would make sense...
2018-01-18 16:20:45 +01:00
62c9713361 wayland: Implement text input protocol
This is the implementation of the internal text-input protocol that will
be used to communicate IMs (to be implemented by gnome-shell) with clients.
The text_input protocol has its own focus expressed through enter/leave
events, that will typically follow the keyboard's.

The client will be able to communicate its current status (eg. focus state,
cursor rectangle in surface coordinates, text surrounding the cursor
position, ...) and will receive commands from the compositor (eg. preedit
text, committing a string, ...).

Whenever there is an active input method, the compositor will route key
events directly through it. The client will not receive wl_keyboard
events if the event is consumed by the IM.
2018-01-18 16:20:45 +01:00
efd7a4af5e protocol: Add internal text input protocol
The text input protocol has been made internal thus far, so mutter ships an
internal copy.
2018-01-18 16:20:45 +01:00
3a914a915e clutter: Implement ClutterInputFocus subclass for ClutterText
This only applies when the actor is editable. This object will allow
editable ClutterText instances to interact with the input method.
2018-01-18 16:20:45 +01:00
aa6561a3b1 clutter: Add ClutterInputMethod and ClutterInputFocus
ClutterInputFocus is an abstract object to be subclassed by UI actors and
the wayland interface and represents the user of an input method. It
represents the current focus of the input method, so all emitted signals
and public API hooks are expected to be called when the input method is
currently interfacing with the input focus.

ClutterInputMethod is an abstract class (to be implemented in the upper
layers) that represents the input method itself. Besides focus management
itself, all public API calls that would be called by the subclasses are
delivered through the current input focus.
2018-01-18 15:35:29 +01:00
9eb9623288 clutter: Add ClutterBackend IM setter/getter
The input method will be global to Clutter and shared between all the
IM aware foci. These methods allow querying it and setting one up.
2018-01-18 15:33:12 +01:00
8c988aa632 clutter: Add special event flag for events that went through an IM
This will be useful to let Clutter know whether those should be or have
already been dispatched through an input method.
2018-01-18 15:33:12 +01:00
13cf19e0b6 wayland: shortcuts inhibitor requires a window
Issuing a shortcut inhibit request for a surface without a window set
will lead to a crash when trying to show the shortcut inhibitor dialog.

In such a case, it's safer to deny the request.

https://bugzilla.gnome.org/show_bug.cgi?id=792599
2018-01-18 14:08:13 +01:00
eac0e253e1 wayland: Add missing breaks on MetaWaylandSeat event handler
The events might fall through if there's no corresponding active
pointer/keyboard/touch interface. Barring bugs this should be safe to do,
just a bit wasteful.
2018-01-17 14:00:44 +01:00
7346419295 clutter/evdev: Ensure a valid ClutterEventSequence on single-touch devices
Libinput shall report those as having slot=-1, which gets mistakenly
translated into the special "NULL" ClutterEventSequence. Making those
events get a non-NULL sequence will make single touch devices work.

https://bugzilla.gnome.org/show_bug.cgi?id=792005
2018-01-17 00:22:22 +01:00
3e77f6704b wayland: send xdg-output size as size, not position
https://bugzilla.gnome.org/show_bug.cgi?id=792527
2018-01-15 10:41:01 +01:00
01e27a4366 input-settings/x11: Fix tap-and-drag libinput property name
It's "libinput Tapping Drag Enabled", not "libinput TappingDrag
Enabled".

https://bugzilla.gnome.org/show_bug.cgi?id=775755
2018-01-12 18:57:57 +08:00
4e3b26d2ed clutter/evdev: Ignore unknown touch points
We might receive touch events for unknown touch points, for example
when starting mutter while touching the screen (resulting in no
touch-down event ever being received). Avoid crashing when this happens
by just dropping these events on the floor.

https://bugzilla.gnome.org/show_bug.cgi?id=791371
2018-01-12 18:57:43 +08:00
5f05112b9a wayland: update location prior to maximize
When maximizing a window, the previous location is saved so that
un-maximize would restore the same original window location.

However, if a Wayland client starts with a window maximized, the
previous location will be 0x0, so if we have to force placement in
xdg_toplevel_set_maximized(), we should update the location as well so
that the window is placed on the right monitor when un-maximizing.

For that purpose, add a new flag to force the update of the window
location, and use that flag from xdg_toplevel_set_maximized().

https://bugzilla.gnome.org/show_bug.cgi?id=783901
2018-01-11 11:03:04 +01:00
6cf7d2d47f wayland: Do not enforce a size on un-maximize
When un-maximizing, use a zero size to pass to the client so that it can
use the right un-maximized size that fits.

https://bugzilla.gnome.org/show_bug.cgi?id=783901
2018-01-11 11:03:04 +01:00
1139ace244 core: Add new unmaximize flag
Wayland clients know their size better, so for Wayland we'd rather not
try to resize the client on un-maximize, but for this to work we need a
new MetaMoveResizeFlags.

https://bugzilla.gnome.org/show_bug.cgi?id=783901
2018-01-11 11:03:04 +01:00
bd9a300801 window: Defer stack placement without a buffer
When closing a window and showing a new one, the new one may not be
granted input focus until it gets a buffer on Wayland.

If another window is chosen to receive focus and raised on top of stack,
the newly mapped window is focused but placed underneath that other
window.

Meaning that for Wayland surfaces, we need to defer adding the window to
the stack until we actually get to show it, once we have a buffer
attached.

Rather that checking the windowing backend prior to decide if a window
is stackable or not, introduce a new vfunc is_stackable() which tells
if a window should be added to the stack regardless of the underlying
windowing system.

Also add meta_window_is_in_stack() API rather than checking the stack
position directly (replacing the define WINDOW_IN_STACK only available
in stack.c) and remove a window from the stack only if it is present
in the stack, so that the test in meta_stack_remote() becomes
irrelevant.

https://bugzilla.gnome.org/show_bug.cgi?id=780820
2018-01-11 11:03:04 +01:00
2d090f9232 Update Friulian translation 2018-01-09 17:49:45 +00:00
1c8aebd811 wayland: Ensure wl_shell_surfaces are set reactive
Wayland clients using the wl_shell interface were never receiving mouse
input. It meant they also couldn't be raised with a click.

This was because the call to meta_wayland_surface_set_window for wl_shell
surfaces did nothing while surface->window == window already. As such, it
never called clutter_actor_set_reactive() and the wl_shell window remained
a non-reactive actor.

Just make sure surface->window isn't already set before calling
meta_wayland_surface_set_window so it can actually do what it's meant to.

https://bugzilla.gnome.org/show_bug.cgi?id=790309
2018-01-09 11:27:30 -05:00
31eafba93a build: Fix build when native backend is disabled
https://bugzilla.gnome.org/show_bug.cgi?id=792281
2018-01-09 12:01:08 +08:00
5eacdf7af7 monitor-unit-tests: Add non upright panel test
https://bugzilla.gnome.org/show_bug.cgi?id=782294
2017-12-25 17:01:45 +08:00
ca638d1354 monitor-unit-tests: Add support for panel-orientation
https://bugzilla.gnome.org/show_bug.cgi?id=782294
2017-12-25 17:01:45 +08:00
f12e6ad4f1 monitor-config-manager: Adjust accelerometer rotation for panel-orientation
The device orientation coming out of iio-sensor-proxy defines upright/normal
as the direction in which the picture is displayed on the LCD panel without
any rotation. This is necessary for accelerometer rotation to work properly
in desktop environments which are not aware of panel-orientation issues.

This means that we need to correct the logical-monitor-config / user-visible
rotation for the panel-orientation when we get rotation info from
iio-sensor-proxy.

https://bugzilla.gnome.org/show_bug.cgi?id=782294
2017-12-25 17:01:45 +08:00
0bbda3ad87 monitor-manager: Take panel-orientation into account for physical size
Just like we swap the x and y resolution of the monitor modes when
the panel-orientation requires 90 or 270 degree rotation to compensate,
we should do the same for the width and height in mm of the monitor.

https://bugzilla.gnome.org/show_bug.cgi?id=782294
2017-12-25 17:01:45 +08:00
dd43d04d42 monitor-manager: Add portrait modes to portrait displays
If a monitor's max resolution is a portrait resolution, then assume it is
a native portrait monitor and add portrait versions of the common modes.

https://bugzilla.gnome.org/show_bug.cgi?id=782294
2017-12-25 17:01:45 +08:00
383ac76d00 cursor-renderer-native: Take panel-orientation into account
Even if the logical_monitor config does not have an active transform,
we might still be doing a transform under the hood to compensate for
panel-orientation. Check for this and fall back to the sw cursor if this
is the case.

https://bugzilla.gnome.org/show_bug.cgi?id=782294
2017-12-25 17:01:45 +08:00
e59ca14f6c monitor-manager: Take panel orientation into account when getting input matrix
If a LCD panel has a non normal orientation (mounted upside-down or 90
degrees rotated) then the kernel will report touchscreen coordinates with
the origin matching the native (e.g. upside down) coordinates of the panel.

Since we transparently rotate the image on the panel to correct for the
non normal panel-orientation, we must apply the same transform to input
coordinates to keep the aligned.

https://bugzilla.gnome.org/show_bug.cgi?id=782294
2017-12-25 17:01:45 +08:00
7917b083cb monitor-manager: Take drm-connector panel-orientation property into account
Some x86 clamshell design devices use portrait tablet LCD panels while
they should use a landscape panel, resoluting in a 90 degree rotated
picture.

Newer kernels detect this and rotate the fb console in software to
compensate. These kernels also export their knowledge of the LCD panel
orientation vs the casing in a "panel orientation" drm_connector property.

This commit adds support to mutter for reading the "panel orientation"
and transparently (from a mutter consumer's pov) fixing this by applying
a (hidden) rotation transform to compensate for the panel orientation.

Related: https://bugs.freedesktop.org/show_bug.cgi?id=94894

https://bugzilla.gnome.org/show_bug.cgi?id=782294
2017-12-25 17:01:45 +08:00
2b3040d04f monitor: s/meta_monitor_derived_derive_layout/meta_monitor_tiled_derive_layout/
Fix meta_monitor_derived_derive_layout typo.

https://bugzilla.gnome.org/show_bug.cgi?id=782294
2017-12-25 17:01:45 +08:00
6cc48d8cbb build: Fix non-wayland builds
meta_dnd_wayland_handle_end_modal is not available on non-wayland build.

https://bugzilla.gnome.org/show_bug.cgi?id=791916
2017-12-24 17:55:14 +08:00
798026498d wayland: Only send full sequences of touch events to clients
If input happens to be grabbed somewhere along the shell, and ungrabbed
while a touch operation is ongoing, the wayland bits will happily start
sending wl_touch.update events from an undeterminate point, without
clients having ever received wl_touch.down for that id.

Consider those touches grabbed for the entirety of their lifetime, if
wl_touch.down wasn't received by the client, no other events will.

https://bugzilla.gnome.org/show_bug.cgi?id=776220
2017-12-21 12:37:20 +01:00
49f029571c keybindings: Super should be inhibitable
When a Wayland client issues a shortcut inhibit request which is granted
by the user, the Super key should be passed to the surface instead of
being handled by the compositor.

https://bugzilla.gnome.org/show_bug.cgi?id=790627
2017-12-21 09:08:41 +01:00
290b257288 Updated Spanish translation 2017-12-20 18:18:07 +01:00
2b60fb0144 stage: Push framebuffer before setting up viewport
When capture_view* functions are called with the paint flag set
to TRUE, we need to setup the framebuffer, however this was
happening after setting up the viewport, while the viewport
needs the framebuffer to be valid when calling cogl_set_viewport.

https://bugzilla.gnome.org/show_bug.cgi?id=791809
2017-12-20 05:56:51 -05:00
7f5f5eb847 wayland/keyboard: preserve layout index
On VT switch, the xkb state layout index is lost and reset to the first
group, so if the first layout is not the last one being used, the xkb
state used in both meta-wayland-keyboard.c and clutter/evdev will be
desynchronized with the keyboard source indicator in the gnome-shell UI.

Save the effective layout chosen along with the seat so it can be
restored when reclaiming devices.

Use the saved layout index from the clutter/evdev's seat to restore the
layout in meta-wayland-keyboard, so that switching VT doesn't reset the
layout and causes further discrepancies with the layout indicator in the
gnome-shell UI.

https://bugzilla.gnome.org/show_bug.cgi?id=791383
2017-12-20 09:56:34 +01:00
44269e6a1d keybindings: Only add multiple keycodes from the same level
The reason why multiple keycodes could be mapped to a single keysym was
to support having both KEY_FAVORITES and KEY_BOOKMARK map to
XF86Favorites. However, iterating through all layout levels adding all
key codes has severe consequences on layouts with levels that map
things like numbers and arrow. The result is that keybindings that
should only have been added for keycodes from the first level, are
replaced by some unexpected keycode where the same keysym was found on
another level.

An example of this is the up-arrow key and l symbol. Normally you'd find
both the up-arrow symbol and the l symbol on the first level and be done
with it. However, on the German Neo-2 layout, layout level 4 maps the
KEY_E to the l symbol, while layout level 4 maps KEY_E to up-arrow.
Which ever gets to take priority is arbitrary, but for this particular
case KEY_E incorrectly mapped to up-arrow instead of the l symbol,
causing the keyboard shortcut Super+l, which would normally lock the
screen, to trigger the workspace-up (Super+up-arrow) key binding.

https://bugzilla.gnome.org/show_bug.cgi?id=789300
2017-12-20 15:02:39 +08:00
70dfe8c97d Use Unicode quotation marks in new translatable strings
See https://developer.gnome.org/hig/stable/typography.html

https://bugzilla.gnome.org/show_bug.cgi?id=772218
2017-12-18 17:22:36 +01:00
072afa5fa3 wayland: Add Xwayland grab keyboard support
This protocol is limited to Xwayland only and is not visible/usable by
any other client.

Mutter uses the following mechanisms to determine if an X11 client
should be granted a grab:

 - is "xwayland-allow-grabs" set?
 - if set, is the client blacklisted?
 - otherwise, has the client set the X11 window property
   _XWAYLAND_MAY_GRAB_KEYBOARD on the window using a client message?
 - if not, is it a client white-listed either via the default system
   list or the settings "xwayland-grab-access-rules"?

https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-12-18 13:15:20 +01:00
519a0fd93d settings: Add xwayland grab settings
Add new settings to control which X11 windows are allowed to
issue Xwayland grabs.

https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-12-18 13:15:17 +01:00
5f132f3975 xwayland: add _XWAYLAND_MAY_GRAB_KEYBOARD property
Add a new client message "_XWAYLAND_MAY_GRAB_KEYBOARD" that X11 clients
can use to tell mutter this is a well behaving X11 client so it may
grant the keyboard grabs when requested.

An X11 client wishing to be granted Xwayland grabs by gnome-shell/mutter
must send a ClientMessage to the root window with:

 - message_type set to "_XWAYLAND_MAY_GRAB_KEYBOARD"
 - window set to the xid of the window on which the grab is to be issued
 - data.l[0] to a non-zero value

Note: Sending this client message when running a plain native X11
environment would have no effect.

https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-12-18 13:15:13 +01:00
1546989845 xwayland: Add MetaWindowXwayland
MetaWindowXwayland derives from MetaWindowX11 to allow for some Xwayland
specific vfunc that wouldn't apply to plain X11 windows, such as
shortcut inhibit routines.

https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-12-18 13:15:09 +01:00
1923db97c1 wayland-outputs: Delay wl_output destruction
This tries to avoid wayland clients getting disconnected for binding
to a wl_output that we already destroyed which is a known protocol
race condition, see https://phabricator.freedesktop.org/T7722 .

https://bugzilla.gnome.org/show_bug.cgi?id=789070
2017-12-15 14:54:13 +01:00
db32047a5d wayland: Add xdg-output support
The xdg-output protocol aims at describing outputs in way which is
more in line with the concept of an output on desktop oriented systems.

For now it just features the position and logical size which describe
the output position and size in the global compositor space.

This is however much useful for Xwayland to advertise the output size
and position to X11 clients which need this to configure their surfaces
in the global compositor space as the compositor may apply a different
scale from what is advertised by the output scaling property (to achieve
fractional scaling, for example).

This was added in wayland-protocols 1.10.

https://bugzilla.gnome.org/show_bug.cgi?id=787363
2017-12-15 14:18:14 +01:00
b505eb261e Update Indonesian translation 2017-12-03 08:19:53 +00:00
1a1db9ef8d window-actor: rename destroy function in queue_destroy
Since this might delay the destruction after animation
has succeeded, it's just better to rename this accordingly.

https://bugzilla.gnome.org/show_bug.cgi?id=791006
2017-11-30 22:53:26 -05:00
b1587f0716 compositor: reset top_window_actor and remove it from windows when destroyed
When the top window actor is destroyed, we need to make sure that
all its references are removed or it could be picked again in next
windows sync, causing crashes.
Since the window might or might not be destroyed when removed (depending
weather animations are in progress over it or not), it's just safer
to wait it to be destroyed before cleaning up any of its reference.

https://bugzilla.gnome.org/show_bug.cgi?id=791006
2017-11-30 22:53:26 -05:00
93e450f37c backends: Fix ClutterRect initialisations
With Clang, these initialisations were warning about missing brackets.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

https://bugzilla.gnome.org/show_bug.cgi?id=791022
2017-11-30 13:06:13 +00:00
fc713ecb70 monitor-unit-tests: Check config loading on lid switches
Check that we apply the correct stored configuration when the lid is
opend and closed while an external monitor is connected.

https://bugzilla.gnome.org/show_bug.cgi?id=788915
2017-11-30 11:48:44 +08:00
500c13ab6f monitor-unit-tests: Always reset CRTC transform ability
Changing the test monitor managers ability to rotate CRTCs in one test
affected the next test. Avoid leaking such state by resetting it before
each test. To continue passing, some tests needed to be updated
regarding to still pass.

https://bugzilla.gnome.org/show_bug.cgi?id=788915
2017-11-30 11:48:44 +08:00
050267fe74 monitor-unit-tests: Add test for lid toggle after hot unplug
https://bugzilla.gnome.org/show_bug.cgi?id=788915
2017-11-30 11:48:44 +08:00
ce25a0171c monitor-unit-tests: Add test for lid closed after hot plug
Add a test case that checks that we don't try to revert to a
laptop-panel-only configuration after closing the lid after an external
monitor is connected.

https://bugzilla.gnome.org/show_bug.cgi?id=788915
2017-11-30 11:48:44 +08:00
b7518c8651 monitor-manager: Compare keys when checking whether a config is complete
We only counted configured monitors and whether the config was
applicable (could be assigned), howeverwe didn't include disabled
monitors when comparing. This could caused incorrect configurations to
be applied when trying to use the previous configuration.

One scenario where this happened was one a system with one laptop
screen and one external monitor that was hot plugged some point after
start up. When the laptop lid was closed, the 'previous configuration'
being the configuration where only the laptop panel was enabled, passed
'is-complete' check as the number of configured monitors were correct,
and the configuration was applicable.

Avoid this issue by simply comparing the configuration key of the
previous configuration and the configuration key of the current state.
This correctly identifies a laptop panel with the lid closed as
inaccessible, thus doesn't incorrectly revert to the previous
configuration.

https://bugzilla.gnome.org/show_bug.cgi?id=788915
2017-11-30 11:48:44 +08:00
62dedfbef3 monitor-config-manager: Don't include closed laptop panel in config key
When deriving the list of disabled monitors when creating new monitors
configs, don't include the laptop panel if the lid is currently closed,
as we consider the laptop panel nonexistent when the laptop lid is
closed when it comes to configuration.

The laptop panel connector(s) will either way be appropriately disabled
anyway, as the field listing disabled monitors in the configuration do
not affect actual CRTC/connector assignments.

https://bugzilla.gnome.org/show_bug.cgi?id=788915
2017-11-30 11:48:44 +08:00
4508978ea5 wayland/xdg-shell: Dismiss a popup on map if parent already dismissed
If a parent doesn't have a window, it means it could have been
dismissed (for example due to a input serial race), but the more recent
popup might win the input serial race and try to map anyway. This would
result in a crash later on when trying to process the placement rule,
as the parent already has no window.

https://bugzilla.gnome.org/show_bug.cgi?id=790358
2017-11-30 10:50:13 +08:00
c533a06e93 wayland/xdg-shell: Check popup parent type when assigning
We only allow mapping popups on top of surfaces with a xdg_surface
based role. Add a check and fail clients that doesn't follow this rule.

https://bugzilla.gnome.org/show_bug.cgi?id=790358
2017-11-30 10:50:13 +08:00
5d3b4f0134 wayland/xdg-shell: Fix top-most check when grabbing
Move the top-most-popup correctness check to the finish_popup_setup()
function after checking the serial. If we pass the serial check, we
should have reached a state that if there are any popups they should be
the one from the same client.

Also avoid failing a client that correctly set the top-most popup at map
time, but where at the time of processing the top most popup have
already been dismissed by the compositor for some arbitrary reason.

https://bugzilla.gnome.org/show_bug.cgi?id=790358
2017-11-30 10:50:13 +08:00
4cf340ae9b Updated Hebrew translation 2017-11-26 17:15:03 +02:00
053ac03f01 Update Nepali translation
(cherry picked from commit 789d740add)
2017-11-26 05:19:55 +00:00
28a9439209 monitor-manager: Refuse to activate closed laptop panels
There's no good reason to allow this and it allows g-c-c to properly
show that such a configuration doesn't work.

https://bugzilla.gnome.org/show_bug.cgi?id=790336
2017-11-22 15:07:11 +01:00
cf4b5efdd1 backends: Do NULL checks before disconnecting/connecting signals
The displayed cursor may be NULL.

https://bugzilla.gnome.org/show_bug.cgi?id=754806
2017-11-20 13:29:22 +01:00
3067dab84c backends: Do not set up the root cursor on invisible window pointers
Commit b1a0bf891 broke the previous logic that we would only fallback
to the root cursor if 1) windows are not interactable or 2) no window
cursor is currently set (i.e. not hovering over any window). Now it
will set up the root cursor if it's NULL, which breaks clients
explicitly setting an invisible cursor. This commit restaurates the
previous behavior.

https://bugzilla.gnome.org/show_bug.cgi?id=754806
2017-11-20 13:29:22 +01:00
1790320ba3 backends: Protect from reentrancy in meta_cursor_sprite_load_from_theme
This function is supposedly not failable, so just move the theme_dirty
flag clearing to the beginning of the function. Protects against cases
where requesting a cursor image may result in it being loaded and set
as a texture, which emits ::texture-changed, which may end up requesting
the cursor image again.

https://bugzilla.gnome.org/show_bug.cgi?id=754806
2017-11-17 17:22:18 +01:00
f45df4265d backends: Trigger MetaCursorTracker::cursor-changed on texture changes
So we allow gnome-shell's magnifier to update fake cursors while it's
turned on.

https://bugzilla.gnome.org/show_bug.cgi?id=754806
2017-11-17 17:22:18 +01:00
bcbcd6a68c backends: Add MetaCursorSprite::texture-changed signal
As wayland implements the cursor role, it consists of a persistent
MetaCursorSprite that gets the backing texture changed. This is
inconvenient for the places using MetaCursorTracker to track cursor
changes, as they actually track MetaCursorSprites.

This signal will be used to trigger emission of
MetaCursorTracker::cursor-changed, which will make users able to
update accordingly.

https://bugzilla.gnome.org/show_bug.cgi?id=754806
2017-11-17 17:22:18 +01:00
b1a0bf8916 backends: Dissociate visibility from current cursor sprite
Just like X11/XFixes behaves, the current cursor is not affected
by its visibility, so it can be queried while invisible (possibly
to be replaced).

For this, keep an extra effective_cursor pointer that will be
either equal to displayed_cursor (maybe a bit of a misnomer now)
or NULL if the cursor is invisible. The MetaCursorRenderer
management is tied to the former, and the ::cursor-changed signal
emission to the latter.

https://bugzilla.gnome.org/show_bug.cgi?id=754806
2017-11-17 17:22:18 +01:00
6c18bae83c compositor: Fix build
Unused variable definition. The fixup didn't make it to the previous
commit.
2017-11-17 16:58:54 +01:00
d0531966eb compositor: End MetaDnd grab on plugin grab end
We must emit ::dnd-leave to pair the ::dnd-enter that shall be
emitted whenever the plugin grab begins, otherwise we leave
listeners unable to clean up if the plugin begins and ends a
grab while there is an ongoing DnD operation.

https://bugzilla.gnome.org/show_bug.cgi?id=784545
2017-11-17 14:43:50 +01:00
989a47ee8c Update Italian translation
(cherry picked from commit 32a151094d)
2017-11-17 13:31:22 +00:00
03be6b687b clutter/x11: Configure XKB accessibility
Configure XKB accessibility features from the x11 and xi2 clutter input
device managers, offloading this feature from gnome-settings-daemon.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
32c22d375a clutter/x11: Add xkb accessibility helpers
Adds a set of convenient functions that can be shared between x11 input
device backends (namely core-x11 and xi2) to control XKB accessibility
features.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
bdf3f49a82 clutter/evdev: implement mouse keys support
Control the pointer using the numeric keypad.

When enabled, creates a virtual pointer and emulate the pointer event
based on keyboard events.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
356b4b0dc5 clutter/evdev: implement toggle keys support
Keeping Shift pressed for 8 seconds enables slow keys, pressing Shift 5
times in a row enables sticky keys.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
3fc2ea8297 wayland/keyboard: Apply sticky keys masks
MetaWaylandKeyboard maintains its own xkb_state used to update Wayland
clients.

Add the necessary hooks to make sure the sticky keys modifier masks set
in clutter-evdev are also applied in MetaWaylandKeyboard's xkb_state so
that Wayland clients also benefit from sticky keys.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
06d976e853 clutter/evdev: implement sticky keys support
One key press on a modifier latches it, two consecutive presses lock it.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
96ebd1c214 clutter/evdev: implement bounce keys support
Ignore multiple consecutive identical key presses within a time frame.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
fa28481736 clutter/evdev: implement slow keys support
Delay emitting clutter key press events when slow key is enabled.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
76b064cffc clutter/evdev: Implement a11y configuration hooks
Apply the keyboard accessibility settings to the master keyboard.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
333b5d12a0 backends: configure keyboard accessibility
Set the relevant flags and values for keyboard accessibility from
gsettings.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
aa73504d95 clutter: add keyboard accessibility signals
Implementing keyboard accessibility in clutter means we need to be able
to notify higher layers of possible modifier masks or setting changes
(as some keyboard accessibility can be disabled or enabled by keyboard).

For this purpose, add two new signals:

   ClutterDeviceManager::kbd-a11y-mods-state-changed
   ClutterDeviceManager::kbd-a11y-flags-changed

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
32305b453d clutter: add hooks for kbd a11y configuration
Use a set of bitwise enum flags to set different keyboard accessibility
features and the necessary vfunc hooks in clutter input device so that
keyboard preferences can be passed to different input device
implementations.

The idea is to be able to configure either the clutter own
implementation of keyboard accessibility for evdev, or eventually
configure AccessX from the X11 clutter input device using the same
mechanism.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
7d5e08c843 clutter-main: Add hooks to plug kbd accessibility
On X11, when AccessX is enabled, all X11 clients benefit from the
AccessX features, including gnome-shell/mutter, meaning that special
keys like the overview or other shortcuts are also affected.

To achieve the same in Wayland, we need to implement the same features
in clutter main rather than the Wayland backend, so that all depending
code within the compositor but also Wayland clients (which rely on the
compositor to get keyboard events) similarly benefit from the
accessibility features.

Add hooks to the clutter main loop to be able to implement such
features.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
dc0fc65229 backend/native: implement bell-notify
https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
428af6d213 backend/x11: implement bell-notify
https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
2ffe597617 clutter/backend: Add bell-notify
We'll need a way to trigger a bell from within clutter for keyboard
accessibility features, add the necessary hooks to be able to call a
backend bell-notify method.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
0461eed0cb wayland: Disable AccessX in Xwayland
Keyboard accessibility features in Wayland are handled in the
compositor, we do not want AccessX in Xwayland to interfere with the
compositor.

https://bugzilla.gnome.org/show_bug.cgi?id=788564
2017-11-16 14:14:31 +01:00
ca1bacc212 Update Turkish translation
(cherry picked from commit 8c45fbfb58)
2017-11-15 20:50:32 +00:00
2229365ca8 Updated Czech translation 2017-11-15 13:35:31 +01:00
8c367364b6 Update French translation
(cherry picked from commit 6797be5e1e)
2017-11-14 08:11:50 +00:00
58909da425 Update Swedish translation
(cherry picked from commit f4b4ef32ed)
2017-11-13 23:44:31 +00:00
ff32bf467c Update German translation
(cherry picked from commit cdfeecc318)
2017-11-11 21:20:20 +00:00
c5572d3095 Update Brazilian Portuguese translation
(cherry picked from commit 19cde75acc)
2017-11-11 18:57:12 +00:00
e706bcdf73 Updated Norwegian bokmål translation. 2017-11-11 18:19:24 +01:00
d9ebcbd55c Update Polish translation 2017-11-10 19:30:56 +01:00
240b13aa74 Update POTFILES.in 2017-11-10 19:16:27 +01:00
97635d6f84 Add restore-shortcuts to key bindings list
gnome-control-center uses this to list the keybindings, without this
users cannot change the default key combo to restore shortcuts.

https://bugzilla.gnome.org/show_bug.cgi?id=789386
2017-11-10 17:59:26 +01:00
6c21a22e4d wayland: Use Super+Escape to re-enable shortcuts
Change the default key combo to re-enable normal keyboard shortcuts
processing while a shortcut inhibitor is in effect to Super+Escape as
primary system modifier key should be Super.

This should reduce the risk of potential conflict with other shortcuts.

https://bugzilla.gnome.org/show_bug.cgi?id=789386
2017-11-10 17:58:00 +01:00
0add6f62b6 window/wayland: Handle resizing when headless
We tried to get the geometry scale, which may depend on the main
logical monitor assigned to the window. To avoid dereferencing a NULL
logical monitor when headless, instead assume the geometry scale is 1.

https://bugzilla.gnome.org/show_bug.cgi?id=788764
2017-11-10 10:24:10 +08:00
049418cd03 renderer/native: Also allow EGL_KHR_platform_gbm extension string
Proprietary drivers such as ARM Mali export EGL_KHR_platform_gbm instead
of EGL_MESA_platform_gbm. As such, GBM platform check should be done for
both MESA and non-MESA drivers.

https://bugzilla.gnome.org/show_bug.cgi?id=780668
2017-11-09 18:16:27 +08:00
3ee1999c70 backend: Reset current device id when current device removed
Bluetooth mouse usually goes in sleep state after a timeout, when that
happen the mouse is disconnected and on_device_removed function is
called. Before the patch if a touch device is available the
on_device_removed function hide the cursor. The issue is that the cursor
does not reappear once the bluetooth mouse is reconnected because
MetaBackend::current_device_id is not invalidated when on_device_removed
was called.

The patch set MetaBackend::current_device_id to 0 if the current device
is removed. This will make update_last_device to be triggered as soon as
another input device is used or the bluetooth mouse reconnect, as
consequence that the cursor reappear. The id 0 is never given to devices
and can safely used as undefine id.

https://bugzilla.gnome.org/show_bug.cgi?id=761067
2017-11-09 17:42:45 +08:00
e4b8920688 Updated Norwegian bokmål translation. 2017-11-08 20:15:37 +01:00
eb236649fc backends: Plug leaks
The DRM properties container must be destroyed with
drmModeFreeObjectProperties, and the connectors must be freed on every
caller. Also make it sure that gbm_device structs are destroyed with the
MetaRendererNativeGpuData that owns them.

https://bugzilla.gnome.org/show_bug.cgi?id=789984
2017-11-07 11:02:00 +01:00
0a36a4545f core: Plug leaks
The MetaWorkspaceLogicalMonitorData structs are leaked, and so is the
stamps hashtable in MetaDisplay.

https://bugzilla.gnome.org/show_bug.cgi?id=789984
2017-11-07 10:48:45 +01:00
180985018b wayland: Plug leak
The remote DBus error is leaked.

https://bugzilla.gnome.org/show_bug.cgi?id=789984
2017-11-07 10:48:45 +01:00
c86c5d6905 clutter: Plug evdev ClutterDeviceManager leaks
The unused ID GList element is leaked, and so is the node path.

https://bugzilla.gnome.org/show_bug.cgi?id=789984
2017-11-06 20:51:58 +01:00
c2fad2dc7c compositor: Keep reference to the screen on the MetaBackground
This is not a leak per se, but it seems too easy to make valgrind
SIGSEGV due to MetaBackground disconnecting signals from an already
destroyed MetaScreen when trying to SIGTERM gnome-shell. Keeping a
reference fixes this.

https://bugzilla.gnome.org/show_bug.cgi?id=789984
2017-11-06 20:51:58 +01:00
1196b7bde4 Updated Norwegian bokmål translation. 2017-11-06 13:43:25 +01:00
19eddfd756 build-sys: allow explicitely disabling remote-desktop and egl-device
https://bugzilla.gnome.org/show_bug.cgi?id=789958

Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
2017-11-06 10:57:33 +01:00
ed280ef4ac Update Arabic translation 2017-11-03 10:23:14 +02:00
b6200ac3ff wayland/keyboard: Don't transfer layout group when replacing xkb state
The layout group determines what actual keyboard layout in the keymap
to use when translating modifier state and key codes to key syms.
When changing a keymap to another, the layout groups has no relation to
the layout groups in the old keymap, thus there is no reason to
transfer it to the new state.

This fixes an issue where the xkb state in meta-wayland-keyboard.c got
desynchronized with the xkb state in clutter-device-manager-evdev.c.

https://bugzilla.gnome.org/show_bug.cgi?id=789300
2017-11-02 12:10:10 +08:00
626621a53a renderer-native-gles3: Add cpp error if gl.h was included
On some architectures, including both GLES3/gl3.h GL/gl.h will cause
compilation issues due to incompatible type definitions. To avoid
running into that issue while building on other architectures, make
sure we haven't included GL/gl.h by accident.

https://bugzilla.gnome.org/show_bug.cgi?id=788695
2017-10-30 19:52:42 +08:00
fb3a64491e renderer-native-gles3: Remove unnecessary includes
They caused conflicts on i686 as GL/gl.h was included by cogl.

https://bugzilla.gnome.org/show_bug.cgi?id=788695
2017-10-30 19:52:42 +08:00
294f9419f7 renderer-native-gles3: Don't pass GPU when rendering
It wasn't used for anything, so don't pass it.

https://bugzilla.gnome.org/show_bug.cgi?id=788695
2017-10-30 19:52:42 +08:00
a37956c95f eglnative: Use gnome-settings-daemon font settings
While the X11 backend gets its font settings from XSettings, the native
backend did not use any user font preferences till now. So all shell fonts
were rendered with grayscale un-hinted, which some people describe as
"blurry text in Wayland sessions".

Although it's somewhat confusing using the "xsettings" schema on eglnative,
this is consistent with what GTK does already for its Wayland backend. It
is also documented here:

https://wiki.gnome.org/Initiatives/Wayland/GTK%2B#XSettings
https://wiki.gnome.org/Initiatives/Wayland/gnome-settings-daemon#xsettings

No more blurry shell text in Wayland sessions.

https://bugzilla.gnome.org/show_bug.cgi?id=645433
2017-10-27 22:12:57 -05:00
89f5ca3301 backends: Unref variants obtained from g_variant_iter_get_next_value()
Those are being leaked.

https://bugzilla.gnome.org/show_bug.cgi?id=789553
2017-10-27 13:22:12 +02:00
07745b3082 wayland/surface: Disconnect actor handlers before unassigning role
The handlers depend on a role being assigned. Destroying the window
causes it to become unmapped, which would sometimes trigger one of the
handlers, resulting in an is-assigned assert hitting in one of the
handlers. Avoid this by disconnecting the handlers earlier, so that
there is no risk that any them being triggered before the role is
assigned.

https://bugzilla.gnome.org/show_bug.cgi?id=789552
2017-10-27 19:08:38 +08:00
054c25f693 wayland: Allow Xwayland to leave core dumps
For historical Xorg-reasons, Xwayland would disable its own core dumps by
default. This is a problem because Xwayland crashing is the biggest cause of
gnome-shell crashes [1][2], and we still have no idea why due to there being
no dumps from Xwayland. So enable core dumping from Xwayland.

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

[1] https://bugs.launchpad.net/bugs/1505409
[2] https://bugs.launchpad.net/bugs/1556601
2017-10-26 19:50:40 -05:00
01de04d8c9 wayland: Update pointer confinement on surface actor relocations
In the unlikely case that a surface is moved by the compositor while
holding a pointer confinement, we also need to update the pointer
position when the surface actor gets moved.

https://bugzilla.gnome.org/show_bug.cgi?id=782344
2017-10-26 12:53:20 +02:00
08e4cb54a8 wayland: Trigger wl_output updates on actor position changes
Both notify::position on the surface actor and position-changed on
MetaWindow are listened to, in order to trigger wl_output updates for
wl_surfaces whenever the surfaces move across them.

Both signals are necessary in order to cater for toplevel and subsurface
relocations (Because it's the parent window actor what changes position
in this last case).

Also, shuffle signal disconnection, so each signal goes away with
the object reference held by MetaWaylandSurface.

https://bugzilla.gnome.org/show_bug.cgi?id=782344
2017-10-26 12:51:44 +02:00
c71faffb71 backends/native: Fix handling of trackball settings
The org.gnome.desktop.peripherals.trackball.scroll-wheel-emulation-button
setting contains buttons X11-style. Work out the BTN evcode that applies
to it when applying the setting on the libinput device.

https://bugzilla.gnome.org/show_bug.cgi?id=787804
2017-10-26 12:48:15 +02:00
91e3a0b3a9 MetaWindowActor: assert that we have plugin manager on simple effect
It looks that there are some extensions that run a Mainloop on startup,
causing to dispatch a clutter paint before the compositor is even available.
In such scenario a MetaWindow could try to start a simple effect
using a compositor plugin which is not there yet.

Then in order to catch these bugs we can now assert that the expected
conditions are valid, so that gnome-shell will provide a dumpstack to
debug the real offending JS code.

https://bugzilla.gnome.org/show_bug.cgi?id=789223
2017-10-24 04:42:54 -05:00
5fa8f78434 Revert "tests: Fix actor-anchors test"
This reverts commit dd451547a5.

since we reverted commit 5cb5baa with commit 4d2647c
2017-10-21 18:58:37 -04:00
ab5ac21104 window: rename get_flatpack_id into get_sandboxed_app_id
This function can be more generic now.

https://bugzilla.gnome.org/show_bug.cgi?id=789277
2017-10-21 13:36:16 -05:00
0ebea2be9c Revert "MetaWindowActor: don't start any effect when no compositor is available"
This reverts commit 35fcf4a4ae.
2017-10-20 03:25:31 -05:00
6f54bab0a8 Revert "MetaPluginManager: don't try to deference a NULL pointer when processing events"
This reverts commit 74565380aa.
2017-10-20 03:23:28 -05:00
5d7deab6da Revert "display: trap X errors in get_current_time_roundtrip"
This reverts commit cc772ddd61.
2017-10-20 03:22:59 -05:00
35fcf4a4ae MetaWindowActor: don't start any effect when no compositor is available
There are cases when no compositor is available (yet) but a MetaWindow tries
to start a simple effect using a compositor plugin which is not available.
In that case we should just ignore any request and protect ourselves from
crashes.

https://bugzilla.gnome.org/show_bug.cgi?id=789223
2017-10-20 16:10:18 +08:00
74565380aa MetaPluginManager: don't try to deference a NULL pointer when processing events
This function might be called by components with invalid plugin manager
(as it might happen to MetaWindow when the compositor isn't initialized
properly), so we need to protect ourselves from crashes.

https://bugzilla.gnome.org/show_bug.cgi?id=789223
2017-10-20 16:10:18 +08:00
fa37496ffb MetaLogicalMonitor: free the monitors list on finalize
https://bugzilla.gnome.org/show_bug.cgi?id=789227
2017-10-20 16:10:18 +08:00
cc772ddd61 display: trap X errors in get_current_time_roundtrip
Only return the actual timestamp if we get one.

https://bugzilla.gnome.org/show_bug.cgi?id=788971
2017-10-20 16:10:18 +08:00
4d2647cdbc Revert "ClutterActor: Optimize away idempotent scale/position updates"
This reverts commit 5cb5baa7d4.

There's a cascade of regressions that needs to be sorted out before
relanding this:

https://bugzilla.gnome.org/show_bug.cgi?id=784314
2017-10-19 19:54:24 -05:00
3caefd8fda compositor: Avoid a crash if the top window actor is finalized
Since we're not holding a reference, the top window actor might be
finalized when we paint resulting in a use after free crash.

https://bugzilla.gnome.org/show_bug.cgi?id=788493
2017-10-19 18:37:34 +02:00
12381d57d1 monitor-unit-tests: Check non-first preferred modes
Check that if there are multiple modes with the same ID (resolution,
refresh rate and handled flags) we correctly add the preferred mode to
the list of monitor modes.

https://bugzilla.gnome.org/show_bug.cgi?id=789153
2017-10-19 10:17:14 +08:00
4ad8c4b86b monitor/normal: Prefer modes with same flags as preferred mode
When generating MetaMonitorMode's, prefer CRTC modes that has the same
set of flags as the preferred mode. This not only is probably a better
set of configurable modes, but it'll guarantee that the preferred mode
is added.

This fixes a crash when the preferred mode was not the first mode with
the same resolution, refresh rate and set of handled modes.

https://bugzilla.gnome.org/show_bug.cgi?id=789153
2017-10-19 10:16:50 +08:00
dbd2827ca1 Bump version to 3.27.1
Update NEWS.
2017-10-17 17:44:39 +02:00
1a78557e0b monitor-manager/xrandr: Use a single supported scales list for all
Under X11 we can only ever have the same scale configured on all
monitors. In order to use e.g. scale 2 when there is a HiDPI monitor
connected, we must not disallow it because there is a monitor that does
not support scale 2. Thus we must show the same scale for every monitor
and monitor mode, even though it might result in a bad experience.

Do this by iterating through all the monitors adding all supported
scales by the preferred mode, combining all the supported scales. This
supported scales list is then used for all monitor and modes no matter
what.

https://bugzilla.gnome.org/show_bug.cgi?id=788901
2017-10-17 15:21:12 +08:00
2e99963087 compositor: Ignore offscreen windows when unredirecting
When determining whether we should unredirect a window or not, ignore
offscreen windows, and just check the top most visible window.

Previously this was not an issue, but since 'stack-tracker: Keep
override redirect windows on top' we started sorting the UI frames
window, which is an offscreen override redirect window, on top, causing
the unredirect checking code to always check whether to unredirect the
UI frames window. This effectively disabled the compositor bypass
functionality.

https://bugzilla.gnome.org/show_bug.cgi?id=788493
2017-10-17 14:50:18 +08:00
4d763e1828 x11/window: Don't manage InputOnly windows
This was dropped by mistake in commit
f166240225.

https://bugzilla.gnome.org/show_bug.cgi?id=788493
2017-10-17 14:50:18 +08:00
a17b343c21 monitor-manager/xrandr: Chain up constructed vfunc
'monitor-manager: Keep pointer to backend' added a
GObjectClass::constructed implementation, but didn't chain it up to the
parent. Fix that.

https://bugzilla.gnome.org/show_bug.cgi?id=788921
2017-10-16 17:13:55 +08:00
556136dacc workspace: ensure that workarea data is valid when fetching by monitor num
https://bugzilla.gnome.org/show_bug.cgi?id=788860
2017-10-13 00:46:51 -05:00
a8c80ccece backend: move the cursor render update on screen changes here
https://bugzilla.gnome.org/show_bug.cgi?id=788860
2017-10-13 00:46:51 -05:00
f044511037 monitor-manager: use g_return_val_if_fail if trying to fetch an invalid monitor
https://bugzilla.gnome.org/show_bug.cgi?id=788860
2017-10-13 13:43:03 +08:00
b31e545c9d backends: add 'monitors-updated-internal' signal to only update internal state
Adding an internal signal and use it to update the internal state before
emitting "monitors-changed" which will be repeated by the screen to the world.

https://bugzilla.gnome.org/show_bug.cgi?id=788860
2017-10-13 00:42:50 -05:00
fad5657eda DisplayConfig: Add 'legacy-ui-scaling-factor' property
We have this value in mutter; lets share it so that for example
gnome-settings-daemon doesn't have to calculate it itself.

https://bugzilla.gnome.org/show_bug.cgi?id=788820
2017-10-12 17:42:52 +08:00
eaf9ccde39 settings: Get UI scaling factor from primary logical monitor
Don't use MAX(logical monitor scales) to determine the UI scaling
factor, just use the primary logical monitor. That's where the shell UI
will most likely be.

https://bugzilla.gnome.org/show_bug.cgi?id=788820
2017-10-12 17:42:52 +08:00
f9c625924e x11: Protect XChangeProperty call with error traps
They may happen around the time a window is destroyed, thus could result
on BadWindow X errors.

https://bugzilla.gnome.org/show_bug.cgi?id=788666
2017-10-10 13:55:40 +02:00
64cb735abf configure: Explicitly require gl pkgconfig file
Mutter now does direct calls to GL, so we should add the requirement to
it. Fixes underlinking when generating Meta-1.gir.
2017-10-09 13:41:41 +02:00
c85f322b20 backends/native: Move functions out of HAVE_EGL_DEVICE
Those are now used in common code, so should be taken out of
the ifdef. Fixes compilation without EGL streams.
2017-10-09 13:39:50 +02:00
76096a725b monitor-unit-tests: Check going headless -> headless
https://bugzilla.gnome.org/show_bug.cgi?id=788607
2017-10-07 00:36:03 -04:00
6eb7d13894 window: Handle updating from no to no monitor
When we received two hot plug events that both resulted in headless
configuration, we tried to find a new window monitor given the old.
That resulted in a null pointer dereference; avoid that by only trying
to find the same monitor if there was an old one.

https://bugzilla.gnome.org/show_bug.cgi?id=788607
2017-10-07 00:36:03 -04:00
7928b25ebf renderer/native: Use g_initable_new() to create renderer
No need to do g_object_new then g_initable_init while tracking the
lifetime when g_initable_new() can do it for us.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-06 13:18:12 -04:00
78e6258b44 cursor-renderer-native: Support HW cursors on multiple GPUs
On hybrid GPU systems, hardware cursors needs to be realized on all the
GPUs, as scanout cursor planes cannot be shared. Do this by moving gbm
buffer and drm buffer ID management to a per GPU struct, realizing a
cursor on each GPU when previously only realized on the primary GPU.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-06 13:18:12 -04:00
c9259c2b15 renderer-native: Add hybrid GPU system support
A hybrid GPU system is a system where more than one GPU is connected to
connectors. A common configuration is having a integrated GPU (iGPU)
connected to a laptop panel, and a dedicated GPU (dGPU) connected to
one or more external connector (such as HDMI).

This commit adds support for rendering the compositor stage using the
iGPU, then copying the framebuffer content onto a secondary framebuffer
that will be page flipped on the CRTC of the dGPU.

This can work in two different ways: GPU accelerated using Open GL ES
3, or CPU unaccelerated.

When supported, GPU accelerated copying works by exporting the iGPU
onscreen framebuffer as a DMA-BUF, importing it as a texture on a
separate dGPU EGL context, then using glBlitFramebuffer(), blitting it
onto a framebuffer on the dGPU that can then be page flipped on the dGPU
CRTC.

When GPU acceleration is not available, copying works by creating two
dumb buffers, and each frame glReadPixels() from the iGPU EGL render
context directly into the dumb buffer. The dumb buffer is then page
flipped on the dGPU CRTC.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-06 13:18:12 -04:00
492d2eb573 renderer-native: Move some error reporting up the call stack
Pass GErrors to functions that can fail, and report the error att the
call site.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:17:26 -04:00
376dcd3b92 gpu-kms: Pass GPU on page flip callbacks
https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:17:26 -04:00
60781bc6c2 backends: Add OpenGL ES 3 abstraction layer
Add helper functions and macros for managing and drawing OpenGL ES 3.
It will be used for blitting framebuffers between multiple GPUs in
hybrid GPU systems.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:17:26 -04:00
2d8827cb0c egl: Add more API used when rendering
Eventually, we'll render buffers without using Cogl, and for this we
need to be able to do things like creating, destroying and changing the
context, as well as swapping buffers.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:17:26 -04:00
802f7dcd30 monitor: Add meta_monitor_get_gpu()
Add API to get what GPU drives this monitor.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:17:26 -04:00
e62cfd9043 egl: Expose eglGetProcAddress
It will be needed for OpenGL ES extension function symbol loading.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:17:26 -04:00
cbcf6a4f23 monitor-manager-kms: Add all GPUs with connectors
First find the primary GPU and open it. Then go through all other
discovered GPUs with connectors and add those too. MetaRendererNative
still fails to initialize when multiple added GPUs and
MetaCursorRendererNative still always falls back on OpenGL based cursor
rendering when there are multiple GPUs.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:17:26 -04:00
b0e42d3f6e renderer-native: Always use MetaEgl when interacting with EGL
Partly for consistency, partly for error handling functionality.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:17:25 -04:00
18eb66de06 cogl: Add way to pass user data when setting custom renderer winsys
When creating a renderer with a custom winsys (which is always how
mutter uses cogl) make it possible to pass a user data with the winsys.
Still unused.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:10:30 -04:00
b32cccddf9 egl: Expose .._has_extensions_..() function
It will be used by e.g. a future GLES helper unit needing similar
functionality.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:10:30 -04:00
362e26b3e2 renderer-native: Add MetaEgl getter from renderer
https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:10:30 -04:00
5c53284bde renderer-native: Turn dumb buffer into a simple type
Make dumb buffer creation/destruction reusable by introducing a
MetaDumbBuffer type (private to meta-renderer-native.c). This will
later be used for software based fallback paths for copying render GPU
buffers onto secondary GPUs.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:10:27 -04:00
e45d7f70e8 crtc-kms: Don't set normal transform when no transforms are supported
On a CRTC that doesn't report any transforms at all, setting the normal
transform will fail. Avoid failing by checking if any transforms are
supported before applying it, and early out if no transforms are
supported.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:08:09 -04:00
70edc7dda4 backends/native: Stop supporting stage views being disabled
Get rid of some technical dept by removing the support in the native
backend for drawing the the whole stage to one large framebuffer.
Previously the only way to disable stage views was to set the
MUTTER_STAGE_VIEWS environment variable to 0; doing that now will cause
the native backend to fail to initialize.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:08:09 -04:00
3244ed37a9 cursor-rendere-native: Don't declare HW cursors broken on EACCES
Don't permanently fall back to OpenGL based cursor rendering when
setting the HW cursor fails with EACCES as that may happen on VT
switching and other things temporarily revoking fd access.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:08:09 -04:00
406359bba1 gpu-kms: poll() on KMS fd on EAGAIN
When drmHandleEvent() returns an error and errno is set to EAGAIN,
instead of ending up in a busy loop, poll() the fd until there is
anything to read.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:08:09 -04:00
8b23dd915f cursor-renderer-native: Don't leak cursor gbm buffers
We tried to free all three cursors by looping, but only ever tried to
free the first buffer.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:08:09 -04:00
7e1f65405f native/renderer: More naming cleanups
The prefix, if any, of a variable name often contains information about
the namespace (such as clutter_backend is the ClutterBackend, while
backend is a MetaBackend). Clean up some more inconsistencies in
meta-renderer-native.c where various variable names were egl_ prefixed
but in fact was Cogl types.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:08:08 -04:00
c1683073f1 backends: Split out CRTC/output management to MetaGpu
In order to eventually support multilpe GPUs with their own connectors,
split out related meta data management (i.e. outputs, CRTCs and CRTC
modes) into a new MetaGpu GObject.

The Xrandr backend always assumes there is always only a single "GPU" as
the GPU is abstracted by the X server; only the native backend (aside
from the test backend) will eventually see more than one GPU.

The Xrandr backend still moves some management to MetaGpuXrandr, in
order to behave more similarly to the KMS counterparts.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 18:05:20 -04:00
18ec86bd90 Remove meta_monitor_manager_get_monitor_for_output() API
This function is replaced by an equivalent that takes a connector
string.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
315a6f43d7 monitor-manager: Keep pointer to backend
Instead of accessing the global singleton, keep a pointer to the
backend in the MetaMonitorManager struct.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
7603bb5fd5 monitor-manager-dummy: Use GObject type declaration macro
Use G_DECLARE_FINAL_TYPE instead of old multiple macro definitions way.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
d53b79f8c3 native/cursor-renderer: Cleanup construction
Pass the backend to a new factory function, and keep a pointer to the
monitor manager, which is accessed elsewhere in the same file instead of
fetching the singleton. The HW cursor initialization part is also made
more obvious, without depending on seemingly irrelevant clutter
features.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
f534452c6a cursor-renderer-native: Remove unused functions and declarations
https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
0f6b83e7df cursor-renderer-native: Cleanup type declaration
Use G_DECLARE_FINAL_TYPE instead of the old macros.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
16a6aef5a7 backends/native: Move KMS fd management to monitor manager
Move finding, opening and managment of the KMS file descriptor to
MetaMonitorManagerKms. This means that the monitor manager creation can
now fail, both if more than one GPU with connectors is discovered, or
if finding or opening the primary GPU fails.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
518fb9fb5e backends: Split monitor manager creation into create and setup
The monitor manager instance was created and setup in one step; at
construction. This is problematic if, in the future, the monitor manager
creation can fail, as the monitor manager is created quite late.

To make it possible to in the future fail creating a monitor manager,
create the instance very early when initiating the backend, then on
post init backend setup, "setup" the monitor manager state, i.e. read
the current state and setup the stage.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
547ace3cf8 backend/native: Propogate error when creating renderer
The error was printed, then dropped, eventually resulting in another
generic error being printed. Lets just propogate the error all the way
up instead.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
a4ba38ee78 backends/x11: Move CRTC code to its own file
Move code dealing with Xrandr MetaCrtcs and related functionality to its
own file. Eventually, MetaCrtcCrtc should be introduced, based on
MetaCrtc, and this commit is in preparation for that.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
e32d52b9b8 backends/x11: Move output code to its own file
Move code dealing with X11 MetaOutputs and related functionality to its
own file. Eventually, a MetaOutputXrandr should be introduced, based on
MetaOutput, and this commit is in preparation for that.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
de40ced8b4 backends/native: Move CRTC code to its own file
Move code dealing with MetaCrtcKms and related functionality to its
own file. Eventually, MetaCrtcKms should become a GObject based on
MetaCrtc, and this commit is in preparation for that.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
cfee58798e backends/crtc: Keep a pointer to the monitor manager
Instead of passing it around or fetching the singleton, keep a pointer
to the monitor manager that owns the CRTC. This will eventually be
replaced with a per GPU/graphics card object.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
7ea01693a7 backends/native: Move output code to its own file
Move code dealing with MetaOutputKms and related functionality to its
own file. Eventually, MetaOutputKms should become a GObject based on
MetaOutput, and this commit is in preparation for that.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
e0d839aea2 backends/output: Keep a pointer to the monitor manager
Instead of passing it around or fetching the singleton, keep a pointer
to the monitor manager that owns the output. This will eventually be
replaced with a per GPU/graphics card object.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
d3efd73429 monitor-manager-kms: Use G_DECLARE_FINAL_TYPE macro
Declare the MetaMonitorManagerKms type using the helper macro, instead
of manually.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
2db5505216 monitor-manager: Turn MetaCrtcMode into a GObject
Convert MetaCrtcMode from a plain struct to a GObject. This changes the
storage format, and also the API, as the API was dependent on the
storage format.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
f44b6c772a monitor-manager/kms: Some naming fixes
Prefix external types (e.g mode -> drm_mode) and rename a search
function to not refer to a local type as ".._meta_..".

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
f64fab1d2d monitor-manager: Make MetaCrtc a GObject
Turn MetaCrtc into a GObject and move it to a separate file. This
changes the storage format, resulting in changing the API for accessing
MetaCrtcs from using an array, to using a GList.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
39bc2e0333 monitor-manager/dummy: Define tile count instead of using array length
Explicitly define the tile count (2) and use this instead of the
crtc_decl array length.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
5bb6f0ad8b renderer/native: Use helper to iterate over logical monitor CRTCs
Don't iterate over all the CRTCs and check the CRTC logical monitor
state, but use the new MetaLogicalMonitor helper instead.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
903537a2a0 logical-monitor: Add helper for iterating over active CRTCs
Add meta_logical_monitor_foreach_crtc() helper to iterate over all the
active CRTCs driving the monitors associated with the specified logical
monitor.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
1db937826c monitor-manager/xrandr: Fix crtc variable naming
The variable name of the local type (MetaCrtc) should not be prefixed,
while the external one should be.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
c1fe1c5d6b window-actor: Use monitor API to get frame message refresh rate
Use the MetaMonitor API instead of accessing outputs directly to get
the refresh rate used when genaritng the frame message.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
a62e9f99a2 backends: Remave unused meta_monitor_manager_get_resources() API 2017-10-05 16:18:43 -04:00
9817a6aa47 Make MetaOutput a GObject
Turn MetaOutput into a GObject and move it to a separate file. This
changes the storage format, resulting in changing the API for accessing
MetaOutputs from using an array, to using a GList.

https://bugzilla.gnome.org/show_bug.cgi?id=785381
2017-10-05 16:18:43 -04:00
8185373bd4 screen-cast-stream-src: Only clean up pipewire remote/core if they exist
They can could fail to create, so lets deal better with that
possibility.

https://bugzilla.gnome.org/show_bug.cgi?id=788569
2017-10-05 16:15:48 -04:00
18c41aefc9 build: Fetch pipewire micro version
Pipewire doesn't export its version defines, so the API checks added
in commit f0c6c4eb1f effectively disable screencasting, whoops.
Breaking changes like this should disappear once the library stabilizes,
so simply define the version ourselves instead of writing a "proper"
test with AC_COMPILE_IFELSE() ...

https://bugzilla.gnome.org/show_bug.cgi?id=788572
2017-10-05 22:11:14 +02:00
32917f1922 wayland-dma-buf: Don't send modifiers to old clients
The modifier event was only added in v3 of the client; sending it to
older clients (e.g. GStreamer waylandsink) causes them to disconnect
immediately.

Send the older 'format' event to all clients, and only send the newer
'modifier' event to resource versions 3 or above.

https://bugzilla.gnome.org/show_bug.cgi?id=788558
2017-10-05 10:51:06 -04:00
7a843e1fd1 [l10n] Updated Catalan (Valencian) translation 2017-10-05 14:15:49 +02:00
0e154ccf76 Bump version to 3.26.1
Update NEWS.
2017-10-04 01:11:31 +02:00
120db06c60 monitor-tests: Test config migration with refresh rate wiggle room
Check that we finish configurations within range, and discard the ones
out of range.

https://bugzilla.gnome.org/show_bug.cgi?id=787668
2017-10-04 09:45:52 -04:00
e76ab05d45 monitor-tests: Fix error message grammar mistake 2017-10-04 09:45:02 -04:00
43eeb009ce monitor-config-migration: Discard if configured mode is missing
If a configuration key matched a current system state, but no monitor
mode was found (for example because of an incorrect refresh rate),
discard it while logging a warning.

https://bugzilla.gnome.org/show_bug.cgi?id=787668
2017-10-04 09:45:02 -04:00
9000eef49d backends: Add envvar to disable wacom configuration
People that relied on xsetwacom to configure their tablets used to get
away with this by disabling the wacom g-s-d plugin prior to running
their scripts. This is not possible anymore with mutter managing device
configuration.

Given that X11 shall not go away soon and there's a core of stubbornly
accustomed users, provide a MUTTER_DISABLE_WACOM_CONFIGURATION envvar
to provide *some* way to do this.
2017-10-04 01:03:49 +02:00
e198c8452b x11: Add support for _GTK_EDGE_CONSTRAINTS atom
To keep feature parity with the Wayland backend, and
to improve the overall tiling experience with GTK apps,
add the _GTK_EDGE_CONSTRAINTS X11 atom and update it
when necessary.

https://bugzilla.gnome.org/show_bug.cgi?id=751857
2017-10-03 19:38:32 -03:00
aea66ddff6 wayland: Send edge constraints
Following up the previous patch, this patch makes the
Wayland backend send the edge constraints through a
custom protocol extension internal to GTK.

As it mature, we can think of upstreaming the protocol
to Wayland itself.

https://bugzilla.gnome.org/show_bug.cgi?id=751857
2017-10-03 19:38:32 -03:00
a5f4ffa58c window: Track edge constraints
GTK has the ability to handle client-decorated windows
in such a way that the behavior of these windows must
match the behavior of the current window manager.

In Mutter, windows can be tiled horizontally (and, in
the future, vertically as well), which comes with a few
requirements that the toolkit must supply. Tiled windows
have their borders' behavior changed depending on the
tiled position, and the toolkit must be aware of this
information in order to properly match the window manager
behavior.

In order to provide toolkits with more precise and general
data regarding resizable and constrained edges, this patch
makes MetaWindow track its own edge constraints.

This will later be used by the backends to send information
to the toolkit.

https://bugzilla.gnome.org/show_bug.cgi?id=751857
2017-10-03 19:38:32 -03:00
a1c39e142d window: Also consider touching edges for matching tiled windows
When computing a potential match for a tiled window, there is a
chance we face the case where 2 windows really complement each
other's tile mode (i.e. left and right) but they have different
sizes, and their borders don't really touch each other.

In that case, the current code would mistakenly assume they're
tile matches, and would resize them with either a hole or an
overlapping area between windows. This is clearly a misbehavior
that is a consequence of the previous assumptions pre-resizable
tiles.

This patch adapts the tile match algorithm to also consider the
touching edges when computing the matching tile, unless:

 * the window is not currently tiled (for example when computing
   the tile preview)
 * the window is currently resized in tandem with an existing
   tile match

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

bar
2017-10-03 19:38:32 -03:00
e76a0f564c window: Raise and lower tile match in tandem
When a pair of tiled windows are grouped together, they
are treated as parts of a whole and interacting with one
affects the other.

Following the idea that sibling tiled windows are treated
as part of the same group, they should also be raised and
lowered together.

It is still possible to break tiled windows grouping by
simply untiling the window with the keyboard or by grabbing
and resizing or moving the window with the cursor.

This patch makes sibling tiled windows be lowered and raised
in tandem. For future reference, this behavior is documented
in [1].

[1] https://wiki.gnome.org/GeorgesNeto/MinutesOfFeaneron/Tiling

https://bugzilla.gnome.org/show_bug.cgi?id=645153
2017-10-03 19:38:31 -03:00
8307d9c4de edge-resistance: Remove useless variable
There is a variable in meta_window_edge_resistance_for_resize
that isn't really helpful: it just assumes TRUE, and is passed
to apply_edge_resistance_to_each_side.

This patch removes that useless variable and simply pass TRUE
instead.

https://bugzilla.gnome.org/show_bug.cgi?id=645153
2017-10-03 19:38:31 -03:00
1dbf6b096b edge-resistance: Add snapping for tiled windows
When windows are tiled, it improves the interaction with
them when they have a set of snapping edges relative to
the monitor. For example, when there's a document editor
and a PDF file opened, I might want to rescale the former
to 2/3 of the screen and the latter to 1/3.

These snapping sections are not really tied to any other
window, and only depend on the current work area of the
window. Thus, it is not necessary to adapt the current
snapping edge detection algorithm.

This patch adds the necessary code in edge-resistance.c
to special-case tiled windows and allow them to cover
1/4, 1/3 and 1/2 (horizontally) of the screen. These
values are hardcoded.

https://bugzilla.gnome.org/show_bug.cgi?id=645153
2017-10-03 19:38:31 -03:00
6fe71ecc01 window: Tile and resize considering the tile match
After the introduction of the possibility to resize tiled windows,
it is a sensible decision to make windows aware of their tiling
match. A tiling match is another window that is tiled in such a
way that is the complement of the current window.

The newly introduced behavior attepts to make tiling as smooth as
possible, with the following rules:

 * Windows now compute their tile match when tiling and, if there's
   a match, they automatically complement the sibling's width.
 * Resizing a window with a sibling automatically resizes the sibling
   too to be the complement of the window's width.
 * It is not possible to resize below windows' minimum widths.

https://bugzilla.gnome.org/show_bug.cgi?id=645153
2017-10-03 19:38:31 -03:00
57e58eaf2a window: Maximize tiled windows when resizing to work area
Now that tiled windows are resizable, the user may grow a tiled
windows until it covers the entire work area. As this makes the
window state mostly indistinguishable from maximization, avoid
subtle differences by properly maximizing the window in that case.

https://bugzilla.gnome.org/show_bug.cgi?id=645153
2017-10-03 19:38:31 -03:00
00a5db71cf window: Allow resizing of tiled windows
Currently tiled windows are not resizable and their size is fixed
to half the screen width. Adjust the code to work with fractions
other than half, and allow users to adjust the split by dragging
the window edge that is not constrained by a monitor edge.

Follow-up patches will improve on that by resizing neighboring
tiled windows by a shared edge, and making the functionality
available to client-side decorated windows implementing the
new edge constraints protocol.
2017-10-03 19:38:31 -03:00
c7fa57cd28 window: Pass mode as parameter to tile() operation
Now that the preview tile mode has been split from the window's
tile_mode property, it is much more natural to pass the requested
tile_mode to the tile() function instead of setting it externally
and calling the function to apply the state.
2017-10-03 19:38:31 -03:00
8f2c86d79e window: Split out preview_tile_mode
The existing semantics of the tile_mode property are terribly confusing,
as it depends on some other property whether it represents the requested
or current mode. Clear this up by just using separate variables for the
two. As it is unlikely that we will ever support more than one tile
preview, we can track the requested mode globally instead of adding
another per-window variable.

https://bugzilla.gnome.org/show_bug.cgi?id=645153
2017-10-03 19:38:31 -03:00
56f1da5c66 window: Update tile monitor before move
The actual move may involve the tile monitor, so make sure to not use
an outdated value by setting it before calling move_between_rects().

https://bugzilla.gnome.org/show_bug.cgi?id=645153
2017-10-03 19:38:31 -03:00
30a205c0e3 window: Remove obsolete code
Commit 91b7dedf36 removed the ability to temporarily break out
of maximization/tiling during grab operations, so this code is no
longer necessary.

https://bugzilla.gnome.org/show_bug.cgi?id=645153
2017-10-03 19:38:31 -03:00
98d77d37d0 screen: Make sure to initialize NUMBER_OF_DESKTOPS
update_num_workspaces() is a no-op when the number of workspaces
did not actually change. That is fine, except that we still want
to initialize the _NET_NUMBER_OF_DESKTOPS hint on startup to not
break components like nautilus-desktop that rely on it.

https://bugzilla.gnome.org/show_bug.cgi?id=760651
2017-10-04 00:07:34 +02:00
0853fb940a project: add **/tags.* to gitignore
Builds adds lots of them in the source tree.
2017-10-03 15:55:11 -03:00
6dd819a61e window: Don't try to auto-maximize when headless
Automatic maximization is done when a window is almost the size of the
work area of a monitor. This makes no sense to try when there is no
monitor available, so skip trying to do this when headless.

https://bugzilla.gnome.org/show_bug.cgi?id=787637
2017-10-02 18:02:19 -04:00
39aae19ed7 window: Treat being headless as not monitor sized
When we are headless, treat this as if the window is always not monitor
sized. This might cause windows to temporarly become redirected while
being headless, but this is harmless as when a new monitor is
connected, we'll recalculate weather it should be redirected or not.

https://bugzilla.gnome.org/show_bug.cgi?id=787637
2017-10-02 18:02:16 -04:00
20749e5dbd renderer-native: Unset mode on disabled CRTCs
Make sure we properly unset the CRTC mode when a monitor is disabled.

https://bugzilla.gnome.org/show_bug.cgi?id=787629
2017-10-02 15:34:41 -04:00
99e1cd549d monitor-unit-tests: Test configs with explicitly disabled monitors
Check that configurations where monitors are disabled are properly
used. Also test that old configurations with explicitly disabled
outputs are migrated properly.

https://bugzilla.gnome.org/show_bug.cgi?id=787629
2017-10-02 15:34:41 -04:00
efdbeb7c1b monitor-unit-tests: Add way for test case setup to specify output serial
This is needed to avoid migration tests to avoid the best-effort tiling
monitor detection paths.

https://bugzilla.gnome.org/show_bug.cgi?id=787629
2017-10-02 15:34:41 -04:00
ea4dbd14bc monitor-config: Keep track of disabled monitors for stored configs
When saving and restoring monitor configurations, we must take disabled
monitors into account, as otherwise one cannot store/restore a
configuration where one or more monitors are explicitly disabled. Make
this possible by adding a <disabled> element to the <configure> element
which lists the monitors that are explicitly disabled. These ones are
included when generating the configuration key, meaning they'll be
picked up correctly.

https://bugzilla.gnome.org/show_bug.cgi?id=787629
2017-10-02 15:34:24 -04:00
838df4b00b monitor-config-store: Make monitor spec parsing/writing reusable
Another use of <monitorspec> will be added, so make the code dealing
with parsing and writing the reusable.

https://bugzilla.gnome.org/show_bug.cgi?id=787629
2017-10-02 15:32:35 -04:00
b6110ba8dc Update Chinese (Taiwan) translation 2017-10-01 14:57:53 +00:00
fd763ad857 Revert "src/core/screen.c: Set _NET_NUMBER_OF_DESKTOPS in meta_screen_new"
When dynamic workspaces are used, we pick up an existing NUMBER_OF_DESKTOP
hint in meta_screen_init_workspaces() to properly restore workspaces
on restart. Unconditionally setting that hint to 1 *before* reading it
breaks that, and we end up shifting all windows to the first workspace.

This reverts commit 8532b10290.

https://bugzilla.gnome.org/show_bug.cgi?id=760651
2017-09-30 00:21:55 +02:00
e3d59832c5 x11/window: Implement _NET_RESTACK_WINDOW and XConfigureRequestEvent sibling
Implement _NET_RESTACK_WINDOW, based on metacity commit 0b5a50c8.

Also respect "above" field (sibling) of XConfigureRequestEvent. When it is
set, perform a stack operation relative to that sibling.

https://bugzilla.gnome.org/show_bug.cgi?id=786363
https://bugzilla.gnome.org/show_bug.cgi?id=786365
2017-09-29 18:30:26 +02:00
2c85bb4178 window: Make should_be_on_all_workspaces() handle being headless
Also adds a soft assert to meta_window_is_on_primary_monitor() to make
it easier to spot when callers might want to handle headless
in a certain way.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-09-29 10:35:13 -04:00
8493777961 backends/x11: Prevent segfault when querying list of devices
The XIQueryDevice function used by device_query_area can return a NULL
pointer and set n_devices to a negative number in some cases. We add
additional checks to prevent a segfault.

https://bugzilla.gnome.org/show_bug.cgi?id=787649
2017-09-28 09:58:17 -04:00
4e7405aca9 wayland/surface: Send buffer release events immediately
Just queuing the buffer release event is prone to starvation, so send
the release immediately. See
https://lists.freedesktop.org/archives/wayland-devel/2017-September/035147.html
for more detailed explanation.

https://bugzilla.gnome.org/show_bug.cgi?id=788197
2017-09-28 09:58:17 -04:00
34207ba509 screen: Unset timeout ID after removal
Otherwise we may try to remove the now invalid ID again, resulting
in a warning.

https://bugzilla.gnome.org/show_bug.cgi?id=788292
2017-09-28 15:12:53 +02:00
6dc499f305 window: Support snap packages for sandboxed app IDs
For now we abuse of meta_window_get_flatpak_id not to break the APIs,
so that it's working seamlessly in gnone shell too.

Rename flatpak_id to sandboxed_app_id internally to get prepared to the future
API.

https://bugzilla.gnome.org/show_bug.cgi?id=788217
2017-09-27 22:08:57 +08:00
92e2242cf0 backend: Remove meta_backend_get_ui_scaling_factor
Forgotten in 2718699ccc

https://bugzilla.gnome.org/show_bug.cgi?id=788199
2017-09-26 17:46:49 +02:00
ea214fbe0f Remove unscaled-font-dpi setting from X11 backend
https://bugzilla.gnome.org/show_bug.cgi?id=788049
2017-09-25 22:01:11 +01:00
487b8a0430 keybindings: Resolve on us layout too if primary is not latin based
If a non-latin based keyboard layout is active, for example Cyrillic,
keybindings won't work unless we resolve the bound keysyms on a
secondary latin based layout. So, to make keybindings work on non-latin
based layouts, detect if a keymap doesn't have all of the basic latin
letters (a-z) and resolve from an additional US layout as well.

https://bugzilla.gnome.org/show_bug.cgi?id=787016
2017-09-25 15:31:07 -04:00
8b060342bd keybindings: Add support for resolving from multiple layouts
Add the infrastructure to resolve keybinding symbols from multiple
layouts. It is still unused, but will be, when the primary layout does
not have the required latin keysyms in it.

https://bugzilla.gnome.org/show_bug.cgi?id=787016
2017-09-25 15:31:07 -04:00
27d6c063ad keybindings: Keep a pointer to the backend
A few less singleton getting.

https://bugzilla.gnome.org/show_bug.cgi?id=787016
2017-09-25 15:31:07 -04:00
0e62b71959 keybindings: Fix inconsistent struct field alignment
https://bugzilla.gnome.org/show_bug.cgi?id=787016
2017-09-25 15:31:07 -04:00
2c3f79829e Update Croatian translation 2017-09-22 18:52:02 +00:00
5d2b0bc0cc meta-input-settings: Fix strv memleak in find_logical_monitor()
The return value from g_settings_get_strv must be g_strfreev-ed.

https://bugzilla.gnome.org/show_bug.cgi?id=787836
2017-09-22 20:09:04 +02:00
7e3a780dcd monitor-config-manager-kms: Fix is_transform_handled
meta_monitor_manager_kms_is_transform_handled should checked the
transform passed as function argument, not the current crtc transform.

https://bugzilla.gnome.org/show_bug.cgi?id=787836
2017-09-22 20:09:04 +02:00
1035200f26 monitor-config-manager: Fix 90/270 degree rotation not working
When rotating 90/270 degrees we need to swap width and height. This fixes
the screen going black and the following errors showing in the journal:

gnome-shell[1097]: Failed to set CRTC mode 800x1280: No space left on device
gnome-shell[1097]: Failed to flip: Device or resource busy
gnome-shell[1097]: Failed to set CRTC mode 800x1280: No space left on device
gnome-shell[1097]: Failed to set CRTC mode 800x1280: No space left on device

When rotating a tablet with accelerometer 90/270 degrees.

https://bugzilla.gnome.org/show_bug.cgi?id=787836
2017-09-22 20:09:04 +02:00
8532b10290 src/core/screen.c: Set _NET_NUMBER_OF_DESKTOPS in meta_screen_new
Make sure to call set_number_of_spaces_hint in meta_screen_new.
_NET_NUMBER_OF_DESKTOPS is required by nautilus-desktop to correctly
get the desktop workarea.

https://bugzilla.gnome.org/show_bug.cgi?id=760651
2017-09-22 14:51:46 +02:00
f0c6c4eb1f screen-cast-stream-src: Adjust to pipewire API break
https://bugzilla.gnome.org/show_bug.cgi?id=787953
2017-09-21 18:14:26 +02:00
ba194bd19e clutter: Fix capture_into on non-origin view
The capture_into() function wrote out of bounds when capturing from a
non-origin view (not positioned at (0,0)). At the time of
implementation, this API was used to capture pixels across views into a
single data buffer, but the way it's used, and the way views may work
now, makes this impossible to do properly.

So remove the ability to capture into a pre-allocated buffer from
multiple views, and complain if the passed rectantgle overlapps with
multiple views. This removes the broken offset calculation all
together, fixing the bug motivating this change.

https://bugzilla.gnome.org/show_bug.cgi?id=787715
2017-09-20 18:27:57 +08:00
a35274ddb7 screen-cast-stream: Add stream parameters
For monitor streams, add position and size (in compositor coordinate
space) parameters.

https://bugzilla.gnome.org/show_bug.cgi?id=787715
2017-09-20 18:27:57 +08:00
ab541e3e0f monitor-config-migration: Fix a minor leak when parsing fails
https://bugzilla.gnome.org/show_bug.cgi?id=787477
2017-09-20 17:26:32 +08:00
67ce04993e monitor: Add scale 1 if no other supported scale was added
We currently have a hard coded limit on logical monitor sizes, meant
for filtering out monitor scales that would result in awkward desktop
sizes. This has the side effect of also disqualifying scale 1 for
resolutions that themself are lower than the mentioned limit. To avoid
listing no supported scales, always add the fallback scale 1 if no
other was added.

https://bugzilla.gnome.org/show_bug.cgi?id=787477
2017-09-20 17:26:32 +08:00
22cdc8f414 monitor-manager: Pass config to derive from when updating state
When we update state, we might not have set the current config yet (for
example if the Xrandr assignment didn't change), so pass the monitors
config we should derive from instead of fetching it from the monitor
config manager.

https://bugzilla.gnome.org/show_bug.cgi?id=787477
2017-09-20 17:26:32 +08:00
8b022a5595 monitor-config-store: Maybe force save configuration on tear down
If there is a pending config file content replacement in progress on
tear down, cancel it and save it synchronously to avoid any data loss.

https://bugzilla.gnome.org/show_bug.cgi?id=787477
2017-09-20 17:26:32 +08:00
7a1393ba26 monitor-config-store: Don't leak when saving synchronously
We currently only save synchronously when running the test suite, but
should still not leak the generated config buffer. We also created the
cancellable but never used it if we saved synchronously, so lets stop
doing that too.

https://bugzilla.gnome.org/show_bug.cgi?id=787477
2017-09-20 17:26:20 +08:00
5ed954e6de monitor-config-store: Don't clear cancellable when cancelled
The cancellable should only be cleared if we weren't cancelled, as if
we were cancelled, the path cancelling have already cleared the
cancellable.

https://bugzilla.gnome.org/show_bug.cgi?id=787477
2017-09-20 17:25:00 +08:00
96572fbe6a monitor-config-migration: Don't destroy autoptr:ed hash table
It'll be destroyed automatically, so don't do it manually as well.

https://bugzilla.gnome.org/show_bug.cgi?id=787477
2017-09-20 17:25:00 +08:00
4ab47e72e5 monitor-config-migration: Clean up properly when deriving
We cleaned up an unused monitor config list, but what we should do is
clear up the logical monitor config list. This commit does that, as
well as removes the unused monitor config list.
2017-09-20 17:24:49 +08:00
70e0fd0b45 backends: Chain up some GObjectClass vfuncs
Various vfunc implementations was not chained up properly. This commit
fixes that.

https://bugzilla.gnome.org/show_bug.cgi?id=787477
2017-09-20 11:14:27 +08:00
26cd031be8 clutter: Use the ClutterScrollFinishFlags when delivering scroll event
This got accidentally hardcoded to CLUTTER_SCROLL_FINISHED_NONE on commit
d3c559a917, which broke kinetic scrolling for touchpads on clients.
2017-09-14 15:39:58 +02:00
743e8cc249 backends: Add some wiggle room for refresh rate comparisons
We have not enough control over the sources of the refresh rate
float variable to make == comparisons reliable, add some room
when comparing these.

https://bugzilla.gnome.org/show_bug.cgi?id=787668
2017-09-14 13:31:25 +02:00
2bf7974076 wayland: do not leak shortcut inhibit data
We would free the shortcut inhibit data only when the client destroys
its request, which is not the case when the clients itself is
destroyed, leading to a leak of the shortcut inhibit data.

Free the data on resource destruction instead, and simply destroy the
resource on destroy request.

https://bugzilla.gnome.org/show_bug.cgi?id=787568
2017-09-14 09:32:26 +02:00
9c16e4e2f3 wayland: Keep the inhibit shortcut dialog
On Wayland, the grab()/ungrab() in gtk+/gdk are wired to the shortcut
inhibitor mechanism, which in turn shows the dialog, which can take
focus away from the client window when the dialog is shown.

If the client issues an ungrab() when the keyboard focus is lost, we
would hide the dialog, causing the keyboard focus to be returned to the
client surface, which in turn would issue a new grab(), so forth and so
on, causing a continuous show/hide of the shortcut inhibitor dialog.

To avoid this issue, keep the dialog around even if the shortcut inhibit
is canceled by the client, so that the user is forced to make a choice
that we can reuse on the next request without showing the dialog again.

Instead of hiding the dialog when the shortcut inhibitor is destroyed by
the client, we simply mark the request as canceled and do not apply the
user's choice.

https://bugzilla.gnome.org/show_bug.cgi?id=787568
2017-09-14 09:32:26 +02:00
07f6c85cc7 wayland/inhibit-shortcuts-dialog: Use g_new0 instead of g_new
The code assumed the newly allocated blocked was initialized to 0, but
it wasn't since g_new was used. Fix that by using g_new0.

https://bugzilla.gnome.org/show_bug.cgi?id=787570
2017-09-14 09:32:26 +02:00
d4968e10e5 Updated Slovenian translation 2017-09-13 12:25:01 +02:00
bd3817198e Bump version to 3.26.0
Update NEWS.
2017-09-12 16:45:03 +02:00
5b5737f65e updated correct location file for Punjabi 2017-09-10 18:27:35 -05:00
5af8753171 Update French translation 2017-09-10 20:16:37 +00:00
8bef74f441 Updated Danish translation 2017-09-10 18:13:01 +02:00
f1a42b0f97 Updated Bulgarian translation 2017-09-10 17:43:33 +03:00
95682a9494 Update Swedish translation 2017-09-10 11:09:05 +00:00
ef41867303 Fixes to Catalan translation 2017-09-10 09:06:57 +02:00
8d4b03ce87 Update Basque language 2017-09-09 18:04:59 +02:00
06263354a5 Updated Vietnamese translation
Signed-off-by: Trần Ngọc Quân <vnwildman@gmail.com>
2017-09-09 08:28:41 +07:00
aa30e11c8b screen-cast-stream-src: Remove malformed include
The mutter prefix is wrong - as the include isn't actually needed in
the header, just remove it altogether.
2017-09-08 17:54:44 +02:00
65bca8e008 Bump version to 3.25.92
Update NEWS.
2017-09-07 17:35:21 +02:00
068791f6c1 meta-background-actor: Add gradient effect
Add a gradient effect that goes from the top to the bottom. The
height and the initial dark tone of the gradient are customizable.

https://bugzilla.gnome.org/show_bug.cgi?id=786618
2017-09-07 16:59:56 +02:00
cbc4563b30 meta-background-actor: Rename brightness to vignette_brightness
The brightness is about the vignette. Add a 'vignette_' prefix in order
to give more context. Keep the property name as it is, doing so we don't
break any plugin (e.g., gnome-shell).

https://bugzilla.gnome.org/show_bug.cgi?id=786618
2017-09-07 16:59:56 +02:00
f381d7c3bf meta-background-actor: Rename shader snippets
Add the word 'vignette' in order to give some context on what the
snippets do. This will be useful later when we land other snippets
for the gradient effect.

https://bugzilla.gnome.org/show_bug.cgi?id=786618
2017-09-07 16:59:56 +02:00
0a8d8128b3 Update Hungarian translation 2017-09-05 15:36:07 +00:00
46135d4f0f configure.ac: Fix comment for HAVE_REMOTE_DESKTOP
It was copy pasted from the HAVE_EGL_DEVICE configuration, but the
comment was not updated. Fix that.
2017-09-05 11:43:38 +08:00
7ba44e7945 meta-background-actor: Style fix
https://bugzilla.gnome.org/show_bug.cgi?id=786618
2017-09-05 01:39:30 +02:00
dd4ad4efc4 Revert "renderer-native: Destroy monitor framebuffers when suspending"
The reverted commit seems to cause
https://bugzilla.gnome.org/show_bug.cgi?id=787240 for some reason. Lets
be safe and revert it for now, as the code freeze is just around the
corner.

This partly (it doesn't reintroduce a whitespace issue) reverts commit
dbc63430d8.
2017-09-04 22:37:16 +08:00
807658e972 wayland: Don't free non-transferred string when cleaning up
When cleaning up the display name string management, the display name
string retrieved from libwayland-server was also passed to free() on
clean up. This is invalid as the display name string ownership is not
transferred to us. Fix this by strdup:ing the string before saving it.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-09-04 12:32:53 +08:00
8499a29d0a Update Latvian translation 2017-09-03 19:25:22 +03:00
283eedef90 Update Brazilian Portuguese translation 2017-09-03 14:08:27 +00:00
ce515c5389 Updated Bulgarian translation 2017-09-02 09:32:27 +03:00
83440614bc Update Korean translation 2017-09-02 03:59:24 +00:00
a93661f9e1 src/Makefile-tests.am: Remove reference to non-existing file
The file headless-start-test.h doesn't exist, so don't include it in
the headless start test case source file list.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-09-02 11:09:28 +08:00
216f7631de Update Belarusian translation 2017-09-01 15:45:16 +00:00
361bf847af build: Require libgudev >= 232
And remove the g_autoptr implementations in mutter itself.

https://bugzilla.gnome.org/show_bug.cgi?id=760670
2017-09-01 11:19:50 +02:00
46f54eb3d9 Update Indonesian translation 2017-09-01 08:14:32 +00:00
bc47c6cc4f Update German translation 2017-08-31 19:29:27 +00:00
8bfdfa1f46 Update Turkish translation 2017-08-31 05:04:23 +00:00
999542c915 Updated Czech translation 2017-08-31 00:12:10 +02:00
cb38e9c4a2 Update Galician translation 2017-08-30 20:30:18 +00:00
42c56c2460 Update Finnish translation 2017-08-30 16:17:19 +00:00
e2d904c32b tests/monitor-unit-tests: Run a client while testing
Run a client while testing and check that it's alive when checking each
monitor configuration.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:44:05 +08:00
fa9c09feee tests/monitor-unit-tests: Sleep some after each hot plug
Give clients (such as Xwayland) a chance to bind the wl_output global
before we continue, otherwise there is an significant risk that mutter
won't see the bind request until after the next hot plug which might
have destroyed the global object.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:44:05 +08:00
3f6a2d02fd tests: Add headless start test case
Test that mutter starts properly when there are no monitors connected
yet, and that things work when a monitor is eventually connected.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:44:05 +08:00
5b37901b57 tests/utils: Add test_client_quit() helper
https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:44:05 +08:00
2df4ccd1cd window: Handle being headless better
This avoids updating state (such as position, size etc) when going
headless. Eventually, when non-headless, things will be updated again,
and not until then will we be able to update to a valid state.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:44:05 +08:00
dcd15e6145 wayland: Don't free the Wayland display name string too early
We accidentally freed the Wayland display name string, meaning
retrieving it later retrieved freed memory.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:42:45 +08:00
2a318eb3f2 wayland/output: Flush clients after creating wl_output global
In order to give the clients the best chance to bind the wl_output
before we later remove it (for example on fast hot plugs or in the test
suite), flush the client sockets after creating the global.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:42:45 +08:00
522eec00cd monitor: Add foreach output helper and fix foreach crtc helper
The foreach CRTC monitor mode helper incorrectly iterated over outputs
without CRTC when non-tiled modes were set on tiled monitors. This was
not expected by callers, so fix the helper to only iterate over active
outputs (that has or should have a CRTC).

The test cases uses the incorrect behaviour of the foreach CRTC helper
to check that the disabled outputs mode are set to NULL, so add a
foreach output helper and change the tests to use that instead.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:09:38 +08:00
be11c32815 tests: Move out test client helper from test-runner.c
It could be useful for running other types of test clients in other
tests.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:09:38 +08:00
24c91d95de core/screen: Make logical monitor getters handle being headless
Don't crash or return invalid indices when we are headless.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:09:38 +08:00
7562eb6006 core/window: Don't set a preferred output when there is none
If there are no active logical monitors, don't try to dereference a
NULL one to get a preferred output winsys id. Instead just set an
invalid one.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:09:38 +08:00
0aa7405a2a monitor-manager: Fall back to minimum screen size of 640 x 480
When headless, we don't have any logical monitors to derive a screen
size from, but we can't set it to empty as that will cause issues with
the clutter stage, UI widget layout and other things. To avoid such
issues, just fall back to a 640 x 480 screen size when headless.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:09:38 +08:00
a119e58773 backend: Only try to center pointer when there not headless
Don't attempt to center the pointer when there is nothing to center on.

https://bugzilla.gnome.org/show_bug.cgi?id=730551
2017-08-30 13:09:38 +08:00
8a32b42172 renderer/native: Round calculated framebuffer size before casting to int
Due to rounding issues, we can't assume a floating point calculation
will end up on an integer, even if we got the factor from the reverse
calculation. Thus, to avoid casting away values like N.999... to N,
when they should really be N+1, round the resulting floating point
calculation before casting it to int.

This fixes an issue where using the scale ~1.739 on a 1920x1080 mode
resulted in error when setting the mode, as the calculated size of the
framebuffer was only 1919x1080.

https://bugzilla.gnome.org/show_bug.cgi?id=786918
2017-08-30 13:07:11 +08:00
94a15404da Update Serbian Latin translation 2017-08-29 19:03:56 +00:00
fefede5b51 Update Serbian translation 2017-08-29 19:02:49 +00:00
5be00f23be Update Polish translation 2017-08-29 18:15:01 +02:00
bdbd2e96de Use Unicode quotation marks in a translatable string
Also adjusts existing translations for it.

See https://developer.gnome.org/hig/stable/typography.html

https://bugzilla.gnome.org/show_bug.cgi?id=772218
2017-08-29 18:08:08 +02:00
7785a57f8a Updated Lithuanian translation 2017-08-29 15:58:03 +03:00
cf01e26b2f Update Italian translation 2017-08-29 08:22:47 +00:00
6e46ad9f3a remote-desktop, screen-cast: Fail session method calls from other peers
Only accept method calls on the session objects from the same peer that
created the session.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 14:39:04 +08:00
921b18f713 screen-cast-session: Allow stand alone screen cast sessions
When a screen cast session is stand-alone, i.e. not created given a
remote desktop session managing it, allow calling the Start/Stop
methods to start and stop it.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 14:39:04 +08:00
53175e8788 ScreenCast: Pass PipeWire stream node ID directly
As of commit 5f5ef3de2cdc816dab82cb7eb5d7171bee0ad2c5 in pipewire the
stream creator can find out the node ID of the stream it created.

So instead of using a special purpose entry to the info property box to
let the application discover stream by monitoring added nodes searching
for the given special purpose entry, just pass the node directly.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 14:39:04 +08:00
920541fa26 screen-cast-stream-src: Only try to record frames when streaming
Only when the PipeWire stream state is 'PW_STREAM_STATE STREAMING'
should the signal be connected causing the src to maybe record a frame.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 14:39:04 +08:00
9d8922764c screen-cast: Handle PipeWire errors
When the PipeWire context or stream ends up in an error state, signal
that the source has closed. This then triggers the stream and finally
the session to be closed too.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 14:39:04 +08:00
97f2c7c161 Add remote desktop and screen cast functionality
This commit adds basic screen casting and remote desktoping
functionalty. This works by exposing two D-Bus API services:
org.gnome.Mutter.ScreenCast and org.gnome.Mutter.RemoteDesktop.

The remote desktop API is used to create remote desktop sessions. For
each session, a D-Bus object is created, and an application can manage
the session by sending messages to the session object. A remote desktop
session the user to emit input events using the D-Bus methods on the
session object. To get framebuffer content, the application should
create an associated screen cast session.

The screen cast API is used to create screen cast sessions. One can so
far either create stand-alone screen cast sessions, or a screen cast
session associated with a remote desktop session. A remote desktop
associated screen cast session is managed by the remote desktop session.

So far only remote desktop managed screen cast sessions are implemented.

Each screen cast session may have one or more streams. A screen cast
stream is a stream of buffers of some part of the compositor content.
So far API exists for creating streams of monitors and windows, but
only monitor streams are implemented.

When a screen cast session is started, the one PipeWire stream is
created for each screen cast stream created for the session. When this
has happened, a PipeWireStreamAdded signal is emitted on the stream
object, passing a unique identifier. The application may use this
identifier to find the associated stream being advertised by the
PipeWire daemon.

The remote desktop and screen cast functionality must be explicitly be
enabled at ./configure time by passing --enable-remote-desktop to
./configure. Doing this will build both screen cast and remote desktop
support.

To actually enable the screen casting and remote desktop, the user must
enable the experimental feature. See
org.gnome.mutter.experimental-features.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 14:39:04 +08:00
38235bc145 Add MetaFraction for dealing with fractions
Add MetaFraction, which consists of two integers, the numerator an the
denominator. The utility function to convert a double to a MetaFraction
comes from gstreamer.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 14:39:04 +08:00
3ce3a5a952 monitor: Add API to compare with old instance
When monitors changed, previous monitor instances are defunct, and any
reference holder should drop its reference. Sometimes they will want to
continue having a reference to the same monitor, so add this function
to make it possible to find it.

Currently the output and crtc references are invalid, as they are not
yet reference counted, so this can only look at cached fields.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 14:38:20 +08:00
3005a400ca monitor-manager: Add helper for getting monitor from connector
This will be used later.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 11:49:01 +08:00
34e7134db2 wayland/xdg-foreign: Move out ID generation helper to util.c
It'll be used to generate ID in the same way in other places later.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 11:49:01 +08:00
12710dc644 clutter/stage: Add capture_into API
Add API similar to clutter_stage_capture() but that draws into
externally allocated memory. It is assumed that the pixel format is
ARGB32, and the memory is structured in a way that the width of the
passed rectangle is identical to the stride divided by 4.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 11:49:01 +08:00
a10ad577a7 ClutterVirtualInputDevice: Add discrete scrolling
Add emitting of discrete scrolling events (such as mouse scroll
wheel-like events).

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 11:49:01 +08:00
d3c559a917 clutter/evdev: Move scroll notification to ClutterSeatEvdev
This refactors the scroll event emitting code, moving it behind a
clutter_seat_evdev_ helper.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 11:49:01 +08:00
1e7628a3ef ClutterVirtualInputDevice: Allow passing CLUTTER_CURRENT_TIME
If CLUTTER_CURRENT_TIME is passed, let the backend find an appropriate
time stamp representing the current time in the clock that is used by
that backend.

https://bugzilla.gnome.org/show_bug.cgi?id=784199
2017-08-29 11:49:01 +08:00
d5a85997f2 Updated Danish translation 2017-08-28 19:32:44 +02:00
5a37e0e1ef Updated Slovenian translation 2017-08-28 19:20:26 +02:00
00f6a74397 Update Latvian translation 2017-08-27 23:50:05 +03:00
c9439107c1 Update Serbian Latin translation 2017-08-27 20:29:58 +00:00
ba65664cbd Update Serbian translation 2017-08-27 20:28:54 +00:00
3da0730a31 Update Chinese (Taiwan) translation 2017-08-27 04:08:18 +00:00
98fcd616a3 Update Catalan translation 2017-08-25 13:23:23 +02:00
06d0989014 wayland-dma-buf: Fix 32bpp channel order inversion
Apparently my understanding of Cogl pixel formats, or at least their
use, was somewhat shaky.

Un-invert the inversion of the DRM FourCC -> Cogl pixel format mapping
when creating dmabufs from clients, fixing inverted channel ordering
seen from GL clients, e.g. gold highlights in gtk4-demo when using the
GSK GL backend when they should be blue.

https://bugzilla.gnome.org/show_bug.cgi?id=786677
2017-08-24 15:11:37 +02:00
c248feb3c1 Update Italian translation 2017-08-24 07:45:30 +00:00
3f2c5ca9bd Update Slovak translation 2017-08-23 17:50:59 +00:00
520c56fe53 Update Croatian translation 2017-08-23 15:40:53 +00:00
d3a670b043 Update Galician translation 2017-08-23 10:22:13 +00:00
6eca267eee Update Polish translation 2017-08-23 04:16:46 +02:00
fdefe776d3 Updated Lithuanian translation 2017-08-22 23:18:07 +03:00
bba8776184 Updated Czech translation 2017-08-22 18:48:01 +02:00
e075242801 egl: Don't require eglGetPlatformDisplayEXT
Trying to unilaterally require eglGetPlatformDisplayEXT causes problems in
scenarios where this method is not available. Besides, this should only be
required on Wayland, so we can stop requiring it always and simply let the
eglGetPlatformDisplay() function error accordingly when needed.

https://bugzilla.gnome.org/show_bug.cgi?id=786619
2017-08-22 18:33:13 +02:00
0f9686fb5a Bump version to 3.25.91
Update NEWS.
2017-08-22 00:21:48 +02:00
168479862d meta-background-actor: Unset flags when they are not valid anymore
Currently, the flags that describe what is changed are never unsetted.
Unset each flag just after using them.

https://bugzilla.gnome.org/show_bug.cgi?id=783512
2017-08-21 22:18:28 +02:00
483ed98777 cogl: Only do the swizzling hack for GL contexts
The GL_BGRA definition is not available for GLES2 contexts, which use
the EXT_texture_format_BGRA8888 instead, causing a build failure when
trying to use it in those contexts.

Fortunately, this hack is only relevant for GL, so let's guard it to
prevent the failure in GLES2, where that extension is used instead.

https://bugzilla.gnome.org/show_bug.cgi?id=786568
2017-08-21 16:29:39 +02:00
14fe6e9c95 cursor-renderer-native: Don't use HW cursor on transformed logical monitor
The HW cursor plane can't do any transformations, and as we still don't
pre-transform any buffer before uploading to the cursor plane, we must
disable the HW cursor when a logical monitor is transformed.

This worked previously because the transform of a MetaCrtc did not
correspond to the transform of a CRTC, but the transform of the logical
monitor the CRTC was assigned to.

https://bugzilla.gnome.org/show_bug.cgi?id=786023
2017-08-21 21:20:19 +08:00
6584d06bb5 monitor-manager: Don't cancel confirm dialog on verifying
When another D-Bus call that just tries to verify a configuration is
made, don't cancel any active monitor configuration dialog, as doing so
would effectively confirm queried configuration.

https://bugzilla.gnome.org/show_bug.cgi?id=786023
2017-08-21 21:20:19 +08:00
92a53f08f4 keybindings: Only resolve keysyms for the current layout group
When resolving what keycodes a key binding resolves to, only look up
key codes from the current layout group. Without this, unwanted
overlaps may occur. For example when a keymap has both a dvorak and a
qwerty layout on different layout groups, one keybinding may be bound
on multiple keys, arbitrarily "shadowing" another.

https://bugzilla.gnome.org/show_bug.cgi?id=786408
2017-08-21 21:19:18 +08:00
a81d4aed7a backend/x11: Notify whenever the layout group changes
Will be used to trigger keyboard binding rebuild.

https://bugzilla.gnome.org/show_bug.cgi?id=786408
2017-08-21 21:19:18 +08:00
517488ef67 backends/native: Only emit layout group changed event when changed
Check that the layout group changed before emitting a changed event.
2017-08-21 21:19:18 +08:00
33f1706634 backend: Add API to get layout group
Add API to get the layout group (layout index) currently active. In the
native backend this is done by fetching the state directly from the
evdev backend; on X11 this works by listening for XkbStateNotify
events, caching the layout group value.

https://bugzilla.gnome.org/show_bug.cgi?id=786408
2017-08-21 21:19:18 +08:00
5685449e15 clutter/evdev: Add API to get current layout index
We set the layout index when changing keyboard layout, but have no way
to get it back would so be needed. Add that.

https://bugzilla.gnome.org/show_bug.cgi?id=786408
2017-08-21 21:19:18 +08:00
a6d67b164a x11: Open backend X11 connection ourself
Don't wait for clutter to initialize for connecting to X11; do it when
constructing the backend instance. This way we can later depend on
having an X11 connection earlier during initialization.

https://bugzilla.gnome.org/show_bug.cgi?id=786408
2017-08-21 21:19:18 +08:00
f950380202 monitor-manager-xrandr: Use G_DECLARE_FINAL_TYPE macro
Declare the MetaMonitorManagerXrandr type using the helper macro,
instead of manually.

https://bugzilla.gnome.org/show_bug.cgi?id=786408
2017-08-21 21:19:18 +08:00
a4270fa7ac Update Indonesian translation 2017-08-21 07:33:47 +00:00
35c9280fb6 monitor-manager: Try to restore previous config before regenerating
When opening a laptop lid, one will likely want to restore the
configuration one had prior to closing it, so when ensuring monitor
configuration, first try to see if the previously set configuration is
both complete (all connected monitors are configured) and applicable
(it is a valid configuration) and only try to generate a new from
scratch if that failed.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-08-21 12:23:51 +08:00
8b92ad1d4b tests/monitor-unit-tests: Clear config history before each test
To not let different tests interfere with each other, clear the config
history before each run.
2017-08-21 12:23:51 +08:00
0d6e3fd675 tests/monitor-unit-tests: Use special purpose add test helper
Will later be used to set a setup function.
2017-08-21 12:23:51 +08:00
b140e7fbeb monitor-config-manager: Keep short history of configurations
In order to go back in monitor configurations, save them to a history.
The history is implemented as a max 3 element long queue, where newly
set configurations are pushed to the head, and old are popped from the
tail.

The difference between using a single previous config reference and a
queue is that we can now remember the configuration used prior to a
D-Bus triggered configuration when the user discarded the configuration.

This will later be used to restore a previous configuration when a
laptop lid is opened.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-08-21 12:23:51 +08:00
6c0f107db0 tests: Add rotated multi head monitor config migration test
https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-08-21 12:23:51 +08:00
61950755ec tests: Add monitor config migration tests
So far some basic testing, including:

 * Test that the migrated configuration is applicable
 * Test that a monitors.xml with multiple configurations are translated
 * Test rotation
 * Test tiled monitor discovery (well, test a made up tiled monitor
   configuration since I don't have a real one)

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-08-21 12:23:51 +08:00
bc3162460f Migrate old monitor configuration files to new system
This commit changes the new configuration system to use monitors.xml
instead of monitors-experimental.xml. When starting up and the
monitors.xml file is loaded, if a legacy monitors.xml file is
discovered (it has the version number 1), an attempt is made to migrate
the stored configuration onto the new system.

This is done in two steps:

1) Parsing and translation of the old configuration. This works by
parsing file using the mostly the old parser, but then translating the
resulting configuration structs into the new configuration system. As
the legacy configuration system doesn't carry over some state (such as
tiling and scale used), some things are not available. For tiling, the
migration paths makes an attempt to discover tiled monitors by
comparing EDID data, and guessing what the main tile is. Determination
of the scale of a migrated configuration is postponed until the
configuration is actually applied. This works by flagging the
configuration as 'migrated'.

2) Finishing the migration when applying. When a configuration with the
'migrated' flag is retrieved from the configuration store, the final
step of the migration is taken place. This involves calculating the
preferred scale given the mode configured, while making sure this
doesn't result in any overlapping logical monitor regions etc.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-08-21 12:23:51 +08:00
27a4f9f862 monitor-manager/kms: Use connector id to find old output
The zero-initialized winsys id was incorrectly used as the key to find
the old output to base active/primary state from, which would never
succeed unless the winsys id happened to be 0. Fix this by using the
winsys id that will be used, i.e. the connector id.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-08-21 12:23:51 +08:00
88f2441330 monitor-manager: Fix output variable naming
Fix the last case of using the variable name "meta_output" for a
MetaOutput.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-08-21 12:23:51 +08:00
ab04286c6b monitor-manager/x11: Don't complain about 'normal' transform
The 'normal' transform has the value 0, so the g_warn_if_fail()
expression failed. Correct it so that it doesn't complain when no
transform is checked.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-08-21 12:23:51 +08:00
e8a62861c9 Remove old monitor configuration system
Remove the old MetaMonitorConfig system and mark the new one as
non-experimental. This also removes the D-Bus property.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-08-21 12:20:53 +08:00
9ac87b36c1 monitor-manager/xrandr: Fix name inconsistencies
MetaOutputs should be "output" and external types should be named as
such, i.e. XRandr outputs are renamed to "xrandr_output".

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-08-21 12:20:30 +08:00
ce7819949f Update Nepali translation 2017-08-20 09:01:04 +00:00
12792f99a0 Add tag-and-drag setting from libinput into mutter
The problem is that libinput offers the possibility to not enabled
dragging when tap-to-click is enabled but mutter doesn't. For people who
have a sensitive touchpad and who like tap-to-click option, dragging is
launched even when you don't want it : for example, when you select a
folder, most of the time the folder is dragging whereas just selected or
when you want to select some lines of a text file, several lines are
moved as a cut-paste which is not expected and erase datas.

To fix it, you need to have the possibility to desactivate the drag
option when you use tap-to-click in mutter. Because it's already a
specification of libinput, it remains to add it to mutter.
Implementation with X11 is added too.

https://bugzilla.gnome.org/show_bug.cgi?id=775755
2017-08-20 09:27:28 +08:00
66996dee4b wayland/inhibit-shortcuts-dialog: Destroy the dialog after response
We'll never actually show it again, but just use the last response, so
we can just destroy it now already.

https://bugzilla.gnome.org/show_bug.cgi?id=786385
2017-08-19 17:24:06 +08:00
2f45e88f06 wayland/inhibit-shortcuts-dialog: Just hide the dialog when hiding
The meta_wayland_surface_hide_inhibit_shortcuts_dialog() function
disconnected the "destroy" handler, but we'd still be listening on
response events. Change this to just hide the dialog, leaving the data
intact with the proper life time signal in place.

https://bugzilla.gnome.org/show_bug.cgi?id=786385
2017-08-19 17:24:06 +08:00
c1439e141e wayland/inhibit-shortcuts-dialog: Make the dialog ownership clearer
Make it clear that the data object is the owner of the dialog; it
creates it, and eventually destroys it.

https://bugzilla.gnome.org/show_bug.cgi?id=786385
2017-08-19 17:24:02 +08:00
dceb0f1f1f wayland/inhibit-shortcuts-dialog: Make data life cycle a bit clearer
The 'data' object is attached to the MetaWaylandSurface as a GObject
qdata. It is created once, and stays allocated until the surface is
destroyed. To make things clearer, connect to the "destroy" signal just
after creating, and from a on_surface_destroyed() callback call the
.._free() function.

https://bugzilla.gnome.org/show_bug.cgi?id=786385
2017-08-19 17:23:07 +08:00
a7915ff8ae wayland/inhibit-shortcuts-dialog: Only reuse last reply if there was one
We might have hidden the dialog, without a response. To avoid using the
not answered response, make sure we have actually got one before
reusing.

https://bugzilla.gnome.org/show_bug.cgi?id=786385
2017-08-19 17:11:21 +08:00
420a712ad5 meta-monitor: Make supported scales determination saner
Scales below 1 and scales that result in a too small logical monitor
size don't make sense. We also don't need so many intermediate scales.

https://bugzilla.gnome.org/show_bug.cgi?id=786474
2017-08-18 18:41:01 +02:00
9a47e5c832 wayland/buffer: Add missing breaks in switch statement
We'd process damage, and no matter whether it succeeded or not we'd
pretend it succeeded, meaning any potential GError would be leaked.

https://bugzilla.gnome.org/show_bug.cgi?id=786300
2017-08-16 13:33:17 +08:00
dbc63430d8 renderer-native: Destroy monitor framebuffers when suspending
When suspending (i.e. VT switching away, the GDM gnome-shell instance
gets hidden, or changing user), destroy the onscreen and offscreen
monitor framebuffers. When resuming, the stage views and framebuffers
will be recreated anyway.

https://bugzilla.gnome.org/show_bug.cgi?id=786299
2017-08-16 13:17:43 +08:00
0f861cecac Updated Serbian translation 2017-08-15 20:57:06 +02:00
586f9666d7 Updated French translation 2017-08-15 09:16:45 +02:00
05a2331052 Update Turkish translation 2017-08-13 15:55:41 +00:00
9f8bee7781 Update Turkish translation 2017-08-13 15:54:17 +00:00
d9505315da Update Turkish translation 2017-08-13 15:46:57 +00:00
c9937faf1e clutter: Fix build with --enable-debug
Message was poking stage_x11, which doesn't exist in this context.
Just print the Window that is receiving the event, the event will be
emitted into the only existing stage anyway.
2017-08-12 11:55:19 +02:00
98606bc046 data: fix gettext domain
https://bugzilla.gnome.org/show_bug.cgi?id=691611
2017-08-10 22:17:55 +03:00
49096f0530 Bump version to 3.25.90
Update NEWS.
2017-08-10 18:30:08 +02:00
ff6eb86bb4 Update Hungarian translation 2017-08-10 08:27:55 +00:00
c735eab216 Update Galician translation 2017-08-09 15:56:33 +00:00
299aa9759c Update Indonesian translation 2017-08-08 23:53:08 +00:00
35e9020f4c Updated Slovenian translation 2017-08-07 10:06:34 +02:00
6d4234e300 Updated Spanish translation 2017-08-05 12:03:45 +02:00
0457870ff1 Update Croatian translation 2017-08-03 19:58:02 +00:00
a52c4c2795 Update Croatian translation 2017-08-03 19:37:50 +00:00
bb8c388a37 Updated Czech translation 2017-08-03 09:42:45 +02:00
46cb506f8f wayland: use the inhibit shortcuts dialog
Plug the new MetaInhbitShortcutsDialog to the relevant Wayland protocol
implementation.

Also, remember the last user choice for a given surface to avoid asking
continuously the same question.

https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-08-02 11:58:55 +02:00
ce20c964a6 compositor: add vmethod to override inhibit shortcut dialog
A MetaPlugin implementation of the MetaInhibitShortcutsDialog can be
used in place of the default inhibit shortcut.

https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-08-02 11:58:55 +02:00
e3f76e9482 core: implement MetaInhibitShortcutsDialogDefault
this is the default implementation of the inhibit shortcuts dialog,
does nothing but allowing the shortcut inhibit request.

https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-08-02 11:58:55 +02:00
b894fbd9ff core: add MetaInhibitShortcutsDialog
Add a new interface for allowing or denying shortcuts inhibit requests.

https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-08-02 11:58:55 +02:00
2ca0871724 wayland: add keyboard shortcuts inhibitor protocol
https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-08-02 11:58:55 +02:00
dd12f569d9 wayland: add inhibit shortcut mechanism
Add a mechanism to MetaWaylandSurface that inhibits compositor's own
shortcuts when the surface has input focus, so that clients can receive
all key events regardless of the compositor own shortcuts.

This will help with implementing "fake" active grabs in Wayland and
XWayland clients.

https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-08-02 11:58:55 +02:00
c54377e3ba configure.ac: update wayland-server requirement
Raise wayland-server requirement to 1.13.0 to use the new API to control
wl_global visibility, so that we can hide Xwayland specific protocols
from other regular clients.

https://bugzilla.gnome.org/show_bug.cgi?id=783342
2017-08-02 11:58:55 +02:00
346acaf7f6 Updated Slovenian translation 2017-08-02 10:29:57 +02:00
3343a199c2 Update Catalan translation 2017-08-02 06:45:02 +02:00
1fb3c9f8bf configure.ac: Bump the API version
We added/changed various API for example the DisplayConfig D-Bus API,
so bump the API version.
2017-08-01 23:55:45 +08:00
b7b5fb293d wayland: Add zwp_linux_dmabuf_v1 support
https://bugzilla.gnome.org/show_bug.cgi?id=785262
Signed-off-by: Daniel Stone <daniels@collabora.com>
2017-08-01 19:05:50 +08:00
1455c402b9 monitor-manager: add API to get the display configuration timeout
Instead of hardcoding this into two different places, add an API so that
gnome-shell can fetch it.

https://bugzilla.gnome.org/show_bug.cgi?id=767805
2017-07-31 15:41:15 +01:00
4c1fe4c30d prefs: fix a couple of typos
It's "threshold", not "trheshold". Also, make sure to add the enum value
to the documentation section.

https://bugzilla.gnome.org/show_bug.cgi?id=767805
2017-07-31 15:21:06 +01:00
9b97a44760 Update Kazakh translation 2017-07-27 12:30:06 +00:00
26fa7b8f6a wayland: Reset tablet tool cursor surface on proximity out
The cursor surface would be remembered until the next proximity in
event, causing flashing of the old cursor till the client underneath
the tablet tool sent the zwp_tablet_tool.set_cursor request.

Forgetting about the cursor surface on proximity out makes the cursor
invisible till the request is made.
2017-07-26 15:41:28 +02:00
7486783692 Updated Spanish translation 2017-07-25 20:17:32 +02:00
9929efb65e Updated Lithuanian translation 2017-07-24 23:59:50 +03:00
5db48faca4 wayland: Update button state on motion/button events
More specifically, avoid crossing events, since clutter does not set
modifier/button state on those. Fixes implicit grabs being broken when
the pointer moves past the surface boundaries.

https://bugzilla.gnome.org/show_bug.cgi?id=785347
2017-07-24 17:57:31 +02:00
b0c54b6675 Update Indonesian translation 2017-07-23 02:46:38 +00:00
d8354cb153 Update Friulian translation 2017-07-22 20:54:15 +00:00
9a348aa859 wayland/buffer: Create EGLImage with no context
Since a wl_buffer is independent of the GL context in use (unlike, e.g.,
a GL renderbuffer), EGLImages with the EGL_WAYLAND_BUFFER_WL target must
pass EGL_NO_CONTEXT as the context. Quoting from the
EGL_WL_bind_wayland_display spec:

    After querying the wl_buffer layout, create EGLImages for the
    planes by calling eglCreateImageKHR with wl_buffer as
    EGLClientBuffer, EGL_WAYLAND_BUFFER_WL as the target, NULL
    context.

The check was already present inside _cogl_egl_create_image.

https://bugzilla.gnome.org/show_bug.cgi?id=785263
Signed-off-by: Daniel Stone <daniels@collabora.com>
2017-07-22 11:44:44 +02:00
fe6e24ddbd Bump version to 3.25.4
Update NEWS.
2017-07-19 20:19:11 +02:00
7e330bd65f keybindings: Add a switch-monitor builtin keybinding
Moved from g-s-d's media keys plugin, where it was called "video-out",
since it requires changing the current monitor configuration and we
want to remove the old DBus API.

This implementation is intentionally simple and not really meant for
more than debugging and validating the various configurations. A
better user experience will be introduced in gnome-shell with a custom
keybinding handler.

The default value includes <Super>P in addition to the standard keysym
for historical reasons.

https://bugzilla.gnome.org/show_bug.cgi?id=781906
2017-07-19 11:18:53 +02:00
3f9c5823cb backends: Add API to switch to predetermined monitor configurations
This will allows us to support the XF86Display key present on some
laptops, directly in mutter. This is also known, in evdev, as
KEY_SWITCHVIDEOMODE.

The common usage for this key is to alternate between a few well known
multi-monitor configurations though these aren't officially
standardized. As an example, Lenovo documents it as:

"Switches the display output location between the computer display
and an external monitor."

On this patch, we're just introducing the configurations that have been
implemented in g-s-d until now, which go a bit beyond the above
description.

https://bugzilla.gnome.org/show_bug.cgi?id=781906
2017-07-19 11:18:53 +02:00
2bdd97e067 monitor-unit-tests: Check tiled monitors with non-origin main output
Test that a tiled monitor with tile (0, 0) as the non-main output,
where main output is defined as the output that is active as long as
the monitor is active.

https://bugzilla.gnome.org/show_bug.cgi?id=781723
2017-07-19 17:06:17 +08:00
32fd1e8c08 monitor-manager: Let the MetaMonitor derive the whole layout
Instead of letting MetaMonitor derive the logical monitor size, then
using the main monitor for the position, just let MetaMonitor derive
the whole layout including the position. This means it can deal with
tiled monitors better, for example when the main output (the output
always active when the monitor is active) is not the origin output (the
output with tile position (0, 0)).

https://bugzilla.gnome.org/show_bug.cgi?id=781723
2017-07-19 17:06:17 +08:00
e126b6ed16 data: Enable monitor-config-manager by default
We'll need to drop the old monitor configuration system to pave way to
better hi-dpi and multi-gpu support. Let's start by defaulting to the
new system in order to give it more real world testing.
2017-07-18 22:32:59 +02:00
4d8cb5408b wayland: Provide basic tablet wheel event support
Adds basic support for the "wheel" event from the Wayland tablet protocol.
Ideally we would accumulate the angle and report a wheel event with an
appropriate value for "clicks". We can get away with a much cruder method
for the time being, however, since no Wacom tablet puck actually provides
a smooth scrollwheel. Checking whether the angle in CLUTTER_INPUT_AXIS_WHEEL
exceeds a nominally-small threshold is sufficient to determine that the
wheel has advanced by at least one physical click.

https://bugzilla.gnome.org/show_bug.cgi?id=783716
2017-07-17 21:22:15 +02:00
f852d2b0eb backends: Extend pad action label checks to rings/strips
This way the pad OSD can obtain the keycombos that are mapped to these
for labeling purposes.

https://bugzilla.gnome.org/show_bug.cgi?id=782033
2017-07-17 19:43:13 +02:00
5c3b27d02f clutter/x11: Emit CLUTTER_PAD_RING/STRIP events on X11
These events will be useful on gnome-shell UI, so translate the
4-5 button events with exotic axes to those. Also use the
XI_Motion event received when first touching those to reset
the ring/strip state, so we don't receive spurious direction
changes in the upper layers.

https://bugzilla.gnome.org/show_bug.cgi?id=782033
2017-07-17 19:43:13 +02:00
ead6556b50 clutter: Add clutter_event_get_pad_event_details()
This function extracts pad event information, and more importantly
exposes it for gobject introspection.

https://bugzilla.gnome.org/show_bug.cgi?id=782033
2017-07-17 19:10:05 +02:00
4afa66fe41 wayland/window: Update toplevel main monitor before non-toplevel
When updating the main monitor, make sure to update the toplevel main
monitor before trying to use that as the main monitor for non-toplevel
windows (such as popups). Without this, when the main monitor is
updated as a side effect to monitors being changed (for example due to
a hot plug event, or coming back from being suspended) the
main monitor pointer may, after 'monitors-changed' has completed, point to
freed memory resulting in undefined behaviour.

https://bugzilla.gnome.org/show_bug.cgi?id=784867
2017-07-17 09:59:34 +08:00
408292959e core: Add meta_close_dialog_focus() vmethod
This is used to request key focus on the close dialog whenever
a window that is frozen would receive key focus. Also, ensure
that the dialog gets focus when first shown if the window was
meant to receive input.

https://bugzilla.gnome.org/show_bug.cgi?id=762083
2017-07-16 19:21:41 +02:00
2d8d9dea97 core: Ensure we send SIGTERM only once to the zenity close dialog. 2017-07-16 19:21:41 +02:00
f38c90961a core: Forward events meant for non-alive windows to clutter
Otherwise the ClutterEventFilter will consider these handled, and not
forward these to Clutter. This gets necessary for key handling if we
mean to implement the close dialog with Clutter UI.

https://bugzilla.gnome.org/show_bug.cgi?id=762083
2017-07-16 19:21:41 +02:00
aa47374d0e core: Add meta_close_dialog_is_visible() property
Since the last show/hide call should be effective, implement
it without requiring an extra interface property.

https://bugzilla.gnome.org/show_bug.cgi?id=762083
2017-07-16 19:21:41 +02:00
5aee5048ba Remove the stamp file for enumeration types
The file was committed by accident.
2017-07-16 11:43:09 +01:00
0e3f80d238 build: Fix enum types rules
The list of files being parsed for enumerations include the header file
we are building with the enumeration types.

Additionally, we are concatenating multiple runs in the same temporary
files; on failure, the temporary files are left around, which means we
end up with broken headers and sources.
2017-07-16 11:43:09 +01:00
ef13ee4488 backends: Map tablet pad rings/strips to action settings
Just like we do for buttons, with a few twists. These have 2 directions
mappable to different keycombos, and are affected by the current mode
in their group.

https://bugzilla.gnome.org/show_bug.cgi?id=782033
2017-07-14 22:30:49 +02:00
8b5d34b24a monitor-manager: Shut up a compiler warning
Add a default switch statement to make it clear that 'transform'
won't be used uninitialized.
2017-07-14 16:56:43 +02:00
c614a2db28 keybindings: Add a rotate-monitor builtin keybinding
Moved from g-s-d's media keys plugin, where it was called
"video-rotate", since it requires changing the current monitor
configuration and we want to remove the old DBus API.

https://bugzilla.gnome.org/show_bug.cgi?id=781906
2017-07-14 15:31:20 +02:00
7360f51ee8 meta-monitor-manager: Add API to rotate the current configuration
This will allows us to support the XF86RotateWindows key present on
some laptops directly in mutter.

https://bugzilla.gnome.org/show_bug.cgi?id=781906
2017-07-14 15:31:20 +02:00
6ae42f3845 monitor-manager: Hook MetaOrientationManager to change the config
On orientation changes we'll apply the appropriate monitor transform
to the current configuration if possible.

https://bugzilla.gnome.org/show_bug.cgi?id=781906
2017-07-14 15:31:20 +02:00
26b66826dc meta-monitor-config: Add API to rotate the current config
This will allow us to do automatic rotation of the builtin display if
that's the only active monitor.

https://bugzilla.gnome.org/show_bug.cgi?id=781906
2017-07-14 15:31:20 +02:00
6d082bf442 monitor-config-manager: Add API to rotate the current config
This will allow us to do automatic rotation of the builtin display if
that's the only active monitor.

https://bugzilla.gnome.org/show_bug.cgi?id=781906
2017-07-14 15:31:20 +02:00
aad2280309 backends: Add a MetaOrientationManager class
This basically moves g-s-d's orientation plugin into mutter so that
eventually g-s-d doesn't need to build monitor configurations by
itself anymore.

https://bugzilla.gnome.org/show_bug.cgi?id=781906
2017-07-14 15:31:20 +02:00
e3d5bc077d stack-tracker: Keep override redirect windows on top
Since commit 6b5cf2e, we keep override redirect windows on a layer
above regular windows in the clutter actor scene graph. In the X
server, and thus for input purposes, these windows might end up being
stacked below regular windows though, e.g. because a new regular
window is mapped after an OR window.

Fix this disconnect by re-stacking OR windows on top when syncing the
window stack with the compositor.

https://bugzilla.gnome.org/show_bug.cgi?id=780485
2017-07-14 15:30:57 +02:00
777963eeb6 monitor-manager: Don't set current config if only verifying
When verifying if a configuration is applicable, don't set it as
current when applying succeeded, or else reverting to a previous
configuration doesn't work after having verified.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
4cc5b25493 tests: Add test for setting an interlaced monitor mode
https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
49c5228655 DisplayConfig: Add support for interlaced modes
Differentiate between non-interlaced and interlaced modes. This is done
by appending an "i" after the resolution part of the mode ID, and
adding a 'is-interlaced' (b) property to the mode properties.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
85638c1b19 tests: Check expected monitor mode count
https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
2507e53d04 tests: Test monitor mode refresh rate
Check that the monitor refresh rate corresponds to the CRTC mode
refresh rate.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
a9c1c6d9fb Fix a couple of wrong indentations
https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
0a8e108f10 DisplayConfig: Replace mode 'u' flags with 'a{sv}' property bag
To be more flexible without having to change any D-Bus type signatures
in the future, replace the 'uint' flags value (currently determining
whether a mode is current and/or preferred) with a variant lookup table.

The keys 'is-current' (b) and 'is-preferred' (b) replace the existing
flags.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
859b01fc39 DisplayConfig: Specify mode ID string instead of mode spec
To be able to add more modes types that happen to have the same
resolution and refresh rate, change the API to specify modes using an
ID string. The ID string is temporary, and only works for associating a
mode for the monitor instance that it was part of.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
e42206cc43 tests: Add non-precise fractional scaling test
https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
41eea5a942 monitor-config: Handle fractional scale precision loss
When calculating sizes given some size and a fractional logical monitor
scale with precision loss, round the result of the floating point
calculation to the closest integer, as otherwise we might end up with
result smaller by 1 if there was a loss of precision when calculating
the scale.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
197401fbf8 cursor-renderer: Track cursor position using floats
To be able to render the pointer cursor sprite at sub-(logical)-pixel
positions, track the pointer position using floats instead of ints.
This also requires users of the cursor sprite rect to deal with
floating points, when e.g. finding the logical monitor etc.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
9ab338d7b6 clutter/stage-cogl: Track regions in buffer coordinate space
When fractional scaling is used, damage and paint clip region is tracked
in stage coordinate space using integers might end up missing some
pixels when the border ends up on half pixels. Change the damage
tracking and clip regions to be in buffer coordinates so we can align
damage on physical pixel borders.

However, just using rounding up to the next physical pixel results in
glitches. To avoid this, extend the damage by one logical pixel in all
directions, but still (scissor) clip the drawing to the non-extended
region, as otherwise drawing the damaged regions will result in
incorrect pixels on the right and bottom edges of the clip region. It is
possible that there are better ways to do this, which can be explored in
the future.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:27 +08:00
aa5d8ac68c monitor-config-store: Don't discard scale < 1.0 configurations
It's not the task of the XML parser to decide this; let the code
listing allowed scales sort out configurations with invalid scales.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
0adc56779f clutter/stage: Don't loose precision when setting up viewport
We always hit non-fractional floats here because the stage views are
always made so that they are aligned on integer positions with integer
sizes, but there is no reason to go float -> int -> float when
calculating the viewport.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
67eb289a6a monitor-manager: Find the supported scales from one passed
When passing scales over D-Bus, we'll loose some precision. To set the
correct scale, use the configured scale and look up the one actually
supported by the monitor mode, and use that. To match the supported one
with the configured one, the difference must be within rounding error
range.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
dfc4d0d523 clutter/stage-view: Allow scales down to 0.5
There is support for scaling logical monitors down to 0.5, so don't let
ClutterStageView stand in the way for that.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
5f2bb43061 backend/native: Don't double-scale pointer motions on scaled monitors
We manually scaled pointer motions when they travel over a scaled
monitor. When a stage view of a monitor is also scaled, in practice this
meant we scaled twice. Avoid this by only manually scaling the pointer
motion when stage views are not scaled.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
fef81cd628 clutter/stage: Fix capturing scaled views
Make clutter_stage_capture() work if views are scaled. This needs
adaptations on the using side to deal with the cairo surface device
scale that is used to communicate the scale used when capturing.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
3e8d0204bd monitor: Dynamically calculate supported scales per resolution
When using logical sized monitors we are allowed to use fractional scaling
but only if the resulting scaled logical monitor size is in integer form.
So, in order to get this, we allow to scale the monitor to up to
8 fractional values per integer, doing some computation in order to
fetch the nearest values which are closer to the scaling factors we can
permit.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
b2a530b326 DisplayConfig: Make supported scales per mode
This changes the API to pass supported scales per mode instead of
providing a global list. This allows for more flexible scaling
scenarious, where a scale compatible with one mode can still be made
available even though another mode is incompatible.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
5ab116a87f tests: Add tests for fractional scaling
https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
10b0351a59 Add support for rudimentary fractional scaling
When the logical layout mode is used, allow configuring the scaling to
be non-integer. Supported scales are so far hard coded to include at
most 1, 1.5 and 2, and scales that doesn't result in non-fractional
logical monitor sizes are discarded.

Wayland outputs are set to have scale ceil(actual_scale) meaning well
behaving Wayland clients will provide buffers with buffer scale 2, thus
being scaled down to the fractional scale.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
b64c69e4bc logical-monitor: Make scale a float
To support fractional scaling, the logical monitor scale must be stored
as a float. No other functional changes is part of this commit.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
c2e49f1bb5 clutter: Change stage view scale to be float
To support fractional scaling, change the stage view scale to be a
float instead of an int. Also change the places where it is retrieved
and used when scaling things.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
a3d63d0ac0 clutter/stage-view: Add G_PARAM_CONSTRUCT flag to properties
Otherwise those properties won't be set when ->construct is called.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
88cae8bd3d settings: Manage our own font DPI
Previously gnome-shell listened on the Xft Xsettings via GTK+s
GtkSettings to get the font DPI setting. The Xsetting might not
be what we want, and we should not rely on Xsettings when we don't need
to, so lets manage it ourself.

https://bugzilla.gnome.org/show_bug.cgi?id=765011
2017-07-14 20:54:26 +08:00
a6ec2b1d42 backends: Set error when opening /sys file fails
The caller in clutter really expects an error if fd==-1, so make
sure we set one here. Otherwise we get a nice crash in addition to
the failure to open the /sys file. Also, retry on EINTR.

https://bugzilla.gnome.org/show_bug.cgi?id=784881
2017-07-14 12:28:32 +02:00
ca600973ba wayland: Store and retrieve implicit grab information for tablet tools
Window moving and resizing depends on the `meta_wayland_seat_get_grab_info`
function succeeding. At the moment, tablet tools do not generate implicit
grabs like the pointer and touch. This commit adds the necessary elements
to track implicit grabs and retrieve their information.

https://bugzilla.gnome.org/show_bug.cgi?id=777333
2017-07-13 19:10:52 +02:00
4b8dd51c4d backends: Fix dangling callback not being disconnected
This fixes possible crashes if configuration is changed on a device that
was added and then removed.

https://bugzilla.gnome.org/show_bug.cgi?id=784881
2017-07-13 19:05:44 +02:00
56c468a2ef clutter/x11: Set master device on pad button events
These should be set one, but just set the master to be the slave
pad device. We are passively grabbing the pad device, so this is
consistent with active grabs on slave devices. Besides, pads are
paired to the VCP, which is not really truthful.

Fixes inoffensive warnings when trying to check whether motion
throttling applies for these events.

https://bugzilla.gnome.org/show_bug.cgi?id=784881
2017-07-13 19:05:44 +02:00
10b30eaba5 backend: Set mapping-mode on X11 pen/eraser devices
And use it in the generic code for the checks about whether mapping to
an specific display applies or not.

https://bugzilla.gnome.org/show_bug.cgi?id=784402
2017-07-12 23:43:23 +02:00
328e3f8f4f clutter: Extend mapping-mode to pen/eraser devices
This just used to apply to CLUTTER_TABLET_DEVICE on wayland, allow using
it on pen/eraser devices (as X11 sees tablets) for consistency.

https://bugzilla.gnome.org/show_bug.cgi?id=784402
2017-07-12 23:43:23 +02:00
7bd69f0b32 window: Don't crash when moving across non-adjecent logical monitors
When moving a window between two non-adjecent logical monitors, don't
try to tile a window when the window position is outside of any logical
monitor.

https://bugzilla.gnome.org/show_bug.cgi?id=783630
2017-07-12 12:30:54 +08:00
538e402d71 wayland: Random whitespace fixes
https://bugzilla.gnome.org/show_bug.cgi?id=784080
2017-07-12 12:08:57 +08:00
9af6ec78ab wayland: Add support for wl_surface.damage_buffer
Implements support for the wl_surface.damage_buffer request, which
damages the buffer using buffer coordinate space.

https://bugzilla.gnome.org/show_bug.cgi?id=784080
2017-07-12 12:08:57 +08:00
41e22ab592 Use newer glib-genmarshal option
When building against a glib-genmarshal from GLib 2.54 we can use the
`--prototypes` command line argument to generate the prototypes for the
marshallers in the C source, and avoid a missing-prototypes compiler
warning.
2017-07-11 11:30:08 +01:00
1303c626b1 renderer-native: Fix compilation when EGLDevice renderer not enabled
When --enable-egl-device is not passed to ./configure, the
egl_device_error will not be declared; don't try to free it when its not
declared.
2017-07-07 17:59:20 +08:00
7eea82d3d7 MetaRendererNative: Give EGLDevice backend priority over GBM
With GLVND, whenever we have both Mesa's and NVIDIA's drives installed
in the system, initializing the GBM backend will always succeed,
regardless of what GPU you have on your system.

This is due to GBM's software rendering fallback.

It seems better to initialize the EGLDevice backend first, which will
fail to find a device match when given a non-NVIDIA GPU.

https://bugzilla.gnome.org/show_bug.cgi?id=784272
2017-07-07 11:55:18 +08:00
80e5955918 screen: Remove stray assert
When the number of (static) workspaces decreases, we relocate windows
from extra workspaces before removing them. As removing a non-empty
workspace is not allowed, we assert that it doesn't contain any windows
before removing it.

However that assert is

 - pointless, because meta_workspace_remove() already asserts that
   the workspace is empty

 - wrong, because even empty workspaces contain windows that are set
   to show on all workspaces

Simply drop the assert to avoid a crash when trying to remove a workspace
while on-all-workspaces windows are present.

https://bugzilla.gnome.org/show_bug.cgi?id=784223
2017-07-05 16:31:18 +02:00
ce989976fa backends: Apply tablet settings on all tablet device types during startup
This skipped the device types that are in use on X11.

https://bugzilla.gnome.org/show_bug.cgi?id=782027
2017-07-03 13:57:35 +02:00
529e5adb2e wayland: Base tablet tool coordinates on the current event
Instead of the last device position. This was copied a little bit too
straight from MetaWaylandPointer.

https://bugzilla.gnome.org/show_bug.cgi?id=783535
2017-07-03 13:56:21 +02:00
a70ae50ca9 clutter: Do not throttle motion events on tablet tools
Events from tablets must not be filtered out, as the event coalescing
results in precision loss.

https://bugzilla.gnome.org/show_bug.cgi?id=783535
2017-07-03 13:56:21 +02:00
74882b2502 backends/x11: Account for non-zero device origin when setting tablet area
Wacom's display tablets typically do not have (0,0) coincident with the top
left corner of the screen. This "outbound" area must be taken into account
when setting the area or else an unexpected offset of the pointer will
occur.

https://bugzilla.gnome.org/show_bug.cgi?id=784009
2017-07-03 13:49:14 +02:00
5f49bda591 window: Include window itself in transient loop check
While it doesn't make sense to set a window as transient to
itself, our existing check whether making a window transient
doesn't cover it, so it's still possible to create an infinite
loop.

https://bugzilla.gnome.org/show_bug.cgi?id=783502
2017-06-22 08:49:40 +02:00
edab8c3a4c Bump version to 3.25.3
Update NEWS.
2017-06-21 21:30:33 +02:00
8153c5b544 compositor: Handle EXIF orientation for backgrounds
Apply the embedded EXIF orientation when the background is loaded.

https://bugzilla.gnome.org/show_bug.cgi?id=783125
2017-06-21 20:23:09 +02:00
a4cef8586c backends/native: Interpret tablet padding as being input-centric
It is possible to interpret the ammount of padding provided to the
*_set_tablet_area functions in two different and incompatible ways. The X11
backend effectively treats them as being input-centric (i.e., the padding
defines the size of the "dead zone" on the tablet) while the native backend
has an output-centric viewpoint (i.e., the padding defines the size of the
"dead zone" on the display) viewpoint. This difference in opinion causes the
cursor offset to change when switching between Xorg and a Wayland sessions.

The calibration utility within g-c-c does its calculations with an input-
centric viewpoint, so this patch modifies the native backend to work
correctly with these values. To change viewpoints, we can simply invert
the scale and negate the offset. It should be noted that this function
also forgot to apply scaling to the offsets (as required by the matrix
transform done by libinput) which would have further compounded the
cursor offset issue under Wayland.

https://bugzilla.gnome.org/show_bug.cgi?id=784009
2017-06-20 23:42:38 +02:00
9b9bb9cf86 backends: Fix output cycling in non display-attached tablets
It would only allow to alternate between the logical monitors, we actually
want to return NULL here so it can cycle to the whole span of monitors.

https://bugzilla.gnome.org/show_bug.cgi?id=782032
2017-06-20 22:02:04 +02:00
dc5b2e396c backends: Fix typo
Instead of checking all MetaMonitors in the monitor manager, we want to
look (as the function name says) in the MetaMonitors contained in the
given logical monitor.

Otherwise, it will return TRUE for every logical monitor, given we are
querying for an existing EDID.

https://bugzilla.gnome.org/show_bug.cgi?id=782032
2017-06-20 22:02:04 +02:00
d23275bc76 backends/x11: Handle left-handed mode on pen/eraser devices correctly
Due to the pen/eraser device separation in X11, CLUTTER_TABLET_DEVICE does
not apply there, this device type is only used in native/evdev. Checking
for CLUTTER_PEN/ERASER_DEVICE makes the left-handed mode correctly applied
on tablets.

https://bugzilla.gnome.org/show_bug.cgi?id=782027
2017-06-20 22:02:04 +02:00
48e820235e backends/x11: Fix c&p issue in tablet area calculation
instead of filling in the last array value, it overwrote the previous one.

https://bugzilla.gnome.org/show_bug.cgi?id=781703
2017-06-20 22:02:04 +02:00
2d3c56b089 Updated Spanish translation 2017-06-19 17:37:23 +02:00
85b2e59e7e Update Arabic translation 2017-06-18 21:28:17 +02:00
e1950ed76f texture-tower: Fix usage of G_*_DECLS
https://bugzilla.gnome.org/show_bug.cgi?id=783505
2017-06-14 11:15:04 +02:00
7938f41c11 monitor: invert logic for 4k TV scaling
For devices connected via HDMI (supposedly TVs) we want have a
scale factor of 1 if we are *below* the smallest 4k resolution
width (not equal or above) and do the scaling factor computation
if we are above the limit. This check was apparently wrongly
ported from gnome-settings-daemon.

Based of a patch by Caolan McNamara <caolanm@redhat.com>.

https://bugzilla.gnome.org/show_bug.cgi?id=777347
2017-06-07 14:03:03 +02:00
9f41bdb086 Update Indonesian translation 2017-06-07 08:01:27 +00:00
8457e2bad6 wayland/pointer: Check for subsurfaces when grabbing
Previously, the function only returned `TRUE` if the given surface was
equal to the given pointer's focused surface. This changes the behaviour
to also return `TRUE` if any of the given surface's subsurfaces are
equal to the pointer's focused surface.

https://bugzilla.gnome.org/show_bug.cgi?id=781811.
2017-06-07 09:47:29 +08:00
4d7329a7e2 window: Include STATE_CHANGED flag when tiling
For size change animations, plugins rely on the size change effect being
followed by size changed signal (or effects being kill altogether).
However unless the move_resize operation included the STATE_CHANGED flag,
the size changed event emitted when the compositor syncs the window
geometry only happens when the operation resulted in an actual change.

To avoid animations getting stuck in that case, make sure to include the
flag when tiling a window.

https://bugzilla.gnome.org/show_bug.cgi?id=783293
2017-06-06 15:35:06 +02:00
b4120a75e0 wayland/pointer: Track lifetime of current surface
Clear the pointer->current when the surface is destroyed.

https://bugzilla.gnome.org/show_bug.cgi?id=783113
2017-06-01 12:46:32 +08:00
b19e4592df wayland/pointer: Use glib signals tracking focus surface
Use the "destroy" MetaWaylandSurface signal instead of the wl_resource
destroy signal for tracking the lifetime of the surface with pointer
focus.

As unsetting the focus may have side effects due to handlers of the
"focus-surface-changed" signal, connect the signal after the default
handler to make sure other clean up facilities have the chance deal with
the surface destruction before we try to unset the focus.

https://bugzilla.gnome.org/show_bug.cgi?id=783113
2017-06-01 12:46:32 +08:00
e9c9ee844c backends/x11: Ensure reply is initialised to NULL 2017-05-31 19:15:39 -04:00
f5f0ff0a2f monitor-manager: Fix crash when UPower is not available
Don't access the upower client if it doesn't exist

https://bugzilla.gnome.org/show_bug.cgi?id=780407
2017-05-31 16:11:24 +02:00
68dacb531b keybindings: handle multiple keycodes for keysym
A single keysym can resolve to multiple keycodes. Instead of only using
the first one and ignoring the others, we store all codes in
MetaResolvedKeyCombo and then handle all of them in keybinding
resolution. If we already have bound a keycode for a keybinding with a
specific keysym then this can get overwritten by a new keybinding with a
different keysym that resolves to the same keycode. Now that we resolve
and bind all keycodes for a keysym this might happen more often; in that
case warn but still overwrite, but only for the first keycode for each
keysym. If a secondary (i.e. all non-first keycodes) is already indexed
we just ignore that; this should resemble the old behavior  where we
only took the first keycode for any keysym as close as possible.

https://bugzilla.gnome.org/show_bug.cgi?id=781223
2017-05-30 15:23:00 +02:00
dd82f4afcd configure: require glib 2.53.2
This is required for the new glib-genmarshal as introduced in
 commit 9131f26cae

https://bugzilla.gnome.org/show_bug.cgi?id=783161
2017-05-28 11:21:42 +10:00
fc010e0edc Update Friulian translation 2017-05-27 20:55:46 +00:00
5132ea64be Use Unicode quotation marks in a translatable string
Also fixes a typo.

See https://developer.gnome.org/hig/stable/typography.html

https://bugzilla.gnome.org/show_bug.cgi?id=772218
2017-05-26 16:15:25 +02:00
82325cbcfd monitor: Don't get the monitor manager from the backend
We will both create and destroy monitors during initialization (when
using the X11 backend), so don't try to access the monitor manager from
the backend, but store a pointer to it instead.

It's stored in MetaMonitor even though only MetaMonitorTiled uses it,
mostly because it makes more sense to store such a pointer there.

https://bugzilla.gnome.org/show_bug.cgi?id=781723
2017-05-26 14:32:43 +08:00
fb5ebffb8d tests/monitor-unit-tests: Check handling of odd tiled monitors
Add tests for handling tiled monitors where the origin tile output is
not the main output.

https://bugzilla.gnome.org/show_bug.cgi?id=781723
2017-05-26 14:32:43 +08:00
94d843b80e tests/monitor-unit-tests: Check meta_monitor_is_active()
https://bugzilla.gnome.org/show_bug.cgi?id=781723
2017-05-26 14:32:43 +08:00
c32e2d17d9 monitor: Handle tiled monitors where (0, 0) is not the main output
In some circumstances, the origin tile (0, 0) is not the one that
should be used to drive the monitor when using a non-tiled mode. Update
MetaMonitorTiled to support this case. It also seems to be so that the
preferred mode might be some low resolution or bogus mode on these
monitors, so also adapt MetaMonitorTiled to manage to ignore the
preferred mode of a tiled monitor if the preferred mode doesn't use
both tiles.

https://bugzilla.gnome.org/show_bug.cgi?id=781723
2017-05-26 14:32:43 +08:00
2b05748d5c monitor: Move get_suggested() behind behind vfunc
Only support suggested monitor positioning if the monitor is non-tiled.
Normally this functionality is used by virtual machines to provide a
hint of how to place the virtual monitors, and they don't tend to use
tiled monitors anyway.

https://bugzilla.gnome.org/show_bug.cgi?id=781723
2017-05-26 14:32:43 +08:00
cd775929bf monitor: Move tiled CRTC mode identification into helper
It'll be used in more places later.

https://bugzilla.gnome.org/show_bug.cgi?id=781723
2017-05-26 14:32:43 +08:00
7303a78b06 monitor: Generate spec struct earlier
By generating the spec struct earlier, code executed later can use the
fields in the spec.

https://bugzilla.gnome.org/show_bug.cgi?id=781723
2017-05-26 14:32:43 +08:00
07b8cc0773 monitor: Fix naming of spec generation function
It was at one point referred to as 'id', but was changed to 'spec', but
the name of this function was not updated.

https://bugzilla.gnome.org/show_bug.cgi?id=781723
2017-05-26 14:32:43 +08:00
1bb0e18042 monitor-manager/xrandr: Allow configuring scales on X11 too
This commit makes it possible to configure logical monitor scale also
when running on top of an X11 server using Xrandr. An extra property
'requires-globla-scale' is added to the D-Bus API is added to instruct
a configuration application to only allow setting a global logical
monitor scale.

This is needed to let gsd-xsettings use the configured state to set a
XSettings state that respects the explicit monitor configuration.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-05-26 14:31:48 +08:00
05bc2e2331 gschema: Add description for "monitor-config-manager"
https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-05-26 14:31:48 +08:00
3b097c7e77 monitor-manager/kms: Move scale calculation to MetaMonitor
The scale calculation doesn't really have anything to do with KMS, and
eventually we'll want to have mutter calculate the monitor scale for
non-KMS backends too, so move the scale calculation to MetaMonitor.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-05-26 14:31:48 +08:00
0bc312a54b monitor-manager/kms: Move global ui scaling setting to MetaSettings
It'll be used elsewhere, so shouldn't be in MetaMonitorManagerKms.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-05-26 14:31:48 +08:00
2718699ccc backend: Move settings into a new MetaSettings object
Introduce MetaSettings and add the settings managed by MetaBackend into
the new object. These settings include: experimental-features and UI
scaling factor.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-05-26 14:31:48 +08:00
be175558c3 backend: Make X11 display opened function explicitly named
It didn't say anything about being the X11 display, so make it say so.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-05-26 14:31:48 +08:00
df39a7d0fd monitor-manager/xrandr: Use xcb API to configure CRTC
Use xcb-randr instead of libXrandr to set the CRTC configuration. This
is needed because data from the reply will later be used.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-05-26 14:31:48 +08:00
43cdf81f6b backend: Make the getter use the cached ui scale
The cached ui scale is kept up to date, so don't recalculate it
everytime meta_backend_get_ui_scaling() is called.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-05-26 14:31:48 +08:00
183f4b0c13 MetaMonitorManager: ignore hotplug_mode_update at startup
hotplug_mode_update is used (mostly by VMs nowadays, and
VMware has implemented it) to inform that modes list (including
the preferred one) might change after an uevent.

However, when using MetaMonitorConfigManager we should
ignore this value at initialization level, or mutter
won't restore the configured values at startup.

https://bugzilla.gnome.org/show_bug.cgi?id=783073
2017-05-25 16:50:29 +08:00
38a772bce7 Bump version to 3.25.2
Update NEWS.
2017-05-24 21:04:07 +02:00
dd451547a5 tests: Fix actor-anchors test
Since commit 5cb5baa7d4, we skip transitions when updating an
actor's scale/position to the existing value. As a result, we
don't get change notification on those properties either - given
that the properties did not actually change, that behavior seems
fine, so just modify the test to not expect a notify signal for
unchanged properties.
2017-05-24 21:04:07 +02:00
270da95cbc window: Notify about size-change when tiling
Call meta_compositor_size_change_window while tiling in order
to emit the size-change signal. Since the untiling action is
considered a unmaximize size change, treat tiling as a maximize
size change for consistency.

https://bugzilla.gnome.org/show_bug.cgi?id=782968
2017-05-24 09:51:29 +02:00
76198e0b3b Implements disable-while-typing in mutter.
Disable-while-typing disables the touchpad while the user is typing.

This patch introduces the necessary backend code to implement the
org.gnome.desktop.peripherals.touchpad.disable-while-typing setting of
gsettings-desktop-schemas which was implemented in commit
4c5b1c1df399d6afaaccb237e299ccd1d5d29ddd and released as part of 3.24.
This is known as dwt in libinput.

This patch has been tested on X11 and Wayland.

https://bugzilla.gnome.org/show_bug.cgi?id=764852
2017-05-24 11:56:54 +08:00
efc190789f backend: Couple of whitespace fixes
https://bugzilla.gnome.org/show_bug.cgi?id=782152
2017-05-24 11:18:56 +08:00
81e99c2680 input-settings: Minor structural cleanup
Let the backend implementations create their own input settings
backend, as is done with other backend specific special purpose
backends. Also use the macro for declaring the GType.

https://bugzilla.gnome.org/show_bug.cgi?id=782152
2017-05-24 11:18:56 +08:00
755755a2f3 backend: Move out some code from post_init()
meta_backend_real_post_init() had some open coded initialization with
some unexpected interdependencies. Split these up and move them to their
own functions in order to make meta_backend_real_post_init() a bit more
readable.

https://bugzilla.gnome.org/show_bug.cgi?id=782152
2017-05-24 11:17:46 +08:00
4b23eb064c clutter: Update pointer position on master clock's update stage
Ensure the pointer position is up-to-date for the pointers inside
the clip area after the stage got actors relayout.

https://bugzilla.gnome.org/show_bug.cgi?id=755164
2017-05-23 16:37:53 +02:00
498200776c wayland: Ensure we repick the pointer on synthesized crossing events
Relayouts in clutter may trigger synthesized crossing events if the
actor below the pointer changes. In that situation we do need to
repick() the MetaWaylandPointer to end up with the right current
wayland surface.

https://bugzilla.gnome.org/show_bug.cgi?id=755164
2017-05-22 17:45:17 +02:00
483 changed files with 69274 additions and 36029 deletions

19
.gitignore vendored
View File

@ -55,6 +55,7 @@ mutter-restart-helper
mutter-test-client
mutter-test-runner
mutter-test-unit-tests
mutter-test-headless-start-test
mutter-all.test
org.gnome.mutter.gschema.valid
org.gnome.mutter.gschema.xml
@ -71,6 +72,8 @@ src/stamp-meta-enum-types.h
src/meta-dbus-display-config.[ch]
src/meta-dbus-idle-monitor.[ch]
src/meta-dbus-login1.[ch]
src/meta-dbus-remote-desktop.[ch]
src/meta-dbus-screen-cast.[ch]
src/gtk-primary-selection-protocol.c
src/gtk-primary-selection-server-protocol.h
src/gtk-shell-protocol.c
@ -85,6 +88,21 @@ src/pointer-constraints-unstable-v*-protocol.c
src/pointer-constraints-unstable-v*-server-protocol.h
src/xdg-foreign-unstable-v*-protocol.c
src/xdg-foreign-unstable-v*-server-protocol.h
src/xdg-output-unstable-v1-protocol.c
src/xdg-output-unstable-v1-server-protocol.h
src/xwayland-keyboard-grab-unstable-v1-protocol.c
src/xwayland-keyboard-grab-unstable-v1-server-protocol.h
src/tablet-unstable-v*-protocol.c
src/tablet-unstable-v*-server-protocol.h
src/text-input-unstable-v*-protocol.c
src/text-input-unstable-v*-server-protocol.h
src/keyboard-shortcuts-inhibit-unstable-v*-protocol.c
src/keyboard-shortcuts-inhibit-unstable-v*-server-protocol.h
src/linux-dmabuf-unstable-v*-protocol.c
src/linux-dmabuf-unstable-v*-server-protocol.h
src/xdg-shell-protocol.c
src/xdg-shell-server-protocol.h
src/wayland-eglstream-controller-server-protocol.h
src/meta/meta-version.h
src/libmutter-*.pc
doc/reference/*.args
@ -112,3 +130,4 @@ ltsugar.m4
ltversion.m4
lt~obsolete.m4
.dirstamp
**/tags.*

378
NEWS
View File

@ -1,3 +1,381 @@
3.30.0
======
Translators:
Fran Dieguez [gl], Balázs Meskó [hu], Rūdolfs Mazurs [lv],
Trần Ngọc Quân [vi], Ask Hjorth Larsen [da], gogo [hr]
3.29.92
=======
* Avoid crash when a cursor is not found [Sebastian; #254]
* Fix screen rotation regression [Jonas; #216]
* Handle requests to unmanaged windows gracefully [Jonas; #240]
* Move popups together with their parent [Jonas; #274]
* Fix non-lowercase letters on virtual key devices [Carlos; gnome-shell#135]
* Misc. bug fixes [Iain, Jonas; #223, #192, #279]
Contributors:
Jonas Ådahl, Carlos Garnacho, Sebastian Keller, Iain Lane, Robert Mader,
Daniel van Vugt
Translators:
Gwan-gyeong Mun [ko], Kukuh Syafaat [id], Milo Casagrande [it],
Anders Jonsson [sv], Rafael Fontenelle [pt_BR], Marek Cernocky [cs]
3.29.91
=======
* Various crash fixes [Olivier, Iain; #255, #223]
* Fix lock up with some DRI drivers [Alex; #127]
* Send correct button codes from virtual evdev devices [Jonas; !190]
* Improve grab-device clock updates on X11 [Jeff; !174]
* Fix popups closing immediately on key down [Jonas; !180]
* Prevent clients from modifying the shared keymap [Jonas; #784206]
Contributors:
Jonas Ådahl, Andrea Azzarone, Piotr Drąg, Olivier Fourdan, Carlos Garnacho,
Jan Grulich, Iain Lane, Alex Villacís Lasso, Jeff Smith, Daniel van Vugt
Translators:
Matej Urbančič [sl], Mario Blättermann [de], Piotr Drąg [pl],
Aurimas Černius [lt], Yi-Jyun Pan [zh_TW], Emin Tufan Çetin [tr],
Fabio Tomat [fur], Bruce Cowan [en_GB]
3.29.90
=======
* Various crash fixes [Olivier, Jonas, Florian; #189, #70, #194, #15, #130]
* Don't expose resolutions that are below the minimum [Andrea; #793223]
* Remove support for preference overrides [Florian; #786496]
* Misc. bug fixes and cleanups [Daniel, Jonas, Florian; #131, #245, !176]
Contributors:
Jonas Ådahl, Andrea Azzarone, Olivier Fourdan, Florian Müllner, Kevin Tamool,
Daniel van Vugt
Translators:
Daniel Mustieles [es], Claude Paroz [fr]
3.29.4
======
* Fix crash with parent-less modal dialogs [Olivier; #174]
* Preserve paint volumes where possible to optimize CPU usage [Carlos; #782344]
Contributors:
Jonas Ådahl, Olivier Fourdan, Carlos Garnacho, Iain Lane, Bastien Nocera
Translators:
Daniel Șerbănescu [ro]
3.29.3
======
* Fix Korean Hangul support on wayland [Changwoo; #152]
* Improve support for proprietary Nvidia driver [Jonas; #790316]
* Only upload HW cursor sprite to the GPU that will display them [Jonas; #77]
* Improve EGLstream support [Miguel; #2, #782575]
* Remove MetaScreen to prepare for non-mandatary X11 dependency
[Armin, Jonas; #759538]
* Misc. bug fixes [Olivier, Jonas, Sam; #160, !130, #786929, #788834]
Contributors:
Jonas Ådahl, Olivier Fourdan, Carlos Garnacho, Armin Krezović, Corentin Noël,
Changwoo Ryu, Sam Spilsbury, Daniel Stone, Marco Trevisan (Treviño),
Miguel A. Vico, Daniel van Vugt
Translators:
Yi-Jyun Pan [zh_TW], Jordi Mas [ca], Daniel Șerbănescu [ro], Fabio Tomat [fur]
3.29.2
======
* Fix size change animations on wayland [Georges; #780292]
* Handle touch events on server-side titlebars [Carlos; #770185]
* Misc. bug fixes [Florian, Olivier, Jonas, Georges; #134, #124, !96, #138,
!102, #781471, #150]
Contributors:
Jonas Ådahl, Olivier Fourdan, Carlos Garnacho, Florian Müllner,
Georges Basile Stavracas Neto, Marco Trevisan (Treviño), Daniel van Vugt
Translators:
Daniel Șerbănescu [ro], Marcos Lans [gl], Dz Chen [zh_CN]
3.29.1
======
* Fix various input-method regressions [Carlos, Olivier; #65, #74, #66, #112]
* Fix wayland build on FreeBSD [Ting-Wei; #792280, #792717]
* Fix swapped colors in screenshots (again) [Carlos; #72]
* Allow building with elogind [Rasmus; !46]
* Consider display rotation for cursor [Olivier; #85]
* Fall back to non-modifier GBM surfaces [Daniel; #84]
* Take inhibitors into account for monitoring idle [Bastien; #705942]
* Misc. bug fixes [handsome-feng, Olivier, Mario, Jonas; !45, #83, #104,
gnome-shell#157, #130, #21]
Contributors:
Jonas Ådahl, Olivier Fourdan, Carlos Garnacho, handsome-feng, Yussuf Khalil,
Ting-Wei Lan, Aleksandr Mezin, Alberts Muktupāvels,
Georges Basile Stavracas Neto, Bastien Nocera, Benjamin Otte,
Mario Sanchez Prada, Daniel Stone, Ray Strode, Rasmus Thomsen,
Marco Trevisan (Treviño), Daniel van Vugt
Translators:
Emin Tufan Çetin [tr], Dušan Kazik [sk], Matej Urbančič [sl]
3.28.0
======
* Fix xdg-foreign regression [Carlos; #63]
Contributors:
Carlos Garnacho, Georges Basile Stavracas Neto
Translators:
Marek Cernocky [cs], Ask Hjorth Larsen [da], Chao-Hsiung Liao [zh_TW],
Anders Jonsson [sv], Mart Raudsepp [et]
3.27.92
=======
* Fix use of modifiers with multi-GPU systems [Louis-Francis; #18]
* Add xdg-shell stable support [Jonas; #791938]
* Fix scaling of icons in titlebar buttons [Egmont; #23]
* Implement missing wacom functionality on X11 [Carlos; #48]
* Force 8-bit RGB config [Jonas; #2]
* Misc. bug fixes [Jonas, Olivier, Robert; #6, #27, #792203]
Contributors:
Jonas Ådahl, Olivier Fourdan, Carlos Garnacho, Egmont Koblinger, Robert Mader,
Bastien Nocera, Louis-Francis Ratté-Boulianne
Translators:
Daniel Mustieles [es], Марко Костић [sr], Милош Поповић [sr@latin],
Fran Dieguez [gl], Balázs Úr [hu], Gwan-gyeong Mun [ko], Rūdolfs Mazurs [lv],
Milo Casagrande [it], Mario Blättermann [de], GNOME Translation Robot [gd,
nl], Claude Paroz [fr], Aurimas Černius [lt]
3.27.91
=======
* Fix handling of trackball settings on wayland [Carlos; #787804]
* Apply font settings on wayland [Daniel; #645433]
* Fix keybindings getting mixed up with some layouts [Jonas; #789300]
* Fix bluetooth mouse cursor disappearing after idle [Benoit; #761067]
* Support platforms that export EGL_KHR_platform_gbm [memeka; #780668]
* Add keyboard accessibility support on wayland [Olivier; #788564]
* Fix missing cursor when using screen magnifier [Carlos; #754806]
* Fix external monitor shutting off on wayland when lid closes [Jonas; #788915]
* Add xdg-output support [Olivier; #787363]
* Add Xwayland grab keyboard support [Olivier; #783342]
* Allow shortcut inhibition of the super key [Olivier; #790627]
* Take "panel orientation" drm_connector property into account [Hans; #782294]
* Fix focus window ending up below other windows on wayland [Olivier; #780820]
* Fix maximized windows restoring to a tiny size on wayland [Olivier; #783901]
* Fix tap-and-drag setting on X11 [Jonas; #775755]
* Fix handling of single-touch devices on wayland [Carlos; #792005]
* Support tiled/compressed buffers [Daniel; #785779]
* Port screencast support to pipewire 0.1.8 [Jonas; #792854]
* Add support for third stylus button on newer tablets [Jason; #790033]
* Fix background corruption regression on nvidia [Jonas; #739178]
* Misc. bug fixes [Jonas, Rui, Michael, Marco, Carlos, Olivier, Philip, Piotr,
Ting-Wei, Daniel, Jeremy, Hans, Florian, Ray, Jeff, George, Gwan-gyeong;
#789153, #788493, #784314, #789227, #789223, #789277, #782344, #789552,
#789553, #788695, #789984, #788764, #789386, #784545, #790336, #790358,
#791022, #791006, #789070, #772218, #791383, #791809, #776220, #791916,
#792281, #790309, #791371, #792527, #792599, #788834, #792765, #792062,
#645460, #792853, !2, #792818, #8, #12, #789501, #10, #789961, #13, !15, #1,
#26, #28, #35, #36, #38]
Contributors:
Jonas Ådahl, Jeremy Bicha, Michael Catanzaro, Piotr Drąg, Olivier Fourdan,
Carlos Garnacho, Jason Gerecke, Hans de Goede, Benoit Gschwind,
Peter Hutterer, George Kiagiadakis, Ting-Wei Lan, Rui Matos, memeka,
Florian Müllner, Gwan-gyeong Mun, Jeremy Nickurak, Marc-Antoine Perennou,
Jeff Smith, Daniel Stone, Ray Strode, Marco Trevisan (Treviño),
Daniel van Vugt, Philip Withnall
Translators:
Khaled Hosny [ar], Kjartan Maraas [nb], Piotr Drąg [pl],
Rafael Fontenelle [pt_BR], Christian Kirbach [de], Anders Jonsson [sv],
Charles Monzat [fr], Marek Cernocky [cs], Muhammet Kara [tr],
Milo Casagrande [it], Pawan Chitrakar [ne], Yosef Or Boczko [he],
Kukuh Syafaat [id], Daniel Mustieles [es], Fabio Tomat [fur],
Kristjan SCHMIDT [eo], Balázs Úr [hu], Andika Triwidada [id],
Fran Dieguez [gl], gogo [hr]
3.27.1
======
* Work with clients that require older linux_dmabuf protocol [Daniel; #788558]
* Support hybrid GPU systems [Jonas; #785381]
* Prevent crash when closing maximized windows [Jonni; #788666]
* Use the correct monitor for HiDPI scaling of shell chrome [Jonas; #788820]
* Fix unredirection of fullscreen windows [Rui, Jonas; #788493]
* Fix list of supported monitor scales on X11 [Jonas; #788901]
* Misc. bug fixes [Florian, Jonas, Marco; #788572, #788569, #788607, #788860,
#788921]
Contributors:
Jonas Ådahl, Carlos Garnacho, Rui Matos, Florian Müllner, Daniel Stone,
Marco Trevisan, Jonni Westphalen
Translations:
Xavi Ivars [ca@valencia]
3.26.1
======
* Fix crash when respawning shortcut inhibitor dialog [Olivier; #787568]
* Fix crash during monitor configuration migration [Carlos, Jonas; #787668]
* Fix multihead regressions in X11 session [Jonas; #787477]
* Fix screen rotation regressions [Hans; #787836]
* Fix keybindings not being resolved with non-latin layouts [Jonas; #787016]
* Support snap packages for sandboxed app IDs [Marco; #788217]
* Fix crash when reconnecting tablet device [Jason; #787649]
* Support running headless [Jonas; #730551, #787637]
* Support _NET_RESTACK_WINDOW and ConfigureRequest siblings [Vasilis; #786365]
* Fix monitor layout not being remembered across sessions [Jonas; #787629]
* Make sure to export _NET_NUMBER_OF_DESKTOPS [Florian; #760651]
* Allow resizing of tiled windows [Georges, Florian; #645153]
* Export tiling information to clients [Georges; #751857]
* Misc. bug fixes [Jonas, Florian, Jeremy, Rico; #787570, #787715, #787953,
#788049, #788199, #788292, #788197]
Contributors:
Jonas Ådahl, Andrea Azzarone, Georges Basile Stavracas Neto, Hans de Goede,
Olivier Fourdan, Carlos Garnacho, Jason Gerecke, Vasilis Liaskovitis,
Rui Matos, Florian Müllner, Jeremy Soller, Marco Trevisan, Rico Tzschichholz
Translations:
Matej Urbančič [sl], gogo [hr], Cheng-Chia Tseng [zh_TW]
3.26.0
======
Contributors:
Florian Müllner
Translations:
Trần Ngọc Quân [vi], Inaki Larranaga Murgoitio [eu], Jordi Mas [ca],
Anders Jonsson [sv], Alexander Shopov [bg], Ask Hjorth Larsen [da],
Jean-Baptiste Holcroft [fr], A S Alam [pa]
3.25.92
=======
* Add screencast and remote desktop support [Jonas; #784199]
* Support running with no attached monitors [Jonas; #730551]
* Add a vertical gradient effect to background actor [Alessandro; #786618]
* Misc. bug fixes [Mario, Daniel, Piotr, Jonas, Bastien; #786619, #786677,
#772218, #786918, #760670]
Contributors:
Jonas Ådahl, Alessandro Bono, Piotr Drąg, Bastien Nocera,
Mario Sanchez Prada, Daniel Stone
Translations:
Marek Cernocky [cs], Aurimas Černius [lt], Piotr Drąg [pl],
Fran Dieguez [gl], gogo [hr], Dušan Kazik [sk], Milo Casagrande [it],
Jordi Mas [ca], Cheng-Chia Tseng [zh_TW], Марко Костић [sr],
Милош Поповић [sr@latin], Rūdolfs Mazurs [lv], Matej Urbančič [sl],
Ask Hjorth Larsen [da], Piotr Drąg [it, lt], Jiri Grönroos [fi],
Emin Tufan Çetin [tr], Wolfgang Stöggl [de], Kukuh Syafaat [id],
Yuras Shumovich [be], Changwoo Ryu [ko], Alexander Shopov [bg],
Rafael Fontenelle [pt_BR], Balázs Úr [hu]
3.25.91
=======
* Reduce memory use of suspended instances [Jonas; #786299]
* Make supported scales determination saner [Rui; #786474]
* Fix crash on inhibit-shortcuts dialog reponse [Jonas; #786385]
* Support libinput's tag-and-drag setting [freeroot; #775755]
* Avoid overlapping keybindings with multiple layouts [Jonas; #786408]
* Fix non-transformed cursor on rotated monitors [Jonas; #786023]
* Avoid unnecessary work during background painting [Alessandro; #783512]
* Misc. bug fixes [Alberts, Jonas, Mario; #691611, #786300, #777732, #786568]
Contributors:
freeroot, Jonas Ådahl, Alessandro Bono, Carlos Garnacho, Rui Matos,
Alberts Muktupāvels, Mario Sanchez Prada
Translations:
Muhammet Kara [tr], Claude Paroz [fr], Мирослав Николић [sr, sr@latin],
Pawan Chitrakar [ne], Kukuh Syafaat [id]
3.25.90
=======
* Add zwp_linux_dmabuf_v1 support [Daniel; #785262]
* Add (x)wayland shortcut inhibitor support [Olivier; #783342]
* Misc. bug fixes [Daniel, Carlos, Cosimo; #785263, #785347, #767805]
Contributors:
Jonas Ådahl, Cosimo Cecchi, Olivier Fourdan, Carlos Garnacho, Daniel Stone
Translations:
Fabio Tomat [fur], Kukuh Syafaat [id], Aurimas Černius [lt],
Daniel Mustieles [es], Baurzhan Muftakhidinov [kk], Jordi Mas [ca],
Matej Urbančič [sl], Marek Cernocky [cs], gogo [hr], Fran Dieguez [gl],
Balázs Meskó [hu]
3.25.4
======
* Do not throttle motion events on tablet tools [Carlos; #783535]
* Handle left-handed mode on pen/eraser devices [Carlos; #782027]
* Add wl_surface.damage_buffer() support [Jonas; #784080]
* Fix crash when moving across on-adjacent monitors [Jonas; #783630]
* Fix window moving/resizing via tablet tools [Jason; #777333]
* Support fractional monitor scaling [Jonas, Marco; #765011]
* Keep override-redirect windows stacked on top [Rui; #780485]
* Implement tablet rings/strips configuration [Carlos; #782033]
* Support tablet wheel events on wayland [Jason; #783716]
* Move g-s-d xrandr functionality into mutter [Rui; #781906]
* Misc. bug fixes [Florian, Jason, Miguel, Carlos, Jonas; #783502, #784009,
#784223, #784272, #784402, #784881, #762083, #784867, #781723]
Contributors:
Jonas Ådahl, Miguel A. Vico, Emmanuele Bassi, Carlos Garnacho, Jason Gerecke,
Rui Matos, Florian Müllner, Marco Trevisan (Treviño)
3.25.3
======
* Ignore hotplug-mode-update value on startup [Marco; #783073]
* Implement configurable monitor scales on X11 [Jonas; #777732]
* Fix handling of tiled monitors [Jonas; #781723]
* Handle multiple keycodes for keysym [Christian; #781223]
* Consider subsurfaces when grabbing [mindtree; #781811]
* Fix logic for HiPDPI scaling of TV outputs [Christian; #777347]
* Fix handling of left-handed mode on pen/eraser devices [Carlos; #782027]
* Fix output cycling in non-display-attached tablets [Carlos; #782032]
* Fix wacom cursor offset on wayland [Jason; #784009]
* Handle EXIF orientation of backgrounds [Silvère; #783125]
* Misc. bug fixes [Piotr, Tim, Bastien, Jonas, Florian, Benoit, Carlos; #772218,
#783161, #780407, #783113, #783293, #783505, #781703]
Contributors:
mitchmindtree, Jonas Ådahl, Ikey Doherty, Piotr Drąg, Carlos Garnacho,
Jason Gerecke, Benoit Gschwind, Christian Kellner, Silvère Latchurié,
Tim Lunn, Florian Müllner, Bastien Nocera, Marco Trevisan (Treviño)
Translations:
Fabio Tomat [fur], Kukuh Syafaat [id], Khaled Hosny [ar],
Daniel Mustieles [es]
3.25.2
======
* Fix frame updates on hide-titlebar-when-maximized changes [Florian; #781862]
* Fix accessible screen coordinates on X11 [Florian; #781902]
* Use less CPU when rendering fast-updating windows [Carlos, Emmanuele; #782344]
* Compute geometry of clients that don't set one explicitly [Olivier; #782213]
* Fix copy+paste of UTF8 strings between X11 and wayland [Carlos; #782472]
* Fix non-wayland builds [Chris; #780533]
* Add plugin vfunc to implement a custom force-quit dialog [Carlos; #711619]
* Fix swapped red and blue channels in CoglTexture data [Carlos; #779234
* Fix build where libtool's link_all_deplibs defaults to 'no' [Marco; #782821]
* Fix glitches when opening a window maximized [Olivier; #781353, #782183]
* Fix wrong cursor after window underneath the pointer changed [Carlos; #755164]
* Implement support for disable-while-typing option [Evan; #764852]
* Emit size-change signal when tiling [Alessandro; #782968]
* Misc. bug fixes [Nigel, Matthias, Jonas; #759085, #780215, #782156, #782152]
Contributors:
Jonas Ådahl, Emmanuele Bassi, Alessandro Bono, Olivier Fourdan,
Carlos Garnacho, Matthias Liertzer, Florian Müllner, Nigel Taylor,
Marco Trevisan (Treviño), Chris Vine, Evan Welsh
Translations:
Fabio Tomat [fur], Jordi Mas [ca], Mario Blättermann [de],
Emin Tufan Çetin [tr], Balázs Úr [hu]
3.25.1
======
* Always sync window geometry on state changes [Jonas; #780292]

30
README.md Normal file
View File

@ -0,0 +1,30 @@
# Mutter
Mutter is a Wayland display server and X11 window manager and compositor library.
When used as a Wayland display server, it runs on top of KMS and libinput. It
implements the compositor side of the Wayland core protocol as well as various
protocol extensions. It also has functionality related to running X11
applications using Xwayland.
When used on top of Xorg it acts as a X11 window manager and compositing manager.
It contains functionality related to, among other things, window management,
window compositing, focus tracking, workspace management, keybindings and
monitor configuration.
Internally it uses a fork of Cogl, a hardware acceleration abstraction library
used to simplify usage of OpenGL pipelines, as well as a fork af Clutter, a
scene graph and user interface toolkit.
Mutter is used by GNOME Shell, the GNOME core user interface. It can also be run
standalone, using the command "mutter", but just running plain mutter is only
intended for debugging purposes.
## License
Mutter is distributed under the terms of the GNU General Public License,
version 2 or later. See the [COPYING][license] file for detalis.
[bug-tracker]: https://gitlab.gnome.org/GNOME/mutter/issues
[license]: COPYING

View File

@ -87,6 +87,8 @@ source_h = \
clutter-image.h \
clutter-input-device.h \
clutter-input-device-tool.h \
clutter-input-focus.h \
clutter-input-method.h \
clutter-interval.h \
clutter-keyframe-transition.h \
clutter-keysyms.h \
@ -169,6 +171,8 @@ source_c = \
clutter-image.c \
clutter-input-device.c \
clutter-input-device-tool.c \
clutter-input-focus.c \
clutter-input-method.c \
clutter-virtual-input-device.c \
clutter-interval.c \
clutter-keyframe-transition.c \
@ -229,6 +233,8 @@ source_h_priv = \
clutter-flatten-effect.h \
clutter-gesture-action-private.h \
clutter-id-pool.h \
clutter-input-focus-private.h \
clutter-input-method-private.h \
clutter-master-clock.h \
clutter-master-clock-default.h \
clutter-offscreen-effect-private.h \
@ -388,6 +394,7 @@ x11_source_c = \
x11/clutter-keymap-x11.c \
x11/clutter-stage-x11.c \
x11/clutter-x11-texture-pixmap.c \
x11/clutter-xkb-a11y-x11.c \
$(NULL)
x11_source_h = \
@ -402,6 +409,7 @@ x11_source_h_priv = \
x11/clutter-keymap-x11.h \
x11/clutter-settings-x11.h \
x11/clutter-stage-x11.h \
x11/clutter-xkb-a11y-x11.h \
$(NULL)
x11_source_c_priv = \
@ -684,7 +692,7 @@ Cally_@LIBMUTTER_API_VERSION@_gir_CFLAGS = $(AM_CPPFLAGS) $(CLUTTER_CFLAGS)
Cally_@LIBMUTTER_API_VERSION@_gir_SCANNERFLAGS = \
--warn-all \
--c-include='cally/cally.h' \
--pkg-export=mutter-cally-@LIBMUTTER_API_VERSION@ \
--pkg-export=mutter-clutter-@LIBMUTTER_API_VERSION@ \
--include-uninstalled=$(top_builddir)/clutter/Clutter-@LIBMUTTER_API_VERSION@.gir
INTROSPECTION_GIRS += Cally-@LIBMUTTER_API_VERSION@.gir

View File

@ -34,6 +34,7 @@ stamp-marshal: $(marshal_list)
$(AM_V_GEN)$(GLIB_GENMARSHAL) \
--prefix=$(glib_marshal_prefix) \
--header \
--valist-marshallers \
$(marshal_list) > xgen-mh \
&& (cmp -s xgen-mh $(marshal_h) || cp -f xgen-mh $(marshal_h)) \
&& rm -f xgen-mh \
@ -46,6 +47,8 @@ $(marshal_c): $(marshal_h)
$(AM_V_GEN)$(GLIB_GENMARSHAL) \
--prefix=$(glib_marshal_prefix) \
--body \
--valist-marshallers \
--prototypes \
$(marshal_list) > xgen-mc \
&& (cmp -s xgen-mc $(marshal_c) || cp -f xgen-mc $(marshal_c)) \
&& rm -f xgen-mc

View File

@ -214,6 +214,8 @@ cally_util_simulate_snooper_install (void)
G_CALLBACK (cally_util_stage_added_cb), cally_key_snooper);
g_signal_connect (G_OBJECT (stage_manager), "stage-removed",
G_CALLBACK (cally_util_stage_removed_cb), cally_key_snooper);
g_slist_free (stage_list);
}
static void

View File

@ -840,6 +840,7 @@ struct _ClutterActorPrivate
guint needs_compute_expand : 1;
guint needs_x_expand : 1;
guint needs_y_expand : 1;
guint needs_paint_volume_update : 1;
};
enum
@ -1092,6 +1093,11 @@ static void clutter_actor_set_child_transform_internal (ClutterActor *sel
static void clutter_actor_realize_internal (ClutterActor *self);
static void clutter_actor_unrealize_internal (ClutterActor *self);
static void clutter_actor_push_in_cloned_branch (ClutterActor *self,
gulong count);
static void clutter_actor_pop_in_cloned_branch (ClutterActor *self,
gulong count);
/* Helper macro which translates by the anchor coord, applies the
given transformation and then translates back */
#define TRANSFORM_ABOUT_ANCHOR_COORD(a,m,c,_transform) G_STMT_START { \
@ -1504,6 +1510,8 @@ clutter_actor_real_map (ClutterActor *self)
CLUTTER_ACTOR_SET_FLAGS (self, CLUTTER_ACTOR_MAPPED);
self->priv->needs_paint_volume_update = TRUE;
stage = _clutter_actor_get_stage_internal (self);
priv->pick_id = _clutter_stage_acquire_pick_id (CLUTTER_STAGE (stage), self);
@ -2737,6 +2745,7 @@ clutter_actor_real_queue_relayout (ClutterActor *self)
priv->needs_width_request = TRUE;
priv->needs_height_request = TRUE;
priv->needs_allocation = TRUE;
priv->needs_paint_volume_update = TRUE;
/* reset the cached size requests */
memset (priv->width_requests, 0,
@ -2821,7 +2830,7 @@ _clutter_actor_fully_transform_vertices (ClutterActor *self,
/* Note: we pass NULL as the ancestor because we don't just want the modelview
* that gets us to stage coordinates, we want to go all the way to eye
* coordinates */
_clutter_actor_apply_relative_transformation_matrix (self, NULL, &modelview);
_clutter_actor_get_relative_transformation_matrix (self, NULL, &modelview);
/* Fetch the projection and viewport */
_clutter_stage_get_projection_matrix (CLUTTER_STAGE (stage), &projection);
@ -4285,6 +4294,9 @@ clutter_actor_remove_child_internal (ClutterActor *self,
self->priv->age += 1;
if (self->priv->in_cloned_branch)
clutter_actor_pop_in_cloned_branch (child, self->priv->in_cloned_branch);
/* if the child that got removed was visible and set to
* expand then we want to reset the parent's state in
* case the child was the only thing that was making it
@ -4828,8 +4840,7 @@ clutter_actor_set_scale_factor (ClutterActor *self,
g_assert (pspec != NULL);
g_assert (scale_p != NULL);
if (*scale_p != factor)
_clutter_actor_create_transition (self, pspec, *scale_p, factor);
_clutter_actor_create_transition (self, pspec, *scale_p, factor);
}
static inline void
@ -8519,6 +8530,7 @@ clutter_actor_init (ClutterActor *self)
priv->needs_width_request = TRUE;
priv->needs_height_request = TRUE;
priv->needs_allocation = TRUE;
priv->needs_paint_volume_update = TRUE;
priv->cached_width_age = 1;
priv->cached_height_age = 1;
@ -10085,6 +10097,9 @@ clutter_actor_allocate (ClutterActor *self,
return;
}
if (CLUTTER_ACTOR_IS_MAPPED (self))
self->priv->needs_paint_volume_update = TRUE;
if (!stage_allocation_changed)
{
/* If the actor didn't move but needs_allocation is set, we just
@ -10264,10 +10279,9 @@ clutter_actor_set_position (ClutterActor *self,
cur_position.x = clutter_actor_get_x (self);
cur_position.y = clutter_actor_get_y (self);
if (!clutter_point_equals (&cur_position, &new_position))
_clutter_actor_create_transition (self, obj_props[PROP_POSITION],
&cur_position,
&new_position);
_clutter_actor_create_transition (self, obj_props[PROP_POSITION],
&cur_position,
&new_position);
}
/**
@ -12904,6 +12918,9 @@ clutter_actor_add_child_internal (ClutterActor *self,
self->priv->age += 1;
if (self->priv->in_cloned_branch)
clutter_actor_push_in_cloned_branch (child, self->priv->in_cloned_branch);
/* if push_internal() has been called then we automatically set
* the flag on the actor
*/
@ -12974,6 +12991,9 @@ clutter_actor_add_child_internal (ClutterActor *self,
child->priv->needs_height_request = TRUE;
child->priv->needs_allocation = TRUE;
if (CLUTTER_ACTOR_IS_MAPPED (child))
child->priv->needs_paint_volume_update = TRUE;
/* we only queue a relayout here, because any possible
* redraw has already been queued either by show() or
* by our call to queue_redraw() above
@ -17516,11 +17536,16 @@ _clutter_actor_get_paint_volume_mutable (ClutterActor *self)
priv = self->priv;
if (priv->paint_volume_valid)
clutter_paint_volume_free (&priv->paint_volume);
{
if (!priv->needs_paint_volume_update)
return &priv->paint_volume;
clutter_paint_volume_free (&priv->paint_volume);
}
if (_clutter_actor_get_paint_volume_real (self, &priv->paint_volume))
{
priv->paint_volume_valid = TRUE;
priv->needs_paint_volume_update = FALSE;
return &priv->paint_volume;
}
else
@ -20690,29 +20715,31 @@ clutter_actor_get_child_transform (ClutterActor *self,
}
static void
clutter_actor_push_in_cloned_branch (ClutterActor *self)
clutter_actor_push_in_cloned_branch (ClutterActor *self,
gulong count)
{
ClutterActor *iter;
for (iter = self->priv->first_child;
iter != NULL;
iter = iter->priv->next_sibling)
clutter_actor_push_in_cloned_branch (iter);
clutter_actor_push_in_cloned_branch (iter, count);
self->priv->in_cloned_branch += 1;
self->priv->in_cloned_branch += count;
}
static void
clutter_actor_pop_in_cloned_branch (ClutterActor *self)
clutter_actor_pop_in_cloned_branch (ClutterActor *self,
gulong count)
{
ClutterActor *iter;
self->priv->in_cloned_branch -= 1;
self->priv->in_cloned_branch -= count;
for (iter = self->priv->first_child;
iter != NULL;
iter = iter->priv->next_sibling)
clutter_actor_pop_in_cloned_branch (iter);
clutter_actor_pop_in_cloned_branch (iter, count);
}
void
@ -20728,7 +20755,7 @@ _clutter_actor_attach_clone (ClutterActor *actor,
g_hash_table_add (priv->clones, clone);
clutter_actor_push_in_cloned_branch (actor);
clutter_actor_push_in_cloned_branch (actor, 1);
}
void
@ -20743,7 +20770,7 @@ _clutter_actor_detach_clone (ClutterActor *actor,
g_hash_table_lookup (priv->clones, clone) == NULL)
return;
clutter_actor_pop_in_cloned_branch (actor);
clutter_actor_pop_in_cloned_branch (actor, 1);
g_hash_table_remove (priv->clones, clone);

View File

@ -58,6 +58,8 @@ struct _ClutterBackend
gint32 units_serial;
GList *event_translators;
ClutterInputMethod *input_method;
};
struct _ClutterBackendClass
@ -100,6 +102,8 @@ struct _ClutterBackendClass
PangoDirection (* get_keymap_direction) (ClutterBackend *backend);
void (* bell_notify) (ClutterBackend *backend);
/* signals */
void (* resolution_changed) (ClutterBackend *backend);
void (* font_changed) (ClutterBackend *backend);

View File

@ -127,6 +127,7 @@ clutter_backend_finalize (GObject *gobject)
g_free (backend->font_name);
clutter_backend_set_font_options (backend, NULL);
g_clear_object (&backend->input_method);
G_OBJECT_CLASS (clutter_backend_parent_class)->finalize (gobject);
}
@ -1363,3 +1364,41 @@ clutter_set_allowed_drivers (const char *drivers)
allowed_drivers = g_strdup (drivers);
}
void
clutter_backend_bell_notify (ClutterBackend *backend)
{
ClutterBackendClass *klass;
klass = CLUTTER_BACKEND_GET_CLASS (backend);
if (klass->bell_notify)
klass->bell_notify (backend);
}
/**
* clutter_backend_get_input_method:
* @backend: the #CLutterBackend
*
* Returns the input method used by Clutter
*
* Returns: (transfer none): the input method
**/
ClutterInputMethod *
clutter_backend_get_input_method (ClutterBackend *backend)
{
return backend->input_method;
}
/**
* clutter_backend_set_input_method:
* @backend: the #ClutterBackend
* @method: the input method
*
* Sets the input method to be used by Clutter
**/
void
clutter_backend_set_input_method (ClutterBackend *backend,
ClutterInputMethod *method)
{
g_set_object (&backend->input_method, method);
}

View File

@ -74,6 +74,15 @@ const cairo_font_options_t * clutter_backend_get_font_options (Clutter
CLUTTER_AVAILABLE_IN_1_8
CoglContext * clutter_backend_get_cogl_context (ClutterBackend *backend);
CLUTTER_AVAILABLE_IN_ALL
void clutter_backend_bell_notify (ClutterBackend *backend);
CLUTTER_AVAILABLE_IN_MUTTER
ClutterInputMethod * clutter_backend_get_input_method (ClutterBackend *backend);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_backend_set_input_method (ClutterBackend *backend,
ClutterInputMethod *method);
G_END_DECLS
#endif /* __CLUTTER_BACKEND_H__ */

View File

@ -324,7 +324,7 @@ _clutter_bezier_init (ClutterBezier *b,
* triggers, we need to change those two functions a bit.
*/
if (b->ax > 0x1fff || b->bx > 0x1fff || b->cx > 0x1fff)
g_warning ("Calculated coefficents will result in multiplication "
g_warning ("Calculated coefficients will result in multiplication "
"overflow in clutter_bezier_t2x and clutter_bezier_t2y.");
/*

View File

@ -145,6 +145,9 @@ struct _ClutterInputDevice
guint is_enabled : 1;
};
typedef void (*ClutterEmitInputDeviceEvent) (ClutterEvent *event,
ClutterInputDevice *device);
struct _ClutterInputDeviceClass
{
GObjectClass parent_class;
@ -163,6 +166,11 @@ struct _ClutterInputDeviceClass
gboolean (* is_grouped) (ClutterInputDevice *device,
ClutterInputDevice *other_device);
/* Keyboard accessbility */
void (* process_kbd_a11y_event) (ClutterEvent *event,
ClutterInputDevice *device,
ClutterEmitInputDeviceEvent emit_event_func);
};
/* Platform-dependent interface */

View File

@ -54,6 +54,9 @@ struct _ClutterDeviceManagerPrivate
{
/* back-pointer to the backend */
ClutterBackend *backend;
/* Keyboard a11y */
ClutterKbdA11ySettings kbd_a11y_settings;
};
enum
@ -72,6 +75,8 @@ enum
DEVICE_ADDED,
DEVICE_REMOVED,
TOOL_CHANGED,
KBD_A11Y_MASK_CHANGED,
KBD_A11Y_FLAGS_CHANGED,
LAST_SIGNAL
};
@ -196,6 +201,46 @@ clutter_device_manager_class_init (ClutterDeviceManagerClass *klass)
G_TYPE_NONE, 2,
CLUTTER_TYPE_INPUT_DEVICE,
CLUTTER_TYPE_INPUT_DEVICE_TOOL);
/**
* ClutterDeviceManager::kbd-a11y-mods-state-changed:
* @manager: the #ClutterDeviceManager that emitted the signal
* @latched_mask: the latched modifier mask from stickykeys
* @locked_mask: the locked modifier mask from stickykeys
*
* The ::kbd-a11y-mods-state-changed signal is emitted each time either the
* latched modifiers mask or locked modifiers mask are changed as the
* result of keyboard accessibilty's sticky keys operations.
*/
manager_signals[KBD_A11Y_MASK_CHANGED] =
g_signal_new (I_("kbd-a11y-mods-state-changed"),
G_TYPE_FROM_CLASS (klass),
G_SIGNAL_RUN_LAST,
0, NULL, NULL,
_clutter_marshal_VOID__UINT_UINT,
G_TYPE_NONE, 2,
G_TYPE_UINT,
G_TYPE_UINT);
/**
* ClutterDeviceManager::kbd-a11y-flags-changed:
* @manager: the #ClutterDeviceManager that emitted the signal
* @settings_flags: the new ClutterKeyboardA11yFlags configuration
* @changed_mask: the ClutterKeyboardA11yFlags changed
*
* The ::kbd-a11y-flags-changed signal is emitted each time the
* ClutterKeyboardA11yFlags configuration is changed as the result of
* keyboard accessibilty operations.
*/
manager_signals[KBD_A11Y_FLAGS_CHANGED] =
g_signal_new (I_("kbd-a11y-flags-changed"),
G_TYPE_FROM_CLASS (klass),
G_SIGNAL_RUN_LAST,
0, NULL, NULL,
_clutter_marshal_VOID__UINT_UINT,
G_TYPE_NONE, 2,
G_TYPE_UINT,
G_TYPE_UINT);
}
static void
@ -471,6 +516,21 @@ clutter_device_manager_create_virtual_device (ClutterDeviceManager *device_man
device_type);
}
/**
* clutter_device_manager_supported_virtua_device_types: (skip)
*/
ClutterVirtualDeviceType
clutter_device_manager_get_supported_virtual_device_types (ClutterDeviceManager *device_manager)
{
ClutterDeviceManagerClass *manager_class;
g_return_val_if_fail (CLUTTER_IS_DEVICE_MANAGER (device_manager),
CLUTTER_VIRTUAL_DEVICE_TYPE_NONE);
manager_class = CLUTTER_DEVICE_MANAGER_GET_CLASS (device_manager);
return manager_class->get_supported_virtual_device_types (device_manager);
}
void
_clutter_device_manager_compress_motion (ClutterDeviceManager *device_manager,
ClutterEvent *event,
@ -487,3 +547,43 @@ _clutter_device_manager_compress_motion (ClutterDeviceManager *device_manager,
manager_class->compress_motion (device_manager, event, to_discard);
}
static gboolean
are_kbd_a11y_settings_equal (ClutterKbdA11ySettings *a,
ClutterKbdA11ySettings *b)
{
return (a->controls == b->controls &&
a->slowkeys_delay == b->slowkeys_delay &&
a->debounce_delay == b->debounce_delay &&
a->timeout_delay == b->timeout_delay &&
a->mousekeys_init_delay == b->mousekeys_init_delay &&
a->mousekeys_max_speed == b->mousekeys_max_speed &&
a->mousekeys_accel_time == b->mousekeys_accel_time);
}
void
clutter_device_manager_set_kbd_a11y_settings (ClutterDeviceManager *device_manager,
ClutterKbdA11ySettings *settings)
{
ClutterDeviceManagerClass *manager_class;
g_return_if_fail (CLUTTER_IS_DEVICE_MANAGER (device_manager));
if (are_kbd_a11y_settings_equal (&device_manager->priv->kbd_a11y_settings, settings))
return;
device_manager->priv->kbd_a11y_settings = *settings;
manager_class = CLUTTER_DEVICE_MANAGER_GET_CLASS (device_manager);
if (manager_class->apply_kbd_a11y_settings)
manager_class->apply_kbd_a11y_settings (device_manager, settings);
}
void
clutter_device_manager_get_kbd_a11y_settings (ClutterDeviceManager *device_manager,
ClutterKbdA11ySettings *settings)
{
g_return_if_fail (CLUTTER_IS_DEVICE_MANAGER (device_manager));
*settings = device_manager->priv->kbd_a11y_settings;
}

View File

@ -44,6 +44,35 @@ typedef struct _ClutterDeviceManager ClutterDeviceManager;
typedef struct _ClutterDeviceManagerPrivate ClutterDeviceManagerPrivate;
typedef struct _ClutterDeviceManagerClass ClutterDeviceManagerClass;
/**
* ClutterVirtualDeviceType:
*/
typedef enum _ClutterVirtualDeviceType
{
CLUTTER_VIRTUAL_DEVICE_TYPE_NONE = 0,
CLUTTER_VIRTUAL_DEVICE_TYPE_KEYBOARD = 1 << 0,
CLUTTER_VIRTUAL_DEVICE_TYPE_POINTER = 1 << 1,
CLUTTER_VIRTUAL_DEVICE_TYPE_TOUCHSCREEN = 1 << 2,
} ClutterVirtualDeviceType;
/**
* ClutterKbdA11ySettings:
*
* The #ClutterKbdA11ySettings structure contains keyboard accessibility
* settings
*
*/
typedef struct _ClutterKbdA11ySettings
{
ClutterKeyboardA11yFlags controls;
gint slowkeys_delay;
gint debounce_delay;
gint timeout_delay;
gint mousekeys_init_delay;
gint mousekeys_max_speed;
gint mousekeys_accel_time;
} ClutterKbdA11ySettings;
/**
* ClutterDeviceManager:
*
@ -85,10 +114,13 @@ struct _ClutterDeviceManagerClass
ClutterStage *stage);
ClutterVirtualInputDevice *(* create_virtual_device) (ClutterDeviceManager *device_manager,
ClutterInputDeviceType device_type);
ClutterVirtualDeviceType (* get_supported_virtual_device_types) (ClutterDeviceManager *device_manager);
void (* compress_motion) (ClutterDeviceManager *device_manger,
ClutterEvent *event,
const ClutterEvent *to_discard);
/* Keyboard accessbility */
void (* apply_kbd_a11y_settings) (ClutterDeviceManager *device_manger,
ClutterKbdA11ySettings *settings);
/* padding */
gpointer _padding[6];
};
@ -114,6 +146,16 @@ CLUTTER_AVAILABLE_IN_ALL
ClutterVirtualInputDevice *clutter_device_manager_create_virtual_device (ClutterDeviceManager *device_manager,
ClutterInputDeviceType device_type);
CLUTTER_AVAILABLE_IN_ALL
ClutterVirtualDeviceType clutter_device_manager_get_supported_virtual_device_types (ClutterDeviceManager *device_manager);
CLUTTER_AVAILABLE_IN_ALL
void clutter_device_manager_set_kbd_a11y_settings (ClutterDeviceManager *device_manager,
ClutterKbdA11ySettings *settings);
CLUTTER_AVAILABLE_IN_ALL
void clutter_device_manager_get_kbd_a11y_settings (ClutterDeviceManager *device_manager,
ClutterKbdA11ySettings *settings);
G_END_DECLS
#endif /* __CLUTTER_DEVICE_MANAGER_H__ */

View File

@ -396,6 +396,43 @@ typedef enum {
CLUTTER_MODIFIER_MASK = 0x5c001fff
} ClutterModifierType;
/**
* ClutterKeyboardA11yFlags:
* @CLUTTER_A11Y_KEYBOARD_ENABLED:
* @CLUTTER_A11Y_TIMEOUT_ENABLED:
* @CLUTTER_A11Y_MOUSE_KEYS_ENABLED:
* @CLUTTER_A11Y_SLOW_KEYS_ENABLED:
* @CLUTTER_A11Y_SLOW_KEYS_BEEP_PRESS:
* @CLUTTER_A11Y_SLOW_KEYS_BEEP_ACCEPT:
* @CLUTTER_A11Y_SLOW_KEYS_BEEP_REJECT:
* @CLUTTER_A11Y_BOUNCE_KEYS_ENABLED:
* @CLUTTER_A11Y_BOUNCE_KEYS_BEEP_REJECT:
* @CLUTTER_A11Y_TOGGLE_KEYS_ENABLED:
* @CLUTTER_A11Y_STICKY_KEYS_ENABLED:
* @CLUTTER_A11Y_STICKY_KEYS_TWO_KEY_OFF:
* @CLUTTER_A11Y_STICKY_KEYS_BEEP:
* @CLUTTER_A11Y_FEATURE_STATE_CHANGE_BEEP:
*
* Keyboard accessibility features applied to a ClutterInputDevice keyboard.
*
*/
typedef enum {
CLUTTER_A11Y_KEYBOARD_ENABLED = 1 << 0,
CLUTTER_A11Y_TIMEOUT_ENABLED = 1 << 1,
CLUTTER_A11Y_MOUSE_KEYS_ENABLED = 1 << 2,
CLUTTER_A11Y_SLOW_KEYS_ENABLED = 1 << 3,
CLUTTER_A11Y_SLOW_KEYS_BEEP_PRESS = 1 << 4,
CLUTTER_A11Y_SLOW_KEYS_BEEP_ACCEPT = 1 << 5,
CLUTTER_A11Y_SLOW_KEYS_BEEP_REJECT = 1 << 6,
CLUTTER_A11Y_BOUNCE_KEYS_ENABLED = 1 << 7,
CLUTTER_A11Y_BOUNCE_KEYS_BEEP_REJECT = 1 << 8,
CLUTTER_A11Y_TOGGLE_KEYS_ENABLED = 1 << 9,
CLUTTER_A11Y_STICKY_KEYS_ENABLED = 1 << 10,
CLUTTER_A11Y_STICKY_KEYS_TWO_KEY_OFF = 1 << 11,
CLUTTER_A11Y_STICKY_KEYS_BEEP = 1 << 12,
CLUTTER_A11Y_FEATURE_STATE_CHANGE_BEEP = 1 << 13,
} ClutterKeyboardA11yFlags;
/**
* ClutterActorFlags:
* @CLUTTER_ACTOR_MAPPED: the actor will be painted (is visible, and inside
@ -724,14 +761,17 @@ typedef enum { /*< prefix=CLUTTER_DRAG >*/
* ClutterEventFlags:
* @CLUTTER_EVENT_NONE: No flag set
* @CLUTTER_EVENT_FLAG_SYNTHETIC: Synthetic event
* @CLUTTER_EVENT_FLAG_REPEATED: Auto-repeated event
*
* Flags for the #ClutterEvent
*
* Since: 0.6
*/
typedef enum { /*< flags prefix=CLUTTER_EVENT >*/
CLUTTER_EVENT_NONE = 0,
CLUTTER_EVENT_FLAG_SYNTHETIC = 1 << 0
CLUTTER_EVENT_NONE = 0,
CLUTTER_EVENT_FLAG_SYNTHETIC = 1 << 0,
CLUTTER_EVENT_FLAG_INPUT_METHOD = 1 << 1,
CLUTTER_EVENT_FLAG_REPEATED = 1 << 2
} ClutterEventFlags;
/**
@ -1536,6 +1576,41 @@ typedef enum {
CLUTTER_INPUT_DEVICE_MAPPING_RELATIVE,
} ClutterInputDeviceMapping;
typedef enum {
CLUTTER_INPUT_CONTENT_HINT_COMPLETION = 1 << 0,
CLUTTER_INPUT_CONTENT_HINT_SPELLCHECK = 1 << 1,
CLUTTER_INPUT_CONTENT_HINT_AUTO_CAPITALIZATION = 1 << 2,
CLUTTER_INPUT_CONTENT_HINT_LOWERCASE = 1 << 3,
CLUTTER_INPUT_CONTENT_HINT_UPPERCASE = 1 << 4,
CLUTTER_INPUT_CONTENT_HINT_TITLECASE = 1 << 5,
CLUTTER_INPUT_CONTENT_HINT_HIDDEN_TEXT = 1 << 6,
CLUTTER_INPUT_CONTENT_HINT_SENSITIVE_DATA = 1 << 7,
CLUTTER_INPUT_CONTENT_HINT_LATIN = 1 << 8,
CLUTTER_INPUT_CONTENT_HINT_MULTILINE = 1 << 9,
} ClutterInputContentHintFlags;
typedef enum {
CLUTTER_INPUT_CONTENT_PURPOSE_NORMAL,
CLUTTER_INPUT_CONTENT_PURPOSE_ALPHA,
CLUTTER_INPUT_CONTENT_PURPOSE_DIGITS,
CLUTTER_INPUT_CONTENT_PURPOSE_NUMBER,
CLUTTER_INPUT_CONTENT_PURPOSE_PHONE,
CLUTTER_INPUT_CONTENT_PURPOSE_URL,
CLUTTER_INPUT_CONTENT_PURPOSE_EMAIL,
CLUTTER_INPUT_CONTENT_PURPOSE_NAME,
CLUTTER_INPUT_CONTENT_PURPOSE_PASSWORD,
CLUTTER_INPUT_CONTENT_PURPOSE_DATE,
CLUTTER_INPUT_CONTENT_PURPOSE_TIME,
CLUTTER_INPUT_CONTENT_PURPOSE_DATETIME,
CLUTTER_INPUT_CONTENT_PURPOSE_TERMINAL,
} ClutterInputContentPurpose;
typedef enum {
CLUTTER_INPUT_PANEL_STATE_OFF,
CLUTTER_INPUT_PANEL_STATE_ON,
CLUTTER_INPUT_PANEL_STATE_TOGGLE,
} ClutterInputPanelState;
G_END_DECLS
#endif /* __CLUTTER_ENUMS_H__ */

View File

@ -2179,3 +2179,61 @@ clutter_event_get_mode_group (const ClutterEvent *event)
return 0;
}
}
/**
* clutter_event_get_pad_event_details:
* @event: a pad event
* @number: (out) (optional): ring/strip/button number
* @mode: (out) (optional): pad mode as per the event
* @value: (out) (optional): event axis value
*
* Returns the details of a pad event.
*
* Returns: #TRUE if event details could be obtained
**/
gboolean
clutter_event_get_pad_event_details (const ClutterEvent *event,
guint *number,
guint *mode,
gdouble *value)
{
guint n, m;
gdouble v;
g_return_val_if_fail (event != NULL, FALSE);
g_return_val_if_fail (event->type == CLUTTER_PAD_BUTTON_PRESS ||
event->type == CLUTTER_PAD_BUTTON_RELEASE ||
event->type == CLUTTER_PAD_RING ||
event->type == CLUTTER_PAD_STRIP, FALSE);
switch (event->type)
{
case CLUTTER_PAD_BUTTON_PRESS:
case CLUTTER_PAD_BUTTON_RELEASE:
n = event->pad_button.button;
m = event->pad_button.mode;
v = 0.0;
break;
case CLUTTER_PAD_RING:
n = event->pad_ring.ring_number;
m = event->pad_ring.mode;
v = event->pad_ring.angle;
break;
case CLUTTER_PAD_STRIP:
n = event->pad_strip.strip_number;
m = event->pad_strip.mode;
v = event->pad_strip.value;
break;
default:
return FALSE;
}
if (number)
*number = n;
if (mode)
*mode = m;
if (value)
*value = v;
return TRUE;
}

View File

@ -778,6 +778,12 @@ ClutterScrollFinishFlags clutter_event_get_scroll_finish_flags (const Clut
CLUTTER_AVAILABLE_IN_ALL
guint clutter_event_get_mode_group (const ClutterEvent *event);
CLUTTER_AVAILABLE_IN_MUTTER
gboolean clutter_event_get_pad_event_details (const ClutterEvent *event,
guint *number,
guint *mode,
gdouble *value);
G_END_DECLS

View File

@ -2243,10 +2243,15 @@ clutter_input_device_get_device_node (ClutterInputDevice *device)
ClutterInputDeviceMapping
clutter_input_device_get_mapping_mode (ClutterInputDevice *device)
{
ClutterInputDeviceType device_type;
g_return_val_if_fail (CLUTTER_IS_INPUT_DEVICE (device),
CLUTTER_INPUT_DEVICE_MAPPING_ABSOLUTE);
g_return_val_if_fail (clutter_input_device_get_device_type (device) ==
CLUTTER_TABLET_DEVICE,
device_type = clutter_input_device_get_device_type (device);
g_return_val_if_fail (device_type == CLUTTER_TABLET_DEVICE ||
device_type == CLUTTER_PEN_DEVICE ||
device_type == CLUTTER_ERASER_DEVICE,
CLUTTER_INPUT_DEVICE_MAPPING_ABSOLUTE);
return device->mapping_mode;
@ -2256,9 +2261,14 @@ void
clutter_input_device_set_mapping_mode (ClutterInputDevice *device,
ClutterInputDeviceMapping mapping)
{
ClutterInputDeviceType device_type;
g_return_if_fail (CLUTTER_IS_INPUT_DEVICE (device));
g_return_if_fail (clutter_input_device_get_device_type (device) ==
CLUTTER_TABLET_DEVICE);
device_type = clutter_input_device_get_device_type (device);
g_return_if_fail (device_type == CLUTTER_TABLET_DEVICE ||
device_type == CLUTTER_PEN_DEVICE ||
device_type == CLUTTER_ERASER_DEVICE);
if (device->mapping_mode == mapping)
return;

View File

@ -0,0 +1,40 @@
/*
* Copyright (C) 2017,2018 Red Hat
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
* 02111-1307, USA.
*
* Author: Carlos Garnacho <carlosg@gnome.org>
*/
#ifndef __CLUTTER_INPUT_FOCUS_PRIVATE_H__
#define __CLUTTER_INPUT_FOCUS_PRIVATE_H__
void clutter_input_focus_focus_in (ClutterInputFocus *focus,
ClutterInputMethod *method);
void clutter_input_focus_focus_out (ClutterInputFocus *focus);
void clutter_input_focus_commit (ClutterInputFocus *focus,
const gchar *text);
void clutter_input_focus_delete_surrounding (ClutterInputFocus *focus,
guint offset,
guint len);
void clutter_input_focus_request_surrounding (ClutterInputFocus *focus);
void clutter_input_focus_set_preedit_text (ClutterInputFocus *focus,
const gchar *preedit,
guint cursor);
#endif /* __CLUTTER_INPUT_FOCUS_PRIVATE_H__ */

View File

@ -0,0 +1,243 @@
/*
* Copyright (C) 2017,2018 Red Hat
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
* 02111-1307, USA.
*
* Author: Carlos Garnacho <carlosg@gnome.org>
*/
#include "clutter-build-config.h"
#include "clutter/clutter-input-focus.h"
#include "clutter/clutter-input-focus-private.h"
#include "clutter/clutter-input-method-private.h"
typedef struct _ClutterInputFocusPrivate ClutterInputFocusPrivate;
struct _ClutterInputFocusPrivate
{
ClutterInputMethod *im;
};
G_DEFINE_ABSTRACT_TYPE_WITH_PRIVATE (ClutterInputFocus, clutter_input_focus, G_TYPE_OBJECT)
static void
clutter_input_focus_real_focus_in (ClutterInputFocus *focus,
ClutterInputMethod *im)
{
ClutterInputFocusPrivate *priv;
priv = clutter_input_focus_get_instance_private (focus);
priv->im = im;
}
static void
clutter_input_focus_real_focus_out (ClutterInputFocus *focus)
{
ClutterInputFocusPrivate *priv;
priv = clutter_input_focus_get_instance_private (focus);
priv->im = NULL;
}
static void
clutter_input_focus_class_init (ClutterInputFocusClass *klass)
{
klass->focus_in = clutter_input_focus_real_focus_in;
klass->focus_out = clutter_input_focus_real_focus_out;
}
static void
clutter_input_focus_init (ClutterInputFocus *focus)
{
}
gboolean
clutter_input_focus_is_focused (ClutterInputFocus *focus)
{
ClutterInputFocusPrivate *priv;
priv = clutter_input_focus_get_instance_private (focus);
return !!priv->im;
}
void
clutter_input_focus_reset (ClutterInputFocus *focus)
{
ClutterInputFocusPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
g_return_if_fail (clutter_input_focus_is_focused (focus));
priv = clutter_input_focus_get_instance_private (focus);
clutter_input_method_reset (priv->im);
}
void
clutter_input_focus_set_cursor_location (ClutterInputFocus *focus,
const ClutterRect *rect)
{
ClutterInputFocusPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
g_return_if_fail (clutter_input_focus_is_focused (focus));
priv = clutter_input_focus_get_instance_private (focus);
clutter_input_method_set_cursor_location (priv->im, rect);
}
void
clutter_input_focus_set_surrounding (ClutterInputFocus *focus,
const gchar *text,
guint cursor,
guint anchor)
{
ClutterInputFocusPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
g_return_if_fail (clutter_input_focus_is_focused (focus));
priv = clutter_input_focus_get_instance_private (focus);
clutter_input_method_set_surrounding (priv->im, text, cursor, anchor);
}
void
clutter_input_focus_set_content_hints (ClutterInputFocus *focus,
ClutterInputContentHintFlags hints)
{
ClutterInputFocusPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
g_return_if_fail (clutter_input_focus_is_focused (focus));
priv = clutter_input_focus_get_instance_private (focus);
clutter_input_method_set_content_hints (priv->im, hints);
}
void
clutter_input_focus_set_content_purpose (ClutterInputFocus *focus,
ClutterInputContentPurpose purpose)
{
ClutterInputFocusPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
g_return_if_fail (clutter_input_focus_is_focused (focus));
priv = clutter_input_focus_get_instance_private (focus);
clutter_input_method_set_content_purpose (priv->im, purpose);
}
gboolean
clutter_input_focus_filter_key_event (ClutterInputFocus *focus,
const ClutterKeyEvent *key)
{
ClutterInputFocusPrivate *priv;
g_return_val_if_fail (CLUTTER_IS_INPUT_FOCUS (focus), FALSE);
g_return_val_if_fail (clutter_input_focus_is_focused (focus), FALSE);
priv = clutter_input_focus_get_instance_private (focus);
return clutter_input_method_filter_key_event (priv->im, key);
}
void
clutter_input_focus_set_can_show_preedit (ClutterInputFocus *focus,
gboolean can_show_preedit)
{
ClutterInputFocusPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
g_return_if_fail (clutter_input_focus_is_focused (focus));
priv = clutter_input_focus_get_instance_private (focus);
clutter_input_method_set_can_show_preedit (priv->im, can_show_preedit);
}
void
clutter_input_focus_request_toggle_input_panel (ClutterInputFocus *focus)
{
ClutterInputFocusPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
g_return_if_fail (clutter_input_focus_is_focused (focus));
priv = clutter_input_focus_get_instance_private (focus);
clutter_input_method_toggle_input_panel (priv->im);
}
void
clutter_input_focus_focus_in (ClutterInputFocus *focus,
ClutterInputMethod *im)
{
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
CLUTTER_INPUT_FOCUS_GET_CLASS (focus)->focus_in (focus, im);
}
void
clutter_input_focus_focus_out (ClutterInputFocus *focus)
{
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
CLUTTER_INPUT_FOCUS_GET_CLASS (focus)->focus_out (focus);
}
void
clutter_input_focus_commit (ClutterInputFocus *focus,
const gchar *text)
{
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
CLUTTER_INPUT_FOCUS_GET_CLASS (focus)->commit_text (focus, text);
}
void
clutter_input_focus_delete_surrounding (ClutterInputFocus *focus,
guint offset,
guint len)
{
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
CLUTTER_INPUT_FOCUS_GET_CLASS (focus)->delete_surrounding (focus, offset, len);
}
void
clutter_input_focus_request_surrounding (ClutterInputFocus *focus)
{
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
CLUTTER_INPUT_FOCUS_GET_CLASS (focus)->request_surrounding (focus);
}
void
clutter_input_focus_set_preedit_text (ClutterInputFocus *focus,
const gchar *preedit,
guint cursor)
{
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
CLUTTER_INPUT_FOCUS_GET_CLASS (focus)->set_preedit_text (focus, preedit, cursor);
}

View File

@ -0,0 +1,83 @@
/*
* Copyright (C) 2017,2018 Red Hat
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
* 02111-1307, USA.
*
* Author: Carlos Garnacho <carlosg@gnome.org>
*/
#ifndef __CLUTTER_INPUT_FOCUS_H__
#define __CLUTTER_INPUT_FOCUS_H__
#include <clutter/clutter.h>
#define CLUTTER_TYPE_INPUT_FOCUS (clutter_input_focus_get_type ())
CLUTTER_AVAILABLE_IN_MUTTER
G_DECLARE_DERIVABLE_TYPE (ClutterInputFocus, clutter_input_focus,
CLUTTER, INPUT_FOCUS, GObject)
struct _ClutterInputFocusClass
{
GObjectClass parent_class;
GTypeInterface iface;
void (* focus_in) (ClutterInputFocus *focus,
ClutterInputMethod *input_method);
void (* focus_out) (ClutterInputFocus *focus);
void (* request_surrounding) (ClutterInputFocus *focus);
void (* delete_surrounding) (ClutterInputFocus *focus,
guint offset,
guint len);
void (* commit_text) (ClutterInputFocus *focus,
const gchar *text);
void (* set_preedit_text) (ClutterInputFocus *focus,
const gchar *preedit,
guint cursor);
};
CLUTTER_AVAILABLE_IN_MUTTER
gboolean clutter_input_focus_is_focused (ClutterInputFocus *focus);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_focus_reset (ClutterInputFocus *focus);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_focus_set_cursor_location (ClutterInputFocus *focus,
const ClutterRect *rect);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_focus_set_surrounding (ClutterInputFocus *focus,
const gchar *text,
guint cursor,
guint anchor);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_focus_set_content_hints (ClutterInputFocus *focus,
ClutterInputContentHintFlags hint);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_focus_set_content_purpose (ClutterInputFocus *focus,
ClutterInputContentPurpose purpose);
CLUTTER_AVAILABLE_IN_MUTTER
gboolean clutter_input_focus_filter_key_event (ClutterInputFocus *focus,
const ClutterKeyEvent *key);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_focus_set_can_show_preedit (ClutterInputFocus *focus,
gboolean can_show_preedit);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_focus_request_toggle_input_panel (ClutterInputFocus *focus);
#endif /* __CLUTTER_INPUT_FOCUS_H__ */

View File

@ -0,0 +1,46 @@
/*
* Copyright (C) 2017,2018 Red Hat
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
* 02111-1307, USA.
*
* Author: Carlos Garnacho <carlosg@gnome.org>
*/
#ifndef __CLUTTER_INPUT_METHOD_PRIVATE_H__
#define __CLUTTER_INPUT_METHOD_PRIVATE_H__
ClutterInputFocus * clutter_input_method_get_focus (ClutterInputMethod *method);
void clutter_input_method_reset (ClutterInputMethod *method);
void clutter_input_method_set_cursor_location (ClutterInputMethod *method,
const ClutterRect *rect);
void clutter_input_method_set_surrounding (ClutterInputMethod *method,
const gchar *text,
guint cursor,
guint anchor);
void clutter_input_method_set_content_hints (ClutterInputMethod *method,
ClutterInputContentHintFlags hints);
void clutter_input_method_set_content_purpose (ClutterInputMethod *method,
ClutterInputContentPurpose purpose);
void clutter_input_method_set_can_show_preedit (ClutterInputMethod *method,
gboolean can_show_preedit);
gboolean clutter_input_method_filter_key_event (ClutterInputMethod *method,
const ClutterKeyEvent *key);
void clutter_input_method_toggle_input_panel (ClutterInputMethod *method);
#endif /* __CLUTTER_INPUT_METHOD_PRIVATE_H__ */

View File

@ -0,0 +1,444 @@
/*
* Copyright (C) 2017,2018 Red Hat
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
* 02111-1307, USA.
*
* Author: Carlos Garnacho <carlosg@gnome.org>
*/
#include "clutter-build-config.h"
#include "clutter-private.h"
#include "clutter/clutter-input-method.h"
#include "clutter/clutter-input-method-private.h"
#include "clutter/clutter-input-focus-private.h"
typedef struct _ClutterInputMethodPrivate ClutterInputMethodPrivate;
struct _ClutterInputMethodPrivate
{
ClutterInputFocus *focus;
ClutterInputContentHintFlags content_hints;
ClutterInputContentPurpose content_purpose;
gboolean can_show_preedit;
};
enum {
COMMIT,
DELETE_SURROUNDING,
REQUEST_SURROUNDING,
INPUT_PANEL_STATE,
CURSOR_LOCATION_CHANGED,
N_SIGNALS,
};
enum {
PROP_0,
PROP_CONTENT_HINTS,
PROP_CONTENT_PURPOSE,
PROP_CAN_SHOW_PREEDIT,
N_PROPS
};
static guint signals[N_SIGNALS] = { 0 };
static GParamSpec *pspecs[N_PROPS] = { 0 };
G_DEFINE_ABSTRACT_TYPE_WITH_PRIVATE (ClutterInputMethod, clutter_input_method, G_TYPE_OBJECT)
static void
set_content_hints (ClutterInputMethod *im,
ClutterInputContentHintFlags content_hints)
{
ClutterInputMethodPrivate *priv;
priv = clutter_input_method_get_instance_private (im);
priv->content_hints = content_hints;
CLUTTER_INPUT_METHOD_GET_CLASS (im)->update_content_hints (im, content_hints);
}
static void
set_content_purpose (ClutterInputMethod *im,
ClutterInputContentPurpose content_purpose)
{
ClutterInputMethodPrivate *priv;
priv = clutter_input_method_get_instance_private (im);
priv->content_purpose = content_purpose;
CLUTTER_INPUT_METHOD_GET_CLASS (im)->update_content_purpose (im,
content_purpose);
}
static void
set_can_show_preedit (ClutterInputMethod *im,
gboolean can_show_preedit)
{
ClutterInputMethodPrivate *priv;
priv = clutter_input_method_get_instance_private (im);
priv->can_show_preedit = can_show_preedit;
}
static void
clutter_input_method_set_property (GObject *object,
guint prop_id,
const GValue *value,
GParamSpec *pspec)
{
switch (prop_id)
{
case PROP_CONTENT_HINTS:
set_content_hints (CLUTTER_INPUT_METHOD (object),
g_value_get_flags (value));
break;
case PROP_CONTENT_PURPOSE:
set_content_purpose (CLUTTER_INPUT_METHOD (object),
g_value_get_enum (value));
break;
case PROP_CAN_SHOW_PREEDIT:
set_can_show_preedit (CLUTTER_INPUT_METHOD (object),
g_value_get_boolean (value));
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
break;
}
}
static void
clutter_input_method_get_property (GObject *object,
guint prop_id,
GValue *value,
GParamSpec *pspec)
{
ClutterInputMethodPrivate *priv;
ClutterInputMethod *im;
im = CLUTTER_INPUT_METHOD (object);
priv = clutter_input_method_get_instance_private (im);
switch (prop_id)
{
case PROP_CONTENT_HINTS:
g_value_set_flags (value, priv->content_hints);
break;
case PROP_CONTENT_PURPOSE:
g_value_set_enum (value, priv->content_purpose);
break;
case PROP_CAN_SHOW_PREEDIT:
g_value_set_boolean (value, priv->can_show_preedit);
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
break;
}
}
static void
clutter_input_method_class_init (ClutterInputMethodClass *klass)
{
GObjectClass *object_class = G_OBJECT_CLASS (klass);
object_class->set_property = clutter_input_method_set_property;
object_class->get_property = clutter_input_method_get_property;
signals[COMMIT] =
g_signal_new ("commit",
G_TYPE_FROM_CLASS (object_class),
G_SIGNAL_RUN_LAST,
0, NULL, NULL, NULL,
G_TYPE_NONE, 1, G_TYPE_STRING);
signals[DELETE_SURROUNDING] =
g_signal_new ("delete-surrounding",
G_TYPE_FROM_CLASS (object_class),
G_SIGNAL_RUN_LAST,
0, NULL, NULL, NULL,
G_TYPE_NONE, 2, G_TYPE_UINT, G_TYPE_UINT);
signals[REQUEST_SURROUNDING] =
g_signal_new ("request-surrounding",
G_TYPE_FROM_CLASS (object_class),
G_SIGNAL_RUN_LAST,
0, NULL, NULL, NULL,
G_TYPE_NONE, 0);
signals[INPUT_PANEL_STATE] =
g_signal_new ("input-panel-state",
G_TYPE_FROM_CLASS (object_class),
G_SIGNAL_RUN_LAST,
0, NULL, NULL, NULL,
G_TYPE_NONE, 1,
CLUTTER_TYPE_INPUT_PANEL_STATE);
signals[CURSOR_LOCATION_CHANGED] =
g_signal_new ("cursor-location-changed",
G_TYPE_FROM_CLASS (object_class),
G_SIGNAL_RUN_LAST,
0, NULL, NULL, NULL,
G_TYPE_NONE, 1, CLUTTER_TYPE_RECT);
pspecs[PROP_CONTENT_HINTS] =
g_param_spec_flags ("content-hints",
P_("Content hints"),
P_("Content hints"),
CLUTTER_TYPE_INPUT_CONTENT_HINT_FLAGS, 0,
G_PARAM_READWRITE |
G_PARAM_STATIC_STRINGS);
pspecs[PROP_CONTENT_PURPOSE] =
g_param_spec_enum ("content-purpose",
P_("Content purpose"),
P_("Content purpose"),
CLUTTER_TYPE_INPUT_CONTENT_PURPOSE, 0,
G_PARAM_READWRITE |
G_PARAM_STATIC_STRINGS);
pspecs[PROP_CAN_SHOW_PREEDIT] =
g_param_spec_boolean ("can-show-preedit",
P_("Can show preedit"),
P_("Can show preedit"),
FALSE,
G_PARAM_READWRITE |
G_PARAM_STATIC_STRINGS);
g_object_class_install_properties (object_class, N_PROPS, pspecs);
}
static void
clutter_input_method_init (ClutterInputMethod *im)
{
}
void
clutter_input_method_focus_in (ClutterInputMethod *im,
ClutterInputFocus *focus)
{
ClutterInputMethodPrivate *priv;
ClutterInputMethodClass *klass;
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
g_return_if_fail (CLUTTER_IS_INPUT_FOCUS (focus));
priv = clutter_input_method_get_instance_private (im);
if (priv->focus == focus)
return;
if (priv->focus)
clutter_input_method_focus_out (im);
g_set_object (&priv->focus, focus);
if (focus)
{
klass = CLUTTER_INPUT_METHOD_GET_CLASS (im);
klass->focus_in (im, focus);
clutter_input_focus_focus_in (priv->focus, im);
}
}
void
clutter_input_method_focus_out (ClutterInputMethod *im)
{
ClutterInputMethodPrivate *priv;
ClutterInputMethodClass *klass;
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
priv = clutter_input_method_get_instance_private (im);
if (!priv->focus)
return;
clutter_input_focus_focus_out (priv->focus);
g_clear_object (&priv->focus);
klass = CLUTTER_INPUT_METHOD_GET_CLASS (im);
klass->focus_out (im);
g_signal_emit (im, signals[INPUT_PANEL_STATE],
0, CLUTTER_INPUT_PANEL_STATE_OFF);
}
ClutterInputFocus *
clutter_input_method_get_focus (ClutterInputMethod *im)
{
ClutterInputMethodPrivate *priv;
priv = clutter_input_method_get_instance_private (im);
return priv->focus;
}
void
clutter_input_method_commit (ClutterInputMethod *im,
const gchar *text)
{
ClutterInputMethodPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
priv = clutter_input_method_get_instance_private (im);
if (priv->focus)
clutter_input_focus_commit (priv->focus, text);
}
void
clutter_input_method_delete_surrounding (ClutterInputMethod *im,
guint offset,
guint len)
{
ClutterInputMethodPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
priv = clutter_input_method_get_instance_private (im);
if (priv->focus)
clutter_input_focus_delete_surrounding (priv->focus, offset, len);
}
void
clutter_input_method_request_surrounding (ClutterInputMethod *im)
{
ClutterInputMethodPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
priv = clutter_input_method_get_instance_private (im);
if (priv->focus)
clutter_input_focus_request_surrounding (priv->focus);
}
/**
* clutter_input_method_set_preedit_text:
* @im: a #ClutterInputMethod
* @preedit: (nullable): the preedit text, or %NULL
* @cursor: the cursor
*
* Sets the preedit text on the current input focus.
**/
void
clutter_input_method_set_preedit_text (ClutterInputMethod *im,
const gchar *preedit,
guint cursor)
{
ClutterInputMethodPrivate *priv;
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
priv = clutter_input_method_get_instance_private (im);
if (priv->focus)
clutter_input_focus_set_preedit_text (priv->focus, preedit, cursor);
}
void
clutter_input_method_notify_key_event (ClutterInputMethod *im,
const ClutterEvent *event,
gboolean filtered)
{
if (!filtered)
{
ClutterEvent *copy;
/* XXX: we rely on the IM implementation to notify back of
* key events in the exact same order they were given.
*/
copy = clutter_event_copy (event);
clutter_event_set_flags (copy, clutter_event_get_flags (event) |
CLUTTER_EVENT_FLAG_INPUT_METHOD);
clutter_event_set_source_device (copy, clutter_event_get_device (copy));
clutter_event_put (copy);
clutter_event_free (copy);
}
}
void
clutter_input_method_toggle_input_panel (ClutterInputMethod *im)
{
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
g_signal_emit (im, signals[INPUT_PANEL_STATE], 0,
CLUTTER_INPUT_PANEL_STATE_TOGGLE);
}
void
clutter_input_method_reset (ClutterInputMethod *im)
{
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
CLUTTER_INPUT_METHOD_GET_CLASS (im)->reset (im);
}
void
clutter_input_method_set_cursor_location (ClutterInputMethod *im,
const ClutterRect *rect)
{
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
CLUTTER_INPUT_METHOD_GET_CLASS (im)->set_cursor_location (im, rect);
g_signal_emit (im, signals[CURSOR_LOCATION_CHANGED], 0, rect);
}
void
clutter_input_method_set_surrounding (ClutterInputMethod *im,
const gchar *text,
guint cursor,
guint anchor)
{
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
CLUTTER_INPUT_METHOD_GET_CLASS (im)->set_surrounding (im, text,
cursor, anchor);
}
void
clutter_input_method_set_content_hints (ClutterInputMethod *im,
ClutterInputContentHintFlags hints)
{
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
g_object_set (G_OBJECT (im), "content-hints", hints, NULL);
}
void
clutter_input_method_set_content_purpose (ClutterInputMethod *im,
ClutterInputContentPurpose purpose)
{
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
g_object_set (G_OBJECT (im), "content-purpose", purpose, NULL);
}
void
clutter_input_method_set_can_show_preedit (ClutterInputMethod *im,
gboolean can_show_preedit)
{
g_return_if_fail (CLUTTER_IS_INPUT_METHOD (im));
g_object_set (G_OBJECT (im), "can-show-preedit", can_show_preedit, NULL);
}
gboolean
clutter_input_method_filter_key_event (ClutterInputMethod *im,
const ClutterKeyEvent *key)
{
ClutterInputMethodClass *im_class = CLUTTER_INPUT_METHOD_GET_CLASS (im);
g_return_val_if_fail (CLUTTER_IS_INPUT_METHOD (im), FALSE);
g_return_val_if_fail (key != NULL, FALSE);
if (clutter_event_get_flags ((ClutterEvent *) key) & CLUTTER_EVENT_FLAG_INPUT_METHOD)
return FALSE;
if (!im_class->filter_key_event)
return FALSE;
return im_class->filter_key_event (im, (const ClutterEvent *) key);
}

View File

@ -0,0 +1,88 @@
/*
* Copyright (C) 2017,2018 Red Hat
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
* 02111-1307, USA.
*
* Author: Carlos Garnacho <carlosg@gnome.org>
*/
#ifndef __CLUTTER_INPUT_METHOD_H__
#define __CLUTTER_INPUT_METHOD_H__
#include <clutter/clutter.h>
#define CLUTTER_TYPE_INPUT_METHOD (clutter_input_method_get_type ())
CLUTTER_AVAILABLE_IN_MUTTER
G_DECLARE_DERIVABLE_TYPE (ClutterInputMethod, clutter_input_method,
CLUTTER, INPUT_METHOD, GObject)
typedef struct _ClutterInputMethodClass ClutterInputMethodClass;
struct _ClutterInputMethodClass
{
GObjectClass parent_class;
void (* focus_in) (ClutterInputMethod *im,
ClutterInputFocus *actor);
void (* focus_out) (ClutterInputMethod *im);
void (* reset) (ClutterInputMethod *im);
void (* set_cursor_location) (ClutterInputMethod *im,
const ClutterRect *rect);
void (* set_surrounding) (ClutterInputMethod *im,
const gchar *text,
guint cursor,
guint anchor);
void (* update_content_hints) (ClutterInputMethod *im,
ClutterInputContentHintFlags hint);
void (* update_content_purpose) (ClutterInputMethod *im,
ClutterInputContentPurpose purpose);
gboolean (* filter_key_event) (ClutterInputMethod *im,
const ClutterEvent *key);
};
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_method_focus_in (ClutterInputMethod *im,
ClutterInputFocus *focus);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_method_focus_out (ClutterInputMethod *im);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_method_commit (ClutterInputMethod *im,
const gchar *text);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_method_delete_surrounding (ClutterInputMethod *im,
guint offset,
guint len);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_method_request_surrounding (ClutterInputMethod *im);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_method_set_preedit_text (ClutterInputMethod *im,
const gchar *preedit,
guint cursor);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_method_notify_key_event (ClutterInputMethod *im,
const ClutterEvent *event,
gboolean filtered);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_input_method_request_toggle_input_panel (ClutterInputMethod *im);
#endif /* __CLUTTER_INPUT_METHOD_H__ */

View File

@ -2089,6 +2089,21 @@ emit_keyboard_event (ClutterEvent *event,
}
}
static inline void
process_key_event (ClutterEvent *event,
ClutterInputDevice *device)
{
ClutterInputDeviceClass *device_class = CLUTTER_INPUT_DEVICE_GET_CLASS (device);
if (device_class->process_kbd_a11y_event)
{
device_class->process_kbd_a11y_event (event, device, emit_keyboard_event);
return;
}
emit_keyboard_event (event, device);
}
static gboolean
is_off_stage (ClutterActor *stage,
gfloat x,
@ -2176,7 +2191,7 @@ _clutter_process_event_details (ClutterActor *stage,
}
}
emit_keyboard_event (event, device);
process_key_event (event, device);
}
break;

View File

@ -40,6 +40,12 @@ gboolean _clutter_get_sync_to_vblank (void);
CLUTTER_AVAILABLE_IN_MUTTER
int64_t clutter_stage_get_frame_counter (ClutterStage *stage);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_stage_capture_into (ClutterStage *stage,
gboolean paint,
cairo_rectangle_int_t *rect,
uint8_t *data);
#undef __CLUTTER_H_INSIDE__
#endif /* __CLUTTER_MUTTER_H__ */

View File

@ -20,6 +20,7 @@
#include "clutter/clutter-stage-view.h"
#include <cairo-gobject.h>
#include <math.h>
enum
{
@ -38,7 +39,7 @@ static GParamSpec *obj_props[PROP_LAST];
typedef struct _ClutterStageViewPrivate
{
cairo_rectangle_int_t layout;
int scale;
float scale;
CoglFramebuffer *framebuffer;
CoglOffscreen *offscreen;
@ -143,7 +144,7 @@ clutter_stage_view_blit_offscreen (ClutterStageView *view,
cogl_framebuffer_pop_matrix (priv->framebuffer);
}
int
float
clutter_stage_view_get_scale (ClutterStageView *view)
{
ClutterStageViewPrivate *priv =
@ -241,7 +242,7 @@ clutter_stage_view_get_property (GObject *object,
g_value_set_boxed (value, priv->offscreen);
break;
case PROP_SCALE:
g_value_set_int (value, priv->scale);
g_value_set_float (value, priv->scale);
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
@ -267,12 +268,26 @@ clutter_stage_view_set_property (GObject *object,
break;
case PROP_FRAMEBUFFER:
priv->framebuffer = g_value_dup_boxed (value);
#ifndef G_DISABLE_CHECKS
if (priv->framebuffer)
{
int fb_width, fb_height;
fb_width = cogl_framebuffer_get_width (priv->framebuffer);
fb_height = cogl_framebuffer_get_height (priv->framebuffer);
g_warn_if_fail (fabsf (roundf (fb_width / priv->scale) -
fb_width / priv->scale) < FLT_EPSILON);
g_warn_if_fail (fabsf (roundf (fb_height / priv->scale) -
fb_height / priv->scale) < FLT_EPSILON);
}
#endif
break;
case PROP_OFFSCREEN:
priv->offscreen = g_value_dup_boxed (value);
break;
case PROP_SCALE:
priv->scale = g_value_get_int (value);
priv->scale = g_value_get_float (value);
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
@ -301,7 +316,7 @@ clutter_stage_view_init (ClutterStageView *view)
priv->dirty_viewport = TRUE;
priv->dirty_projection = TRUE;
priv->scale = 1;
priv->scale = 1.0;
}
static void
@ -322,6 +337,7 @@ clutter_stage_view_class_init (ClutterStageViewClass *klass)
"The view layout on the screen",
CAIRO_GOBJECT_TYPE_RECTANGLE_INT,
G_PARAM_READWRITE |
G_PARAM_CONSTRUCT |
G_PARAM_STATIC_STRINGS);
obj_props[PROP_FRAMEBUFFER] =
@ -330,6 +346,7 @@ clutter_stage_view_class_init (ClutterStageViewClass *klass)
"The front buffer of the view",
COGL_TYPE_HANDLE,
G_PARAM_READWRITE |
G_PARAM_CONSTRUCT |
G_PARAM_STATIC_STRINGS);
obj_props[PROP_OFFSCREEN] =
@ -338,16 +355,17 @@ clutter_stage_view_class_init (ClutterStageViewClass *klass)
"Framebuffer used as intermediate buffer",
COGL_TYPE_HANDLE,
G_PARAM_READWRITE |
G_PARAM_CONSTRUCT_ONLY |
G_PARAM_CONSTRUCT_ONLY |
G_PARAM_STATIC_STRINGS);
obj_props[PROP_SCALE] =
g_param_spec_int ("scale",
"View scale",
"The view scale",
1, G_MAXINT, 1,
G_PARAM_READWRITE |
G_PARAM_STATIC_STRINGS);
g_param_spec_float ("scale",
"View scale",
"The view scale",
0.5, G_MAXFLOAT, 1.0,
G_PARAM_READWRITE |
G_PARAM_CONSTRUCT |
G_PARAM_STATIC_STRINGS);
g_object_class_install_properties (object_class, PROP_LAST, obj_props);
}

View File

@ -61,7 +61,7 @@ void clutter_stage_view_blit_offscreen (ClutterStageView *view,
const cairo_rectangle_int_t *clip);
CLUTTER_AVAILABLE_IN_MUTTER
int clutter_stage_view_get_scale (ClutterStageView *view);
float clutter_stage_view_get_scale (ClutterStageView *view);
gboolean clutter_stage_view_is_dirty_viewport (ClutterStageView *view);

View File

@ -161,6 +161,7 @@ struct _ClutterStagePrivate
guint accept_focus : 1;
guint motion_events_enabled : 1;
guint has_custom_perspective : 1;
guint stage_was_relayout : 1;
};
enum
@ -961,6 +962,7 @@ _clutter_stage_process_queued_events (ClutterStage *stage)
ClutterEvent *next_event;
ClutterInputDevice *device;
ClutterInputDevice *next_device;
ClutterInputDeviceType device_type;
gboolean check_device = FALSE;
event = l->data;
@ -976,8 +978,16 @@ _clutter_stage_process_queued_events (ClutterStage *stage)
if (device != NULL && next_device != NULL)
check_device = TRUE;
/* Skip consecutive motion events coming from the same device */
if (priv->throttle_motion_events && next_event != NULL)
device_type = clutter_input_device_get_device_type (device);
/* Skip consecutive motion events coming from the same device,
* except those of tablet tools, since users of these events
* want no precision loss.
*/
if (priv->throttle_motion_events && next_event != NULL &&
device_type != CLUTTER_TABLET_DEVICE &&
device_type != CLUTTER_PEN_DEVICE &&
device_type != CLUTTER_ERASER_DEVICE)
{
if (event->type == CLUTTER_MOTION &&
(next_event->type == CLUTTER_MOTION ||
@ -1059,6 +1069,7 @@ _clutter_stage_maybe_relayout (ClutterActor *actor)
if (!CLUTTER_ACTOR_IN_RELAYOUT (stage))
{
priv->relayout_pending = FALSE;
priv->stage_was_relayout = TRUE;
CLUTTER_NOTE (ACTOR, "Recomputing layout");
@ -1129,6 +1140,58 @@ clutter_stage_do_redraw (ClutterStage *stage)
stage);
}
static GSList *
_clutter_stage_check_updated_pointers (ClutterStage *stage)
{
ClutterStagePrivate *priv = stage->priv;
ClutterDeviceManager *device_manager;
GSList *updating = NULL;
const GSList *devices;
cairo_rectangle_int_t clip;
ClutterPoint point;
gboolean has_clip;
has_clip = _clutter_stage_window_get_redraw_clip_bounds (priv->impl, &clip);
device_manager = clutter_device_manager_get_default ();
devices = clutter_device_manager_peek_devices (device_manager);
for (; devices != NULL; devices = devices->next)
{
ClutterInputDevice *dev = devices->data;
if (clutter_input_device_get_device_mode (dev) !=
CLUTTER_INPUT_MODE_MASTER)
continue;
switch (clutter_input_device_get_device_type (dev))
{
case CLUTTER_POINTER_DEVICE:
case CLUTTER_TABLET_DEVICE:
case CLUTTER_PEN_DEVICE:
case CLUTTER_ERASER_DEVICE:
case CLUTTER_CURSOR_DEVICE:
if (!clutter_input_device_get_coords (dev, NULL, &point))
continue;
if (!has_clip ||
(point.x >= clip.x && point.x < clip.x + clip.width &&
point.y >= clip.y && point.y < clip.y + clip.height))
updating = g_slist_prepend (updating, dev);
break;
default:
/* Any other devices don't need checking, either because they
* don't have x/y coordinates, or because they're implicitly
* grabbed on an actor by default as it's the case of
* touch(screens).
*/
break;
}
}
return updating;
}
/**
* _clutter_stage_do_update:
* @stage: A #ClutterStage
@ -1141,6 +1204,10 @@ gboolean
_clutter_stage_do_update (ClutterStage *stage)
{
ClutterStagePrivate *priv = stage->priv;
gboolean stage_was_relayout = priv->stage_was_relayout;
GSList *pointers = NULL;
priv->stage_was_relayout = FALSE;
/* if the stage is being destroyed, or if the destruction already
* happened and we don't have an StageWindow any more, then we
@ -1161,6 +1228,9 @@ _clutter_stage_do_update (ClutterStage *stage)
if (!priv->redraw_pending)
return FALSE;
if (stage_was_relayout)
pointers = _clutter_stage_check_updated_pointers (stage);
clutter_stage_maybe_finish_queue_redraws (stage);
clutter_stage_do_redraw (stage);
@ -1178,6 +1248,12 @@ _clutter_stage_do_update (ClutterStage *stage)
}
#endif /* CLUTTER_ENABLE_DEBUG */
while (pointers)
{
_clutter_input_device_update (pointers->data, NULL, TRUE);
pointers = g_slist_delete_link (pointers, pointers);
}
return TRUE;
}
@ -1369,9 +1445,9 @@ _clutter_stage_do_pick_on_view (ClutterStage *stage,
gint read_x;
gint read_y;
float fb_width, fb_height;
int fb_scale;
int viewport_offset_x;
int viewport_offset_y;
float fb_scale;
float viewport_offset_x;
float viewport_offset_y;
priv = stage->priv;
@ -1398,8 +1474,8 @@ _clutter_stage_do_pick_on_view (ClutterStage *stage,
if (G_LIKELY (!(clutter_pick_debug_flags & CLUTTER_DEBUG_DUMP_PICK_BUFFERS)))
{
CLUTTER_NOTE (PICK, "Pushing pick scissor clip x: %d, y: %d, 1x1",
dirty_x * fb_scale,
dirty_y * fb_scale);
(int) dirty_x * fb_scale,
(int) dirty_y * fb_scale);
cogl_framebuffer_push_scissor_clip (fb, dirty_x * fb_scale, dirty_y * fb_scale, 1, 1);
}
@ -1410,10 +1486,11 @@ _clutter_stage_do_pick_on_view (ClutterStage *stage,
priv->viewport[1] * fb_scale - viewport_offset_y,
priv->viewport[2] * fb_scale,
priv->viewport[3] * fb_scale);
cogl_set_viewport (priv->viewport[0] * fb_scale - viewport_offset_x,
priv->viewport[1] * fb_scale - viewport_offset_y,
priv->viewport[2] * fb_scale,
priv->viewport[3] * fb_scale);
cogl_framebuffer_set_viewport (fb,
priv->viewport[0] * fb_scale - viewport_offset_x,
priv->viewport[1] * fb_scale - viewport_offset_y,
priv->viewport[2] * fb_scale,
priv->viewport[3] * fb_scale);
read_x = dirty_x * fb_scale;
read_y = dirty_y * fb_scale;
@ -3541,14 +3618,15 @@ _clutter_stage_maybe_setup_viewport (ClutterStage *stage,
ClutterStageView *view)
{
ClutterStagePrivate *priv = stage->priv;
CoglFramebuffer *fb = clutter_stage_view_get_framebuffer (view);
if (clutter_stage_view_is_dirty_viewport (view))
{
cairo_rectangle_int_t view_layout;
ClutterPerspective perspective;
int fb_scale;
int viewport_offset_x;
int viewport_offset_y;
float fb_scale;
float viewport_offset_x;
float viewport_offset_y;
float z_2d;
CLUTTER_NOTE (PAINT,
@ -3561,10 +3639,11 @@ _clutter_stage_maybe_setup_viewport (ClutterStage *stage,
viewport_offset_x = view_layout.x * fb_scale;
viewport_offset_y = view_layout.y * fb_scale;
cogl_set_viewport (priv->viewport[0] * fb_scale - viewport_offset_x,
priv->viewport[1] * fb_scale - viewport_offset_y,
priv->viewport[2] * fb_scale,
priv->viewport[3] * fb_scale);
cogl_framebuffer_set_viewport (fb,
priv->viewport[0] * fb_scale - viewport_offset_x,
priv->viewport[1] * fb_scale - viewport_offset_y,
priv->viewport[2] * fb_scale,
priv->viewport[3] * fb_scale);
perspective = priv->perspective;
@ -3603,7 +3682,7 @@ _clutter_stage_maybe_setup_viewport (ClutterStage *stage,
if (clutter_stage_view_is_dirty_projection (view))
{
cogl_set_projection_matrix (&priv->projection);
cogl_framebuffer_set_projection_matrix (fb, &priv->projection);
clutter_stage_view_set_dirty_projection (view, FALSE);
}
@ -4644,18 +4723,22 @@ capture_view (ClutterStage *stage,
int stride;
CoglBitmap *bitmap;
cairo_rectangle_int_t view_layout;
float view_scale;
framebuffer = clutter_stage_view_get_framebuffer (view);
if (paint)
{
_clutter_stage_maybe_setup_viewport (stage, view);
cogl_push_framebuffer (framebuffer);
_clutter_stage_maybe_setup_viewport (stage, view);
clutter_stage_do_paint_view (stage, view, rect);
}
view_scale = clutter_stage_view_get_scale (view);
image = cairo_image_surface_create (CAIRO_FORMAT_ARGB32,
rect->width, rect->height);
rect->width * view_scale,
rect->height * view_scale);
cairo_surface_set_device_scale (image, view_scale, view_scale);
data = cairo_image_surface_get_data (image);
stride = cairo_image_surface_get_stride (image);
@ -4663,7 +4746,8 @@ capture_view (ClutterStage *stage,
backend = clutter_get_default_backend ();
context = clutter_backend_get_cogl_context (backend);
bitmap = cogl_bitmap_new_for_data (context,
rect->width, rect->height,
rect->width * view_scale,
rect->height * view_scale,
CLUTTER_CAIRO_FORMAT_ARGB32,
stride,
data);
@ -4671,8 +4755,8 @@ capture_view (ClutterStage *stage,
clutter_stage_view_get_layout (view, &view_layout);
cogl_framebuffer_read_pixels_into_bitmap (framebuffer,
rect->x - view_layout.x,
rect->y - view_layout.y,
(rect->x - view_layout.x) * view_scale,
(rect->y - view_layout.y) * view_scale,
COGL_READ_PIXELS_COLOR_BUFFER,
bitmap);
@ -4729,3 +4813,93 @@ clutter_stage_capture (ClutterStage *stage,
return TRUE;
}
static void
capture_view_into (ClutterStage *stage,
gboolean paint,
ClutterStageView *view,
cairo_rectangle_int_t *rect,
uint8_t *data,
int stride)
{
CoglFramebuffer *framebuffer;
ClutterBackend *backend;
CoglContext *context;
CoglBitmap *bitmap;
cairo_rectangle_int_t view_layout;
framebuffer = clutter_stage_view_get_framebuffer (view);
if (paint)
{
cogl_push_framebuffer (framebuffer);
_clutter_stage_maybe_setup_viewport (stage, view);
clutter_stage_do_paint_view (stage, view, rect);
}
backend = clutter_get_default_backend ();
context = clutter_backend_get_cogl_context (backend);
bitmap = cogl_bitmap_new_for_data (context,
rect->width, rect->height,
CLUTTER_CAIRO_FORMAT_ARGB32,
stride,
data);
clutter_stage_view_get_layout (view, &view_layout);
cogl_framebuffer_read_pixels_into_bitmap (framebuffer,
rect->x - view_layout.x,
rect->y - view_layout.y,
COGL_READ_PIXELS_COLOR_BUFFER,
bitmap);
if (paint)
cogl_pop_framebuffer ();
cogl_object_unref (bitmap);
}
static ClutterStageView *
get_view_at_rect (ClutterStage *stage,
cairo_rectangle_int_t *rect)
{
ClutterStagePrivate *priv = stage->priv;
GList *views = _clutter_stage_window_get_views (priv->impl);
GList *l;
for (l = views; l; l = l->next)
{
ClutterStageView *view = l->data;
cairo_rectangle_int_t view_layout;
cairo_region_t *region;
cairo_rectangle_int_t view_capture_rect;
clutter_stage_view_get_layout (view, &view_layout);
region = cairo_region_create_rectangle (&view_layout);
cairo_region_intersect_rectangle (region, rect);
cairo_region_get_extents (region, &view_capture_rect);
cairo_region_destroy (region);
if (view_capture_rect.width == 0 || view_capture_rect.height == 0)
continue;
g_assert (view_capture_rect.width == rect->width &&
view_capture_rect.height == rect->height);
return view;
}
return NULL;
}
void
clutter_stage_capture_into (ClutterStage *stage,
gboolean paint,
cairo_rectangle_int_t *rect,
uint8_t *data)
{
ClutterStageView *view;
int bpp = 4;
view = get_view_at_rect (stage, rect);
capture_view_into (stage, paint, view, rect, data, rect->width * bpp);
}

View File

@ -63,6 +63,7 @@
#include "clutter-units.h"
#include "clutter-paint-volume-private.h"
#include "clutter-scriptable.h"
#include "clutter-input-focus.h"
/* cursor width in pixels */
#define DEFAULT_CURSOR_SIZE 2
@ -98,6 +99,12 @@ struct _LayoutCache
guint age;
};
struct _ClutterTextInputFocus
{
ClutterInputFocus parent_instance;
ClutterText *text;
};
struct _ClutterTextPrivate
{
PangoFontDescription *font_desc;
@ -176,6 +183,10 @@ struct _ClutterTextPrivate
/* Signal handler for when the :text-direction changes */
guint direction_changed_id;
ClutterInputFocus *input_focus;
ClutterInputContentHintFlags input_hints;
ClutterInputContentPurpose input_purpose;
/* bitfields */
guint alignment : 2;
guint wrap : 1;
@ -236,6 +247,8 @@ enum
PROP_SINGLE_LINE_MODE,
PROP_SELECTED_TEXT_COLOR,
PROP_SELECTED_TEXT_COLOR_SET,
PROP_INPUT_HINTS,
PROP_INPUT_PURPOSE,
PROP_LAST
};
@ -269,6 +282,112 @@ static const ClutterColor default_selected_text_color = { 0, 0, 0, 255 };
static ClutterAnimatableIface *parent_animatable_iface = NULL;
static ClutterScriptableIface *parent_scriptable_iface = NULL;
/* ClutterTextInputFocus */
#define CLUTTER_TYPE_TEXT_INPUT_FOCUS (clutter_text_input_focus_get_type ())
G_DECLARE_FINAL_TYPE (ClutterTextInputFocus, clutter_text_input_focus,
CLUTTER, TEXT_INPUT_FOCUS, ClutterInputFocus)
G_DEFINE_TYPE (ClutterTextInputFocus, clutter_text_input_focus,
CLUTTER_TYPE_INPUT_FOCUS)
static void
clutter_text_input_focus_request_surrounding (ClutterInputFocus *focus)
{
ClutterText *clutter_text = CLUTTER_TEXT_INPUT_FOCUS (focus)->text;
ClutterTextBuffer *buffer;
const gchar *text;
gint anchor_pos, cursor_pos;
buffer = clutter_text_get_buffer (clutter_text);
text = clutter_text_buffer_get_text (buffer);
cursor_pos = clutter_text_get_cursor_position (clutter_text);
if (cursor_pos < 0)
cursor_pos = clutter_text_buffer_get_length (buffer);
anchor_pos = clutter_text_get_selection_bound (clutter_text);
if (anchor_pos < 0)
anchor_pos = cursor_pos;
clutter_input_focus_set_surrounding (focus, text,
g_utf8_offset_to_pointer (text, cursor_pos) - text,
g_utf8_offset_to_pointer (text, anchor_pos) - text);
}
static void
clutter_text_input_focus_delete_surrounding (ClutterInputFocus *focus,
guint offset,
guint len)
{
ClutterText *clutter_text = CLUTTER_TEXT_INPUT_FOCUS (focus)->text;
if (clutter_text_get_editable (clutter_text))
clutter_text_delete_text (clutter_text, offset, len);
}
static void
clutter_text_input_focus_commit_text (ClutterInputFocus *focus,
const gchar *text)
{
ClutterText *clutter_text = CLUTTER_TEXT_INPUT_FOCUS (focus)->text;
if (clutter_text_get_editable (clutter_text))
{
clutter_text_delete_selection (clutter_text);
clutter_text_insert_text (clutter_text, text,
clutter_text_get_cursor_position (clutter_text));
clutter_text_set_preedit_string (clutter_text, NULL, NULL, 0);
}
}
static void
clutter_text_input_focus_set_preedit_text (ClutterInputFocus *focus,
const gchar *preedit_text,
guint cursor_pos)
{
ClutterText *clutter_text = CLUTTER_TEXT_INPUT_FOCUS (focus)->text;
if (clutter_text_get_editable (clutter_text))
{
PangoAttrList *list;
list = pango_attr_list_new ();
pango_attr_list_insert (list, pango_attr_underline_new (PANGO_UNDERLINE_SINGLE));
clutter_text_set_preedit_string (clutter_text,
preedit_text, list,
cursor_pos);
pango_attr_list_unref (list);
}
}
static void
clutter_text_input_focus_class_init (ClutterTextInputFocusClass *klass)
{
ClutterInputFocusClass *focus_class = CLUTTER_INPUT_FOCUS_CLASS (klass);
focus_class->request_surrounding = clutter_text_input_focus_request_surrounding;
focus_class->delete_surrounding = clutter_text_input_focus_delete_surrounding;
focus_class->commit_text = clutter_text_input_focus_commit_text;
focus_class->set_preedit_text = clutter_text_input_focus_set_preedit_text;
}
static void
clutter_text_input_focus_init (ClutterTextInputFocus *focus)
{
}
static ClutterInputFocus *
clutter_text_input_focus_new (ClutterText *text)
{
ClutterTextInputFocus *focus;
focus = g_object_new (CLUTTER_TYPE_TEXT_INPUT_FOCUS, NULL);
focus->text = text;
return CLUTTER_INPUT_FOCUS (focus);
}
/* ClutterText */
static void clutter_scriptable_iface_init (ClutterScriptableIface *iface);
static void clutter_animatable_iface_init (ClutterAnimatableIface *iface);
@ -1009,6 +1128,22 @@ clutter_text_position_to_coords (ClutterText *self,
return TRUE;
}
static inline void
update_cursor_location (ClutterText *self)
{
ClutterTextPrivate *priv = self->priv;
ClutterRect rect;
float x, y;
if (!priv->editable)
return;
rect = priv->cursor_rect;
clutter_actor_get_transformed_position (CLUTTER_ACTOR (self), &x, &y);
clutter_rect_offset (&rect, x, y);
clutter_input_focus_set_cursor_location (priv->input_focus, &rect);
}
static inline void
clutter_text_ensure_cursor_position (ClutterText *self)
{
@ -1057,6 +1192,8 @@ clutter_text_ensure_cursor_position (ClutterText *self)
g_signal_emit (self, text_signals[CURSOR_EVENT], 0, &cursor_pos);
g_signal_emit (self, text_signals[CURSOR_CHANGED], 0);
update_cursor_location (self);
}
}
@ -1503,6 +1640,8 @@ clutter_text_finalize (GObject *gobject)
clutter_text_set_buffer (self, NULL);
g_free (priv->font_name);
g_clear_object (&priv->input_focus);
G_OBJECT_CLASS (clutter_text_parent_class)->finalize (gobject);
}
@ -1643,7 +1782,7 @@ selection_paint (ClutterText *self)
CoglColor cogl_color = { 0, };
CoglFramebuffer *fb;
fb = _clutter_actor_get_active_framebuffer (actor);
fb = cogl_get_draw_framebuffer ();
if (G_UNLIKELY (fb == NULL))
return;
@ -1859,6 +1998,7 @@ clutter_text_press (ClutterActor *actor,
return CLUTTER_EVENT_PROPAGATE;
clutter_actor_grab_key_focus (actor);
clutter_input_focus_request_toggle_input_panel (priv->input_focus);
/* if the actor is empty we just reset everything and not
* set up the dragging of the selection since there's nothing
@ -2084,10 +2224,17 @@ clutter_text_key_press (ClutterActor *actor,
pool = clutter_binding_pool_find (g_type_name (CLUTTER_TYPE_TEXT));
g_assert (pool != NULL);
if (!(event->flags & CLUTTER_EVENT_FLAG_INPUT_METHOD) &&
clutter_input_focus_is_focused (priv->input_focus) &&
clutter_input_focus_filter_key_event (priv->input_focus, event))
return CLUTTER_EVENT_STOP;
/* we allow passing synthetic events that only contain
* the Unicode value and not the key symbol
* the Unicode value and not the key symbol, unless they
* contain the input method flag.
*/
if (event->keyval == 0 && (event->flags & CLUTTER_EVENT_FLAG_SYNTHETIC))
if (event->keyval == 0 && (event->flags & CLUTTER_EVENT_FLAG_SYNTHETIC) &&
!(event->flags & CLUTTER_EVENT_FLAG_INPUT_METHOD))
res = FALSE;
else
res = clutter_binding_pool_activate (pool, event->keyval,
@ -2141,6 +2288,20 @@ clutter_text_key_press (ClutterActor *actor,
return CLUTTER_EVENT_PROPAGATE;
}
static gboolean
clutter_text_key_release (ClutterActor *actor,
ClutterKeyEvent *event)
{
ClutterText *self = CLUTTER_TEXT (actor);
ClutterTextPrivate *priv = self->priv;
if (clutter_input_focus_is_focused (priv->input_focus) &&
clutter_input_focus_filter_key_event (priv->input_focus, event))
return CLUTTER_EVENT_STOP;
return CLUTTER_EVENT_PROPAGATE;
}
static void
clutter_text_compute_layout_offsets (ClutterText *self,
PangoLayout *layout,
@ -2230,13 +2391,7 @@ clutter_text_paint (ClutterActor *self)
float alloc_width;
float alloc_height;
/* FIXME: this should not be needed, but apparently the text-cache
* test unit manages to get in a situation where the active frame
* buffer is NULL
*/
fb = _clutter_actor_get_active_framebuffer (self);
if (fb == NULL)
fb = cogl_get_draw_framebuffer ();
fb = cogl_get_draw_framebuffer ();
/* Note that if anything in this paint method changes it needs to be
reflected in the get_paint_volume implementation which is tightly
@ -2659,11 +2814,33 @@ clutter_text_has_overlaps (ClutterActor *self)
return clutter_text_should_draw_cursor ((ClutterText *) self);
}
static void
clutter_text_im_focus (ClutterText *text)
{
ClutterTextPrivate *priv = text->priv;
ClutterBackend *backend = clutter_get_default_backend ();
ClutterInputMethod *method = clutter_backend_get_input_method (backend);
if (!method)
return;
clutter_input_method_focus_in (method, priv->input_focus);
clutter_input_focus_set_content_purpose (priv->input_focus,
priv->input_purpose);
clutter_input_focus_set_content_hints (priv->input_focus,
priv->input_hints);
clutter_input_focus_set_can_show_preedit (priv->input_focus, TRUE);
update_cursor_location (text);
}
static void
clutter_text_key_focus_in (ClutterActor *actor)
{
ClutterTextPrivate *priv = CLUTTER_TEXT (actor)->priv;
if (priv->editable)
clutter_text_im_focus (CLUTTER_TEXT (actor));
priv->has_focus = TRUE;
clutter_text_queue_redraw (actor);
@ -2673,9 +2850,17 @@ static void
clutter_text_key_focus_out (ClutterActor *actor)
{
ClutterTextPrivate *priv = CLUTTER_TEXT (actor)->priv;
ClutterBackend *backend = clutter_get_default_backend ();
ClutterInputMethod *method = clutter_backend_get_input_method (backend);
priv->has_focus = FALSE;
if (priv->editable && clutter_input_focus_is_focused (priv->input_focus))
{
clutter_text_set_preedit_string (CLUTTER_TEXT (actor), NULL, NULL, 0);
clutter_input_method_focus_out (method);
}
clutter_text_queue_redraw (actor);
}
@ -3369,6 +3554,7 @@ clutter_text_class_init (ClutterTextClass *klass)
actor_class->get_preferred_height = clutter_text_get_preferred_height;
actor_class->allocate = clutter_text_allocate;
actor_class->key_press_event = clutter_text_key_press;
actor_class->key_release_event = clutter_text_key_release;
actor_class->button_press_event = clutter_text_button_press;
actor_class->button_release_event = clutter_text_button_release;
actor_class->motion_event = clutter_text_motion;
@ -3869,6 +4055,22 @@ clutter_text_class_init (ClutterTextClass *klass)
obj_props[PROP_SELECTED_TEXT_COLOR_SET] = pspec;
g_object_class_install_property (gobject_class, PROP_SELECTED_TEXT_COLOR_SET, pspec);
pspec = g_param_spec_flags ("input-hints",
P_("Input hints"),
P_("Input hints"),
CLUTTER_TYPE_INPUT_CONTENT_HINT_FLAGS,
0, CLUTTER_PARAM_READWRITE);
obj_props[PROP_INPUT_HINTS] = pspec;
g_object_class_install_property (gobject_class, PROP_INPUT_HINTS, pspec);
pspec = g_param_spec_enum ("input-purpose",
P_("Input purpose"),
P_("Input purpose"),
CLUTTER_TYPE_INPUT_CONTENT_PURPOSE,
0, CLUTTER_PARAM_READWRITE);
obj_props[PROP_INPUT_PURPOSE] = pspec;
g_object_class_install_property (gobject_class, PROP_INPUT_PURPOSE, pspec);
/**
* ClutterText::text-changed:
* @self: the #ClutterText that emitted the signal
@ -4169,6 +4371,8 @@ clutter_text_init (ClutterText *self)
g_signal_connect (self, "notify::text-direction",
G_CALLBACK (clutter_text_direction_changed_cb),
NULL);
priv->input_focus = clutter_text_input_focus_new (self);
}
/**
@ -4315,6 +4519,27 @@ buffer_deleted_text (ClutterTextBuffer *buffer,
}
}
static void
clutter_text_queue_redraw_or_relayout (ClutterText *self)
{
ClutterActor *actor = CLUTTER_ACTOR (self);
gfloat preferred_width;
gfloat preferred_height;
clutter_text_dirty_cache (self);
/* we're using our private implementations here to avoid the caching done by ClutterActor */
clutter_text_get_preferred_width (actor, -1, NULL, &preferred_width);
clutter_text_get_preferred_height (actor, preferred_width, NULL, &preferred_height);
if (clutter_actor_has_allocation (actor) &&
(fabsf (preferred_width - clutter_actor_get_width (actor)) > 0.001 ||
fabsf (preferred_height - clutter_actor_get_height (actor)) > 0.001))
clutter_actor_queue_relayout (actor);
else
clutter_text_queue_redraw (actor);
}
static void
buffer_notify_text (ClutterTextBuffer *buffer,
GParamSpec *spec,
@ -4322,9 +4547,7 @@ buffer_notify_text (ClutterTextBuffer *buffer,
{
g_object_freeze_notify (G_OBJECT (self));
clutter_text_dirty_cache (self);
clutter_actor_queue_relayout (CLUTTER_ACTOR (self));
clutter_text_queue_redraw_or_relayout (self);
g_signal_emit (self, text_signals[TEXT_CHANGED], 0);
g_object_notify_by_pspec (G_OBJECT (self), obj_props[PROP_TEXT]);
@ -4459,6 +4682,8 @@ void
clutter_text_set_editable (ClutterText *self,
gboolean editable)
{
ClutterBackend *backend = clutter_get_default_backend ();
ClutterInputMethod *method = clutter_backend_get_input_method (backend);
ClutterTextPrivate *priv;
g_return_if_fail (CLUTTER_IS_TEXT (self));
@ -4469,6 +4694,14 @@ clutter_text_set_editable (ClutterText *self,
{
priv->editable = editable;
if (method)
{
if (!priv->editable && clutter_input_focus_is_focused (priv->input_focus))
clutter_input_method_focus_out (method);
else if (priv->has_focus)
clutter_text_im_focus (self);
}
clutter_text_queue_redraw (CLUTTER_ACTOR (self));
g_object_notify_by_pspec (G_OBJECT (self), obj_props[PROP_EDITABLE]);
@ -4666,8 +4899,7 @@ clutter_text_set_cursor_visible (ClutterText *self,
{
priv->cursor_visible = cursor_visible;
clutter_text_dirty_cache (self);
clutter_actor_queue_relayout (CLUTTER_ACTOR (self));
clutter_text_queue_redraw_or_relayout (self);
g_object_notify_by_pspec (G_OBJECT (self), obj_props[PROP_CURSOR_VISIBLE]);
}
@ -5568,9 +5800,7 @@ clutter_text_set_line_alignment (ClutterText *self,
{
priv->alignment = alignment;
clutter_text_dirty_cache (self);
clutter_actor_queue_relayout (CLUTTER_ACTOR (self));
clutter_text_queue_redraw_or_relayout (self);
g_object_notify_by_pspec (G_OBJECT (self), obj_props[PROP_LINE_ALIGNMENT]);
}
@ -5625,9 +5855,7 @@ clutter_text_set_use_markup (ClutterText *self,
if (setting)
clutter_text_set_markup_internal (self, text);
clutter_text_dirty_cache (self);
clutter_actor_queue_relayout (CLUTTER_ACTOR (self));
clutter_text_queue_redraw_or_relayout (self);
}
/**
@ -5674,9 +5902,7 @@ clutter_text_set_justify (ClutterText *self,
{
priv->justify = justify;
clutter_text_dirty_cache (self);
clutter_actor_queue_relayout (CLUTTER_ACTOR (self));
clutter_text_queue_redraw_or_relayout (self);
g_object_notify_by_pspec (G_OBJECT (self), obj_props[PROP_JUSTIFY]);
}
@ -6243,8 +6469,7 @@ clutter_text_set_preedit_string (ClutterText *self,
priv->preedit_set = TRUE;
}
clutter_text_dirty_cache (self);
clutter_actor_queue_relayout (CLUTTER_ACTOR (self));
clutter_text_queue_redraw_or_relayout (self);
}
@ -6298,3 +6523,53 @@ clutter_text_get_cursor_rect (ClutterText *self,
*rect = self->priv->cursor_rect;
}
void
clutter_text_set_input_hints (ClutterText *self,
ClutterInputContentHintFlags hints)
{
g_return_if_fail (CLUTTER_IS_TEXT (self));
self->priv->input_hints = hints;
if (clutter_input_focus_is_focused (self->priv->input_focus))
clutter_input_focus_set_content_hints (self->priv->input_focus, hints);
g_object_notify_by_pspec (G_OBJECT (self), obj_props[PROP_INPUT_HINTS]);
}
ClutterInputContentHintFlags
clutter_text_get_input_hints (ClutterText *self)
{
g_return_val_if_fail (CLUTTER_IS_TEXT (self), 0);
return self->priv->input_hints;
}
void
clutter_text_set_input_purpose (ClutterText *self,
ClutterInputContentPurpose purpose)
{
g_return_if_fail (CLUTTER_IS_TEXT (self));
self->priv->input_purpose = purpose;
if (clutter_input_focus_is_focused (self->priv->input_focus))
clutter_input_focus_set_content_purpose (self->priv->input_focus, purpose);
g_object_notify_by_pspec (G_OBJECT (self), obj_props[PROP_INPUT_PURPOSE]);
}
ClutterInputContentPurpose
clutter_text_get_input_purpose (ClutterText *self)
{
g_return_val_if_fail (CLUTTER_IS_TEXT (self), 0);
return self->priv->input_purpose;
}
gboolean
clutter_text_has_preedit (ClutterText *self)
{
g_return_val_if_fail (CLUTTER_IS_TEXT (self), FALSE);
return self->priv->preedit_set;
}

View File

@ -302,6 +302,20 @@ void clutter_text_get_layout_offsets (ClutterText *
gint *x,
gint *y);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_text_set_input_hints (ClutterText *self,
ClutterInputContentHintFlags hints);
CLUTTER_AVAILABLE_IN_MUTTER
void clutter_text_set_input_purpose (ClutterText *self,
ClutterInputContentPurpose purpose);
CLUTTER_AVAILABLE_IN_MUTTER
ClutterInputContentHintFlags clutter_text_get_input_hints (ClutterText *self);
CLUTTER_AVAILABLE_IN_MUTTER
ClutterInputContentPurpose clutter_text_get_input_purpose (ClutterText *self);
CLUTTER_AVAILABLE_IN_MUTTER
gboolean clutter_text_has_preedit (ClutterText *self);
G_END_DECLS
#endif /* __CLUTTER_TEXT_H__ */

View File

@ -97,6 +97,9 @@ typedef struct _ClutterInputDeviceTool ClutterInputDeviceTool;
typedef struct _ClutterInputDevice ClutterInputDevice;
typedef struct _ClutterVirtualInputDevice ClutterVirtualInputDevice;
typedef struct _ClutterInputMethod ClutterInputMethod;
typedef struct _ClutterInputFocus ClutterInputFocus;
typedef CoglMatrix ClutterMatrix;
typedef union _ClutterEvent ClutterEvent;

View File

@ -115,6 +115,74 @@ clutter_virtual_input_device_notify_keyval (ClutterVirtualInputDevice *virtual_d
klass->notify_keyval (virtual_device, time_us, keyval, key_state);
}
void
clutter_virtual_input_device_notify_discrete_scroll (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
ClutterScrollDirection direction,
ClutterScrollSource scroll_source)
{
ClutterVirtualInputDeviceClass *klass =
CLUTTER_VIRTUAL_INPUT_DEVICE_GET_CLASS (virtual_device);
klass->notify_discrete_scroll (virtual_device, time_us,
direction, scroll_source);
}
void
clutter_virtual_input_device_notify_scroll_continuous (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
double dx,
double dy,
ClutterScrollSource scroll_source,
ClutterScrollFinishFlags finish_flags)
{
ClutterVirtualInputDeviceClass *klass =
CLUTTER_VIRTUAL_INPUT_DEVICE_GET_CLASS (virtual_device);
klass->notify_scroll_continuous (virtual_device, time_us,
dx, dy, scroll_source, finish_flags);
}
void
clutter_virtual_input_device_notify_touch_down (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int slot,
double x,
double y)
{
ClutterVirtualInputDeviceClass *klass =
CLUTTER_VIRTUAL_INPUT_DEVICE_GET_CLASS (virtual_device);
klass->notify_touch_down (virtual_device, time_us,
slot, x, y);
}
void
clutter_virtual_input_device_notify_touch_motion (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int slot,
double x,
double y)
{
ClutterVirtualInputDeviceClass *klass =
CLUTTER_VIRTUAL_INPUT_DEVICE_GET_CLASS (virtual_device);
klass->notify_touch_motion (virtual_device, time_us,
slot, x, y);
}
void
clutter_virtual_input_device_notify_touch_up (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int slot)
{
ClutterVirtualInputDeviceClass *klass =
CLUTTER_VIRTUAL_INPUT_DEVICE_GET_CLASS (virtual_device);
klass->notify_touch_up (virtual_device, time_us,
slot);
}
/**
* clutter_virtual_input_device_get_manager:
* @virtual_device: a virtual device

View File

@ -76,6 +76,34 @@ struct _ClutterVirtualInputDeviceClass
uint64_t time_us,
uint32_t keyval,
ClutterKeyState key_state);
void (*notify_discrete_scroll) (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
ClutterScrollDirection direction,
ClutterScrollSource scroll_source);
void (*notify_scroll_continuous) (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
double dx,
double dy,
ClutterScrollSource scroll_source,
ClutterScrollFinishFlags finish_flags);
void (*notify_touch_down) (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int slot,
double x,
double y);
void (*notify_touch_motion) (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int slot,
double x,
double y);
void (*notify_touch_up) (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int slot);
};
CLUTTER_AVAILABLE_IN_ALL
@ -108,6 +136,39 @@ void clutter_virtual_input_device_notify_keyval (ClutterVirtualInputDevice *virt
uint32_t keyval,
ClutterKeyState key_state);
CLUTTER_AVAILABLE_IN_ALL
void clutter_virtual_input_device_notify_discrete_scroll (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
ClutterScrollDirection direction,
ClutterScrollSource scroll_source);
CLUTTER_AVAILABLE_IN_ALL
void clutter_virtual_input_device_notify_scroll_continuous (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
double dx,
double dy,
ClutterScrollSource scroll_source,
ClutterScrollFinishFlags finish_flags);
CLUTTER_AVAILABLE_IN_ALL
void clutter_virtual_input_device_notify_touch_down (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int slot,
double x,
double y);
CLUTTER_AVAILABLE_IN_ALL
void clutter_virtual_input_device_notify_touch_motion (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int slot,
double x,
double y);
CLUTTER_AVAILABLE_IN_ALL
void clutter_virtual_input_device_notify_touch_up (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int slot);
CLUTTER_AVAILABLE_IN_ALL
ClutterDeviceManager * clutter_virtual_input_device_get_manager (ClutterVirtualInputDevice *virtual_device);

View File

@ -72,6 +72,8 @@
#include "clutter-image.h"
#include "clutter-input-device.h"
#include "clutter-input-device-tool.h"
#include "clutter-input-method.h"
#include "clutter-input-focus.h"
#include "clutter-interval.h"
#include "clutter-keyframe-transition.h"
#include "clutter-keysyms.h"

View File

@ -51,7 +51,9 @@
typedef struct _ClutterStageViewCoglPrivate
{
/* Stores a list of previous damaged areas in the stage coordinate space */
/*
* List of previous damaged areas in stage view framebuffer coordinate space.
*/
#define DAMAGE_HISTORY_MAX 16
#define DAMAGE_HISTORY(x) ((x) & (DAMAGE_HISTORY_MAX - 1))
cairo_rectangle_int_t damage_history[DAMAGE_HISTORY_MAX];
@ -435,13 +437,20 @@ fill_current_damage_history_and_step (ClutterStageView *view)
ClutterStageViewCoglPrivate *view_priv =
clutter_stage_view_cogl_get_instance_private (view_cogl);
cairo_rectangle_int_t view_rect;
cairo_rectangle_int_t *current_damage;
float fb_scale;
cairo_rectangle_int_t *current_fb_damage;
current_damage =
current_fb_damage =
&view_priv->damage_history[DAMAGE_HISTORY (view_priv->damage_index)];
clutter_stage_view_get_layout (view, &view_rect);
fb_scale = clutter_stage_view_get_scale (view);
*current_damage = view_rect;
*current_fb_damage = (cairo_rectangle_int_t) {
.x = 0,
.y = 0,
.width = view_rect.width * fb_scale,
.height = view_rect.height * fb_scale
};
view_priv->damage_index++;
}
@ -481,6 +490,40 @@ transform_swap_region_to_onscreen (ClutterStageView *view,
};
}
static void
calculate_scissor_region (cairo_rectangle_int_t *fb_clip_region,
int subpixel_compensation,
int fb_width,
int fb_height,
cairo_rectangle_int_t *out_scissor_rect)
{
int scissor_x;
int scissor_y;
int scissor_width;
int scissor_height;
scissor_x = fb_clip_region->x;
scissor_y = fb_clip_region->y;
scissor_width = fb_clip_region->width;
scissor_height = fb_clip_region->height;
if (fb_clip_region->x > 0)
scissor_x += subpixel_compensation;
if (fb_clip_region->y > 0)
scissor_y += subpixel_compensation;
if (fb_clip_region->x + fb_clip_region->width < fb_width)
scissor_width -= 2 * subpixel_compensation;
if (fb_clip_region->y + fb_clip_region->height < fb_height)
scissor_height -= 2 * subpixel_compensation;
*out_scissor_rect = (cairo_rectangle_int_t) {
.x = scissor_x,
.y = scissor_y,
.width = scissor_width,
.height = scissor_height
};
}
static gboolean
clutter_stage_cogl_redraw_view (ClutterStageWindow *stage_window,
ClutterStageView *view)
@ -501,13 +544,18 @@ clutter_stage_cogl_redraw_view (ClutterStageWindow *stage_window,
ClutterActor *wrapper;
cairo_rectangle_int_t redraw_clip;
cairo_rectangle_int_t swap_region;
cairo_rectangle_int_t clip_region;
cairo_rectangle_int_t fb_clip_region;
gboolean clip_region_empty;
int fb_scale;
float fb_scale;
int subpixel_compensation = 0;
int fb_width, fb_height;
wrapper = CLUTTER_ACTOR (stage_cogl->wrapper);
clutter_stage_view_get_layout (view, &view_rect);
fb_scale = clutter_stage_view_get_scale (view);
fb_width = cogl_framebuffer_get_width (fb);
fb_height = cogl_framebuffer_get_height (fb);
can_blit_sub_buffer =
cogl_is_onscreen (fb) &&
@ -542,11 +590,24 @@ clutter_stage_cogl_redraw_view (ClutterStageWindow *stage_window,
cogl_onscreen_get_frame_counter (COGL_ONSCREEN (fb)) > 3)
{
may_use_clipped_redraw = TRUE;
clip_region = redraw_clip;
if (fb_scale != floorf (fb_scale))
subpixel_compensation = ceilf (fb_scale);
fb_clip_region = (cairo_rectangle_int_t) {
.x = (floorf ((redraw_clip.x - view_rect.x) * fb_scale) -
subpixel_compensation),
.y = (floorf ((redraw_clip.y - view_rect.y) * fb_scale) -
subpixel_compensation),
.width = (ceilf (redraw_clip.width * fb_scale) +
(2 * subpixel_compensation)),
.height = (ceilf (redraw_clip.height * fb_scale) +
(2 * subpixel_compensation))
};
}
else
{
clip_region = (cairo_rectangle_int_t){ 0 };
fb_clip_region = (cairo_rectangle_int_t) { 0 };
}
if (may_use_clipped_redraw &&
@ -555,9 +616,7 @@ clutter_stage_cogl_redraw_view (ClutterStageWindow *stage_window,
else
use_clipped_redraw = FALSE;
clip_region_empty = may_use_clipped_redraw && clip_region.width == 0;
fb_scale = clutter_stage_view_get_scale (view);
clip_region_empty = may_use_clipped_redraw && fb_clip_region.width == 0;
swap_with_damage = FALSE;
if (has_buffer_age)
@ -565,34 +624,44 @@ clutter_stage_cogl_redraw_view (ClutterStageWindow *stage_window,
if (use_clipped_redraw && !clip_region_empty)
{
int age, i;
cairo_rectangle_int_t *current_damage =
cairo_rectangle_int_t *current_fb_damage =
&view_priv->damage_history[DAMAGE_HISTORY (view_priv->damage_index++)];
age = cogl_onscreen_get_buffer_age (COGL_ONSCREEN (fb));
if (valid_buffer_age (view_cogl, age))
{
*current_damage = clip_region;
cairo_rectangle_int_t damage_region;
*current_fb_damage = fb_clip_region;
for (i = 1; i <= age; i++)
{
cairo_rectangle_int_t *damage =
cairo_rectangle_int_t *fb_damage =
&view_priv->damage_history[DAMAGE_HISTORY (view_priv->damage_index - i - 1)];
_clutter_util_rectangle_union (&clip_region, damage, &clip_region);
_clutter_util_rectangle_union (&fb_clip_region,
fb_damage,
&fb_clip_region);
}
/* Update the bounding redraw clip state with the extra damage. */
damage_region = (cairo_rectangle_int_t) {
.x = view_rect.x + floorf (fb_clip_region.x / fb_scale),
.y = view_rect.y + floorf (fb_clip_region.y / fb_scale),
.width = ceilf (fb_clip_region.width / fb_scale),
.height = ceilf (fb_clip_region.height / fb_scale)
};
_clutter_util_rectangle_union (&stage_cogl->bounding_redraw_clip,
&clip_region,
&damage_region,
&stage_cogl->bounding_redraw_clip);
CLUTTER_NOTE (CLIPPING, "Reusing back buffer(age=%d) - repairing region: x=%d, y=%d, width=%d, height=%d\n",
age,
clip_region.x,
clip_region.y,
clip_region.width,
clip_region.height);
fb_clip_region.x,
fb_clip_region.y,
fb_clip_region.width,
fb_clip_region.height);
swap_with_damage = TRUE;
}
@ -600,7 +669,12 @@ clutter_stage_cogl_redraw_view (ClutterStageWindow *stage_window,
{
CLUTTER_NOTE (CLIPPING, "Invalid back buffer(age=%d): forcing full redraw\n", age);
use_clipped_redraw = FALSE;
*current_damage = view_rect;
*current_fb_damage = (cairo_rectangle_int_t) {
.x = 0,
.y = 0,
.width = view_rect.width * fb_scale,
.height = view_rect.height * fb_scale
};
}
}
else if (!use_clipped_redraw)
@ -616,26 +690,34 @@ clutter_stage_cogl_redraw_view (ClutterStageWindow *stage_window,
}
else if (use_clipped_redraw)
{
int scissor_x;
int scissor_y;
cairo_rectangle_int_t scissor_rect;
calculate_scissor_region (&fb_clip_region,
subpixel_compensation,
fb_width, fb_height,
&scissor_rect);
CLUTTER_NOTE (CLIPPING,
"Stage clip pushed: x=%d, y=%d, width=%d, height=%d\n",
clip_region.x,
clip_region.y,
clip_region.width,
clip_region.height);
scissor_rect.x,
scissor_rect.y,
scissor_rect.width,
scissor_rect.height);
stage_cogl->using_clipped_redraw = TRUE;
scissor_x = (clip_region.x - view_rect.x) * fb_scale;
scissor_y = (clip_region.y - view_rect.y) * fb_scale;
cogl_framebuffer_push_scissor_clip (fb,
scissor_x,
scissor_y,
clip_region.width * fb_scale,
clip_region.height * fb_scale);
paint_stage (stage_cogl, view, &clip_region);
scissor_rect.x,
scissor_rect.y,
scissor_rect.width,
scissor_rect.height);
paint_stage (stage_cogl, view,
&(cairo_rectangle_int_t) {
.x = view_rect.x + floorf ((fb_clip_region.x - 0) / fb_scale),
.y = view_rect.y + floorf ((fb_clip_region.y - 0) / fb_scale),
.width = ceilf ((fb_clip_region.width + 0) / fb_scale),
.height = ceilf ((fb_clip_region.height + 0) / fb_scale)
});
cogl_framebuffer_pop_clip (fb);
stage_cogl->using_clipped_redraw = FALSE;
@ -650,17 +732,25 @@ clutter_stage_cogl_redraw_view (ClutterStageWindow *stage_window,
may_use_clipped_redraw &&
!clip_region_empty)
{
int scissor_x;
int scissor_y;
cairo_rectangle_int_t scissor_rect;
calculate_scissor_region (&fb_clip_region,
subpixel_compensation,
fb_width, fb_height,
&scissor_rect);
scissor_x = (clip_region.x - view_rect.x) * fb_scale;;
scissor_y = (clip_region.y - view_rect.y) * fb_scale;
cogl_framebuffer_push_scissor_clip (fb,
scissor_x,
scissor_y,
clip_region.width * fb_scale,
clip_region.height * fb_scale);
paint_stage (stage_cogl, view, &clip_region);
scissor_rect.x,
scissor_rect.y,
scissor_rect.width,
scissor_rect.height);
paint_stage (stage_cogl, view,
&(cairo_rectangle_int_t) {
.x = view_rect.x + floorf (fb_clip_region.x / fb_scale),
.y = view_rect.y + floorf (fb_clip_region.y / fb_scale),
.width = ceilf (fb_clip_region.width / fb_scale),
.height = ceilf (fb_clip_region.height / fb_scale)
});
cogl_framebuffer_pop_clip (fb);
}
else
@ -723,12 +813,7 @@ clutter_stage_cogl_redraw_view (ClutterStageWindow *stage_window,
}
else if (use_clipped_redraw)
{
swap_region = (cairo_rectangle_int_t) {
.x = (clip_region.x - view_rect.x) * fb_scale,
.y = (clip_region.y - view_rect.y) * fb_scale,
.width = clip_region.width * fb_scale,
.height = clip_region.height * fb_scale,
};
swap_region = fb_clip_region;
g_assert (swap_region.width > 0);
do_swap_buffer = TRUE;
}
@ -810,9 +895,25 @@ clutter_stage_cogl_get_dirty_pixel (ClutterStageWindow *stage_window,
gboolean has_buffer_age =
cogl_is_onscreen (framebuffer) &&
cogl_clutter_winsys_has_feature (COGL_WINSYS_FEATURE_BUFFER_AGE);
cairo_rectangle_int_t *rect;
float fb_scale;
gboolean scale_is_fractional;
if (!has_buffer_age)
fb_scale = clutter_stage_view_get_scale (view);
if (fb_scale != floorf (fb_scale))
scale_is_fractional = TRUE;
else
scale_is_fractional = FALSE;
/*
* Buffer damage is tracked in the framebuffer coordinate space
* using the damage history. When fractional scaling is used, a
* coordinate on the stage might not correspond to the exact position of any
* physical pixel, which causes issues when painting using the pick mode.
*
* For now, always use the (0, 0) pixel for picking when using fractional
* framebuffer scaling.
*/
if (!has_buffer_age || scale_is_fractional)
{
*x = 0;
*y = 0;
@ -823,12 +924,13 @@ clutter_stage_cogl_get_dirty_pixel (ClutterStageWindow *stage_window,
ClutterStageViewCoglPrivate *view_priv =
clutter_stage_view_cogl_get_instance_private (view_cogl);
cairo_rectangle_int_t view_layout;
cairo_rectangle_int_t *fb_damage;
clutter_stage_view_get_layout (view, &view_layout);
rect = &view_priv->damage_history[DAMAGE_HISTORY (view_priv->damage_index - 1)];
*x = rect->x - view_layout.x;
*y = rect->y - view_layout.y;
fb_damage = &view_priv->damage_history[DAMAGE_HISTORY (view_priv->damage_index - 1)];
*x = fb_damage->x / fb_scale;
*y = fb_damage->y / fb_scale;
}
}

View File

@ -48,6 +48,7 @@
#include "clutter-private.h"
#include "clutter-main.h"
#include "clutter-stage-private.h"
#include "clutter-settings-private.h"
#ifdef COGL_HAS_EGL_SUPPORT
#include "clutter-egl.h"
@ -60,6 +61,8 @@ clutter_backend_egl_native_dispose (GObject *gobject)
{
ClutterBackendEglNative *backend_egl_native = CLUTTER_BACKEND_EGL_NATIVE (gobject);
g_clear_object (&backend_egl_native->xsettings);
if (backend_egl_native->event_timer != NULL)
{
g_timer_destroy (backend_egl_native->event_timer);
@ -77,9 +80,181 @@ clutter_backend_egl_native_class_init (ClutterBackendEglNativeClass *klass)
gobject_class->dispose = clutter_backend_egl_native_dispose;
}
typedef struct
{
cairo_antialias_t cairo_antialias;
gint clutter_font_antialias;
cairo_hint_style_t cairo_hint_style;
const char *clutter_font_hint_style;
cairo_subpixel_order_t cairo_subpixel_order;
const char *clutter_font_subpixel_order;
} FontSettings;
static void
get_font_gsettings (GSettings *xsettings,
FontSettings *output)
{
/* org.gnome.settings-daemon.GsdFontAntialiasingMode */
static const struct
{
cairo_antialias_t cairo_antialias;
gint clutter_font_antialias;
}
antialiasings[] =
{
/* none=0 */ {CAIRO_ANTIALIAS_NONE, 0},
/* grayscale=1 */ {CAIRO_ANTIALIAS_GRAY, 1},
/* rgba=2 */ {CAIRO_ANTIALIAS_SUBPIXEL, 1},
};
/* org.gnome.settings-daemon.GsdFontHinting */
static const struct
{
cairo_hint_style_t cairo_hint_style;
const char *clutter_font_hint_style;
}
hintings[] =
{
/* none=0 */ {CAIRO_HINT_STYLE_NONE, "hintnone"},
/* slight=1 */ {CAIRO_HINT_STYLE_SLIGHT, "hintslight"},
/* medium=2 */ {CAIRO_HINT_STYLE_MEDIUM, "hintmedium"},
/* full=3 */ {CAIRO_HINT_STYLE_FULL, "hintfull"},
};
/* org.gnome.settings-daemon.GsdFontRgbaOrder */
static const struct
{
cairo_subpixel_order_t cairo_subpixel_order;
const char *clutter_font_subpixel_order;
}
rgba_orders[] =
{
/* rgba=0 */ {CAIRO_SUBPIXEL_ORDER_RGB, "rgb"}, /* XXX what is 'rgba'? */
/* rgb=1 */ {CAIRO_SUBPIXEL_ORDER_RGB, "rgb"},
/* bgr=2 */ {CAIRO_SUBPIXEL_ORDER_BGR, "bgr"},
/* vrgb=3 */ {CAIRO_SUBPIXEL_ORDER_VRGB, "vrgb"},
/* vbgr=4 */ {CAIRO_SUBPIXEL_ORDER_VBGR, "vbgr"},
};
guint i;
i = g_settings_get_enum (xsettings, "hinting");
if (i < G_N_ELEMENTS (hintings))
{
output->cairo_hint_style = hintings[i].cairo_hint_style;
output->clutter_font_hint_style = hintings[i].clutter_font_hint_style;
}
else
{
output->cairo_hint_style = CAIRO_HINT_STYLE_DEFAULT;
output->clutter_font_hint_style = NULL;
}
i = g_settings_get_enum (xsettings, "antialiasing");
if (i < G_N_ELEMENTS (antialiasings))
{
output->cairo_antialias = antialiasings[i].cairo_antialias;
output->clutter_font_antialias = antialiasings[i].clutter_font_antialias;
}
else
{
output->cairo_antialias = CAIRO_ANTIALIAS_DEFAULT;
output->clutter_font_antialias = -1;
}
i = g_settings_get_enum (xsettings, "rgba-order");
if (i < G_N_ELEMENTS (rgba_orders))
{
output->cairo_subpixel_order = rgba_orders[i].cairo_subpixel_order;
output->clutter_font_subpixel_order = rgba_orders[i].clutter_font_subpixel_order;
}
else
{
output->cairo_subpixel_order = CAIRO_SUBPIXEL_ORDER_DEFAULT;
output->clutter_font_subpixel_order = NULL;
}
if (output->cairo_antialias == CAIRO_ANTIALIAS_GRAY)
output->clutter_font_subpixel_order = "none";
}
static void
init_font_options (ClutterBackendEglNative *backend_egl_native)
{
GSettings *xsettings = backend_egl_native->xsettings;
cairo_font_options_t *options = cairo_font_options_create ();
FontSettings fs;
get_font_gsettings (xsettings, &fs);
cairo_font_options_set_hint_style (options, fs.cairo_hint_style);
cairo_font_options_set_antialias (options, fs.cairo_antialias);
cairo_font_options_set_subpixel_order (options, fs.cairo_subpixel_order);
clutter_backend_set_font_options (CLUTTER_BACKEND (backend_egl_native),
options);
cairo_font_options_destroy (options);
}
static gboolean
on_xsettings_change_event (GSettings *xsettings,
gpointer keys,
gint n_keys,
gpointer user_data)
{
/*
* A simpler alternative to this function that does not update the screen
* immediately (like macOS :P):
*
* init_font_options (CLUTTER_BACKEND_EGL_NATIVE (user_data));
*
* which has the added benefit of eliminating the need for all the
* FontSettings.clutter_ fields. However the below approach is better for
* testing settings and more consistent with the existing x11 backend...
*/
ClutterSettings *csettings = clutter_settings_get_default ();
FontSettings fs;
gint hinting;
get_font_gsettings (xsettings, &fs);
hinting = fs.cairo_hint_style == CAIRO_HINT_STYLE_NONE ? 0 : 1;
g_object_set (csettings,
"font-hinting", hinting,
"font-hint-style", fs.clutter_font_hint_style,
"font-antialias", fs.clutter_font_antialias,
"font-subpixel-order", fs.clutter_font_subpixel_order,
NULL);
return FALSE;
}
static void
clutter_backend_egl_native_init (ClutterBackendEglNative *backend_egl_native)
{
static const gchar xsettings_path[] = "org.gnome.settings-daemon.plugins.xsettings";
GSettingsSchemaSource *source = g_settings_schema_source_get_default ();
GSettingsSchema *schema = g_settings_schema_source_lookup (source,
xsettings_path,
FALSE);
if (!schema)
{
g_warning ("Failed to find schema: %s", xsettings_path);
}
else
{
backend_egl_native->xsettings = g_settings_new_full (schema, NULL, NULL);
if (backend_egl_native->xsettings)
{
init_font_options (backend_egl_native);
g_signal_connect (backend_egl_native->xsettings, "change-event",
G_CALLBACK (on_xsettings_change_event),
backend_egl_native);
}
}
backend_egl_native->event_timer = g_timer_new ();
}

View File

@ -61,6 +61,9 @@ struct _ClutterBackendEglNative
/* event timer */
GTimer *event_timer;
/* "xsettings" is still the defacto place for Xft settings, even in Wayland */
GSettings *xsettings;
};
struct _ClutterBackendEglNativeClass

View File

@ -59,9 +59,6 @@
#include "clutter-device-manager-evdev.h"
#define DISCRETE_SCROLL_STEP 10.0
/*
* Clutter makes the assumption that two core devices have ID's 2 and 3 (core
* pointer and core keyboard).
@ -400,168 +397,6 @@ notify_relative_tool_motion (ClutterInputDevice *input_device,
queue_event (event);
}
static ClutterScrollDirection
discrete_to_direction (gdouble discrete_x,
gdouble discrete_y)
{
if (discrete_x > 0)
return CLUTTER_SCROLL_RIGHT;
else if (discrete_x < 0)
return CLUTTER_SCROLL_LEFT;
else if (discrete_y > 0)
return CLUTTER_SCROLL_DOWN;
else if (discrete_y < 0)
return CLUTTER_SCROLL_UP;
else
return CLUTTER_SCROLL_SMOOTH;
}
static void
notify_discrete_scroll (ClutterInputDevice *input_device,
guint64 time_us,
ClutterScrollDirection direction,
ClutterScrollSource scroll_source,
gboolean emulated)
{
ClutterInputDeviceEvdev *device_evdev;
ClutterSeatEvdev *seat;
ClutterStage *stage;
ClutterEvent *event = NULL;
if (direction == CLUTTER_SCROLL_SMOOTH)
return;
/* We can drop the event on the floor if no stage has been
* associated with the device yet. */
stage = _clutter_input_device_get_stage (input_device);
if (stage == NULL)
return;
device_evdev = CLUTTER_INPUT_DEVICE_EVDEV (input_device);
seat = _clutter_input_device_evdev_get_seat (device_evdev);
event = clutter_event_new (CLUTTER_SCROLL);
_clutter_evdev_event_set_time_usec (event, time_us);
event->scroll.time = us2ms (time_us);
event->scroll.stage = CLUTTER_STAGE (stage);
event->scroll.device = seat->core_pointer;
_clutter_xkb_translate_state (event, seat->xkb, seat->button_state);
event->scroll.direction = direction;
event->scroll.x = seat->pointer_x;
event->scroll.y = seat->pointer_y;
clutter_event_set_device (event, seat->core_pointer);
clutter_event_set_source_device (event, input_device);
event->scroll.scroll_source = scroll_source;
_clutter_event_set_pointer_emulated (event, emulated);
queue_event (event);
}
static void
notify_scroll (ClutterInputDevice *input_device,
guint64 time_us,
gdouble dx,
gdouble dy,
ClutterScrollSource source,
ClutterScrollFinishFlags flags,
gboolean emulated)
{
ClutterInputDeviceEvdev *device_evdev;
ClutterSeatEvdev *seat;
ClutterStage *stage;
ClutterEvent *event = NULL;
gdouble scroll_factor;
/* We can drop the event on the floor if no stage has been
* associated with the device yet. */
stage = _clutter_input_device_get_stage (input_device);
if (stage == NULL)
return;
device_evdev = CLUTTER_INPUT_DEVICE_EVDEV (input_device);
seat = _clutter_input_device_evdev_get_seat (device_evdev);
event = clutter_event_new (CLUTTER_SCROLL);
_clutter_evdev_event_set_time_usec (event, time_us);
event->scroll.time = us2ms (time_us);
event->scroll.stage = CLUTTER_STAGE (stage);
event->scroll.device = seat->core_pointer;
_clutter_xkb_translate_state (event, seat->xkb, seat->button_state);
/* libinput pointer axis events are in pointer motion coordinate space.
* To convert to Xi2 discrete step coordinate space, multiply the factor
* 1/10. */
event->scroll.direction = CLUTTER_SCROLL_SMOOTH;
scroll_factor = 1.0 / DISCRETE_SCROLL_STEP;
clutter_event_set_scroll_delta (event,
scroll_factor * dx,
scroll_factor * dy);
event->scroll.x = seat->pointer_x;
event->scroll.y = seat->pointer_y;
clutter_event_set_device (event, seat->core_pointer);
clutter_event_set_source_device (event, input_device);
event->scroll.scroll_source = source;
event->scroll.finish_flags = flags;
_clutter_event_set_pointer_emulated (event, emulated);
queue_event (event);
}
static void
notify_touch_event (ClutterInputDevice *input_device,
ClutterEventType evtype,
guint64 time_us,
gint32 slot,
gdouble x,
gdouble y)
{
ClutterInputDeviceEvdev *device_evdev;
ClutterSeatEvdev *seat;
ClutterStage *stage;
ClutterEvent *event = NULL;
/* We can drop the event on the floor if no stage has been
* associated with the device yet. */
stage = _clutter_input_device_get_stage (input_device);
if (stage == NULL)
return;
device_evdev = CLUTTER_INPUT_DEVICE_EVDEV (input_device);
seat = _clutter_input_device_evdev_get_seat (device_evdev);
event = clutter_event_new (evtype);
_clutter_evdev_event_set_time_usec (event, time_us);
event->touch.time = us2ms (time_us);
event->touch.stage = CLUTTER_STAGE (stage);
event->touch.device = seat->core_pointer;
event->touch.x = x;
event->touch.y = y;
clutter_input_device_evdev_translate_coordinates (input_device, stage,
&event->touch.x,
&event->touch.y);
/* "NULL" sequences are special cased in clutter */
event->touch.sequence = GINT_TO_POINTER (slot + 1);
_clutter_xkb_translate_state (event, seat->xkb, seat->button_state);
if (evtype == CLUTTER_TOUCH_BEGIN ||
evtype == CLUTTER_TOUCH_UPDATE)
event->touch.modifier_state |= CLUTTER_BUTTON1_MASK;
clutter_event_set_device (event, seat->core_pointer);
clutter_event_set_source_device (event, input_device);
queue_event (event);
}
static void
notify_pinch_gesture_event (ClutterInputDevice *input_device,
ClutterTouchpadGesturePhase phase,
@ -958,10 +793,12 @@ evdev_add_device (ClutterDeviceManagerEvdev *manager_evdev,
if (priv->main_seat->libinput_seat == NULL)
seat = priv->main_seat;
else
seat = clutter_seat_evdev_new (manager_evdev);
{
seat = clutter_seat_evdev_new (manager_evdev);
priv->seats = g_slist_append (priv->seats, seat);
}
clutter_seat_evdev_set_libinput_seat (seat, libinput_seat);
priv->seats = g_slist_append (priv->seats, seat);
}
device = _clutter_input_device_evdev_new (manager, seat, libinput_device);
@ -1084,7 +921,6 @@ clutter_device_manager_evdev_get_device (ClutterDeviceManager *manager,
ClutterDeviceManagerEvdev *manager_evdev;
ClutterDeviceManagerEvdevPrivate *priv;
GSList *l;
GSList *device_it;
manager_evdev = CLUTTER_DEVICE_MANAGER_EVDEV (manager);
priv = manager_evdev->priv;
@ -1092,14 +928,10 @@ clutter_device_manager_evdev_get_device (ClutterDeviceManager *manager,
for (l = priv->seats; l; l = l->next)
{
ClutterSeatEvdev *seat = l->data;
ClutterInputDevice *device = clutter_seat_evdev_get_device (seat, id);
for (device_it = seat->devices; device_it; device_it = device_it->next)
{
ClutterInputDevice *device = device_it->data;
if (clutter_input_device_get_device_id (device) == id)
return device;
}
if (device)
return device;
}
return NULL;
@ -1153,40 +985,6 @@ process_base_event (ClutterDeviceManagerEvdev *manager_evdev,
return handled;
}
static void
check_notify_discrete_scroll (ClutterDeviceManagerEvdev *manager_evdev,
ClutterInputDevice *device,
guint64 time_us,
ClutterScrollSource scroll_source)
{
ClutterInputDeviceEvdev *device_evdev =
CLUTTER_INPUT_DEVICE_EVDEV (device);
ClutterSeatEvdev *seat = _clutter_input_device_evdev_get_seat (device_evdev);
int i, n_xscrolls, n_yscrolls;
n_xscrolls = floor (fabs (seat->accum_scroll_dx) / DISCRETE_SCROLL_STEP);
n_yscrolls = floor (fabs (seat->accum_scroll_dy) / DISCRETE_SCROLL_STEP);
for (i = 0; i < n_xscrolls; i++)
{
notify_discrete_scroll (device, time_us,
seat->accum_scroll_dx > 0 ?
CLUTTER_SCROLL_RIGHT : CLUTTER_SCROLL_LEFT,
scroll_source, TRUE);
}
for (i = 0; i < n_yscrolls; i++)
{
notify_discrete_scroll (device, time_us,
seat->accum_scroll_dy > 0 ?
CLUTTER_SCROLL_DOWN : CLUTTER_SCROLL_UP,
scroll_source, TRUE);
}
seat->accum_scroll_dx = fmodf (seat->accum_scroll_dx, DISCRETE_SCROLL_STEP);
seat->accum_scroll_dy = fmodf (seat->accum_scroll_dy, DISCRETE_SCROLL_STEP);
}
static ClutterScrollSource
translate_scroll_source (enum libinput_pointer_axis_source source)
{
@ -1334,6 +1132,68 @@ seat_from_device (ClutterInputDevice *device)
return _clutter_input_device_evdev_get_seat (device_evdev);
}
static void
notify_continuous_axis (ClutterSeatEvdev *seat,
ClutterInputDevice *device,
uint64_t time_us,
ClutterScrollSource scroll_source,
struct libinput_event_pointer *axis_event)
{
gdouble dx = 0.0, dy = 0.0;
ClutterScrollFinishFlags finish_flags = CLUTTER_SCROLL_FINISHED_NONE;
if (libinput_event_pointer_has_axis (axis_event,
LIBINPUT_POINTER_AXIS_SCROLL_HORIZONTAL))
{
dx = libinput_event_pointer_get_axis_value (
axis_event, LIBINPUT_POINTER_AXIS_SCROLL_HORIZONTAL);
if (fabs (dx) < DBL_EPSILON)
finish_flags |= CLUTTER_SCROLL_FINISHED_HORIZONTAL;
}
if (libinput_event_pointer_has_axis (axis_event,
LIBINPUT_POINTER_AXIS_SCROLL_VERTICAL))
{
dy = libinput_event_pointer_get_axis_value (
axis_event, LIBINPUT_POINTER_AXIS_SCROLL_VERTICAL);
if (fabs (dy) < DBL_EPSILON)
finish_flags |= CLUTTER_SCROLL_FINISHED_VERTICAL;
}
clutter_seat_evdev_notify_scroll_continuous (seat, device, time_us,
dx, dy,
scroll_source, finish_flags);
}
static void
notify_discrete_axis (ClutterSeatEvdev *seat,
ClutterInputDevice *device,
uint64_t time_us,
ClutterScrollSource scroll_source,
struct libinput_event_pointer *axis_event)
{
gdouble discrete_dx = 0.0, discrete_dy = 0.0;
if (libinput_event_pointer_has_axis (axis_event,
LIBINPUT_POINTER_AXIS_SCROLL_HORIZONTAL))
{
discrete_dx = libinput_event_pointer_get_axis_value_discrete (
axis_event, LIBINPUT_POINTER_AXIS_SCROLL_HORIZONTAL);
}
if (libinput_event_pointer_has_axis (axis_event,
LIBINPUT_POINTER_AXIS_SCROLL_VERTICAL))
{
discrete_dy = libinput_event_pointer_get_axis_value_discrete (
axis_event, LIBINPUT_POINTER_AXIS_SCROLL_VERTICAL);
}
clutter_seat_evdev_notify_discrete_scroll (seat, device,
time_us,
discrete_dx, discrete_dy,
scroll_source);
}
static gboolean
process_device_event (ClutterDeviceManagerEvdev *manager_evdev,
struct libinput_event *event)
@ -1341,6 +1201,7 @@ process_device_event (ClutterDeviceManagerEvdev *manager_evdev,
gboolean handled = TRUE;
struct libinput_device *libinput_device = libinput_event_get_device(event);
ClutterInputDevice *device;
ClutterInputDeviceEvdev *device_evdev;
switch (libinput_event_get_type (event))
{
@ -1460,17 +1321,12 @@ process_device_event (ClutterDeviceManagerEvdev *manager_evdev,
case LIBINPUT_EVENT_POINTER_AXIS:
{
gdouble dx = 0.0, dy = 0.0;
gdouble discrete_x = 0.0, discrete_y = 0.0;
guint64 time_us;
gboolean wheel = FALSE;
enum libinput_pointer_axis axis;
enum libinput_pointer_axis_source source;
struct libinput_event_pointer *axis_event =
libinput_event_get_pointer_event (event);
ClutterSeatEvdev *seat;
ClutterScrollSource scroll_source;
ClutterScrollFinishFlags finish_flags = 0;
device = libinput_device_get_user_data (libinput_device);
seat = _clutter_input_device_evdev_get_seat (CLUTTER_INPUT_DEVICE_EVDEV (device));
@ -1484,68 +1340,25 @@ process_device_event (ClutterDeviceManagerEvdev *manager_evdev,
backwards-compat with existing clients, we just send multiples of
the click count. */
if (source == LIBINPUT_POINTER_AXIS_SOURCE_WHEEL)
wheel = TRUE;
axis = LIBINPUT_POINTER_AXIS_SCROLL_VERTICAL;
if (libinput_event_pointer_has_axis (axis_event, axis))
switch (scroll_source)
{
discrete_y = libinput_event_pointer_get_axis_value_discrete (axis_event, axis);
dy = libinput_event_pointer_get_axis_value (axis_event, axis);
if (wheel)
seat->accum_scroll_dy = 0;
else if (fabs (dy) < DBL_EPSILON)
{
finish_flags |= CLUTTER_SCROLL_FINISHED_VERTICAL;
seat->accum_scroll_dy = 0;
}
else
seat->accum_scroll_dy += dy;
case CLUTTER_SCROLL_SOURCE_WHEEL:
notify_discrete_axis (seat, device, time_us, scroll_source,
axis_event);
break;
case CLUTTER_SCROLL_SOURCE_FINGER:
case CLUTTER_SCROLL_SOURCE_CONTINUOUS:
case CLUTTER_SCROLL_SOURCE_UNKNOWN:
notify_continuous_axis (seat, device, time_us, scroll_source,
axis_event);
break;
}
axis = LIBINPUT_POINTER_AXIS_SCROLL_HORIZONTAL;
if (libinput_event_pointer_has_axis (axis_event, axis))
{
discrete_x = libinput_event_pointer_get_axis_value_discrete (axis_event, axis);
dx = libinput_event_pointer_get_axis_value (axis_event, axis);
if (wheel)
seat->accum_scroll_dx = 0;
else if (fabs (dx) < DBL_EPSILON)
{
finish_flags |= CLUTTER_SCROLL_FINISHED_HORIZONTAL;
seat->accum_scroll_dx = 0;
}
else
seat->accum_scroll_dx += dx;
}
if (wheel)
{
notify_scroll (device, time_us,
discrete_x * DISCRETE_SCROLL_STEP,
discrete_y * DISCRETE_SCROLL_STEP,
scroll_source, finish_flags, TRUE);
notify_discrete_scroll (device, time_us,
discrete_to_direction (discrete_x, discrete_y),
scroll_source, FALSE);
}
else
{
notify_scroll (device, time_us, dx, dy,
scroll_source, finish_flags, FALSE);
check_notify_discrete_scroll (manager_evdev, device,
time_us, scroll_source);
}
break;
}
case LIBINPUT_EVENT_TOUCH_DOWN:
{
gint32 slot;
int device_slot;
guint64 time_us;
double x, y;
gfloat stage_width, stage_height;
@ -1556,7 +1369,8 @@ process_device_event (ClutterDeviceManagerEvdev *manager_evdev,
libinput_event_get_touch_event (event);
device = libinput_device_get_user_data (libinput_device);
seat = _clutter_input_device_evdev_get_seat (CLUTTER_INPUT_DEVICE_EVDEV (device));
device_evdev = CLUTTER_INPUT_DEVICE_EVDEV (device);
seat = _clutter_input_device_evdev_get_seat (device_evdev);
stage = _clutter_input_device_get_stage (device);
if (stage == NULL)
@ -1565,25 +1379,31 @@ process_device_event (ClutterDeviceManagerEvdev *manager_evdev,
stage_width = clutter_actor_get_width (CLUTTER_ACTOR (stage));
stage_height = clutter_actor_get_height (CLUTTER_ACTOR (stage));
slot = libinput_event_touch_get_slot (touch_event);
device_slot = libinput_event_touch_get_slot (touch_event);
time_us = libinput_event_touch_get_time_usec (touch_event);
x = libinput_event_touch_get_x_transformed (touch_event,
stage_width);
y = libinput_event_touch_get_y_transformed (touch_event,
stage_height);
touch_state = clutter_seat_evdev_add_touch (seat, slot);
touch_state =
clutter_input_device_evdev_acquire_touch_state (device_evdev,
device_slot);
touch_state->coords.x = x;
touch_state->coords.y = y;
notify_touch_event (device, CLUTTER_TOUCH_BEGIN, time_us, slot,
touch_state->coords.x, touch_state->coords.y);
clutter_seat_evdev_notify_touch_event (seat, device,
CLUTTER_TOUCH_BEGIN,
time_us,
touch_state->seat_slot,
touch_state->coords.x,
touch_state->coords.y);
break;
}
case LIBINPUT_EVENT_TOUCH_UP:
{
gint32 slot;
int device_slot;
guint64 time_us;
ClutterSeatEvdev *seat;
ClutterTouchState *touch_state;
@ -1591,22 +1411,30 @@ process_device_event (ClutterDeviceManagerEvdev *manager_evdev,
libinput_event_get_touch_event (event);
device = libinput_device_get_user_data (libinput_device);
seat = _clutter_input_device_evdev_get_seat (CLUTTER_INPUT_DEVICE_EVDEV (device));
device_evdev = CLUTTER_INPUT_DEVICE_EVDEV (device);
seat = _clutter_input_device_evdev_get_seat (device_evdev);
slot = libinput_event_touch_get_slot (touch_event);
device_slot = libinput_event_touch_get_slot (touch_event);
time_us = libinput_event_touch_get_time_usec (touch_event);
touch_state = clutter_seat_evdev_get_touch (seat, slot);
notify_touch_event (device, CLUTTER_TOUCH_END, time_us, slot,
touch_state->coords.x, touch_state->coords.y);
clutter_seat_evdev_remove_touch (seat, slot);
touch_state =
clutter_input_device_evdev_lookup_touch_state (device_evdev,
device_slot);
if (!touch_state)
break;
clutter_seat_evdev_notify_touch_event (seat, device,
CLUTTER_TOUCH_END, time_us,
touch_state->seat_slot,
touch_state->coords.x,
touch_state->coords.y);
clutter_input_device_evdev_release_touch_state (device_evdev,
touch_state);
break;
}
case LIBINPUT_EVENT_TOUCH_MOTION:
{
gint32 slot;
int device_slot;
guint64 time_us;
double x, y;
gfloat stage_width, stage_height;
@ -1617,7 +1445,8 @@ process_device_event (ClutterDeviceManagerEvdev *manager_evdev,
libinput_event_get_touch_event (event);
device = libinput_device_get_user_data (libinput_device);
seat = _clutter_input_device_evdev_get_seat (CLUTTER_INPUT_DEVICE_EVDEV (device));
device_evdev = CLUTTER_INPUT_DEVICE_EVDEV (device);
seat = _clutter_input_device_evdev_get_seat (device_evdev);
stage = _clutter_input_device_get_stage (device);
if (stage == NULL)
@ -1626,42 +1455,41 @@ process_device_event (ClutterDeviceManagerEvdev *manager_evdev,
stage_width = clutter_actor_get_width (CLUTTER_ACTOR (stage));
stage_height = clutter_actor_get_height (CLUTTER_ACTOR (stage));
slot = libinput_event_touch_get_slot (touch_event);
device_slot = libinput_event_touch_get_slot (touch_event);
time_us = libinput_event_touch_get_time_usec (touch_event);
x = libinput_event_touch_get_x_transformed (touch_event,
stage_width);
y = libinput_event_touch_get_y_transformed (touch_event,
stage_height);
touch_state = clutter_seat_evdev_get_touch (seat, slot);
touch_state =
clutter_input_device_evdev_lookup_touch_state (device_evdev,
device_slot);
if (!touch_state)
break;
touch_state->coords.x = x;
touch_state->coords.y = y;
notify_touch_event (device, CLUTTER_TOUCH_UPDATE, time_us, slot,
touch_state->coords.x, touch_state->coords.y);
clutter_seat_evdev_notify_touch_event (seat, device,
CLUTTER_TOUCH_UPDATE,
time_us,
touch_state->seat_slot,
touch_state->coords.x,
touch_state->coords.y);
break;
}
case LIBINPUT_EVENT_TOUCH_CANCEL:
{
ClutterTouchState *touch_state;
GHashTableIter iter;
guint64 time_us;
struct libinput_event_touch *touch_event =
libinput_event_get_touch_event (event);
ClutterSeatEvdev *seat;
device = libinput_device_get_user_data (libinput_device);
device_evdev = CLUTTER_INPUT_DEVICE_EVDEV (device);
time_us = libinput_event_touch_get_time_usec (touch_event);
seat = _clutter_input_device_evdev_get_seat (CLUTTER_INPUT_DEVICE_EVDEV (device));
g_hash_table_iter_init (&iter, seat->touches);
while (g_hash_table_iter_next (&iter, NULL, (gpointer*) &touch_state))
{
notify_touch_event (device, CLUTTER_TOUCH_CANCEL,
time_us, touch_state->id,
touch_state->coords.x, touch_state->coords.y);
g_hash_table_iter_remove (&iter);
}
clutter_input_device_evdev_release_touch_slots (device_evdev, time_us);
break;
}
@ -2035,6 +1863,14 @@ clutter_device_manager_evdev_create_virtual_device (ClutterDeviceManager *manag
NULL);
}
static ClutterVirtualDeviceType
clutter_device_manager_evdev_get_supported_virtual_device_types (ClutterDeviceManager *device_manager)
{
return (CLUTTER_VIRTUAL_DEVICE_TYPE_KEYBOARD |
CLUTTER_VIRTUAL_DEVICE_TYPE_POINTER |
CLUTTER_VIRTUAL_DEVICE_TYPE_TOUCHSCREEN);
}
static void
clutter_device_manager_evdev_compress_motion (ClutterDeviceManager *device_manger,
ClutterEvent *event,
@ -2060,6 +1896,18 @@ clutter_device_manager_evdev_compress_motion (ClutterDeviceManager *device_mange
dy_unaccel + dst_dy_unaccel);
}
static void
clutter_device_manager_evdev_apply_kbd_a11y_settings (ClutterDeviceManager *device_manager,
ClutterKbdA11ySettings *settings)
{
ClutterInputDevice *device;
device = clutter_device_manager_evdev_get_core_device (device_manager, CLUTTER_KEYBOARD_DEVICE);
if (device)
clutter_input_device_evdev_apply_kbd_a11y_settings (CLUTTER_INPUT_DEVICE_EVDEV (device),
settings);
}
/*
* GObject implementation
*/
@ -2116,6 +1964,7 @@ clutter_device_manager_evdev_constructed (GObject *gobject)
xkb_context_unref (ctx);
priv->main_seat = clutter_seat_evdev_new (manager_evdev);
priv->seats = g_slist_append (priv->seats, priv->main_seat);
dispatch_libinput (manager_evdev);
@ -2201,7 +2050,9 @@ clutter_device_manager_evdev_class_init (ClutterDeviceManagerEvdevClass *klass)
manager_class->get_core_device = clutter_device_manager_evdev_get_core_device;
manager_class->get_device = clutter_device_manager_evdev_get_device;
manager_class->create_virtual_device = clutter_device_manager_evdev_create_virtual_device;
manager_class->get_supported_virtual_device_types = clutter_device_manager_evdev_get_supported_virtual_device_types;
manager_class->compress_motion = clutter_device_manager_evdev_compress_motion;
manager_class->apply_kbd_a11y_settings = clutter_device_manager_evdev_apply_kbd_a11y_settings;
}
static void
@ -2322,7 +2173,7 @@ _clutter_device_manager_evdev_acquire_device_id (ClutterDeviceManagerEvdev *mana
first = g_list_first (priv->free_device_ids);
next_id = GPOINTER_TO_INT (first->data);
priv->free_device_ids = g_list_remove_link (priv->free_device_ids, first);
priv->free_device_ids = g_list_delete_link (priv->free_device_ids, first);
return next_id;
}
@ -2441,7 +2292,7 @@ clutter_evdev_update_xkb_state (ClutterDeviceManagerEvdev *manager_evdev)
0, /* depressed */
latched_mods,
locked_mods,
0, 0, 0);
0, 0, seat->layout_idx);
seat->caps_lock_led = xkb_keymap_led_get_index (priv->keymap, XKB_LED_NAME_CAPS);
seat->num_lock_led = xkb_keymap_led_get_index (priv->keymap, XKB_LED_NAME_NUM);
@ -2589,6 +2440,7 @@ clutter_evdev_set_keyboard_layout_index (ClutterDeviceManager *evdev,
xkb_mod_mask_t latched_mods;
xkb_mod_mask_t locked_mods;
struct xkb_state *state;
GSList *l;
g_return_if_fail (CLUTTER_IS_DEVICE_MANAGER_EVDEV (evdev));
@ -2600,6 +2452,24 @@ clutter_evdev_set_keyboard_layout_index (ClutterDeviceManager *evdev,
locked_mods = xkb_state_serialize_mods (state, XKB_STATE_MODS_LOCKED);
xkb_state_update_mask (state, depressed_mods, latched_mods, locked_mods, 0, 0, idx);
for (l = manager_evdev->priv->seats; l; l = l->next)
{
ClutterSeatEvdev *seat = l->data;
seat->layout_idx = idx;
}
}
/**
* clutter_evdev_get_keyboard_layout_index: (skip)
*/
xkb_layout_index_t
clutter_evdev_get_keyboard_layout_index (ClutterDeviceManager *evdev)
{
ClutterDeviceManagerEvdev *manager_evdev;
manager_evdev = CLUTTER_DEVICE_MANAGER_EVDEV (evdev);
return manager_evdev->priv->main_seat->layout_idx;
}
/**

View File

@ -120,6 +120,9 @@ CLUTTER_AVAILABLE_IN_1_20
void clutter_evdev_set_keyboard_layout_index (ClutterDeviceManager *evdev,
xkb_layout_index_t idx);
CLUTTER_AVAILABLE_IN_MUTTER
xkb_layout_index_t clutter_evdev_get_keyboard_layout_index (ClutterDeviceManager *evdev);
CLUTTER_AVAILABLE_IN_1_26
void clutter_evdev_set_keyboard_numlock (ClutterDeviceManager *evdev,
gboolean numlock_state);

File diff suppressed because it is too large Load Diff

View File

@ -70,6 +70,31 @@ struct _ClutterInputDeviceEvdev
cairo_matrix_t device_matrix;
gdouble device_aspect_ratio; /* w:h */
gdouble output_ratio; /* w:h */
GHashTable *touches;
/* Keyboard a11y */
ClutterKeyboardA11yFlags a11y_flags;
GList *slow_keys_list;
guint debounce_timer;
guint16 debounce_key;
xkb_mod_mask_t stickykeys_depressed_mask;
xkb_mod_mask_t stickykeys_latched_mask;
xkb_mod_mask_t stickykeys_locked_mask;
guint toggle_slowkeys_timer;
guint16 shift_count;
guint32 last_shift_time;
gint mousekeys_btn;
gboolean mousekeys_btn_states[3];
guint32 mousekeys_first_motion_time; /* ms */
guint32 mousekeys_last_motion_time; /* ms */
guint mousekeys_init_delay;
guint mousekeys_accel_time;
guint mousekeys_max_speed;
gdouble mousekeys_curve_factor;
guint move_mousekeys_timer;
guint16 last_mousekeys_key;
ClutterVirtualInputDevice *mousekeys_virtual_device;
};
GType _clutter_input_device_evdev_get_type (void) G_GNUC_CONST;
@ -111,6 +136,22 @@ void clutter_input_device_evdev_translate_coordinates (Clut
gfloat *x,
gfloat *y);
void clutter_input_device_evdev_apply_kbd_a11y_settings (ClutterInputDeviceEvdev *device,
ClutterKbdA11ySettings *settings);
ClutterTouchState * clutter_input_device_evdev_acquire_touch_state (ClutterInputDeviceEvdev *device,
int device_slot);
ClutterTouchState * clutter_input_device_evdev_lookup_touch_state (ClutterInputDeviceEvdev *device,
int device_slot);
void clutter_input_device_evdev_release_touch_state (ClutterInputDeviceEvdev *device,
ClutterTouchState *touch_state);
void clutter_input_device_evdev_release_touch_slots (ClutterInputDeviceEvdev *device_evdev,
uint64_t time_us);
G_END_DECLS
#endif /* __CLUTTER_INPUT_DEVICE_EVDEV_H__ */

View File

@ -29,6 +29,7 @@
#include "clutter-seat-evdev.h"
#include <linux/input.h>
#include <math.h>
#include "clutter-event-private.h"
#include "clutter-input-device-evdev.h"
@ -42,6 +43,12 @@
#define AUTOREPEAT_VALUE 2
#define DISCRETE_SCROLL_STEP 10.0
#ifndef BTN_STYLUS3
#define BTN_STYLUS3 0x149 /* Linux 4.15 */
#endif
void
clutter_seat_evdev_set_libinput_seat (ClutterSeatEvdev *seat,
struct libinput_seat *libinput_seat)
@ -85,32 +92,57 @@ clutter_touch_state_free (ClutterTouchState *touch_state)
g_slice_free (ClutterTouchState, touch_state);
}
ClutterTouchState *
clutter_seat_evdev_add_touch (ClutterSeatEvdev *seat,
guint32 id)
static void
ensure_seat_slot_allocated (ClutterSeatEvdev *seat,
int seat_slot)
{
ClutterTouchState *touch;
if (seat_slot >= seat->n_alloc_touch_states)
{
const int size_increase = 5;
int i;
touch = g_slice_new0 (ClutterTouchState);
touch->id = id;
seat->n_alloc_touch_states += size_increase;
seat->touch_states = g_realloc_n (seat->touch_states,
seat->n_alloc_touch_states,
sizeof (ClutterTouchState *));
for (i = 0; i < size_increase; i++)
seat->touch_states[seat->n_alloc_touch_states - (i + 1)] = NULL;
}
}
g_hash_table_insert (seat->touches, GUINT_TO_POINTER (id), touch);
ClutterTouchState *
clutter_seat_evdev_acquire_touch_state (ClutterSeatEvdev *seat,
int device_slot)
{
ClutterTouchState *touch_state;
int seat_slot;
return touch;
for (seat_slot = 0; seat_slot < seat->n_alloc_touch_states; seat_slot++)
{
if (!seat->touch_states[seat_slot])
break;
}
ensure_seat_slot_allocated (seat, seat_slot);
touch_state = g_slice_new0 (ClutterTouchState);
*touch_state = (ClutterTouchState) {
.seat = seat,
.seat_slot = seat_slot,
.device_slot = device_slot,
};
seat->touch_states[seat_slot] = touch_state;
return touch_state;
}
void
clutter_seat_evdev_remove_touch (ClutterSeatEvdev *seat,
guint32 id)
clutter_seat_evdev_release_touch_state (ClutterSeatEvdev *seat,
ClutterTouchState *touch_state)
{
g_hash_table_remove (seat->touches, GUINT_TO_POINTER (id));
}
ClutterTouchState *
clutter_seat_evdev_get_touch (ClutterSeatEvdev *seat,
guint32 id)
{
return g_hash_table_lookup (seat->touches, GUINT_TO_POINTER (id));
g_clear_pointer (&seat->touch_states[touch_state->seat_slot],
clutter_touch_state_free);
}
ClutterSeatEvdev *
@ -147,9 +179,6 @@ clutter_seat_evdev_new (ClutterDeviceManagerEvdev *manager_evdev)
_clutter_device_manager_add_device (manager, device);
seat->core_keyboard = device;
seat->touches = g_hash_table_new_full (NULL, NULL, NULL,
(GDestroyNotify) clutter_touch_state_free);
seat->repeat = TRUE;
seat->repeat_delay = 250; /* ms */
seat->repeat_interval = 33; /* ms */
@ -281,7 +310,7 @@ clutter_seat_evdev_notify_key (ClutterSeatEvdev *seat,
else
{
changed_state = 0;
clutter_event_set_flags (event, CLUTTER_EVENT_FLAG_SYNTHETIC);
clutter_event_set_flags (event, CLUTTER_EVENT_FLAG_REPEATED);
}
queue_event (event);
@ -489,6 +518,10 @@ clutter_seat_evdev_notify_button (ClutterSeatEvdev *seat,
button_nr = CLUTTER_BUTTON_MIDDLE;
break;
case 0x149: /* BTN_STYLUS3 */
button_nr = 8;
break;
default:
/* For compatibility reasons, all additional buttons go after the old 4-7 scroll ones */
if (clutter_input_device_get_device_type (input_device) == CLUTTER_TABLET_DEVICE)
@ -569,6 +602,238 @@ clutter_seat_evdev_notify_button (ClutterSeatEvdev *seat,
queue_event (event);
}
static void
notify_scroll (ClutterInputDevice *input_device,
guint64 time_us,
gdouble dx,
gdouble dy,
ClutterScrollSource scroll_source,
ClutterScrollFinishFlags flags,
gboolean emulated)
{
ClutterInputDeviceEvdev *device_evdev;
ClutterSeatEvdev *seat;
ClutterStage *stage;
ClutterEvent *event = NULL;
gdouble scroll_factor;
/* We can drop the event on the floor if no stage has been
* associated with the device yet. */
stage = _clutter_input_device_get_stage (input_device);
if (stage == NULL)
return;
device_evdev = CLUTTER_INPUT_DEVICE_EVDEV (input_device);
seat = _clutter_input_device_evdev_get_seat (device_evdev);
event = clutter_event_new (CLUTTER_SCROLL);
_clutter_evdev_event_set_time_usec (event, time_us);
event->scroll.time = us2ms (time_us);
event->scroll.stage = CLUTTER_STAGE (stage);
event->scroll.device = seat->core_pointer;
_clutter_xkb_translate_state (event, seat->xkb, seat->button_state);
/* libinput pointer axis events are in pointer motion coordinate space.
* To convert to Xi2 discrete step coordinate space, multiply the factor
* 1/10. */
event->scroll.direction = CLUTTER_SCROLL_SMOOTH;
scroll_factor = 1.0 / DISCRETE_SCROLL_STEP;
clutter_event_set_scroll_delta (event,
scroll_factor * dx,
scroll_factor * dy);
event->scroll.x = seat->pointer_x;
event->scroll.y = seat->pointer_y;
clutter_event_set_device (event, seat->core_pointer);
clutter_event_set_source_device (event, input_device);
event->scroll.scroll_source = scroll_source;
event->scroll.finish_flags = flags;
_clutter_event_set_pointer_emulated (event, emulated);
queue_event (event);
}
static void
notify_discrete_scroll (ClutterInputDevice *input_device,
uint64_t time_us,
ClutterScrollDirection direction,
ClutterScrollSource scroll_source,
gboolean emulated)
{
ClutterInputDeviceEvdev *device_evdev;
ClutterSeatEvdev *seat;
ClutterStage *stage;
ClutterEvent *event = NULL;
if (direction == CLUTTER_SCROLL_SMOOTH)
return;
/* We can drop the event on the floor if no stage has been
* associated with the device yet. */
stage = _clutter_input_device_get_stage (input_device);
if (stage == NULL)
return;
device_evdev = CLUTTER_INPUT_DEVICE_EVDEV (input_device);
seat = _clutter_input_device_evdev_get_seat (device_evdev);
event = clutter_event_new (CLUTTER_SCROLL);
_clutter_evdev_event_set_time_usec (event, time_us);
event->scroll.time = us2ms (time_us);
event->scroll.stage = CLUTTER_STAGE (stage);
event->scroll.device = seat->core_pointer;
_clutter_xkb_translate_state (event, seat->xkb, seat->button_state);
event->scroll.direction = direction;
event->scroll.x = seat->pointer_x;
event->scroll.y = seat->pointer_y;
clutter_event_set_device (event, seat->core_pointer);
clutter_event_set_source_device (event, input_device);
event->scroll.scroll_source = scroll_source;
_clutter_event_set_pointer_emulated (event, emulated);
queue_event (event);
}
static void
check_notify_discrete_scroll (ClutterSeatEvdev *seat,
ClutterInputDevice *device,
uint64_t time_us,
ClutterScrollSource scroll_source)
{
int i, n_xscrolls, n_yscrolls;
n_xscrolls = floor (fabs (seat->accum_scroll_dx) / DISCRETE_SCROLL_STEP);
n_yscrolls = floor (fabs (seat->accum_scroll_dy) / DISCRETE_SCROLL_STEP);
for (i = 0; i < n_xscrolls; i++)
{
notify_discrete_scroll (device, time_us,
seat->accum_scroll_dx > 0 ?
CLUTTER_SCROLL_RIGHT : CLUTTER_SCROLL_LEFT,
scroll_source, TRUE);
}
for (i = 0; i < n_yscrolls; i++)
{
notify_discrete_scroll (device, time_us,
seat->accum_scroll_dy > 0 ?
CLUTTER_SCROLL_DOWN : CLUTTER_SCROLL_UP,
scroll_source, TRUE);
}
seat->accum_scroll_dx = fmodf (seat->accum_scroll_dx, DISCRETE_SCROLL_STEP);
seat->accum_scroll_dy = fmodf (seat->accum_scroll_dy, DISCRETE_SCROLL_STEP);
}
void
clutter_seat_evdev_notify_scroll_continuous (ClutterSeatEvdev *seat,
ClutterInputDevice *input_device,
uint64_t time_us,
double dx,
double dy,
ClutterScrollSource scroll_source,
ClutterScrollFinishFlags finish_flags)
{
if (finish_flags & CLUTTER_SCROLL_FINISHED_HORIZONTAL)
seat->accum_scroll_dx = 0;
else
seat->accum_scroll_dx += dx;
if (finish_flags & CLUTTER_SCROLL_FINISHED_VERTICAL)
seat->accum_scroll_dy = 0;
else
seat->accum_scroll_dy += dy;
notify_scroll (input_device, time_us, dx, dy, scroll_source,
finish_flags, FALSE);
check_notify_discrete_scroll (seat, input_device, time_us, scroll_source);
}
static ClutterScrollDirection
discrete_to_direction (double discrete_dx,
double discrete_dy)
{
if (discrete_dx > 0)
return CLUTTER_SCROLL_RIGHT;
else if (discrete_dx < 0)
return CLUTTER_SCROLL_LEFT;
else if (discrete_dy > 0)
return CLUTTER_SCROLL_DOWN;
else if (discrete_dy < 0)
return CLUTTER_SCROLL_UP;
else
g_assert_not_reached ();
}
void
clutter_seat_evdev_notify_discrete_scroll (ClutterSeatEvdev *seat,
ClutterInputDevice *input_device,
uint64_t time_us,
double discrete_dx,
double discrete_dy,
ClutterScrollSource scroll_source)
{
notify_scroll (input_device, time_us,
discrete_dx * DISCRETE_SCROLL_STEP,
discrete_dy * DISCRETE_SCROLL_STEP,
scroll_source, CLUTTER_SCROLL_FINISHED_NONE,
TRUE);
notify_discrete_scroll (input_device, time_us,
discrete_to_direction (discrete_dx, discrete_dy),
scroll_source, FALSE);
}
void
clutter_seat_evdev_notify_touch_event (ClutterSeatEvdev *seat,
ClutterInputDevice *input_device,
ClutterEventType evtype,
uint64_t time_us,
int slot,
double x,
double y)
{
ClutterStage *stage;
ClutterEvent *event = NULL;
/* We can drop the event on the floor if no stage has been
* associated with the device yet. */
stage = _clutter_input_device_get_stage (input_device);
if (stage == NULL)
return;
event = clutter_event_new (evtype);
_clutter_evdev_event_set_time_usec (event, time_us);
event->touch.time = us2ms (time_us);
event->touch.stage = CLUTTER_STAGE (stage);
event->touch.device = seat->core_pointer;
event->touch.x = x;
event->touch.y = y;
clutter_input_device_evdev_translate_coordinates (input_device, stage,
&event->touch.x,
&event->touch.y);
/* "NULL" sequences are special cased in clutter */
event->touch.sequence = GINT_TO_POINTER (MAX (1, slot + 1));
_clutter_xkb_translate_state (event, seat->xkb, seat->button_state);
if (evtype == CLUTTER_TOUCH_BEGIN ||
evtype == CLUTTER_TOUCH_UPDATE)
event->touch.modifier_state |= CLUTTER_BUTTON1_MASK;
clutter_event_set_device (event, seat->core_pointer);
clutter_event_set_source_device (event, input_device);
queue_event (event);
}
void
clutter_seat_evdev_free (ClutterSeatEvdev *seat)
{
@ -581,7 +846,7 @@ clutter_seat_evdev_free (ClutterSeatEvdev *seat)
g_object_unref (device);
}
g_slist_free (seat->devices);
g_hash_table_unref (seat->touches);
g_free (seat->touch_states);
xkb_state_unref (seat->xkb);
@ -593,6 +858,24 @@ clutter_seat_evdev_free (ClutterSeatEvdev *seat)
g_free (seat);
}
ClutterInputDevice *
clutter_seat_evdev_get_device (ClutterSeatEvdev *seat,
gint id)
{
ClutterInputDevice *device;
GSList *l;
for (l = seat->devices; l; l = l->next)
{
device = l->data;
if (clutter_input_device_get_device_id (device) == id)
return device;
}
return NULL;
}
void
clutter_seat_evdev_set_stage (ClutterSeatEvdev *seat,
ClutterStage *stage)

View File

@ -38,7 +38,10 @@ typedef struct _ClutterTouchState ClutterTouchState;
struct _ClutterTouchState
{
guint32 id;
ClutterSeatEvdev *seat;
int device_slot;
int seat_slot;
ClutterPoint coords;
};
@ -52,12 +55,14 @@ struct _ClutterSeatEvdev
ClutterInputDevice *core_pointer;
ClutterInputDevice *core_keyboard;
GHashTable *touches;
ClutterTouchState **touch_states;
int n_alloc_touch_states;
struct xkb_state *xkb;
xkb_led_index_t caps_lock_led;
xkb_led_index_t num_lock_led;
xkb_led_index_t scroll_lock_led;
xkb_layout_index_t layout_idx;
uint32_t button_state;
int button_count[KEY_CNT];
@ -106,16 +111,42 @@ void clutter_seat_evdev_notify_button (ClutterSeatEvdev *seat,
uint32_t button,
uint32_t state);
void clutter_seat_evdev_notify_scroll_continuous (ClutterSeatEvdev *seat,
ClutterInputDevice *input_device,
uint64_t time_us,
double dx,
double dy,
ClutterScrollSource source,
ClutterScrollFinishFlags flags);
void clutter_seat_evdev_notify_discrete_scroll (ClutterSeatEvdev *seat,
ClutterInputDevice *input_device,
uint64_t time_us,
double discrete_dx,
double discrete_dy,
ClutterScrollSource source);
void clutter_seat_evdev_notify_touch_event (ClutterSeatEvdev *seat,
ClutterInputDevice *input_device,
ClutterEventType evtype,
uint64_t time_us,
int slot,
double x,
double y);
void clutter_seat_evdev_set_libinput_seat (ClutterSeatEvdev *seat,
struct libinput_seat *libinput_seat);
void clutter_seat_evdev_sync_leds (ClutterSeatEvdev *seat);
ClutterTouchState * clutter_seat_evdev_add_touch (ClutterSeatEvdev *seat,
guint32 id);
ClutterInputDevice * clutter_seat_evdev_get_device (ClutterSeatEvdev *seat,
gint id);
void clutter_seat_evdev_remove_touch (ClutterSeatEvdev *seat,
guint32 id);
ClutterTouchState * clutter_seat_evdev_acquire_touch_state (ClutterSeatEvdev *seat,
int device_slot);
void clutter_seat_evdev_release_touch_state (ClutterSeatEvdev *seat,
ClutterTouchState *touch_state);
ClutterTouchState * clutter_seat_evdev_get_touch (ClutterSeatEvdev *seat,
guint32 id);

View File

@ -156,6 +156,9 @@ clutter_virtual_input_device_evdev_notify_relative_motion (ClutterVirtualInputDe
ClutterVirtualInputDeviceEvdev *virtual_evdev =
CLUTTER_VIRTUAL_INPUT_DEVICE_EVDEV (virtual_device);
if (time_us == CLUTTER_CURRENT_TIME)
time_us = g_get_monotonic_time ();
clutter_seat_evdev_notify_relative_motion (virtual_evdev->seat,
virtual_evdev->device,
time_us,
@ -172,6 +175,9 @@ clutter_virtual_input_device_evdev_notify_absolute_motion (ClutterVirtualInputDe
ClutterVirtualInputDeviceEvdev *virtual_evdev =
CLUTTER_VIRTUAL_INPUT_DEVICE_EVDEV (virtual_device);
if (time_us == CLUTTER_CURRENT_TIME)
time_us = g_get_monotonic_time ();
clutter_seat_evdev_notify_absolute_motion (virtual_evdev->seat,
virtual_evdev->device,
time_us,
@ -179,6 +185,26 @@ clutter_virtual_input_device_evdev_notify_absolute_motion (ClutterVirtualInputDe
NULL);
}
static int
translate_to_evdev_button (int clutter_button)
{
switch (clutter_button)
{
case CLUTTER_BUTTON_PRIMARY:
return BTN_LEFT;
case CLUTTER_BUTTON_SECONDARY:
return BTN_RIGHT;
case CLUTTER_BUTTON_MIDDLE:
return BTN_MIDDLE;
default:
/*
* For compatibility reasons, all additional buttons go after the old
* 4-7 scroll ones.
*/
return clutter_button + (BTN_LEFT - 1) - 4;
}
}
static void
clutter_virtual_input_device_evdev_notify_button (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
@ -188,27 +214,33 @@ clutter_virtual_input_device_evdev_notify_button (ClutterVirtualInputDevice *vir
ClutterVirtualInputDeviceEvdev *virtual_evdev =
CLUTTER_VIRTUAL_INPUT_DEVICE_EVDEV (virtual_device);
int button_count;
int evdev_button;
if (get_button_type (button) != EVDEV_BUTTON_TYPE_BUTTON)
if (time_us == CLUTTER_CURRENT_TIME)
time_us = g_get_monotonic_time ();
evdev_button = translate_to_evdev_button (button);
if (get_button_type (evdev_button) != EVDEV_BUTTON_TYPE_BUTTON)
{
g_warning ("Unknown/invalid virtual device button 0x%x pressed",
button);
evdev_button);
return;
}
button_count = update_button_count (virtual_evdev, button, button_state);
button_count = update_button_count (virtual_evdev, evdev_button, button_state);
if (button_count < 0 || button_count > 1)
{
g_warning ("Received multiple virtual 0x%x button %s (ignoring)", button,
g_warning ("Received multiple virtual 0x%x button %s (ignoring)", evdev_button,
button_state == CLUTTER_BUTTON_STATE_PRESSED ? "presses" : "releases");
update_button_count (virtual_evdev, button, 1 - button_state);
update_button_count (virtual_evdev, evdev_button, 1 - button_state);
return;
}
clutter_seat_evdev_notify_button (virtual_evdev->seat,
virtual_evdev->device,
time_us,
button,
evdev_button,
button_state);
}
@ -222,6 +254,9 @@ clutter_virtual_input_device_evdev_notify_key (ClutterVirtualInputDevice *virtua
CLUTTER_VIRTUAL_INPUT_DEVICE_EVDEV (virtual_device);
int key_count;
if (time_us == CLUTTER_CURRENT_TIME)
time_us = g_get_monotonic_time ();
if (get_button_type (key) != EVDEV_BUTTON_TYPE_KEY)
{
g_warning ("Unknown/invalid virtual device key 0x%x pressed\n", key);
@ -343,6 +378,9 @@ clutter_virtual_input_device_evdev_notify_keyval (ClutterVirtualInputDevice *vir
int key_count;
guint keycode = 0, level = 0, evcode = 0;
if (time_us == CLUTTER_CURRENT_TIME)
time_us = g_get_monotonic_time ();
if (!pick_keycode_for_keyval_in_current_group (virtual_device,
keyval, &keycode, &level))
{
@ -382,6 +420,175 @@ clutter_virtual_input_device_evdev_notify_keyval (ClutterVirtualInputDevice *vir
apply_level_modifiers (virtual_device, time_us, level, key_state);
}
static void
direction_to_discrete (ClutterScrollDirection direction,
double *discrete_dx,
double *discrete_dy)
{
switch (direction)
{
case CLUTTER_SCROLL_UP:
*discrete_dx = 0.0;
*discrete_dy = -1.0;
break;
case CLUTTER_SCROLL_DOWN:
*discrete_dx = 0.0;
*discrete_dy = 1.0;
break;
case CLUTTER_SCROLL_LEFT:
*discrete_dx = -1.0;
*discrete_dy = 0.0;
break;
case CLUTTER_SCROLL_RIGHT:
*discrete_dx = 1.0;
*discrete_dy = 0.0;
break;
case CLUTTER_SCROLL_SMOOTH:
g_assert_not_reached ();
break;
}
}
static void
clutter_virtual_input_device_evdev_notify_discrete_scroll (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
ClutterScrollDirection direction,
ClutterScrollSource scroll_source)
{
ClutterVirtualInputDeviceEvdev *virtual_evdev =
CLUTTER_VIRTUAL_INPUT_DEVICE_EVDEV (virtual_device);
double discrete_dx = 0.0, discrete_dy = 0.0;
if (time_us == CLUTTER_CURRENT_TIME)
time_us = g_get_monotonic_time ();
direction_to_discrete (direction, &discrete_dx, &discrete_dy);
clutter_seat_evdev_notify_discrete_scroll (virtual_evdev->seat,
virtual_evdev->device,
time_us,
discrete_dx, discrete_dy,
scroll_source);
}
static void
clutter_virtual_input_device_evdev_notify_scroll_continuous (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
double dx,
double dy,
ClutterScrollSource scroll_source,
ClutterScrollFinishFlags finish_flags)
{
ClutterVirtualInputDeviceEvdev *virtual_evdev =
CLUTTER_VIRTUAL_INPUT_DEVICE_EVDEV (virtual_device);
if (time_us == CLUTTER_CURRENT_TIME)
time_us = g_get_monotonic_time ();
clutter_seat_evdev_notify_scroll_continuous (virtual_evdev->seat,
virtual_evdev->device,
time_us,
dx, dy,
scroll_source,
CLUTTER_SCROLL_FINISHED_NONE);
}
static void
clutter_virtual_input_device_evdev_notify_touch_down (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int device_slot,
double x,
double y)
{
ClutterVirtualInputDeviceEvdev *virtual_evdev =
CLUTTER_VIRTUAL_INPUT_DEVICE_EVDEV (virtual_device);
ClutterInputDeviceEvdev *device_evdev =
CLUTTER_INPUT_DEVICE_EVDEV (virtual_evdev->device);
ClutterTouchState *touch_state;
if (time_us == CLUTTER_CURRENT_TIME)
time_us = g_get_monotonic_time ();
touch_state = clutter_input_device_evdev_acquire_touch_state (device_evdev,
device_slot);
if (!touch_state)
return;
touch_state->coords.x = x;
touch_state->coords.y = y;
clutter_seat_evdev_notify_touch_event (virtual_evdev->seat,
virtual_evdev->device,
CLUTTER_TOUCH_BEGIN,
time_us,
touch_state->seat_slot,
touch_state->coords.x,
touch_state->coords.y);
}
static void
clutter_virtual_input_device_evdev_notify_touch_motion (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int device_slot,
double x,
double y)
{
ClutterVirtualInputDeviceEvdev *virtual_evdev =
CLUTTER_VIRTUAL_INPUT_DEVICE_EVDEV (virtual_device);
ClutterInputDeviceEvdev *device_evdev =
CLUTTER_INPUT_DEVICE_EVDEV (virtual_evdev->device);
ClutterTouchState *touch_state;
if (time_us == CLUTTER_CURRENT_TIME)
time_us = g_get_monotonic_time ();
touch_state = clutter_input_device_evdev_lookup_touch_state (device_evdev,
device_slot);
if (!touch_state)
return;
touch_state->coords.x = x;
touch_state->coords.y = y;
clutter_seat_evdev_notify_touch_event (virtual_evdev->seat,
virtual_evdev->device,
CLUTTER_TOUCH_BEGIN,
time_us,
touch_state->seat_slot,
touch_state->coords.x,
touch_state->coords.y);
}
static void
clutter_virtual_input_device_evdev_notify_touch_up (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int device_slot)
{
ClutterVirtualInputDeviceEvdev *virtual_evdev =
CLUTTER_VIRTUAL_INPUT_DEVICE_EVDEV (virtual_device);
ClutterInputDeviceEvdev *device_evdev =
CLUTTER_INPUT_DEVICE_EVDEV (virtual_evdev->device);
ClutterTouchState *touch_state;
if (time_us == CLUTTER_CURRENT_TIME)
time_us = g_get_monotonic_time ();
touch_state = clutter_input_device_evdev_lookup_touch_state (device_evdev,
device_slot);
if (!touch_state)
return;
clutter_seat_evdev_notify_touch_event (virtual_evdev->seat,
virtual_evdev->device,
CLUTTER_TOUCH_BEGIN,
time_us,
touch_state->seat_slot,
touch_state->coords.x,
touch_state->coords.y);
clutter_input_device_evdev_release_touch_state (device_evdev, touch_state);
}
static void
clutter_virtual_input_device_evdev_get_property (GObject *object,
guint prop_id,
@ -485,6 +692,11 @@ clutter_virtual_input_device_evdev_class_init (ClutterVirtualInputDeviceEvdevCla
virtual_input_device_class->notify_button = clutter_virtual_input_device_evdev_notify_button;
virtual_input_device_class->notify_key = clutter_virtual_input_device_evdev_notify_key;
virtual_input_device_class->notify_keyval = clutter_virtual_input_device_evdev_notify_keyval;
virtual_input_device_class->notify_discrete_scroll = clutter_virtual_input_device_evdev_notify_discrete_scroll;
virtual_input_device_class->notify_scroll_continuous = clutter_virtual_input_device_evdev_notify_scroll_continuous;
virtual_input_device_class->notify_touch_down = clutter_virtual_input_device_evdev_notify_touch_down;
virtual_input_device_class->notify_touch_motion = clutter_virtual_input_device_evdev_notify_touch_motion;
virtual_input_device_class->notify_touch_up = clutter_virtual_input_device_evdev_notify_touch_up;
obj_props[PROP_SEAT] = g_param_spec_pointer ("seat",
P_("ClutterSeatEvdev"),

View File

@ -109,7 +109,6 @@ static const gchar *atom_names[] = {
#define N_ATOM_NAMES G_N_ELEMENTS (atom_names)
/* various flags corresponding to pre init setup calls */
static gboolean _want_reset_on_video_memory_purge = FALSE;
static gboolean _no_xevent_retrieval = FALSE;
static gboolean clutter_enable_xinput = TRUE;
static gboolean clutter_enable_argb = FALSE;
@ -682,8 +681,7 @@ clutter_backend_x11_get_renderer (ClutterBackend *backend,
/* set the display object we're using */
cogl_xlib_renderer_set_foreign_display (renderer, xdisplay);
cogl_xlib_renderer_request_reset_on_video_memory_purge (renderer,
_want_reset_on_video_memory_purge);
return renderer;
}
@ -1028,30 +1026,6 @@ clutter_x11_has_event_retrieval (void)
return !_no_xevent_retrieval;
}
/**
* clutter_x11_request_reset_on_video_memory_purge:
*
* If the GL driver supports the NV_robustness_video_memory_purge
* extension, this call lets applications request that it gets
* initialized, thus allowing cogl_get_graphics_reset_status() to
* report memory purged errors if they happen. Checking for the
* graphics reset status is the application's responsibility.
*
* This function can only be called before calling clutter_init().
*/
void
clutter_x11_request_reset_on_video_memory_purge (void)
{
if (_clutter_context_is_initialized ())
{
g_warning ("%s() can only be used before calling clutter_init()",
G_STRFUNC);
return;
}
_want_reset_on_video_memory_purge = TRUE;
}
/**
* clutter_x11_get_default_screen:
*

View File

@ -37,6 +37,7 @@
#include "clutter-event-translator.h"
#include "clutter-stage-private.h"
#include "clutter-private.h"
#include "clutter-xkb-a11y-x11.h"
enum
{
@ -352,9 +353,11 @@ static void
clutter_device_manager_x11_constructed (GObject *gobject)
{
ClutterDeviceManagerX11 *manager_x11;
ClutterDeviceManager *manager;
ClutterBackendX11 *backend_x11;
manager_x11 = CLUTTER_DEVICE_MANAGER_X11 (gobject);
manager = CLUTTER_DEVICE_MANAGER (gobject);
g_object_get (gobject, "backend", &backend_x11, NULL);
g_assert (backend_x11 != NULL);
@ -389,6 +392,8 @@ clutter_device_manager_x11_constructed (GObject *gobject)
_clutter_input_device_set_associated_device (manager_x11->core_keyboard,
manager_x11->core_pointer);
clutter_device_manager_x11_a11y_init (manager);
if (G_OBJECT_CLASS (clutter_device_manager_x11_parent_class)->constructed)
G_OBJECT_CLASS (clutter_device_manager_x11_parent_class)->constructed (gobject);
}
@ -485,6 +490,13 @@ clutter_device_manager_x11_create_virtual_device (ClutterDeviceManager *device_
return g_object_new (CLUTTER_TYPE_VIRTUAL_INPUT_DEVICE_X11, NULL);
}
static ClutterVirtualDeviceType
clutter_device_manager_x11_get_supported_virtual_device_types (ClutterDeviceManager *device_manager)
{
return (CLUTTER_VIRTUAL_DEVICE_TYPE_KEYBOARD |
CLUTTER_VIRTUAL_DEVICE_TYPE_POINTER);
}
static void
clutter_device_manager_x11_set_property (GObject *gobject,
guint prop_id,
@ -532,6 +544,8 @@ clutter_device_manager_x11_class_init (ClutterDeviceManagerX11Class *klass)
manager_class->get_core_device = clutter_device_manager_x11_get_core_device;
manager_class->get_device = clutter_device_manager_x11_get_device;
manager_class->create_virtual_device = clutter_device_manager_x11_create_virtual_device;
manager_class->get_supported_virtual_device_types = clutter_device_manager_x11_get_supported_virtual_device_types;
manager_class->apply_kbd_a11y_settings = clutter_device_manager_x11_apply_kbd_a11y_settings;
}
static void

View File

@ -40,6 +40,7 @@
#include "clutter-event-translator.h"
#include "clutter-stage-private.h"
#include "clutter-private.h"
#include "clutter-xkb-a11y-x11.h"
#include <X11/extensions/XInput2.h>
@ -66,6 +67,14 @@ static const char *clutter_input_axis_atom_names[] = {
#define N_AXIS_ATOMS G_N_ELEMENTS (clutter_input_axis_atom_names)
enum {
PAD_AXIS_FIRST = 3, /* First axes are always x/y/pressure, ignored in pads */
PAD_AXIS_STRIP1 = PAD_AXIS_FIRST,
PAD_AXIS_STRIP2,
PAD_AXIS_RING1,
PAD_AXIS_RING2,
};
static Atom clutter_input_axis_atoms[N_AXIS_ATOMS] = { 0, };
static void clutter_event_translator_iface_init (ClutterEventTranslatorIface *iface);
@ -359,6 +368,36 @@ get_device_node_path (ClutterBackendX11 *backend_x11,
return node_path;
}
static void
get_pad_features (XIDeviceInfo *info,
guint *n_rings,
guint *n_strips)
{
gint i, rings = 0, strips = 0;
for (i = PAD_AXIS_FIRST; i < info->num_classes; i++)
{
XIValuatorClassInfo *valuator = (XIValuatorClassInfo*) info->classes[i];
int axis = valuator->number;
if (valuator->type != XIValuatorClass)
continue;
if (valuator->max <= 1)
continue;
/* Ring/strip axes are fixed in pad devices as handled by the
* wacom driver. Match those to detect pad features.
*/
if (axis == PAD_AXIS_STRIP1 || axis == PAD_AXIS_STRIP2)
strips++;
else if (axis == PAD_AXIS_RING1 || axis == PAD_AXIS_RING2)
rings++;
}
*n_rings = rings;
*n_strips = strips;
}
static ClutterInputDevice *
create_device (ClutterDeviceManagerXI2 *manager_xi2,
ClutterBackendX11 *backend_x11,
@ -368,7 +407,7 @@ create_device (ClutterDeviceManagerXI2 *manager_xi2,
ClutterInputDevice *retval;
ClutterInputMode mode;
gboolean is_enabled;
guint num_touches = 0;
guint num_touches = 0, num_rings = 0, num_strips = 0;
gchar *vendor_id = NULL, *product_id = NULL, *node_path = NULL;
if (info->use == XIMasterKeyboard || info->use == XISlaveKeyboard)
@ -436,6 +475,12 @@ create_device (ClutterDeviceManagerXI2 *manager_xi2,
node_path = get_device_node_path (backend_x11, info);
}
if (source == CLUTTER_PAD_DEVICE)
{
is_enabled = TRUE;
get_pad_features (info, &num_rings, &num_strips);
}
retval = g_object_new (CLUTTER_TYPE_INPUT_DEVICE_XI2,
"name", info->name,
"id", info->deviceid,
@ -448,13 +493,23 @@ create_device (ClutterDeviceManagerXI2 *manager_xi2,
"vendor-id", vendor_id,
"product-id", product_id,
"device-node", node_path,
"n-rings", num_rings,
"n-strips", num_strips,
"n-mode-groups", MAX (num_rings, num_strips),
NULL);
translate_device_classes (backend_x11->xdpy, retval,
info->classes,
info->num_classes);
#ifdef HAVE_LIBWACOM
if (source == CLUTTER_PAD_DEVICE)
clutter_input_device_xi2_ensure_wacom_info (retval, manager_xi2->wacom_db);
#endif
g_free (vendor_id);
g_free (product_id);
g_free (node_path);
CLUTTER_NOTE (BACKEND, "Created device '%s' (id: %d, has-cursor: %s)",
info->name,
@ -847,6 +902,54 @@ translate_axes (ClutterInputDevice *device,
return retval;
}
static gboolean
translate_pad_axis (ClutterInputDevice *device,
XIValuatorState *valuators,
ClutterEventType *evtype,
guint *number,
gdouble *value)
{
double *values;
gint i;
values = valuators->values;
for (i = PAD_AXIS_FIRST; i < valuators->mask_len * 8; i++)
{
gdouble val;
guint axis_number = 0;
if (!XIMaskIsSet (valuators->mask, i))
continue;
val = *values++;
if (val <= 0)
continue;
_clutter_input_device_translate_axis (device, i, val, value);
if (i == PAD_AXIS_RING1 || i == PAD_AXIS_RING2)
{
*evtype = CLUTTER_PAD_RING;
(*value) *= 360.0;
}
else if (i == PAD_AXIS_STRIP1 || i == PAD_AXIS_STRIP2)
{
*evtype = CLUTTER_PAD_STRIP;
}
else
continue;
if (i == PAD_AXIS_STRIP2 || i == PAD_AXIS_RING2)
axis_number++;
*number = axis_number;
return TRUE;
}
return FALSE;
}
static void
translate_coords (ClutterStageX11 *stage_x11,
gdouble event_x,
@ -1025,6 +1128,60 @@ handle_property_event (ClutterDeviceManagerXI2 *manager_xi2,
}
}
static gboolean
translate_pad_event (ClutterEvent *event,
XIDeviceEvent *xev,
ClutterInputDevice *device)
{
gdouble value;
guint number, mode = 0;
if (!translate_pad_axis (device, &xev->valuators,
&event->any.type,
&number, &value))
return FALSE;
/* When touching a ring/strip a first XI_Motion event
* is generated. Use it to reset the pad state, so
* later events actually have a directionality.
*/
if (xev->evtype == XI_Motion)
value = -1;
#ifdef HAVE_LIBWACOM
mode = clutter_input_device_xi2_get_pad_group_mode (device, number);
#endif
if (event->any.type == CLUTTER_PAD_RING)
{
event->pad_ring.ring_number = number;
event->pad_ring.angle = value;
event->pad_ring.mode = mode;
}
else
{
event->pad_strip.strip_number = number;
event->pad_strip.value = value;
event->pad_strip.mode = mode;
}
event->any.time = xev->time;
clutter_event_set_device (event, device);
clutter_event_set_source_device (event, device);
CLUTTER_NOTE (EVENT,
"%s: win:0x%x, device:%d '%s', time:%d "
"(value:%f)",
event->any.type == CLUTTER_PAD_RING
? "pad ring "
: "pad strip",
(unsigned int) xev->event,
device->id,
device->device_name,
event->any.time, value);
return TRUE;
}
static ClutterTranslateReturn
clutter_device_manager_xi2_translate_event (ClutterEventTranslator *translator,
gpointer native,
@ -1114,6 +1271,9 @@ clutter_device_manager_xi2_translate_event (ClutterEventTranslator *translator,
? CLUTTER_KEY_PRESS
: CLUTTER_KEY_RELEASE;
if (xev->evtype == XI_KeyPress && xev->flags & XIKeyRepeat)
clutter_event_set_flags (event, CLUTTER_EVENT_FLAG_REPEATED);
event->key.time = xev->time;
event->key.stage = stage;
_clutter_input_device_xi2_translate_state (event, &xev->mods, &xev->buttons, &xev->group);
@ -1206,15 +1366,23 @@ clutter_device_manager_xi2_translate_event (ClutterEventTranslator *translator,
XIAsyncDevice,
xev->time);
/* Ignore 4-7 buttons */
if (xev->detail >= 4 && xev->detail <= 7)
return CLUTTER_TRANSLATE_REMOVE;
event->any.stage = stage;
event->pad_button.type =
if (xev->detail >= 4 && xev->detail <= 7)
{
retval = CLUTTER_TRANSLATE_REMOVE;
if (xi_event->evtype == XI_ButtonPress &&
translate_pad_event (event, xev, source_device))
retval = CLUTTER_TRANSLATE_QUEUE;
break;
}
event->any.type =
(xi_event->evtype == XI_ButtonPress) ? CLUTTER_PAD_BUTTON_PRESS
: CLUTTER_PAD_BUTTON_RELEASE;
event->pad_button.time = xev->time;
event->pad_button.stage = stage;
event->any.time = xev->time;
/* The 4-7 button range is taken as non-existent on pad devices,
* let the buttons above that take over this range.
@ -1224,6 +1392,14 @@ clutter_device_manager_xi2_translate_event (ClutterEventTranslator *translator,
/* Pad buttons are 0-indexed */
event->pad_button.button = xev->detail - 1;
#ifdef HAVE_LIBWACOM
clutter_input_device_xi2_update_pad_state (device,
event->pad_button.button,
(xi_event->evtype == XI_ButtonPress),
&event->pad_button.group,
&event->pad_button.mode);
#endif
clutter_event_set_device (event, device);
clutter_event_set_source_device (event, source_device);
CLUTTER_NOTE (EVENT,
@ -1380,6 +1556,15 @@ clutter_device_manager_xi2_translate_event (ClutterEventTranslator *translator,
device = g_hash_table_lookup (manager_xi2->devices_by_id,
GINT_TO_POINTER (xev->deviceid));
if (clutter_input_device_get_device_type (source_device) == CLUTTER_PAD_DEVICE)
{
event->any.stage = stage;
if (translate_pad_event (event, xev, source_device))
retval = CLUTTER_TRANSLATE_QUEUE;
break;
}
/* Set the stage for core events coming out of nowhere (see bug #684509) */
if (clutter_input_device_get_device_mode (device) == CLUTTER_INPUT_MODE_MASTER &&
clutter_input_device_get_pointer_stage (device) == NULL &&
@ -1827,6 +2012,8 @@ clutter_device_manager_xi2_constructed (GObject *gobject)
XSync (backend_x11->xdpy, False);
clutter_device_manager_x11_a11y_init (manager);
if (G_OBJECT_CLASS (clutter_device_manager_xi2_parent_class)->constructed)
G_OBJECT_CLASS (clutter_device_manager_xi2_parent_class)->constructed (gobject);
}
@ -1861,6 +2048,13 @@ clutter_device_manager_xi2_create_virtual_device (ClutterDeviceManager *manage
NULL);
}
static ClutterVirtualDeviceType
clutter_device_manager_xi2_get_supported_virtual_device_types (ClutterDeviceManager *device_manager)
{
return (CLUTTER_VIRTUAL_DEVICE_TYPE_KEYBOARD |
CLUTTER_VIRTUAL_DEVICE_TYPE_POINTER);
}
static void
clutter_device_manager_xi2_class_init (ClutterDeviceManagerXI2Class *klass)
{
@ -1889,6 +2083,8 @@ clutter_device_manager_xi2_class_init (ClutterDeviceManagerXI2Class *klass)
manager_class->get_device = clutter_device_manager_xi2_get_device;
manager_class->select_stage_events = clutter_device_manager_xi2_select_stage_events;
manager_class->create_virtual_device = clutter_device_manager_xi2_create_virtual_device;
manager_class->get_supported_virtual_device_types = clutter_device_manager_xi2_get_supported_virtual_device_types;
manager_class->apply_kbd_a11y_settings = clutter_device_manager_x11_apply_kbd_a11y_settings;
}
static void
@ -1899,4 +2095,8 @@ clutter_device_manager_xi2_init (ClutterDeviceManagerXI2 *self)
(GDestroyNotify) g_object_unref);
self->tools_by_serial = g_hash_table_new_full (NULL, NULL, NULL,
(GDestroyNotify) g_object_unref);
#ifdef HAVE_LIBWACOM
self->wacom_db = libwacom_database_new ();
#endif
}

View File

@ -26,6 +26,10 @@
#include <clutter/clutter-device-manager.h>
#ifdef HAVE_LIBWACOM
#include <libwacom/libwacom.h>
#endif
G_BEGIN_DECLS
#define CLUTTER_TYPE_DEVICE_MANAGER_XI2 (_clutter_device_manager_xi2_get_type ())
@ -51,6 +55,10 @@ struct _ClutterDeviceManagerXI2
GList *slave_devices;
int opcode;
#ifdef HAVE_LIBWACOM
WacomDeviceDatabase *wacom_db;
#endif
};
struct _ClutterDeviceManagerXI2Class

View File

@ -45,6 +45,11 @@ struct _ClutterInputDeviceXI2
gint device_id;
ClutterInputDeviceTool *current_tool;
#ifdef HAVE_LIBWACOM
WacomDevice *wacom_device;
GArray *group_modes;
#endif
};
#define N_BUTTONS 5
@ -64,6 +69,15 @@ clutter_input_device_xi2_constructed (GObject *gobject)
if (G_OBJECT_CLASS (clutter_input_device_xi2_parent_class)->constructed)
G_OBJECT_CLASS (clutter_input_device_xi2_parent_class)->constructed (gobject);
#ifdef HAVE_LIBWACOM
if (clutter_input_device_get_device_type (CLUTTER_INPUT_DEVICE (gobject)) == CLUTTER_PAD_DEVICE)
{
device_xi2->group_modes = g_array_new (FALSE, TRUE, sizeof (guint));
g_array_set_size (device_xi2->group_modes,
clutter_input_device_get_n_mode_groups (CLUTTER_INPUT_DEVICE (gobject)));
}
#endif
}
static gboolean
@ -87,6 +101,85 @@ clutter_input_device_xi2_is_grouped (ClutterInputDevice *device,
return FALSE;
}
static void
clutter_input_device_xi2_finalize (GObject *object)
{
#ifdef HAVE_LIBWACOM
ClutterInputDeviceXI2 *device_xi2 = CLUTTER_INPUT_DEVICE_XI2 (object);
if (device_xi2->wacom_device)
libwacom_destroy (device_xi2->wacom_device);
if (device_xi2->group_modes)
g_array_unref (device_xi2->group_modes);
#endif
G_OBJECT_CLASS (clutter_input_device_xi2_parent_class)->finalize (object);
}
static gint
clutter_input_device_xi2_get_group_n_modes (ClutterInputDevice *device,
gint group)
{
#ifdef HAVE_LIBWACOM
ClutterInputDeviceXI2 *device_xi2 = CLUTTER_INPUT_DEVICE_XI2 (device);
if (device_xi2->wacom_device)
{
if (group == 0)
{
if (libwacom_has_ring (device_xi2->wacom_device))
return libwacom_get_ring_num_modes (device_xi2->wacom_device);
else if (libwacom_get_num_strips (device_xi2->wacom_device) >= 1)
return libwacom_get_strips_num_modes (device_xi2->wacom_device);
}
else if (group == 1)
{
if (libwacom_has_ring2 (device_xi2->wacom_device))
return libwacom_get_ring2_num_modes (device_xi2->wacom_device);
else if (libwacom_get_num_strips (device_xi2->wacom_device) >= 2)
return libwacom_get_strips_num_modes (device_xi2->wacom_device);
}
}
#endif
return -1;
}
#ifdef HAVE_LIBWACOM
static int
clutter_input_device_xi2_get_button_group (ClutterInputDevice *device,
guint button)
{
ClutterInputDeviceXI2 *device_xi2 = CLUTTER_INPUT_DEVICE_XI2 (device);
if (device_xi2->wacom_device)
{
if (button >= libwacom_get_num_buttons (device_xi2->wacom_device))
return -1;
return libwacom_get_button_led_group (device_xi2->wacom_device,
'A' + button);
}
else
return -1;
}
#endif
static gboolean
clutter_input_device_xi2_is_mode_switch_button (ClutterInputDevice *device,
guint group,
guint button)
{
int button_group = -1;
#ifdef HAVE_LIBWACOM
button_group = clutter_input_device_xi2_get_button_group (device, button);
#endif
return button_group == (int) group;
}
static void
clutter_input_device_xi2_class_init (ClutterInputDeviceXI2Class *klass)
{
@ -94,9 +187,12 @@ clutter_input_device_xi2_class_init (ClutterInputDeviceXI2Class *klass)
ClutterInputDeviceClass *device_class = CLUTTER_INPUT_DEVICE_CLASS (klass);
gobject_class->constructed = clutter_input_device_xi2_constructed;
gobject_class->finalize = clutter_input_device_xi2_finalize;
device_class->keycode_to_evdev = clutter_input_device_xi2_keycode_to_evdev;
device_class->is_grouped = clutter_input_device_xi2_is_grouped;
device_class->get_group_n_modes = clutter_input_device_xi2_get_group_n_modes;
device_class->is_mode_switch_button = clutter_input_device_xi2_is_mode_switch_button;
}
static void
@ -196,3 +292,66 @@ clutter_input_device_xi2_get_current_tool (ClutterInputDevice *device)
ClutterInputDeviceXI2 *device_xi2 = CLUTTER_INPUT_DEVICE_XI2 (device);
return device_xi2->current_tool;
}
#ifdef HAVE_LIBWACOM
void
clutter_input_device_xi2_ensure_wacom_info (ClutterInputDevice *device,
WacomDeviceDatabase *wacom_db)
{
ClutterInputDeviceXI2 *device_xi2 = CLUTTER_INPUT_DEVICE_XI2 (device);
const gchar *node_path;
node_path = clutter_input_device_get_device_node (device);
device_xi2->wacom_device = libwacom_new_from_path (wacom_db, node_path,
WFALLBACK_NONE, NULL);
}
guint
clutter_input_device_xi2_get_pad_group_mode (ClutterInputDevice *device,
guint group)
{
ClutterInputDeviceXI2 *device_xi2 = CLUTTER_INPUT_DEVICE_XI2 (device);
if (group >= device_xi2->group_modes->len)
return 0;
return g_array_index (device_xi2->group_modes, guint, group);
}
void
clutter_input_device_xi2_update_pad_state (ClutterInputDevice *device,
guint button,
guint state,
guint *group,
guint *mode)
{
ClutterInputDeviceXI2 *device_xi2 = CLUTTER_INPUT_DEVICE_XI2 (device);
guint button_group, *group_mode;
gboolean is_mode_switch = FALSE;
button_group = clutter_input_device_xi2_get_button_group (device, button);
is_mode_switch = button_group >= 0;
/* Assign all non-mode-switch buttons to group 0 so far */
button_group = MAX (0, button_group);
if (button_group >= device_xi2->group_modes->len)
return;
group_mode = &g_array_index (device_xi2->group_modes, guint, button_group);
if (is_mode_switch && state)
{
guint next, n_modes;
n_modes = clutter_input_device_get_group_n_modes (device, button_group);
next = (*group_mode + 1) % n_modes;
*group_mode = next;
}
if (group)
*group = button_group;
if (mode)
*mode = *group_mode;
}
#endif

View File

@ -27,6 +27,10 @@
#include <clutter/clutter-input-device.h>
#include <X11/extensions/XInput2.h>
#ifdef HAVE_LIBWACOM
#include <libwacom/libwacom.h>
#endif
G_BEGIN_DECLS
#define CLUTTER_TYPE_INPUT_DEVICE_XI2 (_clutter_input_device_xi2_get_type ())
@ -45,6 +49,21 @@ void clutter_input_device_xi2_update_tool (ClutterInputDevice *device,
ClutterInputDeviceTool *tool);
ClutterInputDeviceTool * clutter_input_device_xi2_get_current_tool (ClutterInputDevice *device);
#ifdef HAVE_LIBWACOM
void clutter_input_device_xi2_ensure_wacom_info (ClutterInputDevice *device,
WacomDeviceDatabase *wacom_db);
guint clutter_input_device_xi2_get_pad_group_mode (ClutterInputDevice *device,
guint group);
void clutter_input_device_xi2_update_pad_state (ClutterInputDevice *device,
guint button,
guint state,
guint *group,
guint *mode);
#endif
G_END_DECLS
#endif /* __CLUTTER_INPUT_DEVICE_XI2_H__ */

View File

@ -38,6 +38,14 @@
typedef struct _ClutterKeymapX11Class ClutterKeymapX11Class;
typedef struct _DirectionCacheEntry DirectionCacheEntry;
typedef struct _ClutterKeymapKey ClutterKeymapKey;
struct _ClutterKeymapKey
{
guint keycode;
guint group;
guint level;
};
struct _DirectionCacheEntry
{
@ -59,6 +67,7 @@ struct _ClutterKeymapX11
ClutterModifierType num_lock_mask;
ClutterModifierType scroll_lock_mask;
ClutterModifierType level3_shift_mask;
PangoDirection current_direction;
@ -69,6 +78,7 @@ struct _ClutterKeymapX11
Atom current_group_atom;
guint current_cache_serial;
DirectionCacheEntry group_direction_cache[4];
int current_group;
#endif
guint caps_lock_state : 1;
@ -198,6 +208,9 @@ get_xkb (ClutterKeymapX11 *keymap_x11)
if (keymap_x11->scroll_lock_mask == 0)
keymap_x11->scroll_lock_mask = XkbKeysymToModifiers (backend_x11->xdpy,
XK_Scroll_Lock);
if (keymap_x11->level3_shift_mask == 0)
keymap_x11->level3_shift_mask = XkbKeysymToModifiers (backend_x11->xdpy,
XK_ISO_Level3_Shift);
return keymap_x11->xkb_desc;
}
@ -469,6 +482,7 @@ static void
clutter_keymap_x11_init (ClutterKeymapX11 *keymap)
{
keymap->current_direction = PANGO_DIRECTION_NEUTRAL;
keymap->current_group = -1;
}
static ClutterTranslateReturn
@ -498,7 +512,8 @@ clutter_keymap_x11_translate_event (ClutterEventTranslator *translator,
{
case XkbStateNotify:
CLUTTER_NOTE (EVENT, "Updating keyboard state");
update_direction (keymap_x11, XkbStateGroup (&xkb_event->state));
keymap_x11->current_group = XkbStateGroup (&xkb_event->state);
update_direction (keymap_x11, keymap_x11->current_group);
update_locked_mods (keymap_x11, xkb_event->state.locked_mods);
retval = CLUTTER_TRANSLATE_REMOVE;
break;
@ -665,3 +680,164 @@ _clutter_keymap_x11_get_direction (ClutterKeymapX11 *keymap)
#endif
return PANGO_DIRECTION_NEUTRAL;
}
static gboolean
clutter_keymap_x11_get_entries_for_keyval (ClutterKeymapX11 *keymap_x11,
guint keyval,
ClutterKeymapKey **keys,
gint *n_keys)
{
#ifdef HAVE_XKB
if (CLUTTER_BACKEND_X11 (keymap_x11->backend)->use_xkb)
{
XkbDescRec *xkb = get_xkb (keymap_x11);
GArray *retval;
gint keycode;
keycode = keymap_x11->min_keycode;
retval = g_array_new (FALSE, FALSE, sizeof (ClutterKeymapKey));
while (keycode <= keymap_x11->max_keycode)
{
gint max_shift_levels = XkbKeyGroupsWidth (xkb, keycode);
gint group = 0;
gint level = 0;
gint total_syms = XkbKeyNumSyms (xkb, keycode);
gint i = 0;
KeySym *entry;
/* entry is an array with all syms for group 0, all
* syms for group 1, etc. and for each group the
* shift level syms are in order
*/
entry = XkbKeySymsPtr (xkb, keycode);
while (i < total_syms)
{
g_assert (i == (group * max_shift_levels + level));
if (entry[i] == keyval)
{
ClutterKeymapKey key;
key.keycode = keycode;
key.group = group;
key.level = level;
g_array_append_val (retval, key);
g_assert (XkbKeySymEntry (xkb, keycode, level, group) ==
keyval);
}
++level;
if (level == max_shift_levels)
{
level = 0;
++group;
}
++i;
}
++keycode;
}
if (retval->len > 0)
{
*keys = (ClutterKeymapKey*) retval->data;
*n_keys = retval->len;
}
else
{
*keys = NULL;
*n_keys = 0;
}
g_array_free (retval, retval->len > 0 ? FALSE : TRUE);
return *n_keys > 0;
}
else
#endif
{
return FALSE;
}
}
void
clutter_keymap_x11_latch_modifiers (ClutterKeymapX11 *keymap_x11,
uint32_t level,
gboolean enable)
{
#ifdef HAVE_XKB
ClutterBackendX11 *backend_x11 = CLUTTER_BACKEND_X11 (keymap_x11->backend);
uint32_t modifiers[] = {
0,
ShiftMask,
keymap_x11->level3_shift_mask,
keymap_x11->level3_shift_mask | ShiftMask,
};
uint32_t value = 0;
if (!backend_x11->use_xkb)
return;
level = CLAMP (level, 0, G_N_ELEMENTS (modifiers) - 1);
if (enable)
value = modifiers[level];
else
value = 0;
XkbLatchModifiers (clutter_x11_get_default_display (),
XkbUseCoreKbd, modifiers[level],
value);
#endif
}
static uint32_t
clutter_keymap_x11_get_current_group (ClutterKeymapX11 *keymap_x11)
{
ClutterBackendX11 *backend_x11 = CLUTTER_BACKEND_X11 (keymap_x11->backend);
XkbStateRec state_rec;
if (keymap_x11->current_group >= 0)
return keymap_x11->current_group;
XkbGetState (backend_x11->xdpy, XkbUseCoreKbd, &state_rec);
return XkbStateGroup (&state_rec);
}
gboolean
clutter_keymap_x11_keycode_for_keyval (ClutterKeymapX11 *keymap_x11,
guint keyval,
guint *keycode_out,
guint *level_out)
{
ClutterKeymapKey *keys;
gint i, n_keys, group;
gboolean found = FALSE;
g_return_val_if_fail (keycode_out != NULL, FALSE);
g_return_val_if_fail (level_out != NULL, FALSE);
group = clutter_keymap_x11_get_current_group (keymap_x11);
if (!clutter_keymap_x11_get_entries_for_keyval (keymap_x11, keyval, &keys, &n_keys))
return FALSE;
for (i = 0; i < n_keys && !found; i++)
{
if (keys[i].group == group)
{
*keycode_out = keys[i].keycode;
*level_out = keys[i].level;
found = TRUE;
}
}
g_free (keys);
return found;
}

View File

@ -51,6 +51,14 @@ gboolean _clutter_keymap_x11_get_is_modifier (ClutterKeymapX11 *keymap,
PangoDirection _clutter_keymap_x11_get_direction (ClutterKeymapX11 *keymap);
gboolean clutter_keymap_x11_keycode_for_keyval (ClutterKeymapX11 *keymap_x11,
guint keyval,
guint *keycode_out,
guint *level_out);
void clutter_keymap_x11_latch_modifiers (ClutterKeymapX11 *keymap_x11,
uint32_t level,
gboolean enable);
G_END_DECLS
#endif /* __CLUTTER_KEYMAP_X11_H__ */

View File

@ -10,12 +10,10 @@ static const struct {
{ "Net/DndDragThreshold", "dnd-drag-threshold" },
{ "Gtk/FontName", "font-name" },
{ "Xft/Antialias", "font-antialias" },
{ "Xft/DPI", "font-dpi" },
{ "Xft/Hinting", "font-hinting" },
{ "Xft/HintStyle", "font-hint-style" },
{ "Xft/RGBA", "font-subpixel-order" },
{ "Fontconfig/Timestamp", "fontconfig-timestamp" },
{ "Gdk/UnscaledDPI", "unscaled-font-dpi" },
};
static const gint _n_clutter_settings_map = G_N_ELEMENTS (_clutter_settings_map);

View File

@ -32,6 +32,8 @@
#include "clutter-virtual-input-device.h"
#include "x11/clutter-virtual-input-device-x11.h"
#include "x11/clutter-backend-x11.h"
#include "x11/clutter-keymap-x11.h"
struct _ClutterVirtualInputDeviceX11
{
@ -48,6 +50,10 @@ clutter_virtual_input_device_x11_notify_relative_motion (ClutterVirtualInputDevi
double dx,
double dy)
{
XTestFakeRelativeMotionEvent (clutter_x11_get_default_display (),
(int) dx,
(int) dy,
0);
}
static void
@ -56,6 +62,11 @@ clutter_virtual_input_device_x11_notify_absolute_motion (ClutterVirtualInputDevi
double x,
double y)
{
XTestFakeMotionEvent (clutter_x11_get_default_display (),
clutter_x11_get_default_screen (),
(int) x,
(int) y,
0);
}
static void
@ -68,6 +79,48 @@ clutter_virtual_input_device_x11_notify_button (ClutterVirtualInputDevice *virtu
button, button_state == CLUTTER_BUTTON_STATE_PRESSED, 0);
}
static void
clutter_virtual_input_device_x11_notify_discrete_scroll (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
ClutterScrollDirection direction,
ClutterScrollSource scroll_source)
{
Display *xdisplay = clutter_x11_get_default_display ();
int button;
switch (direction)
{
case CLUTTER_SCROLL_UP:
button = 4;
break;
case CLUTTER_SCROLL_DOWN:
button = 5;
break;
case CLUTTER_SCROLL_LEFT:
button = 6;
break;
case CLUTTER_SCROLL_RIGHT:
button = 7;
break;
default:
g_warn_if_reached ();
return;
}
XTestFakeButtonEvent (xdisplay, button, True, 0);
XTestFakeButtonEvent (xdisplay, button, False, 0);
}
static void
clutter_virtual_input_device_x11_notify_scroll_continuous (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
double dx,
double dy,
ClutterScrollSource scroll_source,
ClutterScrollFinishFlags finish_flags)
{
}
static void
clutter_virtual_input_device_x11_notify_key (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
@ -84,11 +137,53 @@ clutter_virtual_input_device_x11_notify_keyval (ClutterVirtualInputDevice *virtu
uint32_t keyval,
ClutterKeyState key_state)
{
KeyCode keycode;
ClutterBackendX11 *backend_x11 = CLUTTER_BACKEND_X11 (clutter_get_default_backend ());
ClutterKeymapX11 *keymap = backend_x11->keymap;
uint32_t keycode, level;
if (!clutter_keymap_x11_keycode_for_keyval (keymap, keyval, &keycode, &level))
{
g_warning ("No keycode found for keyval %x in current group", keyval);
return;
}
if (key_state == CLUTTER_KEY_STATE_PRESSED)
clutter_keymap_x11_latch_modifiers (keymap, level, TRUE);
keycode = XKeysymToKeycode (clutter_x11_get_default_display (), keyval);
XTestFakeKeyEvent (clutter_x11_get_default_display (),
keycode, key_state == CLUTTER_KEY_STATE_PRESSED, 0);
(KeyCode) keycode,
key_state == CLUTTER_KEY_STATE_PRESSED, 0);
if (key_state == CLUTTER_KEY_STATE_RELEASED)
clutter_keymap_x11_latch_modifiers (keymap, level, FALSE);
}
static void
clutter_virtual_input_device_x11_notify_touch_down (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int device_slot,
double x,
double y)
{
g_warning ("Virtual touch motion not implemented under X11");
}
static void
clutter_virtual_input_device_x11_notify_touch_motion (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int device_slot,
double x,
double y)
{
g_warning ("Virtual touch motion not implemented under X11");
}
static void
clutter_virtual_input_device_x11_notify_touch_up (ClutterVirtualInputDevice *virtual_device,
uint64_t time_us,
int device_slot)
{
g_warning ("Virtual touch motion not implemented under X11");
}
static void
@ -105,6 +200,11 @@ clutter_virtual_input_device_x11_class_init (ClutterVirtualInputDeviceX11Class *
virtual_input_device_class->notify_relative_motion = clutter_virtual_input_device_x11_notify_relative_motion;
virtual_input_device_class->notify_absolute_motion = clutter_virtual_input_device_x11_notify_absolute_motion;
virtual_input_device_class->notify_button = clutter_virtual_input_device_x11_notify_button;
virtual_input_device_class->notify_discrete_scroll = clutter_virtual_input_device_x11_notify_discrete_scroll;
virtual_input_device_class->notify_scroll_continuous = clutter_virtual_input_device_x11_notify_scroll_continuous;
virtual_input_device_class->notify_key = clutter_virtual_input_device_x11_notify_key;
virtual_input_device_class->notify_keyval = clutter_virtual_input_device_x11_notify_keyval;
virtual_input_device_class->notify_touch_down = clutter_virtual_input_device_x11_notify_touch_down;
virtual_input_device_class->notify_touch_motion = clutter_virtual_input_device_x11_notify_touch_motion;
virtual_input_device_class->notify_touch_up = clutter_virtual_input_device_x11_notify_touch_up;
}

View File

@ -161,9 +161,6 @@ gint clutter_x11_event_get_key_group (const ClutterEvent *event);
CLUTTER_AVAILABLE_IN_ALL
guint clutter_x11_event_sequence_get_touch_detail (const ClutterEventSequence *sequence);
CLUTTER_AVAILABLE_IN_ALL
void clutter_x11_request_reset_on_video_memory_purge (void);
G_END_DECLS
#endif /* __CLUTTER_X11_H__ */

View File

@ -0,0 +1,328 @@
/*
*
* Copyright © 2001 Ximian, Inc.
* Copyright (C) 2007 William Jon McCann <mccann@jhu.edu>
* Copyright (C) 2017 Red Hat
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
* 02111-1307, USA.
*
*/
#include "clutter-device-manager-private.h"
#include "clutter-xkb-a11y-x11.h"
#include <X11/XKBlib.h>
#include <X11/extensions/XKBstr.h>
#define DEFAULT_XKB_SET_CONTROLS_MASK XkbSlowKeysMask | \
XkbBounceKeysMask | \
XkbStickyKeysMask | \
XkbMouseKeysMask | \
XkbMouseKeysAccelMask | \
XkbAccessXKeysMask | \
XkbAccessXTimeoutMask | \
XkbAccessXFeedbackMask | \
XkbControlsEnabledMask
static int _xkb_event_base;
static XkbDescRec *
get_xkb_desc_rec (ClutterBackendX11 *backend_x11)
{
XkbDescRec *desc;
Status status = Success;
clutter_x11_trap_x_errors ();
desc = XkbGetMap (backend_x11->xdpy, XkbAllMapComponentsMask, XkbUseCoreKbd);
if (desc != NULL)
{
desc->ctrls = NULL;
status = XkbGetControls (backend_x11->xdpy, XkbAllControlsMask, desc);
}
clutter_x11_untrap_x_errors ();
g_return_val_if_fail (desc != NULL, NULL);
g_return_val_if_fail (desc->ctrls != NULL, NULL);
g_return_val_if_fail (status == Success, NULL);
return desc;
}
static void
set_xkb_desc_rec (ClutterBackendX11 *backend_x11,
XkbDescRec *desc)
{
clutter_x11_trap_x_errors ();
XkbSetControls (backend_x11->xdpy, DEFAULT_XKB_SET_CONTROLS_MASK, desc);
XSync (backend_x11->xdpy, FALSE);
clutter_x11_untrap_x_errors ();
}
static void
check_settings_changed (ClutterDeviceManager *device_manager)
{
ClutterBackendX11 *backend_x11;
ClutterKbdA11ySettings kbd_a11y_settings;
ClutterKeyboardA11yFlags what_changed = 0;
XkbDescRec *desc;
backend_x11 = CLUTTER_BACKEND_X11 (clutter_get_default_backend ());
desc = get_xkb_desc_rec (backend_x11);
if (!desc)
return;
clutter_device_manager_get_kbd_a11y_settings (device_manager, &kbd_a11y_settings);
if (desc->ctrls->enabled_ctrls & XkbSlowKeysMask &&
!(kbd_a11y_settings.controls & CLUTTER_A11Y_SLOW_KEYS_ENABLED))
{
what_changed |= CLUTTER_A11Y_SLOW_KEYS_ENABLED;
kbd_a11y_settings.controls |= CLUTTER_A11Y_SLOW_KEYS_ENABLED;
}
else if (!(desc->ctrls->enabled_ctrls & XkbSlowKeysMask) &&
kbd_a11y_settings.controls & CLUTTER_A11Y_SLOW_KEYS_ENABLED)
{
what_changed |= CLUTTER_A11Y_SLOW_KEYS_ENABLED;
kbd_a11y_settings.controls &= ~CLUTTER_A11Y_SLOW_KEYS_ENABLED;
}
if (desc->ctrls->enabled_ctrls & XkbStickyKeysMask &&
!(kbd_a11y_settings.controls & CLUTTER_A11Y_STICKY_KEYS_ENABLED))
{
what_changed |= CLUTTER_A11Y_STICKY_KEYS_ENABLED;
kbd_a11y_settings.controls |= CLUTTER_A11Y_STICKY_KEYS_ENABLED;
}
else if (!(desc->ctrls->enabled_ctrls & XkbStickyKeysMask) &&
kbd_a11y_settings.controls & CLUTTER_A11Y_STICKY_KEYS_ENABLED)
{
what_changed |= CLUTTER_A11Y_STICKY_KEYS_ENABLED;
kbd_a11y_settings.controls &= ~CLUTTER_A11Y_STICKY_KEYS_ENABLED;
}
if (what_changed)
g_signal_emit_by_name (device_manager,
"kbd-a11y-flags-changed",
kbd_a11y_settings.controls,
what_changed);
XkbFreeKeyboard (desc, XkbAllComponentsMask, TRUE);
}
static ClutterX11FilterReturn
xkb_a11y_event_filter (XEvent *xevent,
ClutterEvent *clutter_event,
gpointer data)
{
ClutterDeviceManager *device_manager = CLUTTER_DEVICE_MANAGER (data);
XkbEvent *xkbev = (XkbEvent *) xevent;
/* 'event_type' is set to zero on notifying us of updates in
* response to client requests (including our own) and non-zero
* to notify us of key/mouse events causing changes (like
* pressing shift 5 times to enable sticky keys).
*
* We only want to update out settings when it's in response to an
* explicit user input event, so require a non-zero event_type.
*/
if (xevent->xany.type == (_xkb_event_base + XkbEventCode) &&
xkbev->any.xkb_type == XkbControlsNotify && xkbev->ctrls.event_type != 0)
check_settings_changed (device_manager);
return CLUTTER_X11_FILTER_CONTINUE;
}
static gboolean
is_xkb_available (ClutterBackendX11 *backend_x11)
{
gint opcode, error_base, event_base, major, minor;
if (_xkb_event_base)
return TRUE;
if (!XkbQueryExtension (backend_x11->xdpy,
&opcode,
&event_base,
&error_base,
&major,
&minor))
return FALSE;
if (!XkbUseExtension (backend_x11->xdpy, &major, &minor))
return FALSE;
_xkb_event_base = event_base;
return TRUE;
}
static unsigned long
set_value_mask (gboolean flag,
unsigned long value,
unsigned long mask)
{
if (flag)
return value | mask;
return value & ~mask;
}
static gboolean
set_xkb_ctrl (XkbDescRec *desc,
ClutterKeyboardA11yFlags settings,
ClutterKeyboardA11yFlags flag,
unsigned long mask)
{
gboolean result = (settings & flag) == flag;
desc->ctrls->enabled_ctrls = set_value_mask (result, desc->ctrls->enabled_ctrls, mask);
return result;
}
void
clutter_device_manager_x11_apply_kbd_a11y_settings (ClutterDeviceManager *device_manager,
ClutterKbdA11ySettings *kbd_a11y_settings)
{
ClutterBackendX11 *backend_x11;
XkbDescRec *desc;
gboolean enable_accessX;
backend_x11 = CLUTTER_BACKEND_X11 (clutter_get_default_backend ());
desc = get_xkb_desc_rec (backend_x11);
if (!desc)
return;
/* general */
enable_accessX = kbd_a11y_settings->controls & CLUTTER_A11Y_KEYBOARD_ENABLED;
desc->ctrls->enabled_ctrls = set_value_mask (enable_accessX,
desc->ctrls->enabled_ctrls,
XkbAccessXKeysMask);
if (set_xkb_ctrl (desc, kbd_a11y_settings->controls, CLUTTER_A11Y_TIMEOUT_ENABLED,
XkbAccessXTimeoutMask))
{
desc->ctrls->ax_timeout = kbd_a11y_settings->timeout_delay;
/* disable only the master flag via the server we will disable
* the rest on the rebound without affecting settings state
* don't change the option flags at all.
*/
desc->ctrls->axt_ctrls_mask = XkbAccessXKeysMask | XkbAccessXFeedbackMask;
desc->ctrls->axt_ctrls_values = 0;
desc->ctrls->axt_opts_mask = 0;
}
desc->ctrls->ax_options =
set_value_mask (kbd_a11y_settings->controls & CLUTTER_A11Y_FEATURE_STATE_CHANGE_BEEP,
desc->ctrls->ax_options,
XkbAccessXFeedbackMask | XkbAX_FeatureFBMask | XkbAX_SlowWarnFBMask);
/* bounce keys */
if (set_xkb_ctrl (desc, kbd_a11y_settings->controls,
CLUTTER_A11Y_BOUNCE_KEYS_ENABLED, XkbBounceKeysMask))
{
desc->ctrls->debounce_delay = kbd_a11y_settings->debounce_delay;
desc->ctrls->ax_options =
set_value_mask (kbd_a11y_settings->controls & CLUTTER_A11Y_BOUNCE_KEYS_BEEP_REJECT,
desc->ctrls->ax_options,
XkbAccessXFeedbackMask | XkbAX_BKRejectFBMask);
}
/* mouse keys */
if (set_xkb_ctrl (desc, kbd_a11y_settings->controls,
CLUTTER_A11Y_MOUSE_KEYS_ENABLED, XkbMouseKeysMask | XkbMouseKeysAccelMask))
{
gint mk_max_speed;
gint mk_accel_time;
desc->ctrls->mk_interval = 100; /* msec between mousekey events */
desc->ctrls->mk_curve = 50;
/* We store pixels / sec, XKB wants pixels / event */
mk_max_speed = kbd_a11y_settings->mousekeys_max_speed;
desc->ctrls->mk_max_speed = mk_max_speed / (1000 / desc->ctrls->mk_interval);
if (desc->ctrls->mk_max_speed <= 0)
desc->ctrls->mk_max_speed = 1;
mk_accel_time = kbd_a11y_settings->mousekeys_accel_time;
desc->ctrls->mk_time_to_max = mk_accel_time / desc->ctrls->mk_interval;
if (desc->ctrls->mk_time_to_max <= 0)
desc->ctrls->mk_time_to_max = 1;
desc->ctrls->mk_delay = kbd_a11y_settings->mousekeys_init_delay;
}
/* slow keys */
if (set_xkb_ctrl (desc, kbd_a11y_settings->controls,
CLUTTER_A11Y_SLOW_KEYS_ENABLED, XkbSlowKeysMask))
{
desc->ctrls->ax_options =
set_value_mask (kbd_a11y_settings->controls & CLUTTER_A11Y_SLOW_KEYS_BEEP_PRESS,
desc->ctrls->ax_options, XkbAccessXFeedbackMask | XkbAX_SKPressFBMask);
desc->ctrls->ax_options =
set_value_mask (kbd_a11y_settings->controls & CLUTTER_A11Y_SLOW_KEYS_BEEP_ACCEPT,
desc->ctrls->ax_options, XkbAccessXFeedbackMask | XkbAX_SKAcceptFBMask);
desc->ctrls->ax_options =
set_value_mask (kbd_a11y_settings->controls & CLUTTER_A11Y_SLOW_KEYS_BEEP_REJECT,
desc->ctrls->ax_options, XkbAccessXFeedbackMask | XkbAX_SKRejectFBMask);
desc->ctrls->slow_keys_delay = kbd_a11y_settings->slowkeys_delay;
/* anything larger than 500 seems to loose all keyboard input */
if (desc->ctrls->slow_keys_delay > 500)
desc->ctrls->slow_keys_delay = 500;
}
/* sticky keys */
if (set_xkb_ctrl (desc, kbd_a11y_settings->controls,
CLUTTER_A11Y_STICKY_KEYS_ENABLED, XkbStickyKeysMask))
{
desc->ctrls->ax_options |= XkbAX_LatchToLockMask;
desc->ctrls->ax_options =
set_value_mask (kbd_a11y_settings->controls & CLUTTER_A11Y_STICKY_KEYS_TWO_KEY_OFF,
desc->ctrls->ax_options, XkbAccessXFeedbackMask | XkbAX_TwoKeysMask);
desc->ctrls->ax_options =
set_value_mask (kbd_a11y_settings->controls & CLUTTER_A11Y_STICKY_KEYS_BEEP,
desc->ctrls->ax_options, XkbAccessXFeedbackMask | XkbAX_StickyKeysFBMask);
}
/* toggle keys */
desc->ctrls->ax_options =
set_value_mask (kbd_a11y_settings->controls & CLUTTER_A11Y_TOGGLE_KEYS_ENABLED,
desc->ctrls->ax_options, XkbAccessXFeedbackMask | XkbAX_IndicatorFBMask);
set_xkb_desc_rec (backend_x11, desc);
XkbFreeKeyboard (desc, XkbAllComponentsMask, TRUE);
}
gboolean
clutter_device_manager_x11_a11y_init (ClutterDeviceManager *device_manager)
{
ClutterBackendX11 *backend_x11;
guint event_mask;
backend_x11 =
CLUTTER_BACKEND_X11 (_clutter_device_manager_get_backend (device_manager));
if (!is_xkb_available (backend_x11))
return FALSE;
event_mask = XkbControlsNotifyMask | XkbAccessXNotifyMask;
XkbSelectEvents (backend_x11->xdpy, XkbUseCoreKbd, event_mask, event_mask);
clutter_x11_add_filter (xkb_a11y_event_filter, device_manager);
return TRUE;
}

View File

@ -0,0 +1,39 @@
/*
*
* Copyright © 2001 Ximian, Inc.
* Copyright (C) 2007 William Jon McCann <mccann@jhu.edu>
* Copyright (C) 2017 Red Hat
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
* 02111-1307, USA.
*
*/
#ifndef CLUTTER_XKB_A11Y_X11_H
#define CLUTTER_XKB_A11Y_X11_H
#include "clutter-device-manager-private.h"
#include "clutter-backend-x11.h"
#include <X11/Xlib.h>
void
clutter_device_manager_x11_apply_kbd_a11y_settings (ClutterDeviceManager *device_manager,
ClutterKbdA11ySettings *kbd_a11y_settings);
gboolean
clutter_device_manager_x11_a11y_init (ClutterDeviceManager *device_manager);
#endif /* CLUTTER_XKB_A11Y_X11_H */

View File

@ -110,7 +110,7 @@ LT_LIB_M
AC_HEADER_STDC
# required versions for dependencies
m4_define([glib_req_version], [2.44.0])
m4_define([glib_req_version], [2.53.2])
m4_define([cogl_req_version], [1.21.2])
m4_define([json_glib_req_version], [0.12.0])
m4_define([atk_req_version], [2.5.3])
@ -121,6 +121,7 @@ m4_define([xcomposite_req_version], [0.4])
m4_define([gdk_req_version], [3.3.18])
m4_define([libinput_req_version], [1.4.0])
m4_define([libudev_req_version], [136])
m4_define([libwacom_req_version], [0.13])
AC_SUBST([GLIB_REQ_VERSION], [glib_req_version])
AC_SUBST([COGL_REQ_VERSION], [cogl_req_version])
@ -133,6 +134,7 @@ AC_SUBST([XCOMPOSITE_REQ_VERSION], [xcomposite_req_version])
AC_SUBST([GDK_REQ_VERSION], [gdk_req_version])
AC_SUBST([LIBINPUT_REQ_VERSION], [libinput_req_version])
AC_SUBST([LIBUDEV_REQ_VERSION], [libudev_req_version])
AC_SUBST([LIBWACOM_REQ_VERSION], [libwacom_req_version])
# Checks for typedefs, structures, and compiler characteristics.
AM_PATH_GLIB_2_0([glib_req_version],
@ -149,7 +151,7 @@ AC_ARG_ENABLE([Bsymbolic],
saved_LDFLAGS="${LDFLAGS}"
AC_MSG_CHECKING([for -Bsymbolic-functions linker flag])
LDFLAGS=-Wl,-Bsymbolic-functions
AC_TRY_LINK([], [int main (void) { return 0; }],
AC_TRY_LINK([], [return 0],
[
AC_MSG_RESULT([yes])
enable_Bsymbolic=yes
@ -170,7 +172,7 @@ dnl on other compilers, check if we can do -fvisibility=hidden
SAVED_CFLAGS="${CFLAGS}"
CFLAGS="-fvisibility=hidden"
AC_MSG_CHECKING([for -fvisibility=hidden compiler flag])
AC_TRY_COMPILE([], [int main (void) { return 0; }],
AC_TRY_COMPILE([], [return 0],
AC_MSG_RESULT(yes)
enable_fvisibility_hidden=yes,
AC_MSG_RESULT(no)
@ -508,6 +510,32 @@ X11_EXTS=${X11_EXTS#* }
AC_CACHE_SAVE
dnl === Libwacom support for X11 ===============================================
AC_ARG_WITH(libwacom,
AC_HELP_STRING([--without-libwacom],
[disable the use of libwacom for advanced tablet management]),,
with_libwacom=auto)
have_libwacom=no
AC_MSG_CHECKING([libwacom])
if test x$with_libwacom = xno ; then
AC_MSG_RESULT([disabled])
else
if $PKG_CONFIG --exists libwacom '>=' $LIBWACOM_REQ_VERSION; then
have_libwacom=yes
AC_MSG_RESULT(yes)
PKG_CHECK_MODULES([LIBWACOM], [libwacom])
AC_SUBST(LIBWACOM_CFLAGS)
AC_SUBST(LIBWACOM_LIBS)
AC_DEFINE([HAVE_LIBWACOM], 1, [Building with libwacom for advanced tablet management])
else
AC_MSG_RESULT(no)
if test x$with_libwacom = xyes ; then
AC_MSG_ERROR([libwacom forced but not found])
fi
fi
fi
dnl === Enable GDK-Pixbuf in tests ============================================
m4_define([pixbuf_default], [yes])
@ -679,8 +707,8 @@ AS_IF([test "x$CLUTTER_BASE_PC_FILES_PRIVATE" = "x" && test "x$BACKEND_PC_FILES_
AC_SUBST(CLUTTER_REQUIRES)
AC_SUBST(CLUTTER_REQUIRES_PRIVATE)
CLUTTER_CFLAGS="$FLAVOUR_CFLAGS $CLUTTER_DEPS_CFLAGS $CLUTTER_DEPS_PRIVATE_CFLAGS $GLIB_CFLAGS"
CLUTTER_LIBS="$FLAVOUR_LIBS $CLUTTER_DEPS_LIBS $CLUTTER_DEPS_PRIVATE_LIBS $GLIB_LIBS"
CLUTTER_CFLAGS="$FLAVOUR_CFLAGS $CLUTTER_DEPS_CFLAGS $CLUTTER_DEPS_PRIVATE_CFLAGS $GLIB_CFLAGS $LIBWACOM_CFLAGS"
CLUTTER_LIBS="$FLAVOUR_LIBS $CLUTTER_DEPS_LIBS $CLUTTER_DEPS_PRIVATE_LIBS $GLIB_LIBS $LIBWACOM_LIBS"
AC_SUBST(CLUTTER_CFLAGS)
AC_SUBST(CLUTTER_LIBS)

View File

@ -61,11 +61,6 @@ G_END_DECLS
/* Coglbox private declaration
*--------------------------------------------------*/
G_DEFINE_TYPE (TestCoglbox, test_coglbox, CLUTTER_TYPE_ACTOR);
#define TEST_COGLBOX_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), TEST_TYPE_COGLBOX, TestCoglboxPrivate))
struct _TestCoglboxPrivate
{
CoglHandle texhand_id;
@ -73,6 +68,11 @@ struct _TestCoglboxPrivate
CoglHandle offscreen_id;
};
G_DEFINE_TYPE_WITH_PRIVATE (TestCoglbox, test_coglbox, CLUTTER_TYPE_ACTOR);
#define TEST_COGLBOX_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), TEST_TYPE_COGLBOX, TestCoglboxPrivate))
/* Coglbox implementation
*--------------------------------------------------*/
@ -290,8 +290,6 @@ test_coglbox_class_init (TestCoglboxClass *klass)
actor_class->map = test_coglbox_map;
actor_class->paint = test_coglbox_paint;
g_type_class_add_private (gobject_class, sizeof (TestCoglboxPrivate));
}
static ClutterActor*

View File

@ -61,17 +61,17 @@ G_END_DECLS
/* Coglbox private declaration
*--------------------------------------------------*/
G_DEFINE_TYPE (TestCoglbox, test_coglbox, CLUTTER_TYPE_ACTOR);
#define TEST_COGLBOX_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), TEST_TYPE_COGLBOX, TestCoglboxPrivate))
struct _TestCoglboxPrivate
{
CoglHandle cogl_tex_id[4];
gint frame;
};
G_DEFINE_TYPE_WITH_PRIVATE (TestCoglbox, test_coglbox, CLUTTER_TYPE_ACTOR);
#define TEST_COGLBOX_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), TEST_TYPE_COGLBOX, TestCoglboxPrivate))
/* Coglbox implementation
*--------------------------------------------------*/
@ -182,8 +182,6 @@ test_coglbox_class_init (TestCoglboxClass *klass)
gobject_class->finalize = test_coglbox_finalize;
gobject_class->dispose = test_coglbox_dispose;
actor_class->paint = test_coglbox_paint;
g_type_class_add_private (gobject_class, sizeof (TestCoglboxPrivate));
}
static ClutterActor*

View File

@ -86,11 +86,6 @@ G_END_DECLS
/* Coglbox private declaration
*--------------------------------------------------*/
G_DEFINE_TYPE (TestCoglbox, test_coglbox, CLUTTER_TYPE_ACTOR);
#define TEST_COGLBOX_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), TEST_TYPE_COGLBOX, TestCoglboxPrivate))
struct _TestCoglboxPrivate
{
guint gl_handle;
@ -116,6 +111,11 @@ struct _TestCoglboxPrivate
(* glBindTexture) (guint target, guint texture);
};
G_DEFINE_TYPE_WITH_PRIVATE (TestCoglbox, test_coglbox, CLUTTER_TYPE_ACTOR);
#define TEST_COGLBOX_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), TEST_TYPE_COGLBOX, TestCoglboxPrivate))
/* Coglbox implementation
*--------------------------------------------------*/
@ -229,8 +229,6 @@ test_coglbox_class_init (TestCoglboxClass *klass)
gobject_class->finalize = test_coglbox_finalize;
gobject_class->dispose = test_coglbox_dispose;
actor_class->paint = test_coglbox_paint;
g_type_class_add_private (gobject_class, sizeof (TestCoglboxPrivate));
}
static ClutterActor*

View File

@ -61,11 +61,6 @@ G_END_DECLS
/* Coglbox private declaration
*--------------------------------------------------*/
G_DEFINE_TYPE (TestCoglbox, test_coglbox, CLUTTER_TYPE_ACTOR);
#define TEST_COGLBOX_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), TEST_TYPE_COGLBOX, TestCoglboxPrivate))
struct _TestCoglboxPrivate
{
CoglHandle sliced_tex, not_sliced_tex;
@ -74,6 +69,11 @@ struct _TestCoglboxPrivate
gboolean use_linear_filtering;
};
G_DEFINE_TYPE_WITH_PRIVATE (TestCoglbox, test_coglbox, CLUTTER_TYPE_ACTOR);
#define TEST_COGLBOX_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), TEST_TYPE_COGLBOX, TestCoglboxPrivate))
/* Coglbox implementation
*--------------------------------------------------*/
@ -293,8 +293,6 @@ test_coglbox_class_init (TestCoglboxClass *klass)
gobject_class->finalize = test_coglbox_finalize;
gobject_class->dispose = test_coglbox_dispose;
actor_class->paint = test_coglbox_paint;
g_type_class_add_private (gobject_class, sizeof (TestCoglboxPrivate));
}
static ClutterActor*

View File

@ -62,17 +62,17 @@ G_END_DECLS
/* Coglbox private declaration
*--------------------------------------------------*/
G_DEFINE_TYPE (TestCoglbox, test_coglbox, CLUTTER_TYPE_ACTOR);
#define TEST_COGLBOX_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), TEST_TYPE_COGLBOX, TestCoglboxPrivate))
struct _TestCoglboxPrivate
{
CoglHandle cogl_tex_id;
gdouble animation_progress;
};
G_DEFINE_TYPE_WITH_PRIVATE (TestCoglbox, test_coglbox, CLUTTER_TYPE_ACTOR);
#define TEST_COGLBOX_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), TEST_TYPE_COGLBOX, TestCoglboxPrivate))
/* Coglbox implementation
*--------------------------------------------------*/
@ -158,8 +158,6 @@ test_coglbox_class_init (TestCoglboxClass *klass)
gobject_class->finalize = test_coglbox_finalize;
gobject_class->dispose = test_coglbox_dispose;
actor_class->paint = test_coglbox_paint;
g_type_class_add_private (gobject_class, sizeof (TestCoglboxPrivate));
}
static ClutterActor*

View File

@ -40,11 +40,6 @@ enum
PROP_USE_TRANSFORMED_BOX
};
G_DEFINE_TYPE (MyThing, my_thing, CLUTTER_TYPE_ACTOR)
#define MY_THING_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), MY_TYPE_THING, MyThingPrivate))
struct _MyThingPrivate
{
gfloat spacing;
@ -53,6 +48,11 @@ struct _MyThingPrivate
guint use_transformed_box : 1;
};
G_DEFINE_TYPE_WITH_PRIVATE (MyThing, my_thing, CLUTTER_TYPE_ACTOR)
#define MY_THING_GET_PRIVATE(obj) \
(G_TYPE_INSTANCE_GET_PRIVATE ((obj), MY_TYPE_THING, MyThingPrivate))
static void
my_thing_set_property (GObject *gobject,
guint prop_id,
@ -409,8 +409,6 @@ my_thing_class_init (MyThingClass *klass)
"Use transformed box when allocating",
FALSE,
G_PARAM_READWRITE));
g_type_class_add_private (klass, sizeof (MyThingPrivate));
}
static void

View File

@ -452,7 +452,7 @@ libmutter_cogl_@LIBMUTTER_API_VERSION@_la_LDFLAGS = \
-avoid-version \
-export-dynamic \
-rpath $(mutterlibdir) \
-export-symbols-regex "^(cogl|_cogl_debug_flags|_cogl_atlas_new|_cogl_atlas_add_reorganize_callback|_cogl_atlas_reserve_space|_cogl_callback|_cogl_util_get_eye_planes_for_screen_poly|_cogl_atlas_texture_remove_reorganize_callback|_cogl_atlas_texture_add_reorganize_callback|_cogl_texture_get_format|_cogl_texture_foreach_sub_texture_in_region|_cogl_texture_set_region|_cogl_profile_trace_message|_cogl_context_get_default|_cogl_framebuffer_get_stencil_bits|_cogl_clip_stack_push_rectangle|_cogl_framebuffer_get_modelview_stack|_cogl_object_default_unref|_cogl_pipeline_foreach_layer_internal|_cogl_clip_stack_push_primitive|_cogl_buffer_unmap_for_fill_or_fallback|_cogl_framebuffer_draw_primitive|_cogl_debug_instances|_cogl_framebuffer_get_projection_stack|_cogl_pipeline_layer_get_texture|_cogl_buffer_map_for_fill_or_fallback|_cogl_texture_can_hardware_repeat|_cogl_pipeline_prune_to_n_layers|_cogl_primitive_draw|test_|unit_test_|_cogl_winsys_glx_get_vtable|_cogl_winsys_egl_xlib_get_vtable|_cogl_winsys_egl_get_vtable|_cogl_closure_disconnect|_cogl_onscreen_notify_complete|_cogl_onscreen_notify_frame_sync|_cogl_winsys_egl_renderer_connect_common|_cogl_winsys_error_quark|_cogl_set_error|_cogl_poll_renderer_add_fd|_cogl_poll_renderer_add_idle|_cogl_framebuffer_winsys_update_size|_cogl_winsys_egl_make_current|_cogl_pixel_format_get_bytes_per_pixel).*"
-export-symbols-regex "^(cogl|_cogl_debug_flags|_cogl_atlas_new|_cogl_atlas_add_reorganize_callback|_cogl_atlas_reserve_space|_cogl_callback|_cogl_util_get_eye_planes_for_screen_poly|_cogl_atlas_texture_remove_reorganize_callback|_cogl_atlas_texture_add_reorganize_callback|_cogl_texture_get_format|_cogl_texture_foreach_sub_texture_in_region|_cogl_texture_set_region|_cogl_profile_trace_message|_cogl_context_get_default|_cogl_framebuffer_get_stencil_bits|_cogl_clip_stack_push_rectangle|_cogl_framebuffer_get_modelview_stack|_cogl_object_default_unref|_cogl_pipeline_foreach_layer_internal|_cogl_clip_stack_push_primitive|_cogl_buffer_unmap_for_fill_or_fallback|_cogl_framebuffer_draw_primitive|_cogl_debug_instances|_cogl_framebuffer_get_projection_stack|_cogl_pipeline_layer_get_texture|_cogl_buffer_map_for_fill_or_fallback|_cogl_texture_can_hardware_repeat|_cogl_pipeline_prune_to_n_layers|_cogl_primitive_draw|test_|unit_test_|_cogl_winsys_glx_get_vtable|_cogl_winsys_egl_xlib_get_vtable|_cogl_winsys_egl_get_vtable|_cogl_closure_disconnect|_cogl_onscreen_notify_complete|_cogl_onscreen_notify_frame_sync|_cogl_winsys_egl_renderer_connect_common|_cogl_winsys_error_quark|_cogl_set_error|_cogl_poll_renderer_add_fd|_cogl_poll_renderer_add_idle|_cogl_framebuffer_winsys_update_size|_cogl_winsys_egl_make_current|_cogl_winsys_egl_ensure_current|_cogl_pixel_format_get_bytes_per_pixel).*"
libmutter_cogl_@LIBMUTTER_API_VERSION@_la_SOURCES = $(cogl_sources_c)
nodist_libmutter_cogl_@LIBMUTTER_API_VERSION@_la_SOURCES = $(BUILT_SOURCES)

View File

@ -89,11 +89,8 @@ int64_t cogl_frame_info_get_frame_counter (CoglFrameInfo *info);
* Gets the presentation time for the frame. This is the time at which
* the frame became visible to the user.
*
* The presentation time measured in nanoseconds is based on a
* monotonic time source. The time source is not necessarily
* correlated with system/wall clock time and may represent the time
* elapsed since some undefined system event such as when the system
* last booted.
* The presentation time measured in nanoseconds, is based on
* cogl_get_clock_time().
*
* <note>Linux kernel version less that 3.8 can result in
* non-monotonic timestamps being reported when using a drm based

View File

@ -43,6 +43,7 @@
#include <cogl/winsys/cogl-winsys-private.h>
void cogl_renderer_set_custom_winsys (CoglRenderer *renderer,
CoglCustomWinsysVtableGetter winsys_vtable_getter);
CoglCustomWinsysVtableGetter winsys_vtable_getter,
void *user_data);
#endif /* __COGL_MUTTER_H___ */

View File

@ -109,7 +109,11 @@ _cogl_object_default_unref (void *object)
void
cogl_object_unref (void *obj)
{
void (* unref_func) (void *) = ((CoglObject *) obj)->klass->virt_unref;
void (* unref_func) (void *);
_COGL_RETURN_IF_FAIL (obj != NULL);
unref_func = ((CoglObject *) obj)->klass->virt_unref;
unref_func (obj);
}

View File

@ -592,7 +592,7 @@ _cogl_rectangles_validate_layer_cb (CoglPipeline *pipeline,
if (!warning_seen)
g_warning ("Skipping layer %d of your pipeline consisting of "
"a sliced texture (unsuported for multi texturing)",
"a sliced texture (unsupported for multi texturing)",
state->i);
warning_seen = TRUE;

View File

@ -54,6 +54,7 @@ struct _CoglRenderer
const CoglDriverVtable *driver_vtable;
const CoglTextureDriver *texture_driver;
const CoglWinsysVtable *winsys_vtable;
void *custom_winsys_user_data;
CoglCustomWinsysVtableGetter custom_winsys_vtable_getter;
CoglWinsysID winsys_id_override;
GList *constraints;

View File

@ -566,8 +566,10 @@ _cogl_renderer_choose_driver (CoglRenderer *renderer,
void
cogl_renderer_set_custom_winsys (CoglRenderer *renderer,
CoglCustomWinsysVtableGetter winsys_vtable_getter)
CoglCustomWinsysVtableGetter winsys_vtable_getter,
void *user_data)
{
renderer->custom_winsys_user_data = user_data;
renderer->custom_winsys_vtable_getter = winsys_vtable_getter;
}

View File

@ -542,285 +542,6 @@ cogl_texture_set_data (CoglTexture *texture,
error);
}
/* Reads back the contents of a texture by rendering it to the framebuffer
* and reading back the resulting pixels.
*
* It will perform multiple renders if the texture is larger than the
* current glViewport.
*
* It assumes the projection and modelview have already been setup so
* that rendering to 0,0 with the same width and height of the viewport
* will exactly cover the viewport.
*
* NB: Normally this approach isn't normally used since we can just use
* glGetTexImage, but may be used as a fallback in some circumstances.
*/
static CoglBool
do_texture_draw_and_read (CoglFramebuffer *fb,
CoglPipeline *pipeline,
CoglTexture *texture,
CoglBitmap *target_bmp,
float *viewport,
CoglError **error)
{
float rx1, ry1;
float rx2, ry2;
float tx1, ty1;
float tx2, ty2;
int bw, bh;
CoglBitmap *rect_bmp;
unsigned int tex_width, tex_height;
CoglContext *ctx = fb->context;
tex_width = cogl_texture_get_width (texture);
tex_height = cogl_texture_get_height (texture);
ry2 = 0;
ty2 = 0;
/* Walk Y axis until whole bitmap height consumed */
for (bh = tex_height; bh > 0; bh -= viewport[3])
{
/* Rectangle Y coords */
ry1 = ry2;
ry2 += (bh < viewport[3]) ? bh : viewport[3];
/* Normalized texture Y coords */
ty1 = ty2;
ty2 = (ry2 / (float) tex_height);
rx2 = 0;
tx2 = 0;
/* Walk X axis until whole bitmap width consumed */
for (bw = tex_width; bw > 0; bw-=viewport[2])
{
int width;
int height;
/* Rectangle X coords */
rx1 = rx2;
rx2 += (bw < viewport[2]) ? bw : viewport[2];
width = rx2 - rx1;
height = ry2 - ry1;
/* Normalized texture X coords */
tx1 = tx2;
tx2 = (rx2 / (float) tex_width);
/* Draw a portion of texture */
cogl_framebuffer_draw_textured_rectangle (fb,
pipeline,
0, 0,
rx2 - rx1,
ry2 - ry1,
tx1, ty1,
tx2, ty2);
/* Read into a temporary bitmap */
rect_bmp = _cogl_bitmap_new_with_malloc_buffer
(ctx,
width, height,
COGL_PIXEL_FORMAT_RGBA_8888_PRE,
error);
if (!rect_bmp)
return FALSE;
if (!_cogl_framebuffer_read_pixels_into_bitmap
(fb,
viewport[0], viewport[1],
COGL_READ_PIXELS_COLOR_BUFFER,
rect_bmp,
error))
{
cogl_object_unref (rect_bmp);
return FALSE;
}
/* Copy to target bitmap */
if (!_cogl_bitmap_copy_subregion (rect_bmp,
target_bmp,
0, 0,
rx1, ry1,
width,
height,
error))
{
cogl_object_unref (rect_bmp);
return FALSE;
}
/* Free temp bitmap */
cogl_object_unref (rect_bmp);
}
}
return TRUE;
}
/* Reads back the contents of a texture by rendering it to the framebuffer
* and reading back the resulting pixels.
*
* NB: Normally this approach isn't normally used since we can just use
* glGetTexImage, but may be used as a fallback in some circumstances.
*/
static CoglBool
_cogl_texture_draw_and_read (CoglTexture *texture,
CoglBitmap *target_bmp,
GLuint target_gl_format,
GLuint target_gl_type,
CoglError **error)
{
CoglFramebuffer *framebuffer = cogl_get_draw_framebuffer ();
CoglContext *ctx = framebuffer->context;
float save_viewport[4];
float viewport[4];
CoglBool status = FALSE;
viewport[0] = 0;
viewport[1] = 0;
viewport[2] = cogl_framebuffer_get_width (framebuffer);
viewport[3] = cogl_framebuffer_get_height (framebuffer);
cogl_framebuffer_get_viewport4fv (framebuffer, save_viewport);
_cogl_framebuffer_push_projection (framebuffer);
cogl_framebuffer_orthographic (framebuffer,
0, 0,
viewport[2],
viewport[3],
0, 100);
cogl_framebuffer_push_matrix (framebuffer);
cogl_framebuffer_identity_matrix (framebuffer);
/* Direct copy operation */
if (ctx->texture_download_pipeline == NULL)
{
ctx->texture_download_pipeline = cogl_pipeline_new (ctx);
cogl_pipeline_set_blend (ctx->texture_download_pipeline,
"RGBA = ADD (SRC_COLOR, 0)",
NULL);
}
cogl_pipeline_set_layer_texture (ctx->texture_download_pipeline, 0, texture);
cogl_pipeline_set_layer_combine (ctx->texture_download_pipeline,
0, /* layer */
"RGBA = REPLACE (TEXTURE)",
NULL);
cogl_pipeline_set_layer_filters (ctx->texture_download_pipeline, 0,
COGL_PIPELINE_FILTER_NEAREST,
COGL_PIPELINE_FILTER_NEAREST);
if (!do_texture_draw_and_read (framebuffer,
ctx->texture_download_pipeline,
texture, target_bmp, viewport,
error))
return FALSE;
/* XXX: As an alleged PowerVR driver bug workaround where the driver
* is apparently not maintaining the alpha component of some
* framebuffers we render the alpha component of the texture
* separately to be sure we retrieve all components of the texture.
*
* TODO: verify if this is still an issue
*/
if ((_cogl_texture_get_format (texture) & COGL_A_BIT)/* && a_bits == 0*/)
{
uint8_t *srcdata;
uint8_t *dstdata;
uint8_t *srcpixel;
uint8_t *dstpixel;
int target_width = cogl_bitmap_get_width (target_bmp);
int target_height = cogl_bitmap_get_height (target_bmp);
int target_rowstride = cogl_bitmap_get_rowstride (target_bmp);
int bpp = _cogl_pixel_format_get_bytes_per_pixel (COGL_PIXEL_FORMAT_RGBA_8888);
int alpha_rowstride = bpp * target_width;
CoglBitmap *alpha_bmp;
int x,y;
if ((dstdata = _cogl_bitmap_map (target_bmp,
COGL_BUFFER_ACCESS_WRITE,
COGL_BUFFER_MAP_HINT_DISCARD,
error)) == NULL)
goto EXIT;
/* Create temp bitmap for alpha values */
alpha_bmp =
_cogl_bitmap_new_with_malloc_buffer (ctx,
target_width,
target_height,
COGL_PIXEL_FORMAT_RGBA_8888,
error);
if (!alpha_bmp)
{
_cogl_bitmap_unmap (target_bmp);
goto EXIT;
}
/* Draw alpha values into RGB channels */
cogl_pipeline_set_layer_combine (ctx->texture_download_pipeline,
0, /* layer */
"RGBA = REPLACE (TEXTURE[A])",
NULL);
if (!do_texture_draw_and_read (framebuffer,
ctx->texture_download_pipeline,
texture, alpha_bmp, viewport,
error))
{
cogl_object_unref (alpha_bmp);
_cogl_bitmap_unmap (target_bmp);
goto EXIT;
}
/* Copy temp R to target A */
/* Note: we don't try to catch errors since "mapping" an
* malloc buffer should never fail */
srcdata = _cogl_bitmap_map (alpha_bmp,
COGL_BUFFER_ACCESS_READ,
0 /* hints */,
NULL);
for (y=0; y<target_height; ++y)
{
for (x=0; x<target_width; ++x)
{
srcpixel = srcdata + x*bpp;
dstpixel = dstdata + x*bpp;
dstpixel[3] = srcpixel[0];
}
srcdata += alpha_rowstride;
dstdata += target_rowstride;
}
_cogl_bitmap_unmap (alpha_bmp);
_cogl_bitmap_unmap (target_bmp);
cogl_object_unref (alpha_bmp);
}
status = TRUE;
EXIT:
/* Restore old state */
cogl_framebuffer_pop_matrix (framebuffer);
_cogl_framebuffer_pop_projection (framebuffer);
cogl_framebuffer_set_viewport (framebuffer,
save_viewport[0],
save_viewport[1],
save_viewport[2],
save_viewport[3]);
return status;
}
static CoglBool
get_texture_bits_via_offscreen (CoglTexture *meta_texture,
CoglTexture *sub_texture,
@ -1156,25 +877,13 @@ cogl_texture_get_data (CoglTexture *texture,
tg_data.success = FALSE;
}
/* XXX: In some cases _cogl_texture_2d_download_from_gl may fail
* to read back the texture data; such as for GLES which doesn't
* support glGetTexImage, so here we fallback to drawing the
* texture and reading the pixels from the framebuffer. */
/* XXX: In some cases this api may fail to read back the texture
* data; such as for GLES which doesn't support glGetTexImage
*/
if (!tg_data.success)
{
if (!_cogl_texture_draw_and_read (texture, target_bmp,
closest_gl_format,
closest_gl_type,
&ignore_error))
{
/* We have no more fallbacks so we just give up and
* hope for the best */
g_warning ("Failed to read texture since draw-and-read "
"fallback failed: %s", ignore_error->message);
cogl_error_free (ignore_error);
cogl_object_unref (target_bmp);
return 0;
}
cogl_object_unref (target_bmp);
return 0;
}
/* Was intermediate used? */

View File

@ -168,7 +168,7 @@ cogl_xlib_renderer_set_event_retrieval_enabled (CoglRenderer *renderer,
CoglBool enable);
/**
* cogl_xlib_renderer_set_threaded_swap_wait_enabled:
* cogl_xlib_renderer_set_threaded_swap_wait_enabled: (skip)
* @renderer: a #CoglRenderer
* @enable: The new value
*

View File

@ -1412,20 +1412,12 @@ _cogl_framebuffer_gl_read_pixels_into_bitmap (CoglFramebuffer *framebuffer,
if (!cogl_is_offscreen (framebuffer))
y = framebuffer_height - y - height;
required_format = ctx->driver_vtable->pixel_format_to_gl (ctx,
format,
&gl_intformat,
&gl_format,
&gl_type);
/* As we are reading pixels, we want to consider the bitmap according to
* its real pixel format, not the swizzled channels we pretend face to the
* pipeline.
*/
if ((format == COGL_PIXEL_FORMAT_BGRA_8888 ||
format == COGL_PIXEL_FORMAT_BGRA_8888_PRE) &&
_cogl_has_private_feature (ctx, COGL_PRIVATE_FEATURE_TEXTURE_SWIZZLE))
gl_format = GL_BGRA;
required_format = ctx->driver_vtable->pixel_format_to_gl_with_target (ctx,
framebuffer->internal_format,
format,
&gl_intformat,
&gl_format,
&gl_type);
/* NB: All offscreen rendering is done upside down so there is no need
* to flip in this case... */

View File

@ -90,6 +90,11 @@ typedef struct _CoglWinsysEGLVtable
(* add_config_attributes) (CoglDisplay *display,
CoglFramebufferConfig *config,
EGLint *attributes);
CoglBool
(* choose_config) (CoglDisplay *display,
EGLint *attributes,
EGLConfig *out_config,
CoglError **error);
} CoglWinsysEGLVtable;
typedef enum _CoglEGLWinsysFeature
@ -176,6 +181,9 @@ _cogl_winsys_egl_make_current (CoglDisplay *display,
EGLSurface read,
EGLContext context);
EGLBoolean
_cogl_winsys_egl_ensure_current (CoglDisplay *display);
#ifdef EGL_KHR_image_base
EGLImageKHR
_cogl_egl_create_image (CoglContext *ctx,

View File

@ -336,6 +336,32 @@ _cogl_winsys_egl_add_config_attributes (CoglDisplay *display,
return i;
}
static CoglBool
_cogl_winsys_egl_choose_config (CoglDisplay *display,
EGLint *attributes,
EGLConfig *out_config,
CoglError **error)
{
CoglRenderer *renderer = display->renderer;
CoglRendererEGL *egl_renderer = renderer->winsys;
EGLint config_count = 0;
EGLBoolean status;
status = eglChooseConfig (egl_renderer->edpy,
attributes,
out_config, 1,
&config_count);
if (status != EGL_TRUE || config_count == 0)
{
_cogl_set_error (error, COGL_WINSYS_ERROR,
COGL_WINSYS_ERROR_CREATE_CONTEXT,
"No compatible EGL configs found");
return FALSE;
}
return TRUE;
}
static CoglBool
_cogl_winsys_egl_display_setup (CoglDisplay *display,
CoglError **error)
@ -841,6 +867,7 @@ static const CoglWinsysEGLVtable
_cogl_winsys_egl_vtable =
{
.add_config_attributes = _cogl_winsys_egl_add_config_attributes,
.choose_config = _cogl_winsys_egl_choose_config,
.display_setup = _cogl_winsys_egl_display_setup,
.display_destroy = _cogl_winsys_egl_display_destroy,
.context_created = _cogl_winsys_egl_context_created,

View File

@ -309,6 +309,18 @@ _cogl_winsys_egl_make_current (CoglDisplay *display,
return ret;
}
EGLBoolean
_cogl_winsys_egl_ensure_current (CoglDisplay *display)
{
CoglDisplayEGL *egl_display = display->winsys;
CoglRendererEGL *egl_renderer = display->renderer->winsys;
return eglMakeCurrent (egl_renderer->edpy,
egl_display->current_draw_surface,
egl_display->current_read_surface,
egl_display->current_context);
}
static void
cleanup_context (CoglDisplay *display)
{
@ -338,10 +350,9 @@ try_create_context (CoglDisplay *display,
CoglRendererEGL *egl_renderer = renderer->winsys;
EGLDisplay edpy;
EGLConfig config;
EGLint config_count = 0;
EGLBoolean status;
EGLint attribs[9];
EGLint cfg_attribs[MAX_EGL_CONFIG_ATTRIBS];
GError *config_error = NULL;
const char *error_message;
_COGL_RETURN_VAL_IF_FAIL (egl_display->egl_context == NULL, TRUE);
@ -356,14 +367,16 @@ try_create_context (CoglDisplay *display,
edpy = egl_renderer->edpy;
status = eglChooseConfig (edpy,
cfg_attribs,
&config, 1,
&config_count);
if (status != EGL_TRUE || config_count == 0)
if (!egl_renderer->platform_vtable->choose_config (display,
cfg_attribs,
&config,
&config_error))
{
error_message = "Unable to find a usable EGL configuration";
goto fail;
_cogl_set_error (error, COGL_WINSYS_ERROR,
COGL_WINSYS_ERROR_CREATE_CONTEXT,
"Couldn't choose config: %s", config_error->message);
g_error_free (config_error);
goto err;
}
egl_display->egl_config = config;
@ -419,6 +432,7 @@ fail:
COGL_WINSYS_ERROR_CREATE_CONTEXT,
"%s", error_message);
err:
cleanup_context (display);
return FALSE;

View File

@ -1,15 +1,15 @@
AC_PREREQ(2.62)
m4_define([mutter_major_version], [3])
m4_define([mutter_minor_version], [25])
m4_define([mutter_micro_version], [1])
m4_define([mutter_minor_version], [30])
m4_define([mutter_micro_version], [0])
m4_define([mutter_version],
[mutter_major_version.mutter_minor_version.mutter_micro_version])
m4_define([mutter_plugin_api_version], [3])
m4_define([libmutter_api_version], [0])
m4_define([libmutter_api_version], [3])
AC_INIT([mutter], [mutter_version],
[http://bugzilla.gnome.org/enter_bug.cgi?product=mutter])
@ -72,7 +72,7 @@ AC_HEADER_STDC
PKG_PROG_PKG_CONFIG([0.21])
# Sets GLIB_GENMARSHAL and GLIB_MKENUMS
AM_PATH_GLIB_2_0([2.49.0])
AM_PATH_GLIB_2_0([2.53.2])
CANBERRA_GTK=libcanberra-gtk3
CANBERRA_GTK_VERSION=0.26
@ -80,6 +80,7 @@ CANBERRA_GTK_VERSION=0.26
LIBWACOM_VERSION=0.13
MUTTER_PC_MODULES="
gl
egl
gtk+-3.0 >= 3.19.8
gio-unix-2.0 >= 2.35.1
@ -87,7 +88,6 @@ MUTTER_PC_MODULES="
cairo >= 1.10.0
gsettings-desktop-schemas >= 3.21.4
json-glib-1.0
upower-glib >= 0.99.0
gnome-desktop-3.0
xcomposite >= 0.2
xcursor
@ -104,6 +104,7 @@ MUTTER_PC_MODULES="
xcb-randr
xcb-res
"
XWAYLAND_GRAB_DEFAULT_ACCESS_RULES="gnome-boxes,remote-viewer,virt-viewer,virt-manager,vinagre,vncviewer,Xephyr"
GLIB_GSETTINGS
@ -225,10 +226,10 @@ AC_MSG_CHECKING([gudev])
if test x$with_gudev = xno ; then
AC_MSG_RESULT([disabled])
else
if $PKG_CONFIG --exists gudev-1.0; then
if $PKG_CONFIG --exists "gudev-1.0 >= 232"; then
have_gudev=yes
AC_MSG_RESULT(yes)
MUTTER_PC_MODULES="$MUTTER_PC_MODULES gudev-1.0"
MUTTER_PC_MODULES="$MUTTER_PC_MODULES gudev-1.0 >= 232"
AC_DEFINE([HAVE_LIBGUDEV], 1, [Building with gudev for device type detection])
else
AC_MSG_RESULT(no)
@ -238,6 +239,16 @@ else
fi
fi
AC_ARG_ENABLE(remote-desktop,
AS_HELP_STRING([--enable-remote-desktop], [enable support for remote desktop and screen cast]),,
enable_remote_desktop=no
)
AS_IF([test "$enable_remote_desktop" = "yes"], [
MUTTER_PC_MODULES="$MUTTER_PC_MODULES libpipewire-0.2 >= 0.2.2"
AC_DEFINE([HAVE_REMOTE_DESKTOP],[1], [Defined if screen cast and remote desktop support is enabled])
])
AM_CONDITIONAL([HAVE_REMOTE_DESKTOP],[test "$enable_remote_desktop" = "yes"])
INTROSPECTION_VERSION=0.9.5
GOBJECT_INTROSPECTION_CHECK([$INTROSPECTION_VERSION])
@ -250,7 +261,19 @@ AC_SUBST(XWAYLAND_PATH)
PKG_CHECK_MODULES(MUTTER, $MUTTER_PC_MODULES)
MUTTER_NATIVE_BACKEND_MODULES="libdrm libsystemd libinput >= 1.4 gudev-1.0 gbm >= 10.3"
PKG_CHECK_MODULES(ELOGIND, [libelogind], [have_elogind=yes], [have_elogind=no])
if test x$have_elogind = xyes; then
logind_provider="libelogind"
fi
PKG_CHECK_MODULES(SYSTEMD, [libsystemd], [have_systemd=yes], [have_systemd=no])
if test x$have_systemd = xyes -o -z "$logind_provider"; then
logind_provider="libsystemd"
fi
MUTTER_NATIVE_BACKEND_MODULES="libdrm $logind_provider libinput >= 1.4 gudev-1.0 gbm >= 10.3"
AC_ARG_ENABLE(native-backend,
AS_HELP_STRING([--disable-native-backend], [disable mutter native (KMS) backend]),,
@ -266,16 +289,26 @@ AS_IF([test "$have_native_backend" = "yes"], [
])
AM_CONDITIONAL([HAVE_NATIVE_BACKEND],[test "$have_native_backend" = "yes"])
MUTTER_WAYLAND_EGLSTREAM_MODULES="wayland-eglstream-protocols"
AC_ARG_ENABLE(egl-device,
AS_HELP_STRING([--enable-egl-device], [enable support for EGLDevice on top of KMS]),
enable_egl_device=yes,
AS_HELP_STRING([--enable-egl-device], [enable support for EGLDevice on top of KMS]),,
enable_egl_device=no
have_wayland_eglstream=no
)
AS_IF([test "$enable_egl_device" = "yes"], [
AC_DEFINE([HAVE_EGL_DEVICE],[1], [Defined if EGLDevice support is enabled])
PKG_CHECK_EXISTS([$MUTTER_WAYLAND_EGLSTREAM_MODULES], [have_wayland_eglstream=yes], [have_wayland_eglstream=no])
])
AS_IF([test "$have_wayland_eglstream" = "yes"], [
AC_DEFINE([HAVE_WAYLAND_EGLSTREAM],[1],[Defined if Wayland EGLStream protocols are available])
PKG_CHECK_MODULES(WAYLAND_EGLSTREAM, [$MUTTER_WAYLAND_EGLSTREAM_MODULES],
[ac_wayland_eglstream_pkgdatadir=`$PKG_CONFIG --variable=pkgdatadir $MUTTER_WAYLAND_EGLSTREAM_MODULES`])
AC_SUBST(WAYLAND_EGLSTREAM_DATADIR, $ac_wayland_eglstream_pkgdatadir)
])
AM_CONDITIONAL([HAVE_WAYLAND_EGLSTREAM],[test "$have_wayland_eglstream" = "yes"])
MUTTER_WAYLAND_MODULES="wayland-server >= 1.6.90"
MUTTER_WAYLAND_MODULES="wayland-server >= 1.13.0"
AC_ARG_ENABLE(wayland,
AS_HELP_STRING([--disable-wayland], [disable mutter on wayland support]),,
@ -292,12 +325,27 @@ AS_IF([test "$have_wayland" = "yes"], [
AC_SUBST([WAYLAND_SCANNER])
AC_DEFINE([HAVE_WAYLAND],[1],[Define if you want to enable Wayland support])
PKG_CHECK_MODULES(WAYLAND_PROTOCOLS, [wayland-protocols >= 1.7],
PKG_CHECK_MODULES(WAYLAND_PROTOCOLS, [wayland-protocols >= 1.16],
[ac_wayland_protocols_pkgdatadir=`$PKG_CONFIG --variable=pkgdatadir wayland-protocols`])
AC_SUBST(WAYLAND_PROTOCOLS_DATADIR, $ac_wayland_protocols_pkgdatadir)
])
AM_CONDITIONAL([HAVE_WAYLAND],[test "$have_wayland" = "yes"])
AC_ARG_WITH([xwayland-grab-default-access-rules],
[AS_HELP_STRING([--with-xwayland-grab-default-access-rules="app-res1,app-res2,..."],
[comma delimited list of applications ressources or class allowed to issue X11 grabs in Xwayland"])],
[with_XWAYLAND_GRAB_DEFAULT_ACCESS_RULES="$withval"],
[with_XWAYLAND_GRAB_DEFAULT_ACCESS_RULES="$XWAYLAND_GRAB_DEFAULT_ACCESS_RULES"])
case "$with_XWAYLAND_GRAB_DEFAULT_ACCESS_RULES" in
yes) with_XWAYLAND_GRAB_DEFAULT_ACCESS_RULES="$XWAYLAND_GRAB_DEFAULT_ACCESS_RULES" ;;
no) with_XWAYLAND_GRAB_DEFAULT_ACCESS_RULES='' ;;
esac
AC_DEFINE_UNQUOTED([XWAYLAND_GRAB_DEFAULT_ACCESS_RULES],
"$with_XWAYLAND_GRAB_DEFAULT_ACCESS_RULES",
[Xwayland applications allowed to issue keyboard grabs])
AC_SUBST(XWAYLAND_GRAB_DEFAULT_ACCESS_RULES)
PKG_CHECK_EXISTS([xi >= 1.6.99.1],
AC_DEFINE([HAVE_XI23],[1],[Define if you have support for XInput 2.3 or greater]))
@ -511,8 +559,10 @@ mutter-$VERSION
Introspection: ${found_introspection}
Session management: ${found_sm}
Wayland: ${have_wayland}
Wayland EGLStream: ${have_wayland_eglstream}
Native (KMS) backend: ${have_native_backend}
EGLDevice: ${enable_egl_device}
Remote desktop: ${enable_remote_desktop}
"

View File

@ -20,12 +20,6 @@
<KeyListEntry name="move-to-workspace-last"
description="Move window to last workspace" />
<KeyListEntry name="move-to-workspace-left"
description="Move window one workspace to the left" />
<KeyListEntry name="move-to-workspace-right"
description="Move window one workspace to the right" />
<KeyListEntry name="move-to-workspace-up"
description="Move window one workspace up" />
@ -125,12 +119,6 @@
<KeyListEntry name="switch-to-workspace-last"
description="Switch to last workspace" />
<KeyListEntry name="switch-to-workspace-left"
description="Move to workspace left" />
<KeyListEntry name="switch-to-workspace-right"
description="Move to workspace right" />
<KeyListEntry name="switch-to-workspace-up"
description="Move to workspace above" />

View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<KeyListEntries schema="org.gnome.mutter.wayland.keybindings"
group="system"
name="System"
wm_name="Mutter"
package="mutter">
<KeyListEntry name="restore-shortcuts" description="Restore the keyboard shortcuts"/>
</KeyListEntries>

View File

@ -15,8 +15,6 @@
<KeyListEntry name="unmaximize" description="Restore window"/>
<KeyListEntry name="toggle-shaded" description="Toggle shaded state"/>
<KeyListEntry name="close" description="Close window"/>
<KeyListEntry name="minimize" description="Hide window"/>

View File

@ -12,13 +12,19 @@ xml_DATA = \
50-mutter-system.xml \
50-mutter-windows.xml
if HAVE_WAYLAND
xml_DATA += \
50-mutter-wayland.xml
endif
gschema_in_files = \
org.gnome.mutter.gschema.xml.in \
org.gnome.mutter.wayland.gschema.xml.in
gsettings_SCHEMAS = $(gschema_in_files:.xml.in=.xml)
%.gschema.xml: %.gschema.xml.in Makefile
$(AM_V_GEN) sed -e 's|@GETTEXT_DOMAIN[@]|$(GETTEXT_DOMAIN)|g' \
$(AM_V_GEN) sed -e 's|@GETTEXT_DOMAIN[@]|$(GETTEXT_PACKAGE)|g' \
-e 's|@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES[@]|$(XWAYLAND_GRAB_DEFAULT_ACCESS_RULES)|g' \
$< > $@ || rm $@
@GSETTINGS_RULES@

View File

@ -1,6 +1,6 @@
<schemalist>
<schema id="org.gnome.mutter" path="/org/gnome/mutter/"
gettext-domain="@GETTEXT_DOMAIN">
gettext-domain="@GETTEXT_DOMAIN@">
<key name="overlay-key" type="s">
<default>'Super_L'</default>
@ -146,5 +146,15 @@
<summary>Cancel tab popup</summary>
</key>
<key name="switch-monitor" type="as">
<default><![CDATA[['<Super>p','XF86Display']]]></default>
<summary>Switch monitor configurations</summary>
</key>
<key name="rotate-monitor" type="as">
<default><![CDATA[['XF86RotateWindows']]]></default>
<summary>Rotates the built-in monitor configuration</summary>
</key>
</schema>
</schemalist>

View File

@ -49,5 +49,53 @@
<default><![CDATA[['<Primary><Alt>F12']]]></default>
<summary>Switch to VT 12</summary>
</key>
<key name="restore-shortcuts" type="as">
<default><![CDATA[['<Super>Escape']]]></default>
<summary>Re-enable shortcuts</summary>
</key>
</schema>
<schema id="org.gnome.mutter.wayland" path="/org/gnome/mutter/wayland/"
gettext-domain="@GETTEXT_DOMAIN@">
<key name="xwayland-allow-grabs" type="b">
<default>false</default>
<summary>Allow grabs with Xwayland</summary>
<description>
Allow keyboard grabs issued by X11 applications running in Xwayland
to be taken into account.
For a X11 grab to be taken into account under Wayland, the client must
also either send a specific X11 ClientMessage to the root window or be
among the applications white-listed in key “xwayland-grab-access-rules”.
</description>
</key>
<key name="xwayland-grab-access-rules" type="as">
<default>[]</default>
<summary>Xwayland applications allowed to issue keyboard grabs</summary>
<description>
List the resource names or resource class of X11 windows either
allowed or not allowed to issue X11 keyboard grabs under Xwayland.
The resource name or resource class of a given X11 window can be
obtained using the command “xprop WM_CLASS”.
Wildcards “*” and jokers “?” in the values are supported.
Values starting with “!” are blacklisted, which has precedence over
the whitelist, to revoke applications from the default system list.
The default system list includes the following applications:
“@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES@”
Users can break an existing grab by using the specific keyboard
shortcut defined by the keybinding key “restore-shortcuts”.
</description>
</key>
</schema>
</schemalist>

View File

@ -26,7 +26,6 @@ XGETTEXT_OPTIONS = --from-code=UTF-8 --keyword=_ --keyword=N_ \
--flag=g_sprintf:2:c-format \
--flag=g_snprintf:3:c-format
# This is the copyright holder that gets inserted into the header of the
# $(DOMAIN).pot file. Set this to the copyright holder of the surrounding
# package. (Note that the msgstr strings, extracted from the package's
@ -36,6 +35,7 @@ XGETTEXT_OPTIONS = --from-code=UTF-8 --keyword=_ --keyword=N_ \
# the public domain; in this case the translators are expected to disclaim
# their copyright.
COPYRIGHT_HOLDER = Translation copyright holder
# This is the email address or URL to which the translators shall report
# bugs in the untranslated strings:
# - Strings which are not entire sentences, see the maintainer guidelines
@ -50,7 +50,7 @@ COPYRIGHT_HOLDER = Translation copyright holder
# It can be your email address, or a mailing list address where translators
# can write to without being subscribed, or the URL of a web page through
# which the translators can contact you.
MSGID_BUGS_ADDRESS = http://bugzilla.gnome.org/enter_bug.cgi?product=mutter&keywords=I18N+L10N&component=general
MSGID_BUGS_ADDRESS = https://gitlab.gnome.org/GNOME/mutter/issues
# This is the list of locale categories, beyond LC_MESSAGES, for which the
# message catalogs shall be used. It is usually empty.

View File

@ -2,6 +2,7 @@
# Please keep this file sorted alphabetically.
data/50-mutter-navigation.xml
data/50-mutter-system.xml
data/50-mutter-wayland.xml
data/50-mutter-windows.xml
data/mutter.desktop.in
data/org.gnome.mutter.gschema.xml.in
@ -13,18 +14,18 @@ src/compositor/meta-background.c
src/core/bell.c
src/core/core.c
src/core/display.c
src/core/errors.c
src/core/keybindings.c
src/core/main.c
src/core/meta-close-dialog-default.c
src/core/mutter.c
src/core/prefs.c
src/core/screen.c
src/core/util.c
src/core/window.c
src/ui/frames.c
src/ui/theme.c
src/wayland/meta-wayland-tablet-pad.c
src/x11/meta-x11-display.c
src/x11/meta-x11-errors.c
src/x11/session.c
src/x11/window-props.c
src/x11/xprops.c

View File

@ -28,6 +28,7 @@ clutter/clutter/clutter-grid-layout.c
clutter/clutter/clutter-image.c
clutter/clutter/clutter-input-device.c
clutter/clutter/clutter-input-device-tool.c
clutter/clutter/clutter-input-method.c
clutter/clutter/clutter-interval.c
clutter/clutter/clutter-layout-manager.c
clutter/clutter/clutter-layout-meta.c

822
po/ar.po
View File

@ -4,14 +4,15 @@
# Arafat Medini <lumina@silverpen.de>, 2003.
# Abdulaziz Al-Arfaj <alarfaj0@yahoo.com>, 2004.
# Djihed Afifi <djihed@gmail.com>, 2006.
# Khaled Hosny <khaledhosny@eglug.org>, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015.
# Khaled Hosny <khaledhosny@eglug.org>, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2017.
# Anas Afif Emad <anas.e87@gmail.com>, 2008.
msgid ""
msgstr ""
"Project-Id-Version: metacity.HEAD\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2015-03-23 21:38+0200\n"
"PO-Revision-Date: 2015-03-23 21:45+0200\n"
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?product=mutter&"
"keywords=I18N+L10N&component=general\n"
"POT-Creation-Date: 2017-11-03 10:20+0200\n"
"PO-Revision-Date: 2017-11-03 10:22+0200\n"
"Last-Translator: Khaled Hosny <khaledhosny@eglug.org>\n"
"Language-Team: Arabic <doc@arabeyes.org>\n"
"Language: ar\n"
@ -20,524 +21,130 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 "
"&& n%100<=10 ? 3 : n%100>=11 ? 4 : 5;\n"
"X-Generator: Virtaal 0.7.1\n"
"X-Generator: Virtaal 1.0.0-beta1\n"
"X-Project-Style: gnome\n"
#: ../data/50-mutter-navigation.xml.in.h:1
msgid "Navigation"
msgstr "الإبحار"
#: ../data/50-mutter-navigation.xml.in.h:2
msgid "Move window to workspace 1"
msgstr "انقل النافذة إلى مساحة العمل 1"
#: ../data/50-mutter-navigation.xml.in.h:3
msgid "Move window to workspace 2"
msgstr "انقل النافذة إلى مساحة العمل 2"
#: ../data/50-mutter-navigation.xml.in.h:4
msgid "Move window to workspace 3"
msgstr "انقل النافذة إلى مساحة العمل 3"
#: ../data/50-mutter-navigation.xml.in.h:5
msgid "Move window to workspace 4"
msgstr "انقل النافذة إلى مساحة العمل 4"
#: ../data/50-mutter-navigation.xml.in.h:6
msgid "Move window to last workspace"
msgstr "انقل النافذة إلى مساحة العمل الأخيرة"
#: ../data/50-mutter-navigation.xml.in.h:7
msgid "Move window one workspace to the left"
msgstr "انقل النافذة مساحة عمل واحدة إلى اليسار"
#: ../data/50-mutter-navigation.xml.in.h:8
msgid "Move window one workspace to the right"
msgstr "انقل النافذة مساحة عمل واحدة إلى اليمين"
#: ../data/50-mutter-navigation.xml.in.h:9
msgid "Move window one workspace up"
msgstr "انقل النافذة مساحة عمل واحدة إلى الأعلى"
#: ../data/50-mutter-navigation.xml.in.h:10
msgid "Move window one workspace down"
msgstr "انقل النافذة مساحة عمل واحدة إلى الأسفل"
#: ../data/50-mutter-navigation.xml.in.h:11
msgid "Move window one monitor to the left"
msgstr "انقل النافذة شاشة واحدة إلى اليسار"
#: ../data/50-mutter-navigation.xml.in.h:12
msgid "Move window one monitor to the right"
msgstr "انقل النافذة شاشة واحدة إلى اليمين"
#: ../data/50-mutter-navigation.xml.in.h:13
msgid "Move window one monitor up"
msgstr "انقل النافذة شاشة واحدة إلى الأعلى"
#: ../data/50-mutter-navigation.xml.in.h:14
msgid "Move window one monitor down"
msgstr "انقل النافذة شاشة واحدة إلى الأسفل"
#: ../data/50-mutter-navigation.xml.in.h:15
msgid "Switch applications"
msgstr "تنقل بين التطبيقات"
#: ../data/50-mutter-navigation.xml.in.h:16
msgid "Switch to previous application"
msgstr "انتقل إلى التطبيق السابق"
#: ../data/50-mutter-navigation.xml.in.h:17
msgid "Switch windows"
msgstr "تنقل بين النوافذ"
#: ../data/50-mutter-navigation.xml.in.h:18
msgid "Switch to previous window"
msgstr "انتقل إلى النافذة السابقة"
#: ../data/50-mutter-navigation.xml.in.h:19
msgid "Switch windows of an application"
msgstr "تنقل بين نوافذ التطبيق"
#: ../data/50-mutter-navigation.xml.in.h:20
msgid "Switch to previous window of an application"
msgstr "انتقل إلى نافذة التطبيق السابقة"
#: ../data/50-mutter-navigation.xml.in.h:21
msgid "Switch system controls"
msgstr "تنقل بين تحكمات النظام"
#: ../data/50-mutter-navigation.xml.in.h:22
msgid "Switch to previous system control"
msgstr "انتقل إلى تحكم النظام السابق"
#: ../data/50-mutter-navigation.xml.in.h:23
msgid "Switch windows directly"
msgstr "تنقل مباشرة بين النوافذ"
#: ../data/50-mutter-navigation.xml.in.h:24
msgid "Switch directly to previous window"
msgstr "انتقل مباشرة إلى النافذة السابقة"
#: ../data/50-mutter-navigation.xml.in.h:25
msgid "Switch windows of an app directly"
msgstr "تنقل مباشرة بين نوافذ التطبيق"
#: ../data/50-mutter-navigation.xml.in.h:26
msgid "Switch directly to previous window of an app"
msgstr "انتقل مباشرة إلى نافذة التطبيق السابقة"
#: ../data/50-mutter-navigation.xml.in.h:27
msgid "Switch system controls directly"
msgstr "تنقل مباشرة بين تحكمات النظام"
#: ../data/50-mutter-navigation.xml.in.h:28
msgid "Switch directly to previous system control"
msgstr "انتقل مباشرة إلى تحكم النظام السابق"
#: ../data/50-mutter-navigation.xml.in.h:29
msgid "Hide all normal windows"
msgstr "أخفِ كل النوافذ العادية"
#: ../data/50-mutter-navigation.xml.in.h:30
msgid "Switch to workspace 1"
msgstr "انتقل إلى مساحة العمل 1"
#: ../data/50-mutter-navigation.xml.in.h:31
msgid "Switch to workspace 2"
msgstr "انتقل إلى مساحة العمل 2"
#: ../data/50-mutter-navigation.xml.in.h:32
msgid "Switch to workspace 3"
msgstr "انتقل إلى مساحة العمل 3"
#: ../data/50-mutter-navigation.xml.in.h:33
msgid "Switch to workspace 4"
msgstr "انتقل إلى مساحة العمل 4"
#: ../data/50-mutter-navigation.xml.in.h:34
msgid "Switch to last workspace"
msgstr "انتقل إلى مساحة العمل الأخيرة"
#: ../data/50-mutter-navigation.xml.in.h:35
msgid "Move to workspace left"
msgstr "انقل لمساحة العمل على اليسار"
#: ../data/50-mutter-navigation.xml.in.h:36
msgid "Move to workspace right"
msgstr "انقل لمساحة العمل على اليمين"
#: ../data/50-mutter-navigation.xml.in.h:37
msgid "Move to workspace above"
msgstr "انقل لمساحة العمل أعلى"
#: ../data/50-mutter-navigation.xml.in.h:38
msgid "Move to workspace below"
msgstr "انقل لمساحة العمل أسفل"
#: ../data/50-mutter-system.xml.in.h:1
msgid "System"
msgstr "النظام"
#: ../data/50-mutter-system.xml.in.h:2
msgid "Show the run command prompt"
msgstr "أظهر محث تشغيل أمر"
#: ../data/50-mutter-system.xml.in.h:3
msgid "Show the activities overview"
msgstr "أظهر نظرة عامة على الأنشطة"
#: ../data/50-mutter-windows.xml.in.h:1
msgid "Windows"
msgstr "النوافذ"
#: ../data/50-mutter-windows.xml.in.h:2
msgid "Activate the window menu"
msgstr "فعّل قائمة النافذة"
#: ../data/50-mutter-windows.xml.in.h:3
msgid "Toggle fullscreen mode"
msgstr "بدّل نمط ملء الشاشة"
#: ../data/50-mutter-windows.xml.in.h:4
msgid "Toggle maximization state"
msgstr "بدّل حالة التكبير"
#: ../data/50-mutter-windows.xml.in.h:5
msgid "Maximize window"
msgstr "كبّر النّافذة"
#: ../data/50-mutter-windows.xml.in.h:6
msgid "Restore window"
msgstr "استعد النّافذة"
#: ../data/50-mutter-windows.xml.in.h:7
msgid "Toggle shaded state"
msgstr "بدّل حالة الإخفاء"
#: ../data/50-mutter-windows.xml.in.h:8
msgid "Close window"
msgstr "أغلق النّافذة"
#: ../data/50-mutter-windows.xml.in.h:9
msgid "Hide window"
msgstr "أخفِ النّافذة"
#: ../data/50-mutter-windows.xml.in.h:10
msgid "Move window"
msgstr "انقل النّافذة"
#: ../data/50-mutter-windows.xml.in.h:11
msgid "Resize window"
msgstr "حجّم النّافذة"
#: ../data/50-mutter-windows.xml.in.h:12
msgid "Toggle window on all workspaces or one"
msgstr "بدّل حالة ظهور النافذة على جميع مساحات العمل أو واحدة منها"
#: ../data/50-mutter-windows.xml.in.h:13
msgid "Raise window if covered, otherwise lower it"
msgstr "ارفع النافذة إذا كانت أخرى تغطيها، أو أخفضها في ما عدا ذلك"
#: ../data/50-mutter-windows.xml.in.h:14
msgid "Raise window above other windows"
msgstr "ارفع النافذة فوق النوافذ الأخرى"
#: ../data/50-mutter-windows.xml.in.h:15
msgid "Lower window below other windows"
msgstr "اخفض النافذة تحت النوافذ الأخرى"
#: ../data/50-mutter-windows.xml.in.h:16
msgid "Maximize window vertically"
msgstr "كبّر النافذة رأسيا"
#: ../data/50-mutter-windows.xml.in.h:17
msgid "Maximize window horizontally"
msgstr "كبّر النافذة أفقيا"
#: ../data/50-mutter-windows.xml.in.h:18
msgid "View split on left"
msgstr "المنظور مقسوم على اليمين"
#: ../data/50-mutter-windows.xml.in.h:19
msgid "View split on right"
msgstr "المنظور مقسوم على اليسار"
#: ../data/mutter.desktop.in.h:1
msgid "Mutter"
msgstr "مَتَر"
#: ../data/org.gnome.mutter.gschema.xml.in.h:1
msgid "Modifier to use for extended window management operations"
msgstr "المغير الذي سيُستعمل لتمديد عمليات إدارة النوافذ "
#: ../data/org.gnome.mutter.gschema.xml.in.h:2
msgid ""
"This key will initiate the \"overlay\", which is a combination window "
"overview and application launching system. The default is intended to be the "
"\"Windows key\" on PC hardware. It's expected that this binding either the "
"default or set to the empty string."
#. TRANSLATORS: This string refers to a button that switches between
#. * different modes.
#.
#: ../src/backends/meta-input-settings.c:2167
#, c-format
msgid "Mode Switch (Group %d)"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:3
msgid "Attach modal dialogs"
msgstr ""
#. TRANSLATORS: This string refers to an action, cycles drawing tablets'
#. * mapping through the available outputs.
#.
#: ../src/backends/meta-input-settings.c:2190
msgid "Switch monitor"
msgstr "غيّر الشاشة"
#: ../data/org.gnome.mutter.gschema.xml.in.h:4
msgid ""
"When true, instead of having independent titlebars, modal dialogs appear "
"attached to the titlebar of the parent window and are moved together with "
"the parent window."
msgstr ""
#: ../src/backends/meta-input-settings.c:2192
msgid "Show on-screen help"
msgstr "اعرض المساعدة على الشاشة"
#: ../data/org.gnome.mutter.gschema.xml.in.h:5
msgid "Enable edge tiling when dropping windows on screen edges"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:6
msgid ""
"If enabled, dropping windows on vertical screen edges maximizes them "
"vertically and resizes them horizontally to cover half of the available "
"area. Dropping windows on the top screen edge maximizes them completely."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:7
msgid "Workspaces are managed dynamically"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:8
msgid ""
"Determines whether workspaces are managed dynamically or whether there's a "
"static number of workspaces (determined by the num-workspaces key in org."
"gnome.desktop.wm.preferences)."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:9
msgid "Workspaces only on primary"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:10
msgid ""
"Determines whether workspace switching should happen for windows on all "
"monitors or only for windows on the primary monitor."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:11
msgid "No tab popup"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:12
msgid ""
"Determines whether the use of popup and highlight frame should be disabled "
"for window cycling."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:13
msgid "Delay focus changes until the pointer stops moving"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:14
msgid ""
"If set to true, and the focus mode is either \"sloppy\" or \"mouse\" then "
"the focus will not be changed immediately when entering a window, but only "
"after the pointer stops moving."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:15
msgid "Draggable border width"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:16
msgid ""
"The amount of total draggable borders. If the theme's visible borders are "
"not enough, invisible borders will be added to meet this value."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:17
msgid "Auto maximize nearly monitor sized windows"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:18
msgid ""
"If enabled, new windows that are initially the size of the monitor "
"automatically get maximized."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:19
msgid "Place new windows in the center"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:20
msgid ""
"When true, the new windows will always be put in the center of the active "
"screen of the monitor."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:21
msgid "Select window from tab popup"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:22
msgid "Cancel tab popup"
msgstr ""
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:1
#, fuzzy
msgid "Switch to VT 1"
msgstr "انتقل إلى مساحة العمل 1"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:2
#, fuzzy
msgid "Switch to VT 2"
msgstr "انتقل إلى مساحة العمل 2"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:3
#, fuzzy
msgid "Switch to VT 3"
msgstr "انتقل إلى مساحة العمل 3"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:4
#, fuzzy
msgid "Switch to VT 4"
msgstr "انتقل إلى مساحة العمل 4"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:5
#, fuzzy
msgid "Switch to VT 5"
msgstr "انتقل إلى مساحة العمل 5"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:6
#, fuzzy
msgid "Switch to VT 6"
msgstr "انتقل إلى مساحة العمل 6"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:7
#, fuzzy
msgid "Switch to VT 7"
msgstr "انتقل إلى مساحة العمل 7"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:8
#, fuzzy
msgid "Switch to VT 8"
msgstr "انتقل إلى مساحة العمل 8"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:9
#, fuzzy
msgid "Switch to VT 9"
msgstr "انتقل إلى مساحة العمل 9"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:10
#, fuzzy
msgid "Switch to VT 10"
msgstr "انتقل إلى مساحة العمل 10"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:11
#, fuzzy
msgid "Switch to VT 11"
msgstr "انتقل إلى مساحة العمل 11"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:12
#, fuzzy
msgid "Switch to VT 12"
msgstr "انتقل إلى مساحة العمل 12"
#: ../src/backends/meta-monitor-manager.c:364
#: ../src/backends/meta-monitor-manager.c:900
msgid "Built-in display"
msgstr "شاشة مدمجة"
#: ../src/backends/meta-monitor-manager.c:391
#: ../src/backends/meta-monitor-manager.c:923
msgid "Unknown"
msgstr "غير معروفة"
#: ../src/backends/meta-monitor-manager.c:393
#: ../src/backends/meta-monitor-manager.c:925
msgid "Unknown Display"
msgstr "شاشة غير معروفة"
#. TRANSLATORS: this is a monitor vendor name, followed by a
#. * size in inches, like 'Dell 15"'
#.
#: ../src/backends/meta-monitor-manager.c:401
#: ../src/backends/meta-monitor-manager.c:933
#, c-format
msgid "%s %s"
msgstr "%s %s"
#. This probably means that a non-WM compositor like xcompmgr is running;
#. * we have no way to get it to exit
#: ../src/compositor/compositor.c:456
#: ../src/compositor/compositor.c:476
#, c-format
msgid ""
"Another compositing manager is already running on screen %i on display \"%s"
"\"."
msgstr "يعمل مدير مزج آخر على الشاشة %i والعرض \"%s\"."
"Another compositing manager is already running on screen %i on display “%s”."
msgstr "يعمل مدير مزج آخر على الشاشة %i و العرض ”%s“."
#: ../src/core/bell.c:185
#: ../src/core/bell.c:194
msgid "Bell event"
msgstr "حدث جرس"
#: ../src/core/delete.c:127
#: ../src/core/display.c:608
#, c-format
msgid "Failed to open X Window System display “%s”\n"
msgstr "فشل فتح عرض نظام نوافذ إكس ”%s“\n"
#: ../src/core/main.c:189
msgid "Disable connection to session manager"
msgstr "عطّل الاتصال بمدير الجلسة"
#: ../src/core/main.c:195
msgid "Replace the running window manager"
msgstr "استبدل بمدير النوافذ الذي يعمل"
#: ../src/core/main.c:201
msgid "Specify session management ID"
msgstr "حدّد رقم هويّة إدارة الجلسة"
#: ../src/core/main.c:206
msgid "X Display to use"
msgstr "معراض س الذي سيستعمل"
#: ../src/core/main.c:212
msgid "Initialize session from savefile"
msgstr "ابدأ الجلسة من ملف محفوظ"
#: ../src/core/main.c:218
msgid "Make X calls synchronous"
msgstr "اجعل نداءات س متزامنة"
#: ../src/core/main.c:225
msgid "Run as a wayland compositor"
msgstr ""
#: ../src/core/main.c:231
msgid "Run as a nested compositor"
msgstr ""
#: ../src/core/main.c:239
msgid "Run as a full display server, rather than nested"
msgstr ""
#. Translators: %s is a window title
#: ../src/core/meta-close-dialog-default.c:147
#, c-format
msgid "“%s” is not responding."
msgstr "”‏%s“ لا يستجيب."
#: ../src/core/delete.c:129
#: ../src/core/meta-close-dialog-default.c:149
msgid "Application is not responding."
msgstr "لا يستجيب التطبيق"
#: ../src/core/delete.c:134
#: ../src/core/meta-close-dialog-default.c:154
msgid ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
msgstr "ربما ترغب في الانتظار قليلا ليُكمِل أو إجبار التطبيق على الإنهاء كُلّية."
#: ../src/core/delete.c:141
msgid "_Wait"
msgstr "ا_نتظر"
#: ../src/core/delete.c:141
#: ../src/core/meta-close-dialog-default.c:161
msgid "_Force Quit"
msgstr "أ_جبر الإنهاء"
#: ../src/core/display.c:562
#, c-format
msgid "Failed to open X Window System display '%s'\n"
msgstr "فشل فتح عرض نظام نوافذ إكس '%s'\n"
#: ../src/core/main.c:176
msgid "Disable connection to session manager"
msgstr "عطّل الاتصال بمدير الجلسة"
#: ../src/core/main.c:182
msgid "Replace the running window manager"
msgstr "استبدل بمدير النوافذ الذي يعمل"
#: ../src/core/main.c:188
msgid "Specify session management ID"
msgstr "حدّد رقم هويّة إدارة الجلسة"
#: ../src/core/main.c:193
msgid "X Display to use"
msgstr "معراض س الذي سيستعمل"
#: ../src/core/main.c:199
msgid "Initialize session from savefile"
msgstr "ابدأ الجلسة من ملف محفوظ"
#: ../src/core/main.c:205
msgid "Make X calls synchronous"
msgstr "اجعل نداءات س متزامنة"
#: ../src/core/main.c:212
msgid "Run as a wayland compositor"
msgstr ""
#: ../src/core/main.c:220
msgid "Run as a full display server, rather than nested"
msgstr ""
#: ../src/core/meta-close-dialog-default.c:161
msgid "_Wait"
msgstr "ا_نتظر"
#: ../src/core/mutter.c:39
#, c-format
msgid ""
"mutter %s\n"
"Copyright (C) 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
"Copyright © 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
"This is free software; see the source for copying conditions.\n"
"There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A "
"PARTICULAR PURPOSE.\n"
@ -555,42 +162,281 @@ msgstr "اطبع الإصدارة"
msgid "Mutter plugin to use"
msgstr "ملحق مَتَر الذي سيُستخدم"
#: ../src/core/prefs.c:2004
#: ../src/core/prefs.c:1997
#, c-format
msgid "Workspace %d"
msgstr "مساحة العمل %d"
#: ../src/core/screen.c:525
#: ../src/core/screen.c:583
#, c-format
msgid ""
"Display \"%s\" already has a window manager; try using the --replace option "
"to replace the current window manager."
"Display “%s” already has a window manager; try using the --replace option to "
"replace the current window manager."
msgstr ""
"الشاشة \"%s\" لها مدير نوافذ بالفعل، حاول استعمال خيار التبديل --replace "
"لتحُلّ محلّ مدير النوافذ الحالي."
"الشاشة ”%s“ لها مدير نوافذ بالفعل، حاول استعمال خيار التبديل --replace لتحُلّ"
" محلّ مدير النوافذ الحالي."
#: ../src/core/screen.c:607
#: ../src/core/screen.c:668
#, c-format
msgid "Screen %d on display '%s' is invalid\n"
msgstr "الشاشة %d على العرض '%s' غير صحيحة\n"
msgid "Screen %d on display %s is invalid\n"
msgstr "الشاشة %d على العرض %s غير صحيحة\n"
#: ../src/core/util.c:118
#: ../src/core/util.c:120
msgid "Mutter was compiled without support for verbose mode\n"
msgstr "جُمِّع مَتَر دون دعم للنمط المطنب\n"
#: ../src/wayland/meta-wayland-tablet-pad.c:563
#, c-format
msgid "Mode Switch: Mode %d"
msgstr ""
#: ../src/x11/session.c:1815
msgid ""
"These windows do not support &quot;save current setup&quot; and will have to "
"be restarted manually next time you log in."
"These windows do not support save current setup and will have to be "
"restarted manually next time you log in."
msgstr ""
"هذه النوافذ لا تدعم &quot;احفظ الضبط الحالي&quot; يجب إعادة تشغيلها يدويا "
"عند الولوج المرة القادمة."
"هذه النوافذ لا تدعم الضبط الحالي&quot; إعادة تشغيلها يدويا عند الولوج "
"المرة القادمة."
#: ../src/x11/window-props.c:549
#: ../src/x11/window-props.c:559
#, c-format
msgid "%s (on %s)"
msgstr "%s (على %s)"
#~ msgid "Navigation"
#~ msgstr "الإبحار"
#~ msgid "Move window to workspace 1"
#~ msgstr "انقل النافذة إلى مساحة العمل 1"
#~ msgid "Move window to workspace 2"
#~ msgstr "انقل النافذة إلى مساحة العمل 2"
#~ msgid "Move window to workspace 3"
#~ msgstr "انقل النافذة إلى مساحة العمل 3"
#~ msgid "Move window to workspace 4"
#~ msgstr "انقل النافذة إلى مساحة العمل 4"
#~ msgid "Move window to last workspace"
#~ msgstr "انقل النافذة إلى مساحة العمل الأخيرة"
#~ msgid "Move window one workspace to the left"
#~ msgstr "انقل النافذة مساحة عمل واحدة إلى اليسار"
#~ msgid "Move window one workspace to the right"
#~ msgstr "انقل النافذة مساحة عمل واحدة إلى اليمين"
#~ msgid "Move window one workspace up"
#~ msgstr "انقل النافذة مساحة عمل واحدة إلى الأعلى"
#~ msgid "Move window one workspace down"
#~ msgstr "انقل النافذة مساحة عمل واحدة إلى الأسفل"
#~ msgid "Move window one monitor to the left"
#~ msgstr "انقل النافذة شاشة واحدة إلى اليسار"
#~ msgid "Move window one monitor to the right"
#~ msgstr "انقل النافذة شاشة واحدة إلى اليمين"
#~ msgid "Move window one monitor up"
#~ msgstr "انقل النافذة شاشة واحدة إلى الأعلى"
#~ msgid "Move window one monitor down"
#~ msgstr "انقل النافذة شاشة واحدة إلى الأسفل"
#~ msgid "Switch applications"
#~ msgstr "تنقل بين التطبيقات"
#~ msgid "Switch to previous application"
#~ msgstr "انتقل إلى التطبيق السابق"
#~ msgid "Switch windows"
#~ msgstr "تنقل بين النوافذ"
#~ msgid "Switch to previous window"
#~ msgstr "انتقل إلى النافذة السابقة"
#~ msgid "Switch windows of an application"
#~ msgstr "تنقل بين نوافذ التطبيق"
#~ msgid "Switch to previous window of an application"
#~ msgstr "انتقل إلى نافذة التطبيق السابقة"
#~ msgid "Switch system controls"
#~ msgstr "تنقل بين تحكمات النظام"
#~ msgid "Switch to previous system control"
#~ msgstr "انتقل إلى تحكم النظام السابق"
#~ msgid "Switch windows directly"
#~ msgstr "تنقل مباشرة بين النوافذ"
#~ msgid "Switch directly to previous window"
#~ msgstr "انتقل مباشرة إلى النافذة السابقة"
#~ msgid "Switch windows of an app directly"
#~ msgstr "تنقل مباشرة بين نوافذ التطبيق"
#~ msgid "Switch directly to previous window of an app"
#~ msgstr "انتقل مباشرة إلى نافذة التطبيق السابقة"
#~ msgid "Switch system controls directly"
#~ msgstr "تنقل مباشرة بين تحكمات النظام"
#~ msgid "Switch directly to previous system control"
#~ msgstr "انتقل مباشرة إلى تحكم النظام السابق"
#~ msgid "Hide all normal windows"
#~ msgstr "أخفِ كل النوافذ العادية"
#~ msgid "Switch to workspace 1"
#~ msgstr "انتقل إلى مساحة العمل 1"
#~ msgid "Switch to workspace 2"
#~ msgstr "انتقل إلى مساحة العمل 2"
#~ msgid "Switch to workspace 3"
#~ msgstr "انتقل إلى مساحة العمل 3"
#~ msgid "Switch to workspace 4"
#~ msgstr "انتقل إلى مساحة العمل 4"
#~ msgid "Switch to last workspace"
#~ msgstr "انتقل إلى مساحة العمل الأخيرة"
#~ msgid "Move to workspace left"
#~ msgstr "انقل لمساحة العمل على اليسار"
#~ msgid "Move to workspace right"
#~ msgstr "انقل لمساحة العمل على اليمين"
#~ msgid "Move to workspace above"
#~ msgstr "انقل لمساحة العمل أعلى"
#~ msgid "Move to workspace below"
#~ msgstr "انقل لمساحة العمل أسفل"
#~ msgid "System"
#~ msgstr "النظام"
#~ msgid "Show the run command prompt"
#~ msgstr "أظهر محث تشغيل أمر"
#~ msgid "Show the activities overview"
#~ msgstr "أظهر نظرة عامة على الأنشطة"
#~ msgid "Windows"
#~ msgstr "النوافذ"
#~ msgid "Activate the window menu"
#~ msgstr "فعّل قائمة النافذة"
#~ msgid "Toggle fullscreen mode"
#~ msgstr "بدّل نمط ملء الشاشة"
#~ msgid "Toggle maximization state"
#~ msgstr "بدّل حالة التكبير"
#~ msgid "Maximize window"
#~ msgstr "كبّر النّافذة"
#~ msgid "Restore window"
#~ msgstr "استعد النّافذة"
#~ msgid "Toggle shaded state"
#~ msgstr "بدّل حالة الإخفاء"
#~ msgid "Close window"
#~ msgstr "أغلق النّافذة"
#~ msgid "Hide window"
#~ msgstr "أخفِ النّافذة"
#~ msgid "Move window"
#~ msgstr "انقل النّافذة"
#~ msgid "Resize window"
#~ msgstr "حجّم النّافذة"
#~ msgid "Toggle window on all workspaces or one"
#~ msgstr "بدّل حالة ظهور النافذة على جميع مساحات العمل أو واحدة منها"
#~ msgid "Raise window if covered, otherwise lower it"
#~ msgstr "ارفع النافذة إذا كانت أخرى تغطيها، أو أخفضها في ما عدا ذلك"
#~ msgid "Raise window above other windows"
#~ msgstr "ارفع النافذة فوق النوافذ الأخرى"
#~ msgid "Lower window below other windows"
#~ msgstr "اخفض النافذة تحت النوافذ الأخرى"
#~ msgid "Maximize window vertically"
#~ msgstr "كبّر النافذة رأسيا"
#~ msgid "Maximize window horizontally"
#~ msgstr "كبّر النافذة أفقيا"
#~ msgid "View split on left"
#~ msgstr "المنظور مقسوم على اليمين"
#~ msgid "View split on right"
#~ msgstr "المنظور مقسوم على اليسار"
#~ msgid "Mutter"
#~ msgstr "مَتَر"
#~ msgid "Modifier to use for extended window management operations"
#~ msgstr "المغير الذي سيُستعمل لتمديد عمليات إدارة النوافذ "
#, fuzzy
#~ msgid "Switch to VT 1"
#~ msgstr "انتقل إلى مساحة العمل 1"
#, fuzzy
#~ msgid "Switch to VT 2"
#~ msgstr "انتقل إلى مساحة العمل 2"
#, fuzzy
#~ msgid "Switch to VT 3"
#~ msgstr "انتقل إلى مساحة العمل 3"
#, fuzzy
#~ msgid "Switch to VT 4"
#~ msgstr "انتقل إلى مساحة العمل 4"
#, fuzzy
#~ msgid "Switch to VT 5"
#~ msgstr "انتقل إلى مساحة العمل 5"
#, fuzzy
#~ msgid "Switch to VT 6"
#~ msgstr "انتقل إلى مساحة العمل 6"
#, fuzzy
#~ msgid "Switch to VT 7"
#~ msgstr "انتقل إلى مساحة العمل 7"
#, fuzzy
#~ msgid "Switch to VT 8"
#~ msgstr "انتقل إلى مساحة العمل 8"
#, fuzzy
#~ msgid "Switch to VT 9"
#~ msgstr "انتقل إلى مساحة العمل 9"
#, fuzzy
#~ msgid "Switch to VT 10"
#~ msgstr "انتقل إلى مساحة العمل 10"
#, fuzzy
#~ msgid "Switch to VT 11"
#~ msgstr "انتقل إلى مساحة العمل 11"
#, fuzzy
#~ msgid "Switch to VT 12"
#~ msgstr "انتقل إلى مساحة العمل 12"
#~ msgid "Unknown window information request: %d"
#~ msgstr "طلب معلومات نافذة مجهول: %d"

View File

@ -5,8 +5,8 @@ msgstr ""
"Project-Id-Version: mutter.master\n"
"Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?"
"product=mutter&keywords=I18N+L10N&component=general\n"
"POT-Creation-Date: 2017-04-21 21:33+0000\n"
"PO-Revision-Date: 2017-04-23 16:56+0300\n"
"POT-Creation-Date: 2017-08-29 16:09+0000\n"
"PO-Revision-Date: 2017-09-01 18:44+0300\n"
"Last-Translator: Yuras Shumovich <shumovichy@gmail.com>\n"
"Language-Team: Belarusian <i18n-bel-gnome@googlegroups.com>\n"
"Language: be\n"
@ -409,7 +409,10 @@ msgid ""
"proof. Currently possible keywords: • “scale-monitor-framebuffer” — makes "
"mutter default to layout logical monitors in a logical pixel coordinate "
"space, while scaling monitor framebuffers instead of window content, to "
"manage HiDPI monitors. Does not require a restart."
"manage HiDPI monitors. Does not require a restart. • “remote-desktop” — "
"enables remote desktop support. To support remote desktop with screen "
"sharing, “screen-cast” must also be enabled. • “screen-cast” — enables "
"screen cast support."
msgstr ""
"Каб уключыць эксперыментальныя функцыі, дадайце адпаведнае ключавое слова ў "
"гэты ліст. Некаторыя функцыі могуць патрабаваць перазапуску кампазітара. "
@ -418,16 +421,27 @@ msgstr ""
"\"scale-monitor-framebuffer\" - прымушае mutter прадвызначана размяшчаць "
"лагічныя маніторы ў лагічнай прасторы каардынат пікселаў, пры гэтым "
"маштабаваць кадравы буфер, а не змесціва акна, для падтрымкі HiDPI "
"манітораў. Не патрабуе перазапуску."
"манітораў. Не патрабуе перазапуску. • \"remote-desktop\" - уключае падтрымку "
"аддаленых манітораў. Для падтрымкі аддаленых манітораў з супольным доступам "
"да экрана трэба таксама ўключыць \"screen-cast\". • \"screen-cast\" - "
"уключае падтрымку скрынкасту."
#: data/org.gnome.mutter.gschema.xml.in:141
#: data/org.gnome.mutter.gschema.xml.in:145
msgid "Select window from tab popup"
msgstr "Выбраць акно з выплыўнога акенца"
#: data/org.gnome.mutter.gschema.xml.in:146
#: data/org.gnome.mutter.gschema.xml.in:150
msgid "Cancel tab popup"
msgstr "Закрыць выплыўное акенца"
#: data/org.gnome.mutter.gschema.xml.in:155
msgid "Switch monitor configurations"
msgstr "Пераключыць канфігурацыі манітора"
#: data/org.gnome.mutter.gschema.xml.in:160
msgid "Rotates the built-in monitor configuration"
msgstr "Паварочвае убудаваны манітор"
#: data/org.gnome.mutter.wayland.gschema.xml.in:6
msgid "Switch to VT 1"
msgstr "Перайсці ў віртуальны тэрмінал 1"
@ -476,10 +490,14 @@ msgstr "Перайсці ў віртуальны тэрмінал 11"
msgid "Switch to VT 12"
msgstr "Перайсці ў віртуальны тэрмінал 12"
#: data/org.gnome.mutter.wayland.gschema.xml.in:54
msgid "Re-enable shortcuts"
msgstr "Уключыць назад клавіятурныя скароты"
#. TRANSLATORS: This string refers to a button that switches between
#. * different modes.
#.
#: src/backends/meta-input-settings.c:1848
#: src/backends/meta-input-settings.c:2151
#, c-format
msgid "Mode Switch (Group %d)"
msgstr "Пераключыць рэжым (група %d)"
@ -487,37 +505,37 @@ msgstr "Пераключыць рэжым (група %d)"
#. TRANSLATORS: This string refers to an action, cycles drawing tablets'
#. * mapping through the available outputs.
#.
#: src/backends/meta-input-settings.c:1870
#: src/backends/meta-input-settings.c:2174
msgid "Switch monitor"
msgstr "Пераключыць манітор"
#: src/backends/meta-input-settings.c:1872
#: src/backends/meta-input-settings.c:2176
msgid "Show on-screen help"
msgstr "Паказаць экранную даведку"
#: src/backends/meta-monitor-manager.c:783
#: src/backends/meta-monitor-manager.c:903
msgid "Built-in display"
msgstr "Убудаваны дысплей"
#: src/backends/meta-monitor-manager.c:806
#: src/backends/meta-monitor-manager.c:926
msgid "Unknown"
msgstr "Невядомы"
#: src/backends/meta-monitor-manager.c:808
#: src/backends/meta-monitor-manager.c:928
msgid "Unknown Display"
msgstr "Невядомы дысплей"
#. TRANSLATORS: this is a monitor vendor name, followed by a
#. * size in inches, like 'Dell 15"'
#.
#: src/backends/meta-monitor-manager.c:816
#: src/backends/meta-monitor-manager.c:936
#, c-format
msgid "%s %s"
msgstr "%s %s"
#. This probably means that a non-WM compositor like xcompmgr is running;
#. * we have no way to get it to exit
#: src/compositor/compositor.c:474
#: src/compositor/compositor.c:476
#, c-format
msgid ""
"Another compositing manager is already running on screen %i on display “%s”."
@ -528,31 +546,6 @@ msgstr ""
msgid "Bell event"
msgstr "Падзея з сігналам"
#. Translators: %s is a window title
#: src/core/delete.c:127
#, c-format
msgid "“%s” is not responding."
msgstr "\"%s\" не адказвае на запыты."
#: src/core/delete.c:129
msgid "Application is not responding."
msgstr "Праграма не адказвае на запыты."
#: src/core/delete.c:134
msgid ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
msgstr ""
"Вы можаце альбо крыху пачакаць адказу, альбо змусіць праграму да выхаду."
#: src/core/delete.c:141
msgid "_Force Quit"
msgstr "_Змусіць да выхаду"
#: src/core/delete.c:141
msgid "_Wait"
msgstr "_Пачакаць"
#: src/core/display.c:608
#, c-format
msgid "Failed to open X Window System display “%s”\n"
@ -594,6 +587,31 @@ msgstr "Запусціць у якасці ўложанага кампазіта
msgid "Run as a full display server, rather than nested"
msgstr "Запусціць у якасці паўнавартаснага сервера дысплея, я не як уложаны "
#. Translators: %s is a window title
#: src/core/meta-close-dialog-default.c:147
#, c-format
msgid "“%s” is not responding."
msgstr "\"%s\" не адказвае на запыты."
#: src/core/meta-close-dialog-default.c:149
msgid "Application is not responding."
msgstr "Праграма не адказвае на запыты."
#: src/core/meta-close-dialog-default.c:154
msgid ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
msgstr ""
"Вы можаце альбо крыху пачакаць адказу, альбо змусіць праграму да выхаду."
#: src/core/meta-close-dialog-default.c:161
msgid "_Force Quit"
msgstr "_Змусіць да выхаду"
#: src/core/meta-close-dialog-default.c:161
msgid "_Wait"
msgstr "_Пачакаць"
#: src/core/mutter.c:39
#, c-format
msgid ""

988
po/bg.po

File diff suppressed because it is too large Load Diff

303
po/ca.po
View File

@ -5,24 +5,23 @@
# Jesús Moreno <jmmolas@wanadoo.es>, 2002.
# Jordi Mallach <jordi@sindominio.net>, 2003, 2004, 2005, 2006, 2007, 2008.
# David Planella <david.planella@gmail.com>, 2008, 2009, 2011, 2012.
# Jordi Serratosa <jordis@softcatala.cat>, 2012.
# Jordi Serratosa <jordis@softcatala.cat>, 2012, 2017.
# Gil Forcada <gilforcada@guifi.net>, 2012, 2013, 2014, 2016.
#
msgid ""
msgstr ""
"Project-Id-Version: metacity 2.24\n"
"Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?"
"product=mutter&keywords=I18N+L10N&component=general\n"
"POT-Creation-Date: 2017-04-21 21:33+0000\n"
"PO-Revision-Date: 2016-03-13 14:45+0100\n"
"Last-Translator: Gil Forcada <gilforcada@guifi.net>\n"
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/mutter/issues\n"
"POT-Creation-Date: 2018-06-07 13:00+0000\n"
"PO-Revision-Date: 2018-06-17 10:25+0200\n"
"Last-Translator: Jordi Mas <jmas@softcatala.org>\n"
"Language-Team: Catalan <tradgnome@softcatala.org>\n"
"Language: ca\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bits\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Gtranslator 2.91.6\n"
"X-Generator: Poedit 2.0.6\n"
#: data/50-mutter-navigation.xml:6
msgid "Navigation"
@ -49,136 +48,118 @@ msgid "Move window to last workspace"
msgstr "Mou la finestra a l'últim espai de treball"
#: data/50-mutter-navigation.xml:24
msgid "Move window one workspace to the left"
msgstr "Mou la finestra un espai de treball a l'esquerra"
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace to the right"
msgstr "Mou la finestra un espai de treball a la dreta"
#: data/50-mutter-navigation.xml:30
msgid "Move window one workspace up"
msgstr "Mou la finestra un espai de treball amunt"
#: data/50-mutter-navigation.xml:33
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace down"
msgstr "Mou la finestra un espai de treball avall"
#: data/50-mutter-navigation.xml:36
#: data/50-mutter-navigation.xml:30
msgid "Move window one monitor to the left"
msgstr "Mou la finestra un monitor a l'esquerra"
#: data/50-mutter-navigation.xml:39
#: data/50-mutter-navigation.xml:33
msgid "Move window one monitor to the right"
msgstr "Mou la finestra un monitor a la dreta"
#: data/50-mutter-navigation.xml:42
#: data/50-mutter-navigation.xml:36
msgid "Move window one monitor up"
msgstr "Mou la finestra un monitor amunt"
#: data/50-mutter-navigation.xml:45
#: data/50-mutter-navigation.xml:39
msgid "Move window one monitor down"
msgstr "Mou la finestra un monitor avall"
#: data/50-mutter-navigation.xml:49
#: data/50-mutter-navigation.xml:43
msgid "Switch applications"
msgstr "Canvia d'aplicacions"
#: data/50-mutter-navigation.xml:54
#: data/50-mutter-navigation.xml:48
msgid "Switch to previous application"
msgstr "Canvia a l'aplicació anterior"
#: data/50-mutter-navigation.xml:58
#: data/50-mutter-navigation.xml:52
msgid "Switch windows"
msgstr "Canvia de finestres"
#: data/50-mutter-navigation.xml:63
#: data/50-mutter-navigation.xml:57
msgid "Switch to previous window"
msgstr "Canvia a la finestra anterior"
#: data/50-mutter-navigation.xml:67
#: data/50-mutter-navigation.xml:61
msgid "Switch windows of an application"
msgstr "Canvia entre les finestres d'una aplicació"
#: data/50-mutter-navigation.xml:72
#: data/50-mutter-navigation.xml:66
msgid "Switch to previous window of an application"
msgstr "Canvia a la finestra anterior d'una aplicació"
#: data/50-mutter-navigation.xml:76
#, fuzzy
#| msgid "Switch system controls directly"
#: data/50-mutter-navigation.xml:70
msgid "Switch system controls"
msgstr "Canvia immediatament entre els controls del sistema"
msgstr "Canvia els controls del sistema"
#: data/50-mutter-navigation.xml:81
#: data/50-mutter-navigation.xml:75
msgid "Switch to previous system control"
msgstr "Canvia al control del sistema anterior"
#: data/50-mutter-navigation.xml:85
#: data/50-mutter-navigation.xml:79
msgid "Switch windows directly"
msgstr "Canvia immediatament entre finestres"
#: data/50-mutter-navigation.xml:90
#: data/50-mutter-navigation.xml:84
msgid "Switch directly to previous window"
msgstr "Canvia immediatament a la finestra anterior"
#: data/50-mutter-navigation.xml:94
#: data/50-mutter-navigation.xml:88
msgid "Switch windows of an app directly"
msgstr "Canvia immediatament entre les finestres d'una aplicació"
#: data/50-mutter-navigation.xml:99
#: data/50-mutter-navigation.xml:93
msgid "Switch directly to previous window of an app"
msgstr "Canvia immediatament a la finestra anterior d'una aplicació"
#: data/50-mutter-navigation.xml:103
#: data/50-mutter-navigation.xml:97
msgid "Switch system controls directly"
msgstr "Canvia immediatament entre els controls del sistema"
#: data/50-mutter-navigation.xml:108
#: data/50-mutter-navigation.xml:102
msgid "Switch directly to previous system control"
msgstr "Canvia immediatament al control del sistema anterior"
#: data/50-mutter-navigation.xml:111
#: data/50-mutter-navigation.xml:105
msgid "Hide all normal windows"
msgstr "Oculta totes les finestres normals"
#: data/50-mutter-navigation.xml:114
#: data/50-mutter-navigation.xml:108
msgid "Switch to workspace 1"
msgstr "Canvia a l'espai de treball 1"
#: data/50-mutter-navigation.xml:117
#: data/50-mutter-navigation.xml:111
msgid "Switch to workspace 2"
msgstr "Canvia a l'espai de treball 2"
#: data/50-mutter-navigation.xml:120
#: data/50-mutter-navigation.xml:114
msgid "Switch to workspace 3"
msgstr "Canvia a l'espai de treball 3"
#: data/50-mutter-navigation.xml:123
#: data/50-mutter-navigation.xml:117
msgid "Switch to workspace 4"
msgstr "Canvia a l'espai de treball 4"
#: data/50-mutter-navigation.xml:126
#: data/50-mutter-navigation.xml:120
msgid "Switch to last workspace"
msgstr "Canvia a l'últim espai de treball"
#: data/50-mutter-navigation.xml:129
msgid "Move to workspace left"
msgstr "Mou a l'espai de treball de l'esquerra"
#: data/50-mutter-navigation.xml:132
msgid "Move to workspace right"
msgstr "Mou a l'espai de treball de la dreta"
#: data/50-mutter-navigation.xml:135
#: data/50-mutter-navigation.xml:123
msgid "Move to workspace above"
msgstr "Mou a l'espai de treball de sobre"
#: data/50-mutter-navigation.xml:138
#: data/50-mutter-navigation.xml:126
msgid "Move to workspace below"
msgstr "Mou a l'espai de treball de sota"
#: data/50-mutter-system.xml:6
#: data/50-mutter-system.xml:6 data/50-mutter-wayland.xml:6
msgid "System"
msgstr "Sistema"
@ -190,6 +171,10 @@ msgstr "Mostra l'indicador d'execució d'aplicacions"
msgid "Show the activities overview"
msgstr "Mostra la vista general d'activitats"
#: data/50-mutter-wayland.xml:8
msgid "Restore the keyboard shortcuts"
msgstr "Restaura les dreceres de teclat"
#: data/50-mutter-windows.xml:6
msgid "Windows"
msgstr "Finestres"
@ -215,56 +200,52 @@ msgid "Restore window"
msgstr "Restaura la finestra"
#: data/50-mutter-windows.xml:18
msgid "Toggle shaded state"
msgstr "Canvia l'estat d'ombrejat"
#: data/50-mutter-windows.xml:20
msgid "Close window"
msgstr "Tanca la finestra"
#: data/50-mutter-windows.xml:22
#: data/50-mutter-windows.xml:20
msgid "Hide window"
msgstr "Oculta la finestra"
#: data/50-mutter-windows.xml:24
#: data/50-mutter-windows.xml:22
msgid "Move window"
msgstr "Mou la finestra"
#: data/50-mutter-windows.xml:26
#: data/50-mutter-windows.xml:24
msgid "Resize window"
msgstr "Redimensiona la finestra"
#: data/50-mutter-windows.xml:29
#: data/50-mutter-windows.xml:27
msgid "Toggle window on all workspaces or one"
msgstr ""
"Canvia la funció que fa que la finestra estigui en tots els espais de "
"treball o només en un"
#: data/50-mutter-windows.xml:31
#: data/50-mutter-windows.xml:29
msgid "Raise window if covered, otherwise lower it"
msgstr "Alça la finestra si està coberta per una altra, o sinó baixa-la"
msgstr "Alça la finestra si està coberta per una altra; altrament, baixa-la"
#: data/50-mutter-windows.xml:33
#: data/50-mutter-windows.xml:31
msgid "Raise window above other windows"
msgstr "Alça la finestra per damunt de les altres"
#: data/50-mutter-windows.xml:35
#: data/50-mutter-windows.xml:33
msgid "Lower window below other windows"
msgstr "Baixa la finestra sota les altres"
#: data/50-mutter-windows.xml:37
#: data/50-mutter-windows.xml:35
msgid "Maximize window vertically"
msgstr "Maximitza la finestra verticalment"
#: data/50-mutter-windows.xml:39
#: data/50-mutter-windows.xml:37
msgid "Maximize window horizontally"
msgstr "Maximitza la finestra horitzontalment"
#: data/50-mutter-windows.xml:43
#: data/50-mutter-windows.xml:41
msgid "View split on left"
msgstr "Mostra la partició a l'esquerra"
#: data/50-mutter-windows.xml:47
#: data/50-mutter-windows.xml:45
msgid "View split on right"
msgstr "Mostra la partició a la dreta"
@ -279,12 +260,6 @@ msgstr ""
"finestres"
#: data/org.gnome.mutter.gschema.xml.in:8
#, fuzzy
#| msgid ""
#| "This key will initiate the \"overlay\", which is a combination window "
#| "overview and application launching system. The default is intended to be "
#| "the \"Windows key\" on PC hardware. It's expected that this binding "
#| "either the default or set to the empty string."
msgid ""
"This key will initiate the “overlay”, which is a combination window overview "
"and application launching system. The default is intended to be the “Windows "
@ -314,7 +289,7 @@ msgstr ""
#: data/org.gnome.mutter.gschema.xml.in:30
msgid "Enable edge tiling when dropping windows on screen edges"
msgstr ""
"Habilita la tesselització a les vores en deixar anar les finestres a les "
"Habilita la tessel·lització a les vores en deixar anar les finestres a les "
"vores de la pantalla"
#: data/org.gnome.mutter.gschema.xml.in:31
@ -333,11 +308,6 @@ msgid "Workspaces are managed dynamically"
msgstr "Els espais de treball es gestionen dinàmicament"
#: data/org.gnome.mutter.gschema.xml.in:41
#, fuzzy
#| msgid ""
#| "Determines whether workspaces are managed dynamically or whether there's "
#| "a static number of workspaces (determined by the num-workspaces key in "
#| "org.gnome.desktop.wm.preferences)."
msgid ""
"Determines whether workspaces are managed dynamically or whether theres a "
"static number of workspaces (determined by the num-workspaces key in org."
@ -376,11 +346,6 @@ msgid "Delay focus changes until the pointer stops moving"
msgstr "Retarda el canvi del focus fins que s'aturi el punter"
#: data/org.gnome.mutter.gschema.xml.in:69
#, fuzzy
#| msgid ""
#| "If set to true, and the focus mode is either \"sloppy\" or \"mouse\" then "
#| "the focus will not be changed immediately when entering a window, but "
#| "only after the pointer stops moving."
msgid ""
"If set to true, and the focus mode is either “sloppy” or “mouse” then the "
"focus will not be changed immediately when entering a window, but only after "
@ -395,10 +360,6 @@ msgid "Draggable border width"
msgstr "Amplada del contorn arrossegable"
#: data/org.gnome.mutter.gschema.xml.in:80
#, fuzzy
#| msgid ""
#| "The amount of total draggable borders. If the theme's visible borders are "
#| "not enough, invisible borders will be added to meet this value."
msgid ""
"The amount of total draggable borders. If the themes visible borders are "
"not enough, invisible borders will be added to meet this value."
@ -435,7 +396,7 @@ msgstr ""
#: data/org.gnome.mutter.gschema.xml.in:107
msgid "Enable experimental features"
msgstr ""
msgstr "Habilita les funcionalitats experimentals"
#: data/org.gnome.mutter.gschema.xml.in:108
msgid ""
@ -457,6 +418,14 @@ msgstr "Selecció de finestra entre les emergents d'una pestanya"
msgid "Cancel tab popup"
msgstr "Cancel·lació de les finestres emergents a les pestanyes"
#: data/org.gnome.mutter.gschema.xml.in:151
msgid "Switch monitor configurations"
msgstr "Canvia configuracions de monitor"
#: data/org.gnome.mutter.gschema.xml.in:156
msgid "Rotates the built-in monitor configuration"
msgstr "Gira la configuració del monitor integrada"
#: data/org.gnome.mutter.wayland.gschema.xml.in:6
msgid "Switch to VT 1"
msgstr "Canvia al terminal virtual 1"
@ -505,10 +474,45 @@ msgstr "Canvia al terminal virtual 11"
msgid "Switch to VT 12"
msgstr "Canvia al terminal virtual 12"
#: data/org.gnome.mutter.wayland.gschema.xml.in:54
msgid "Re-enable shortcuts"
msgstr "Torna a habilitar les dreceres"
#: data/org.gnome.mutter.wayland.gschema.xml.in:64
msgid "Allow grabs with Xwayland"
msgstr "Permetre la captura amb Xwayland"
#: data/org.gnome.mutter.wayland.gschema.xml.in:65
msgid ""
"Allow keyboard grabs issued by X11 applications running in Xwayland to be "
"taken into account. For a X11 grab to be taken into account under Wayland, "
"the client must also either send a specific X11 ClientMessage to the root "
"window or be among the applications white-listed in key “xwayland-grab-"
"access-rules”."
msgstr ""
#: data/org.gnome.mutter.wayland.gschema.xml.in:77
msgid "Xwayland applications allowed to issue keyboard grabs"
msgstr "Les aplicacions Xwayland poden capturar el teclat"
#: data/org.gnome.mutter.wayland.gschema.xml.in:78
msgid ""
"List the resource names or resource class of X11 windows either allowed or "
"not allowed to issue X11 keyboard grabs under Xwayland. The resource name or "
"resource class of a given X11 window can be obtained using the command "
"“xprop WM_CLASS”. Wildcards “*” and jokers “?” in the values are supported. "
"Values starting with “!” are blacklisted, which has precedence over the "
"whitelist, to revoke applications from the default system list. The default "
"system list includes the following applications: "
"“@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES@” Users can break an existing grab by "
"using the specific keyboard shortcut defined by the keybinding key “restore-"
"shortcuts”."
msgstr ""
#. TRANSLATORS: This string refers to a button that switches between
#. * different modes.
#.
#: src/backends/meta-input-settings.c:1848
#: src/backends/meta-input-settings.c:2325
#, c-format
msgid "Mode Switch (Group %d)"
msgstr "Mode de commutació (grup %d)"
@ -516,37 +520,37 @@ msgstr "Mode de commutació (grup %d)"
#. TRANSLATORS: This string refers to an action, cycles drawing tablets'
#. * mapping through the available outputs.
#.
#: src/backends/meta-input-settings.c:1870
#: src/backends/meta-input-settings.c:2348
msgid "Switch monitor"
msgstr "Commuta el monitor"
#: src/backends/meta-input-settings.c:1872
#: src/backends/meta-input-settings.c:2350
msgid "Show on-screen help"
msgstr "Mostra l'ajuda en pantalla"
#: src/backends/meta-monitor-manager.c:783
#: src/backends/meta-monitor-manager.c:903
msgid "Built-in display"
msgstr "Pantalla integrada"
#: src/backends/meta-monitor-manager.c:806
#: src/backends/meta-monitor-manager.c:926
msgid "Unknown"
msgstr "Desconeguda"
#: src/backends/meta-monitor-manager.c:808
#: src/backends/meta-monitor-manager.c:928
msgid "Unknown Display"
msgstr "Pantalla desconeguda"
#. TRANSLATORS: this is a monitor vendor name, followed by a
#. * size in inches, like 'Dell 15"'
#.
#: src/backends/meta-monitor-manager.c:816
#: src/backends/meta-monitor-manager.c:936
#, c-format
msgid "%s %s"
msgstr "%s %s"
#. This probably means that a non-WM compositor like xcompmgr is running;
#. * we have no way to get it to exit
#: src/compositor/compositor.c:474
#: src/compositor/compositor.c:481
#, c-format
msgid ""
"Another compositing manager is already running on screen %i on display “%s”."
@ -558,63 +562,37 @@ msgstr ""
msgid "Bell event"
msgstr "Esdeveniment de campana"
#. Translators: %s is a window title
#: src/core/delete.c:127
#, c-format
msgid "“%s” is not responding."
msgstr "«%s» no està responent."
#: src/core/delete.c:129
msgid "Application is not responding."
msgstr "L'aplicació no està responent."
#: src/core/delete.c:134
msgid ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
msgstr ""
"Podeu esperar un moment perquè continuï o podeu forçar-ne la sortida "
"completa."
#: src/core/delete.c:141
msgid "_Force Quit"
msgstr "_Força'n la sortida"
#: src/core/delete.c:141
msgid "_Wait"
msgstr "_Espera"
#: src/core/display.c:608
#, c-format
msgid "Failed to open X Window System display “%s”\n"
msgstr ""
"S'ha produït un error en obrir la pantalla del sistema de finestres X «%s»\n"
#: src/core/main.c:189
#: src/core/main.c:190
msgid "Disable connection to session manager"
msgstr "Inhabilita la connexió al gestor de sessions"
#: src/core/main.c:195
#: src/core/main.c:196
msgid "Replace the running window manager"
msgstr "Reemplaça el gestor de finestres en execució"
#: src/core/main.c:201
#: src/core/main.c:202
msgid "Specify session management ID"
msgstr "Especifica l'ID de gestió de sessió"
#: src/core/main.c:206
#: src/core/main.c:207
msgid "X Display to use"
msgstr "Visualització X per usar"
#: src/core/main.c:212
#: src/core/main.c:213
msgid "Initialize session from savefile"
msgstr "Inicialitza la sessió des del fitxer desat"
#: src/core/main.c:218
#: src/core/main.c:219
msgid "Make X calls synchronous"
msgstr "Fes que les crides a l'X siguin síncrones"
#: src/core/main.c:225
#: src/core/main.c:226
msgid "Run as a wayland compositor"
msgstr "Funciona com a compositor de Wayland"
@ -623,14 +601,44 @@ msgstr "Funciona com a compositor de Wayland"
#
# Camins:
# ../src/core/main.c:223
#: src/core/main.c:231
#: src/core/main.c:232
msgid "Run as a nested compositor"
msgstr "Funciona com a compositor imbricat"
#: src/core/main.c:239
#: src/core/main.c:240
msgid "Run as a full display server, rather than nested"
msgstr "Funciona com a servidor de pantalla completa, en comptes d'imbricat"
#: src/core/main.c:246
msgid "Run with X11 backend"
msgstr "Executa amb un rerefons X11"
#. Translators: %s is a window title
#: src/core/meta-close-dialog-default.c:147
#, c-format
msgid "“%s” is not responding."
msgstr "«%s» no està responent."
#: src/core/meta-close-dialog-default.c:149
msgid "Application is not responding."
msgstr "L'aplicació no està responent."
#: src/core/meta-close-dialog-default.c:154
msgid ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
msgstr ""
"Podeu esperar un moment perquè continuï o podeu forçar-ne la sortida "
"completa."
#: src/core/meta-close-dialog-default.c:161
msgid "_Force Quit"
msgstr "_Força'n la sortida"
#: src/core/meta-close-dialog-default.c:161
msgid "_Wait"
msgstr "_Espera"
#: src/core/mutter.c:39
#, c-format
msgid ""
@ -660,7 +668,7 @@ msgstr "Connector del Mutter a utilitzar"
msgid "Workspace %d"
msgstr "Espai de treball %d"
#: src/core/screen.c:580
#: src/core/screen.c:583
#, c-format
msgid ""
"Display “%s” already has a window manager; try using the --replace option to "
@ -669,7 +677,7 @@ msgstr ""
"La pantalla «%s» ja té un gestor de finestres; proveu l'opció --replace per "
"reemplaçar el gestor de finestres actual."
#: src/core/screen.c:665
#: src/core/screen.c:668
#, c-format
msgid "Screen %d on display “%s” is invalid\n"
msgstr "El monitor %d en la pantalla '%s' no és vàlida\n"
@ -678,12 +686,12 @@ msgstr "El monitor %d en la pantalla '%s' no és vàlida\n"
msgid "Mutter was compiled without support for verbose mode\n"
msgstr "Mutter es va compilar sense compatibilitat per al mode detallat\n"
#: src/wayland/meta-wayland-tablet-pad.c:563
#: src/wayland/meta-wayland-tablet-pad.c:567
#, c-format
msgid "Mode Switch: Mode %d"
msgstr "Mode de commutació: mode %d"
#: src/x11/session.c:1815
#: src/x11/session.c:1818
msgid ""
"These windows do not support “save current setup” and will have to be "
"restarted manually next time you log in."
@ -696,6 +704,21 @@ msgstr ""
msgid "%s (on %s)"
msgstr "%s (a %s)"
#~ msgid "Move window one workspace to the left"
#~ msgstr "Mou la finestra un espai de treball a l'esquerra"
#~ msgid "Move window one workspace to the right"
#~ msgstr "Mou la finestra un espai de treball a la dreta"
#~ msgid "Move to workspace left"
#~ msgstr "Mou a l'espai de treball de l'esquerra"
#~ msgid "Move to workspace right"
#~ msgstr "Mou a l'espai de treball de la dreta"
#~ msgid "Toggle shaded state"
#~ msgstr "Canvia l'estat d'ombrejat"
#~ msgid "Failed to scan themes directory: %s\n"
#~ msgstr "No s'ha pogut analitzar el directori de temes: %s\n"

File diff suppressed because it is too large Load Diff

360
po/cs.po
View File

@ -6,15 +6,14 @@
# Petr Tomeš <ptomes@gmail.com>, 2006.
# Jakub Friedl <jfriedl@suse.cz>, 2006, 2007.
# Petr Kovar <pknbe@volny.cz>, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014.
# Marek Černocký <marek@manet.cz>, 2012, 2013, 2014, 2016, 2017.
# Marek Černocký <marek@manet.cz>, 2012, 2013, 2014, 2016, 2017, 2018.
#
msgid ""
msgstr ""
"Project-Id-Version: mutter\n"
"Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?"
"product=mutter&keywords=I18N+L10N&component=general\n"
"POT-Creation-Date: 2017-03-07 12:40+0000\n"
"PO-Revision-Date: 2017-03-09 07:51+0100\n"
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/mutter/issues\n"
"POT-Creation-Date: 2018-07-07 09:58+0000\n"
"PO-Revision-Date: 2018-08-29 07:28+0200\n"
"Last-Translator: Marek Černocký <marek@manet.cz>\n"
"Language-Team: čeština <gnome-cs-list@gnome.org>\n"
"Language: cs\n"
@ -50,134 +49,118 @@ msgid "Move window to last workspace"
msgstr "Přesunout okno na poslední pracovní plochu"
#: data/50-mutter-navigation.xml:24
msgid "Move window one workspace to the left"
msgstr "Přesunout okno o jednu pracovní plochu doleva"
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace to the right"
msgstr "Přesunout okno o jednu pracovní plochu doprava"
#: data/50-mutter-navigation.xml:30
msgid "Move window one workspace up"
msgstr "Přesunout okno o jednu pracovní plochu nahoru"
#: data/50-mutter-navigation.xml:33
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace down"
msgstr "Přesunout okno o jednu pracovní plochu dolů"
#: data/50-mutter-navigation.xml:36
#: data/50-mutter-navigation.xml:30
msgid "Move window one monitor to the left"
msgstr "Přesunout okno o jeden monitor doleva"
#: data/50-mutter-navigation.xml:39
#: data/50-mutter-navigation.xml:33
msgid "Move window one monitor to the right"
msgstr "Přesunout okno o jeden monitor doprava"
#: data/50-mutter-navigation.xml:42
#: data/50-mutter-navigation.xml:36
msgid "Move window one monitor up"
msgstr "Přesunout okno o jeden monitor nahoru"
#: data/50-mutter-navigation.xml:45
#: data/50-mutter-navigation.xml:39
msgid "Move window one monitor down"
msgstr "Přesunout okno o jeden monitor dolů"
#: data/50-mutter-navigation.xml:49
#: data/50-mutter-navigation.xml:43
msgid "Switch applications"
msgstr "Přepnout do jiné aplikace"
#: data/50-mutter-navigation.xml:54
#: data/50-mutter-navigation.xml:48
msgid "Switch to previous application"
msgstr "Přepnout do předchozí aplikaci"
#: data/50-mutter-navigation.xml:58
#: data/50-mutter-navigation.xml:52
msgid "Switch windows"
msgstr "Přepnout do jiného okna"
#: data/50-mutter-navigation.xml:63
#: data/50-mutter-navigation.xml:57
msgid "Switch to previous window"
msgstr "Přepnout do minulého okna"
#: data/50-mutter-navigation.xml:67
#: data/50-mutter-navigation.xml:61
msgid "Switch windows of an application"
msgstr "Přepnout do jiného okna aplikace"
#: data/50-mutter-navigation.xml:72
#: data/50-mutter-navigation.xml:66
msgid "Switch to previous window of an application"
msgstr "Přepnout do předchozího okna aplikace"
#: data/50-mutter-navigation.xml:76
#: data/50-mutter-navigation.xml:70
msgid "Switch system controls"
msgstr "Přepnout na systémový ovládací prvek"
#: data/50-mutter-navigation.xml:81
#: data/50-mutter-navigation.xml:75
msgid "Switch to previous system control"
msgstr "Přepnout na minulý systémový ovládací prvek"
#: data/50-mutter-navigation.xml:85
#: data/50-mutter-navigation.xml:79
msgid "Switch windows directly"
msgstr "Přepnout do minulého okna"
#: data/50-mutter-navigation.xml:90
#: data/50-mutter-navigation.xml:84
msgid "Switch directly to previous window"
msgstr "Přepnout přímo na předchozí okno"
#: data/50-mutter-navigation.xml:94
#: data/50-mutter-navigation.xml:88
msgid "Switch windows of an app directly"
msgstr "Přepnout do jiného okna aplikace"
#: data/50-mutter-navigation.xml:99
#: data/50-mutter-navigation.xml:93
msgid "Switch directly to previous window of an app"
msgstr "Přepnout do předchozího okna aplikace"
#: data/50-mutter-navigation.xml:103
#: data/50-mutter-navigation.xml:97
msgid "Switch system controls directly"
msgstr "Přepnout na minulý systémový ovládací prvek"
#: data/50-mutter-navigation.xml:108
#: data/50-mutter-navigation.xml:102
msgid "Switch directly to previous system control"
msgstr "Přepnout přímo na předchozí systémové ovládací prvky"
#: data/50-mutter-navigation.xml:111
#: data/50-mutter-navigation.xml:105
msgid "Hide all normal windows"
msgstr "Skrýt všechna běžná okna"
#: data/50-mutter-navigation.xml:114
#: data/50-mutter-navigation.xml:108
msgid "Switch to workspace 1"
msgstr "Přepnout na plochu 1"
#: data/50-mutter-navigation.xml:117
#: data/50-mutter-navigation.xml:111
msgid "Switch to workspace 2"
msgstr "Přepnout na plochu 2"
#: data/50-mutter-navigation.xml:120
#: data/50-mutter-navigation.xml:114
msgid "Switch to workspace 3"
msgstr "Přepnout na plochu 3"
#: data/50-mutter-navigation.xml:123
#: data/50-mutter-navigation.xml:117
msgid "Switch to workspace 4"
msgstr "Přepnout na plochu 4"
#: data/50-mutter-navigation.xml:126
#: data/50-mutter-navigation.xml:120
msgid "Switch to last workspace"
msgstr "Přepnout na poslední plochu"
#: data/50-mutter-navigation.xml:129
msgid "Move to workspace left"
msgstr "Přesunout na plochu vlevo"
#: data/50-mutter-navigation.xml:132
msgid "Move to workspace right"
msgstr "Přesunout na plochu vpravo"
#: data/50-mutter-navigation.xml:135
#: data/50-mutter-navigation.xml:123
msgid "Move to workspace above"
msgstr "Přesunout na plochu nad"
#: data/50-mutter-navigation.xml:138
#: data/50-mutter-navigation.xml:126
msgid "Move to workspace below"
msgstr "Přesunout na plochu pod"
#: data/50-mutter-system.xml:6
#: data/50-mutter-system.xml:6 data/50-mutter-wayland.xml:6
msgid "System"
msgstr "Systém"
@ -189,6 +172,10 @@ msgstr "Zobrazit řádek ke spuštění příkazu"
msgid "Show the activities overview"
msgstr "Zobrazit přehled činností"
#: data/50-mutter-wayland.xml:8
msgid "Restore the keyboard shortcuts"
msgstr "Obnovit klávesové zkratky"
#: data/50-mutter-windows.xml:6
msgid "Windows"
msgstr "Okna"
@ -214,54 +201,50 @@ msgid "Restore window"
msgstr "Obnovit velikost okna"
#: data/50-mutter-windows.xml:18
msgid "Toggle shaded state"
msgstr "Přepnout stav svinutí"
#: data/50-mutter-windows.xml:20
msgid "Close window"
msgstr "Zavřít okno"
#: data/50-mutter-windows.xml:22
#: data/50-mutter-windows.xml:20
msgid "Hide window"
msgstr "Skrýt okno"
#: data/50-mutter-windows.xml:24
#: data/50-mutter-windows.xml:22
msgid "Move window"
msgstr "Přesunout okno"
#: data/50-mutter-windows.xml:26
#: data/50-mutter-windows.xml:24
msgid "Resize window"
msgstr "Změnit velikost okna"
#: data/50-mutter-windows.xml:29
#: data/50-mutter-windows.xml:27
msgid "Toggle window on all workspaces or one"
msgstr "Přepnout okno na všechny/jednu pracovní plochu"
#: data/50-mutter-windows.xml:31
#: data/50-mutter-windows.xml:29
msgid "Raise window if covered, otherwise lower it"
msgstr "Když je okno zakryté vynést jej do popředí, jinak odsunout do pozadí"
#: data/50-mutter-windows.xml:33
#: data/50-mutter-windows.xml:31
msgid "Raise window above other windows"
msgstr "Vynést okno do popředí nad ostatní okna"
#: data/50-mutter-windows.xml:35
#: data/50-mutter-windows.xml:33
msgid "Lower window below other windows"
msgstr "Odsunout okno do pozadí za ostatní okna"
#: data/50-mutter-windows.xml:37
#: data/50-mutter-windows.xml:35
msgid "Maximize window vertically"
msgstr "Maximalizovat okno svisle"
#: data/50-mutter-windows.xml:39
#: data/50-mutter-windows.xml:37
msgid "Maximize window horizontally"
msgstr "Maximalizovat okno vodorovně"
#: data/50-mutter-windows.xml:43
#: data/50-mutter-windows.xml:41
msgid "View split on left"
msgstr "Rozdělit okno přes levou půlku obrazovky"
#: data/50-mutter-windows.xml:47
#: data/50-mutter-windows.xml:45
msgid "View split on right"
msgstr "Rozdělit okno přes pravou půlku obrazovky"
@ -361,9 +344,8 @@ msgid ""
"focus will not be changed immediately when entering a window, but only after "
"the pointer stops moving."
msgstr ""
"Je-li zapnuto a režim zaměření je buď „sloppy“ nebo „mouse“, pak se "
"zaměření nezmění hned, když vstoupíte do kona, ale až se přestane pohybovat "
"ukazatel."
"Je-li zapnuto a režim zaměření je buď „sloppy“ nebo „mouse“, pak se zaměření "
"nezmění hned, když vstoupíte do kona, ale až se přestane pohybovat ukazatel."
#: data/org.gnome.mutter.gschema.xml.in:79
msgid "Draggable border width"
@ -401,14 +383,48 @@ msgstr ""
"Je-li zapnuto, nová okna budou vždy umístěna ve středu aktivní obrazovky "
"monitoru."
#: data/org.gnome.mutter.gschema.xml.in:120
#: data/org.gnome.mutter.gschema.xml.in:107
msgid "Enable experimental features"
msgstr "Povolit experimentální funkce"
#: data/org.gnome.mutter.gschema.xml.in:108
msgid ""
"To enable experimental features, add the feature keyword to the list. "
"Whether the feature requires restarting the compositor depends on the given "
"feature. Any experimental feature is not required to still be available, or "
"configurable. Dont expect adding anything in this setting to be future "
"proof. Currently possible keywords: • “scale-monitor-framebuffer” — makes "
"mutter default to layout logical monitors in a logical pixel coordinate "
"space, while scaling monitor framebuffers instead of window content, to "
"manage HiDPI monitors. Does not require a restart."
msgstr ""
"Chcete-li povolit experimentální funkce, přidejte klíčové slovo funkce do "
"seznamu. Zda funkce vyžaduje restartování kompozitoru, závisí na dané "
"funkci. Ne u každé experimentální funkce je vyžadováno, aby byla stále "
"dostupná nebo konfigurovatelná. Neočekávejte, že by bylo v tomto nastavení "
"přidáno něco, co by do budoucna přineslo vylepšení. V současné době jsou "
"možná tato klíčová slova: • „scale-monitor-framebuffer“ zajistí, aby byl "
"mutter výchozí pro logické uspořádání monitorů v logickém souřadnicovém "
"prostoru pixelů, zatímco škáluje přímo v grafické vyrovnávací paměti, "
"namísto v obsahu oken, aby se postaral o správu montorů s HiDPI. Nevyžaduje "
"restart."
#: data/org.gnome.mutter.gschema.xml.in:141
msgid "Select window from tab popup"
msgstr "Vybrat okno z překryvné nabídky tabulátoru"
#: data/org.gnome.mutter.gschema.xml.in:125
#: data/org.gnome.mutter.gschema.xml.in:146
msgid "Cancel tab popup"
msgstr "Zrušit překryvné okno tabulátoru"
#: data/org.gnome.mutter.gschema.xml.in:151
msgid "Switch monitor configurations"
msgstr "Přepnout nastavení monitoru"
#: data/org.gnome.mutter.gschema.xml.in:156
msgid "Rotates the built-in monitor configuration"
msgstr "Postupně mění vestavěná nastavení monitoru"
#: data/org.gnome.mutter.wayland.gschema.xml.in:6
msgid "Switch to VT 1"
msgstr "Přepnout na VT 1"
@ -457,10 +473,61 @@ msgstr "Přepnout na VT 11"
msgid "Switch to VT 12"
msgstr "Přepnout na VT 12"
#: data/org.gnome.mutter.wayland.gschema.xml.in:54
msgid "Re-enable shortcuts"
msgstr "Znovu povolit klávesové zkratky"
#: data/org.gnome.mutter.wayland.gschema.xml.in:64
msgid "Allow grabs with Xwayland"
msgstr "Povolit zachytávání pomocí Xwaylandu"
#: data/org.gnome.mutter.wayland.gschema.xml.in:65
msgid ""
"Allow keyboard grabs issued by X11 applications running in Xwayland to be "
"taken into account. For a X11 grab to be taken into account under Wayland, "
"the client must also either send a specific X11 ClientMessage to the root "
"window or be among the applications white-listed in key “xwayland-grab-"
"access-rules”."
msgstr ""
"Povolit, aby bylo bráno v úvahu zachytávání kláves, o které se stará "
"aplikace X11 běžící v Xwaylandu. Aby bylo pod Waylandem zachytávání bráno v "
"úvahu, musí klient navíc buď poslat specifickou zprávu X11 ClientMessage do "
"kořenového okna, nebo být mezi aplikacemi na bílé listině v klíči „xwayland-"
"grab-access-rules“."
#: data/org.gnome.mutter.wayland.gschema.xml.in:77
msgid "Xwayland applications allowed to issue keyboard grabs"
msgstr ""
"Aplikace pod Xwaylandem mají povoleno se starat o zachytávání klávesnice"
#: data/org.gnome.mutter.wayland.gschema.xml.in:78
msgid ""
"List the resource names or resource class of X11 windows either allowed or "
"not allowed to issue X11 keyboard grabs under Xwayland. The resource name or "
"resource class of a given X11 window can be obtained using the command "
"“xprop WM_CLASS”. Wildcards “*” and jokers “?” in the values are supported. "
"Values starting with “!” are blacklisted, which has precedence over the "
"whitelist, to revoke applications from the default system list. The default "
"system list includes the following applications: "
"“@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES@” Users can break an existing grab by "
"using the specific keyboard shortcut defined by the keybinding key “restore-"
"shortcuts”."
msgstr ""
"Seznam názvů prostředků nebo tříd prostředků oken X11, které buď mají nebo "
"nemají povolené se starat o zachytávání klávesnice X11 pod Xwaylandem. Název "
"nebo třída prostředku daného okna X11 se dá zjistit pomocí příkazu „xprop "
"WM_CLASS“. V názvech jsou podporované divoké znaky „*“ a „?“. Hodnoty "
"začínající „!“ jsou na černé listině, což má přednost před bílou listinou, "
"aby se daly aplikace odvolat z výchozího systémového seznamu. Do výchozího "
"systémového seznamu patří následující aplikace: "
"„@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES@“. Uživatel může přerušit existující "
"zachytávání pomocí speciální klávesové zkratky definované klíčem „restore-"
"shortcuts“."
#. TRANSLATORS: This string refers to a button that switches between
#. * different modes.
#.
#: src/backends/meta-input-settings.c:1800
#: src/backends/meta-input-settings.c:2325
#, c-format
msgid "Mode Switch (Group %d)"
msgstr "Přepínač režimu (skupina %d)"
@ -468,57 +535,101 @@ msgstr "Přepínač režimu (skupina %d)"
#. TRANSLATORS: This string refers to an action, cycles drawing tablets'
#. * mapping through the available outputs.
#.
#: src/backends/meta-input-settings.c:1822
#: src/backends/meta-input-settings.c:2348
msgid "Switch monitor"
msgstr "Přepnout monitor"
#: src/backends/meta-input-settings.c:1824
#: src/backends/meta-input-settings.c:2350
msgid "Show on-screen help"
msgstr "Zobrazit nápovědu na obrazovce"
#: src/backends/meta-monitor-manager.c:675
#: src/backends/meta-monitor-manager.c:907
msgid "Built-in display"
msgstr "Vestavěný displej"
#: src/backends/meta-monitor-manager.c:698
#: src/backends/meta-monitor-manager.c:930
msgid "Unknown"
msgstr "Neznámý"
#: src/backends/meta-monitor-manager.c:700
#: src/backends/meta-monitor-manager.c:932
msgid "Unknown Display"
msgstr "Neznámý displej"
#. TRANSLATORS: this is a monitor vendor name, followed by a
#. * size in inches, like 'Dell 15"'
#.
#: src/backends/meta-monitor-manager.c:708
#: src/backends/meta-monitor-manager.c:940
#, c-format
msgid "%s %s"
msgstr "%s %s"
#. This probably means that a non-WM compositor like xcompmgr is running;
#. * we have no way to get it to exit
#: src/compositor/compositor.c:474
#: src/compositor/compositor.c:481
#, c-format
msgid ""
"Another compositing manager is already running on screen %i on display “%s”."
msgstr "Jiný kompozitní správce již běží na obrazovce %i displeje „%s“."
#: src/core/bell.c:194
#: src/core/bell.c:254
msgid "Bell event"
msgstr "Událost zvonku"
#: src/core/main.c:191
msgid "Disable connection to session manager"
msgstr "Zakázat připojení ke správci sezení"
#: src/core/main.c:197
msgid "Replace the running window manager"
msgstr "Nahradí běžícího správce oken"
#: src/core/main.c:203
msgid "Specify session management ID"
msgstr "Určit ID správy sezení"
#: src/core/main.c:208
msgid "X Display to use"
msgstr "Displej X, který se má použít"
#: src/core/main.c:214
msgid "Initialize session from savefile"
msgstr "Spustit sezení z uloženého souboru"
#: src/core/main.c:220
msgid "Make X calls synchronous"
msgstr "Provádět volání X synchronně"
#: src/core/main.c:227
msgid "Run as a wayland compositor"
msgstr "Spustit jako kompozitor protokolu Wayland"
#: src/core/main.c:233
msgid "Run as a nested compositor"
msgstr "Spustit jako podkladový kompozitor"
#: src/core/main.c:239
msgid "Run wayland compositor without starting Xwayland"
msgstr "Spustit kompozitor wayland bez spuštění Xwayland"
#: src/core/main.c:247
msgid "Run as a full display server, rather than nested"
msgstr "Spustit jako plnohodnotný server displeje, nikoliv vnořeně"
#: src/core/main.c:253
msgid "Run with X11 backend"
msgstr "Spustit se serverem X11"
#. Translators: %s is a window title
#: src/core/delete.c:127
#: src/core/meta-close-dialog-default.c:148
#, c-format
msgid "“%s” is not responding."
msgstr "„%s“ nereaguje."
#: src/core/delete.c:129
#: src/core/meta-close-dialog-default.c:150
msgid "Application is not responding."
msgstr "Aplikace nereaguje."
#: src/core/delete.c:134
#: src/core/meta-close-dialog-default.c:155
msgid ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
@ -526,55 +637,14 @@ msgstr ""
"Je možné chvíli počkat, aby aplikace mohla pokračovat, nebo si vynutit úplné "
"ukončení aplikace."
#: src/core/delete.c:141
#: src/core/meta-close-dialog-default.c:162
msgid "_Force Quit"
msgstr "_Vynutit ukončení"
#: src/core/delete.c:141
#: src/core/meta-close-dialog-default.c:162
msgid "_Wait"
msgstr "_Počkat"
#: src/core/display.c:608
#, c-format
msgid "Failed to open X Window System display “%s”\n"
msgstr "Nelze otevřít displej X Window System „%s“\n"
#: src/core/main.c:189
msgid "Disable connection to session manager"
msgstr "Zakáže připojení ke správci sezení"
#: src/core/main.c:195
msgid "Replace the running window manager"
msgstr "Nahradí běžícího správce oken"
#: src/core/main.c:201
msgid "Specify session management ID"
msgstr "Určení ID správy sezení"
#: src/core/main.c:206
msgid "X Display to use"
msgstr "Displej X, který použije"
#: src/core/main.c:212
msgid "Initialize session from savefile"
msgstr "Spustí sezení z uloženého souboru"
#: src/core/main.c:218
msgid "Make X calls synchronous"
msgstr "Provede volání X synchronně"
#: src/core/main.c:225
msgid "Run as a wayland compositor"
msgstr "Spustit jako kompozitor protokolu Wayland"
#: src/core/main.c:231
msgid "Run as a nested compositor"
msgstr "Spustit jako podkladový kompozitor"
#: src/core/main.c:239
msgid "Run as a full display server, rather than nested"
msgstr "Spustit jako plnohodnotný server displeje, nikoliv vnořeně"
#: src/core/mutter.c:39
#, c-format
msgid ""
@ -599,12 +669,21 @@ msgstr "Vypsat verzi"
msgid "Mutter plugin to use"
msgstr "Zásuvný modul Mutter, který se má použít"
#: src/core/prefs.c:1997
#: src/core/prefs.c:1915
#, c-format
msgid "Workspace %d"
msgstr "Plocha %d"
#: src/core/screen.c:580
#: src/core/util.c:120
msgid "Mutter was compiled without support for verbose mode\n"
msgstr "Mutter bylo přeloženo bez podpory podrobného režimu\n"
#: src/wayland/meta-wayland-tablet-pad.c:567
#, c-format
msgid "Mode Switch: Mode %d"
msgstr "Přepínač režimu: režim %d"
#: src/x11/meta-x11-display.c:666
#, c-format
msgid ""
"Display “%s” already has a window manager; try using the --replace option to "
@ -613,30 +692,29 @@ msgstr ""
"Displej „%s“ již správce oken má; zkuste prosím nahradit aktuálního správce "
"oken pomocí přepínače --replace."
#: src/core/screen.c:665
#: src/x11/meta-x11-display.c:1010
msgid "Failed to initialize GDK\n"
msgstr "Selhala inicializace GDK\n"
#: src/x11/meta-x11-display.c:1034
#, c-format
msgid "Failed to open X Window System display “%s”\n"
msgstr "Nelze otevřít displej X Window System „%s“\n"
#: src/x11/meta-x11-display.c:1117
#, c-format
msgid "Screen %d on display “%s” is invalid\n"
msgstr "Obrazovka %d na displeji „%s“ je neplatná\n"
#: src/core/util.c:120
msgid "Mutter was compiled without support for verbose mode\n"
msgstr "Mutter bylo přeloženo bez podpory podrobného režimu\n"
#: src/wayland/meta-wayland-tablet-pad.c:563
#, c-format
msgid "Mode Switch: Mode %d"
msgstr "Přepínač režimu: režim %d"
#: src/x11/session.c:1815
#: src/x11/session.c:1819
msgid ""
"These windows do not support “save current setup” and will have to be "
"restarted manually next time you log in."
msgstr ""
"Tato okna nepodporují „uložení aktuálního nastavení“ a po svém "
"příštím přihlášení je budete muset spustit ručně."
"Tato okna nepodporují „uložení aktuálního nastavení“ a po svém příštím "
"přihlášení je budete muset spustit ručně."
#: src/x11/window-props.c:559
#: src/x11/window-props.c:565
#, c-format
msgid "%s (on %s)"
msgstr "%s (na %s)"

801
po/da.po

File diff suppressed because it is too large Load Diff

351
po/de.po
View File

@ -2,19 +2,19 @@
# Copyright (C) 2002-2004 Free Software Foundation, Inc.
# Matthias Warkus <mawarkus@gnome.org>, 2002.
# Christian Neumair <chris@gnome-de.org>, 2002-2004.
# Hendrik Richter <hendrikr@gnome.org>, 2005, 2006, 2007, 2008.
# Mario Blättermann <mario.blaettermann@gmail.com>, 2010-2013, 2016-2017.
# Christian Kirbach <Christian.Kirbach@googlemail.com>, 2009, 2011, 2012.
# Wolfgang Stöggl <c72578@yahoo.de> 2011.
# Hendrik Richter <hendrikr@gnome.org>, 2005-2008.
# Mario Blättermann <mario.blaettermann@gmail.com>, 2010-2013, 2016-2018.
# Christian Kirbach <Christian.Kirbach@googlemail.com>, 2009, 2011-2012.
# Wolfgang Stöggl <c72578@yahoo.de> 2011, 2017.
# Tobias Endrigkeit <tobiasendrigkeit@googlemail.com>, 2012.
# Tim Sabsch <timæsabsch.com>, 2018.
#
msgid ""
msgstr ""
"Project-Id-Version: mutter master\n"
"Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?"
"product=mutter&keywords=I18N+L10N&component=general\n"
"POT-Creation-Date: 2017-05-10 19:07+0000\n"
"PO-Revision-Date: 2017-05-12 17:35+0200\n"
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/mutter/issues\n"
"POT-Creation-Date: 2018-07-07 09:58+0000\n"
"PO-Revision-Date: 2018-08-04 19:59+0200\n"
"Last-Translator: Mario Blättermann <mario.blaettermann@gmail.com>\n"
"Language-Team: Deutsch <gnome-de@gnome.org>\n"
"Language: de\n"
@ -22,7 +22,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 2.0.1\n"
"X-Generator: Poedit 2.0.9\n"
#: data/50-mutter-navigation.xml:6
msgid "Navigation"
@ -49,134 +49,118 @@ msgid "Move window to last workspace"
msgstr "Fenster auf letzte Arbeitsfläche verschieben"
#: data/50-mutter-navigation.xml:24
msgid "Move window one workspace to the left"
msgstr "Fenster eine Arbeitsfläche nach links verschieben"
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace to the right"
msgstr "Fenster eine Arbeitsfläche nach rechts verschieben"
#: data/50-mutter-navigation.xml:30
msgid "Move window one workspace up"
msgstr "Fenster eine Arbeitsfläche nach oben verschieben"
#: data/50-mutter-navigation.xml:33
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace down"
msgstr "Fenster eine Arbeitsfläche nach unten verschieben"
#: data/50-mutter-navigation.xml:36
#: data/50-mutter-navigation.xml:30
msgid "Move window one monitor to the left"
msgstr "Fenster einen Bildschirm nach links verschieben"
#: data/50-mutter-navigation.xml:39
#: data/50-mutter-navigation.xml:33
msgid "Move window one monitor to the right"
msgstr "Fenster einen Bildschirm nach rechts verschieben"
#: data/50-mutter-navigation.xml:42
#: data/50-mutter-navigation.xml:36
msgid "Move window one monitor up"
msgstr "Fenster einen Bildschirm nach oben verschieben"
#: data/50-mutter-navigation.xml:45
#: data/50-mutter-navigation.xml:39
msgid "Move window one monitor down"
msgstr "Fenster einen Bildschirm nach unten verschieben"
#: data/50-mutter-navigation.xml:49
#: data/50-mutter-navigation.xml:43
msgid "Switch applications"
msgstr "Anwendungen wechseln"
#: data/50-mutter-navigation.xml:54
#: data/50-mutter-navigation.xml:48
msgid "Switch to previous application"
msgstr "Zur vorherigen Anwendung wechseln"
#: data/50-mutter-navigation.xml:58
#: data/50-mutter-navigation.xml:52
msgid "Switch windows"
msgstr "Fenster wechseln"
#: data/50-mutter-navigation.xml:63
#: data/50-mutter-navigation.xml:57
msgid "Switch to previous window"
msgstr "Zum vorherigen Fenster wechseln"
#: data/50-mutter-navigation.xml:67
#: data/50-mutter-navigation.xml:61
msgid "Switch windows of an application"
msgstr "Zwischen den Fenstern einer Anwendung wechseln"
#: data/50-mutter-navigation.xml:72
#: data/50-mutter-navigation.xml:66
msgid "Switch to previous window of an application"
msgstr "Zum vorherigen Fenster einer Anwendung wechseln"
#: data/50-mutter-navigation.xml:76
#: data/50-mutter-navigation.xml:70
msgid "Switch system controls"
msgstr "Systemsteuerungen umschalten"
#: data/50-mutter-navigation.xml:81
#: data/50-mutter-navigation.xml:75
msgid "Switch to previous system control"
msgstr "Zur vorherigen Systemsteuerungen wechseln"
#: data/50-mutter-navigation.xml:85
#: data/50-mutter-navigation.xml:79
msgid "Switch windows directly"
msgstr "Fenster sofort wechseln"
#: data/50-mutter-navigation.xml:90
#: data/50-mutter-navigation.xml:84
msgid "Switch directly to previous window"
msgstr "Direkt zum vorherigen Fenster wechseln"
#: data/50-mutter-navigation.xml:94
#: data/50-mutter-navigation.xml:88
msgid "Switch windows of an app directly"
msgstr "Sofort zwischen den Fenstern einer Anwendung wechseln"
#: data/50-mutter-navigation.xml:99
#: data/50-mutter-navigation.xml:93
msgid "Switch directly to previous window of an app"
msgstr "Direkt zum vorherigen Fenster einer Anwendung wechseln"
#: data/50-mutter-navigation.xml:103
#: data/50-mutter-navigation.xml:97
msgid "Switch system controls directly"
msgstr "Systemsteuerungen sofort umschalten"
#: data/50-mutter-navigation.xml:108
#: data/50-mutter-navigation.xml:102
msgid "Switch directly to previous system control"
msgstr "Direkt zur vorherigen Systemsteuerungen wechselen"
msgstr "Direkt zur vorherigen Systemsteuerungen wechseln"
#: data/50-mutter-navigation.xml:111
#: data/50-mutter-navigation.xml:105
msgid "Hide all normal windows"
msgstr "Alle normalen Fenster verbergen"
#: data/50-mutter-navigation.xml:114
#: data/50-mutter-navigation.xml:108
msgid "Switch to workspace 1"
msgstr "Zur Arbeitsfläche 1 wechseln"
#: data/50-mutter-navigation.xml:117
#: data/50-mutter-navigation.xml:111
msgid "Switch to workspace 2"
msgstr "Zur Arbeitsfläche 2 wechseln"
#: data/50-mutter-navigation.xml:120
#: data/50-mutter-navigation.xml:114
msgid "Switch to workspace 3"
msgstr "Zur Arbeitsfläche 3 wechseln"
#: data/50-mutter-navigation.xml:123
#: data/50-mutter-navigation.xml:117
msgid "Switch to workspace 4"
msgstr "Zur Arbeitsfläche 4 wechseln"
#: data/50-mutter-navigation.xml:126
#: data/50-mutter-navigation.xml:120
msgid "Switch to last workspace"
msgstr "Zur letzten Arbeitsfläche wechseln"
#: data/50-mutter-navigation.xml:129
msgid "Move to workspace left"
msgstr "Auf Arbeitsfläche links verschieben"
#: data/50-mutter-navigation.xml:132
msgid "Move to workspace right"
msgstr "Auf Arbeitsfläche rechts verschieben"
#: data/50-mutter-navigation.xml:135
#: data/50-mutter-navigation.xml:123
msgid "Move to workspace above"
msgstr "Auf Arbeitsfläche darüber verschieben"
#: data/50-mutter-navigation.xml:138
#: data/50-mutter-navigation.xml:126
msgid "Move to workspace below"
msgstr "Auf Arbeitsfläche darunter verschieben"
#: data/50-mutter-system.xml:6
#: data/50-mutter-system.xml:6 data/50-mutter-wayland.xml:6
msgid "System"
msgstr "System"
@ -188,6 +172,10 @@ msgstr "Den »Befehl ausführen«-Dialog anzeigen"
msgid "Show the activities overview"
msgstr "Aktivitäten-Übersicht anzeigen"
#: data/50-mutter-wayland.xml:8
msgid "Restore the keyboard shortcuts"
msgstr "Die Tastenkombinationen wiederherstellen"
#: data/50-mutter-windows.xml:6
msgid "Windows"
msgstr "Fenster"
@ -213,55 +201,51 @@ msgid "Restore window"
msgstr "Fenstergröße wiederherstellen"
#: data/50-mutter-windows.xml:18
msgid "Toggle shaded state"
msgstr "Fenster ein-/ausrollen"
#: data/50-mutter-windows.xml:20
msgid "Close window"
msgstr "Fenster schließen"
#: data/50-mutter-windows.xml:22
#: data/50-mutter-windows.xml:20
msgid "Hide window"
msgstr "Fenster verbergen"
#: data/50-mutter-windows.xml:24
#: data/50-mutter-windows.xml:22
msgid "Move window"
msgstr "Fenster verschieben"
#: data/50-mutter-windows.xml:26
#: data/50-mutter-windows.xml:24
msgid "Resize window"
msgstr "Fenstergröße ändern"
#: data/50-mutter-windows.xml:29
#: data/50-mutter-windows.xml:27
msgid "Toggle window on all workspaces or one"
msgstr ""
"Festlegen, ob das Fenster auf allen oder nur einer Arbeitsfläche sichtbar ist"
#: data/50-mutter-windows.xml:31
#: data/50-mutter-windows.xml:29
msgid "Raise window if covered, otherwise lower it"
msgstr "Fenster anheben, falls es verdeckt ist, andernfalls absenken"
#: data/50-mutter-windows.xml:33
#: data/50-mutter-windows.xml:31
msgid "Raise window above other windows"
msgstr "Fenster vor die anderen Fenster anheben"
#: data/50-mutter-windows.xml:35
#: data/50-mutter-windows.xml:33
msgid "Lower window below other windows"
msgstr "Fenster hinter die anderen Fenster absenken"
#: data/50-mutter-windows.xml:37
#: data/50-mutter-windows.xml:35
msgid "Maximize window vertically"
msgstr "Fenster vertikal maximieren"
#: data/50-mutter-windows.xml:39
#: data/50-mutter-windows.xml:37
msgid "Maximize window horizontally"
msgstr "Fenster horizontal maximieren"
#: data/50-mutter-windows.xml:43
#: data/50-mutter-windows.xml:41
msgid "View split on left"
msgstr "Ansicht links teilen"
#: data/50-mutter-windows.xml:47
#: data/50-mutter-windows.xml:45
msgid "View split on right"
msgstr "Ansicht rechts teilen"
@ -319,7 +303,7 @@ msgstr ""
#: data/org.gnome.mutter.gschema.xml.in:40
msgid "Workspaces are managed dynamically"
msgstr "Arbeitsflächen sollen dynamisch verwaltet werden "
msgstr "Arbeitsflächen sollen dynamisch verwaltet werden"
#: data/org.gnome.mutter.gschema.xml.in:41
msgid ""
@ -405,14 +389,13 @@ msgid ""
"screen of the monitor."
msgstr ""
"Falls wahr, so werden neue Fenster immer in der Mitte des aktiven "
"Bildschirms platziert"
"Bildschirms platziert."
#: data/org.gnome.mutter.gschema.xml.in:107
msgid "Enable experimental features"
msgstr "Experimentelle Funktionsmerkmale aktivieren"
#: data/org.gnome.mutter.gschema.xml.in:108
#, fuzzy
msgid ""
"To enable experimental features, add the feature keyword to the list. "
"Whether the feature requires restarting the compositor depends on the given "
@ -425,10 +408,14 @@ msgid ""
msgstr ""
"Um experimentelle Funktionsmerkmale zu aktivieren, fügen Sie das "
"entsprechende Schlüsselwort zur Liste hinzu. Möglicherweise muss der "
"Compositor neu gestartet werden, um es zu aktivieren. Für diese "
"experimentellen Funktionsmerkmale gilt, dass sie nicht unbedingt dauerhaft "
"verfügbar sein werden, oder Einstellungen möglich sind. Derzeit mögliche "
"Schlüsselwörter: • scale-monitor-framebuffer” — "
"Compositor neu gestartet werden, um es zu aktivieren, dies ist vom "
"Funktionsmerkmal abhängig. Für diese experimentellen Funktionsmerkmale gilt, "
"dass sie nicht unbedingt dauerhaft verfügbar sein werden, oder Einstellungen "
"möglich sind. Derzeit mögliche Schlüsselwörter: • »scale-monitor-"
"framebuffer« weist Mutter an, in der Voreinstellung logische Bildschirme "
"in einem logischen Pixel-Koordinatensystem anzuordnen, wobei die Bildschirm-"
"Framebuffer anstelle der Fensterinhalte skaliert werden, um HiDPI-"
"Bildschirme besser versorgen zu können. Dafür ist kein Neustart erforderlich."
#: data/org.gnome.mutter.gschema.xml.in:141
msgid "Select window from tab popup"
@ -438,6 +425,15 @@ msgstr "Fenster aus Tab-Anzeige auswählen"
msgid "Cancel tab popup"
msgstr "Tab-Anzeige abbrechen"
#: data/org.gnome.mutter.gschema.xml.in:151
msgid "Switch monitor configurations"
msgstr "Bildschirmkonfigurationen wechseln"
# Ich denke nicht, dass »rotate« hier die Bildschirmdrehung meint, sondern eher eine Liste aus Konfigurationen rotiert (d.h. umgewälzt) wird.
#: data/org.gnome.mutter.gschema.xml.in:156
msgid "Rotates the built-in monitor configuration"
msgstr "Wechselt die Konfiguration des eingebauten Bildschirms"
#: data/org.gnome.mutter.wayland.gschema.xml.in:6
msgid "Switch to VT 1"
msgstr "Zum virtuellen Terminal 1 wechseln"
@ -486,10 +482,63 @@ msgstr "Zum virtuellen Terminal 11 wechseln"
msgid "Switch to VT 12"
msgstr "Zum virtuellen Terminal 12 wechseln"
#: data/org.gnome.mutter.wayland.gschema.xml.in:54
msgid "Re-enable shortcuts"
msgstr "Tastenkombinationen erneut aktivieren"
#: data/org.gnome.mutter.wayland.gschema.xml.in:64
msgid "Allow grabs with Xwayland"
msgstr "Tastatur-Kontrollübernahmen in Xwayland erlauben"
#: data/org.gnome.mutter.wayland.gschema.xml.in:65
msgid ""
"Allow keyboard grabs issued by X11 applications running in Xwayland to be "
"taken into account. For a X11 grab to be taken into account under Wayland, "
"the client must also either send a specific X11 ClientMessage to the root "
"window or be among the applications white-listed in key “xwayland-grab-"
"access-rules”."
msgstr ""
"Erlauben, dass in Xwayland laufende X11-Anwendungen Kontrolle über die "
"Tastatur übernehmen dürfen. Damit eine X11-Kontrollübernahme unter Wayland "
"durchgeführt werden kann, muss der Client auch entweder eine spezifische X11-"
"ClientMessage an das Root-Fenster senden oder in den als »whitelisted« im "
"Schlüssel »xwayland-grab-access-rules« aufgelisteten Anwendungen enthalten "
"sein."
#: data/org.gnome.mutter.wayland.gschema.xml.in:77
msgid "Xwayland applications allowed to issue keyboard grabs"
msgstr "Xwayland-Anwendungen mit Erlaubnis zur Kontrollübernahme der Tastatur"
#: data/org.gnome.mutter.wayland.gschema.xml.in:78
msgid ""
"List the resource names or resource class of X11 windows either allowed or "
"not allowed to issue X11 keyboard grabs under Xwayland. The resource name or "
"resource class of a given X11 window can be obtained using the command "
"“xprop WM_CLASS”. Wildcards “*” and jokers “?” in the values are supported. "
"Values starting with “!” are blacklisted, which has precedence over the "
"whitelist, to revoke applications from the default system list. The default "
"system list includes the following applications: "
"“@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES@” Users can break an existing grab by "
"using the specific keyboard shortcut defined by the keybinding key “restore-"
"shortcuts”."
msgstr ""
"Listet die Ressourcennamen oder -klassen von X11-Fenstern auf, die unter "
"Xwayland X11-Tastatur-Kontrollübernahmen durchführen dürfen. Ressourcenname "
"oder -klasse eines bestimmten X11-Fensters kann mit dem Befehl »xprop "
"WM_CLASS« ermittelt werden. Dabei werden »*« als Platzhalter und »?« als "
"Joker in den Wertangaben unterstützt. Mit »!« beginnende Werte gelten als "
"»blacklisted« und werden gegenüber den als »whitelisted« markierten Werten "
"bevorzugt, um in der Standardliste des Systems aufgeführte Anwendungen außer "
"Kraft zu setzen. Die Standardliste des Systems enthält die folgenden "
"Anwendungen: »@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES@« Benutzer können eine "
"existierende Kontrollübernahme unterbrechen, indem sie das spezifische "
"Tastenkürzel verwenden, wie es im Schlüssel »restore-shortcuts« angegeben "
"ist."
#. TRANSLATORS: This string refers to a button that switches between
#. * different modes.
#.
#: src/backends/meta-input-settings.c:1848
#: src/backends/meta-input-settings.c:2325
#, c-format
msgid "Mode Switch (Group %d)"
msgstr "Moduswechsel (Gruppe %d)"
@ -497,37 +546,37 @@ msgstr "Moduswechsel (Gruppe %d)"
#. TRANSLATORS: This string refers to an action, cycles drawing tablets'
#. * mapping through the available outputs.
#.
#: src/backends/meta-input-settings.c:1870
#: src/backends/meta-input-settings.c:2348
msgid "Switch monitor"
msgstr "Bildschirm wechseln"
#: src/backends/meta-input-settings.c:1872
#: src/backends/meta-input-settings.c:2350
msgid "Show on-screen help"
msgstr "Bildschirmhilfe anzeigen"
#: src/backends/meta-monitor-manager.c:783
#: src/backends/meta-monitor-manager.c:907
msgid "Built-in display"
msgstr "Eingebaute Anzeige"
#: src/backends/meta-monitor-manager.c:806
#: src/backends/meta-monitor-manager.c:930
msgid "Unknown"
msgstr "Unbekannt"
#: src/backends/meta-monitor-manager.c:808
#: src/backends/meta-monitor-manager.c:932
msgid "Unknown Display"
msgstr "Unbekannte Anzeige"
#. TRANSLATORS: this is a monitor vendor name, followed by a
#. * size in inches, like 'Dell 15"'
#.
#: src/backends/meta-monitor-manager.c:816
#: src/backends/meta-monitor-manager.c:940
#, c-format
msgid "%s %s"
msgstr "%s %s"
#. This probably means that a non-WM compositor like xcompmgr is running;
#. * we have no way to get it to exit
#: src/compositor/compositor.c:474
#: src/compositor/compositor.c:481
#, c-format
msgid ""
"Another compositing manager is already running on screen %i on display “%s”."
@ -535,21 +584,65 @@ msgstr ""
"Ein weiterer Compositing-Verwalter läuft bereits auf Bildschirm %i der "
"Anzeige »%s«."
#: src/core/bell.c:194
#: src/core/bell.c:254
msgid "Bell event"
msgstr "Klangereignis"
#: src/core/main.c:191
msgid "Disable connection to session manager"
msgstr "Verbindung zur Sitzungsverwaltung deaktivieren"
#: src/core/main.c:197
msgid "Replace the running window manager"
msgstr "Den aktuellen Fensterverwalter ersetzen"
#: src/core/main.c:203
msgid "Specify session management ID"
msgstr "Kennung der Sitzungsverwaltung angeben"
#: src/core/main.c:208
msgid "X Display to use"
msgstr "Zu verwendende X-Anzeige"
#: src/core/main.c:214
msgid "Initialize session from savefile"
msgstr "Sitzung anhand gespeicherter Datei starten"
#: src/core/main.c:220
msgid "Make X calls synchronous"
msgstr "X-Aufrufe abgleichen"
#: src/core/main.c:227
msgid "Run as a wayland compositor"
msgstr "Als Wayland-Compositor ausführen"
#: src/core/main.c:233
msgid "Run as a nested compositor"
msgstr "Als eingebetteten Compositor ausführen"
#: src/core/main.c:239
msgid "Run wayland compositor without starting Xwayland"
msgstr "Wayland-Compositor ausführen, ohne Xwayland zu starten"
#: src/core/main.c:247
msgid "Run as a full display server, rather than nested"
msgstr "Als vollwertigen Display-Server verwenden (nicht eingebettet)"
#: src/core/main.c:253
msgid "Run with X11 backend"
msgstr "Mit X11-Backend ausführen"
#. Translators: %s is a window title
#: src/core/delete.c:127
#: src/core/meta-close-dialog-default.c:148
#, c-format
msgid "“%s” is not responding."
msgstr "»%s« antwortet nicht."
#: src/core/delete.c:129
#: src/core/meta-close-dialog-default.c:150
msgid "Application is not responding."
msgstr "Die Anwendung antwortet nicht."
#: src/core/delete.c:134
#: src/core/meta-close-dialog-default.c:155
msgid ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
@ -557,55 +650,14 @@ msgstr ""
"Sie können der Anwendung noch etwas Zeit geben oder ein sofortiges Beenden "
"erzwingen."
#: src/core/delete.c:141
#: src/core/meta-close-dialog-default.c:162
msgid "_Force Quit"
msgstr "_Beenden erzwingen"
#: src/core/delete.c:141
#: src/core/meta-close-dialog-default.c:162
msgid "_Wait"
msgstr "_Warten"
#: src/core/display.c:608
#, c-format
msgid "Failed to open X Window System display “%s”\n"
msgstr "X-Window-Systemanzeige »%s« konnte nicht geöffnet werden\n"
#: src/core/main.c:189
msgid "Disable connection to session manager"
msgstr "Verbindung zur Sitzungsverwaltung deaktivieren"
#: src/core/main.c:195
msgid "Replace the running window manager"
msgstr "Den aktuellen Fensterverwalter ersetzen"
#: src/core/main.c:201
msgid "Specify session management ID"
msgstr "Kennung der Sitzungsverwaltung angeben"
#: src/core/main.c:206
msgid "X Display to use"
msgstr "Zu verwendende X-Anzeige"
#: src/core/main.c:212
msgid "Initialize session from savefile"
msgstr "Sitzung anhand gespeicherter Datei starten"
#: src/core/main.c:218
msgid "Make X calls synchronous"
msgstr "X-Aufrufe abgleichen"
#: src/core/main.c:225
msgid "Run as a wayland compositor"
msgstr "Als Wayland-Compositor ausführen"
#: src/core/main.c:231
msgid "Run as a nested compositor"
msgstr "Als eingebetteten Compositor ausführen"
#: src/core/main.c:239
msgid "Run as a full display server, rather than nested"
msgstr "Als vollwertigen Display-Server verwenden (nicht eingebettet)"
# CHECK
# c-format
#: src/core/mutter.c:39
@ -632,12 +684,21 @@ msgstr "Version ausgeben"
msgid "Mutter plugin to use"
msgstr "Zu benutzendes Mutter-Plugin"
#: src/core/prefs.c:1997
#: src/core/prefs.c:1915
#, c-format
msgid "Workspace %d"
msgstr "Arbeitsfläche %d"
#: src/core/screen.c:580
#: src/core/util.c:120
msgid "Mutter was compiled without support for verbose mode\n"
msgstr "Mutter wurde ohne Unterstützung für den redseligen Modus kompiliert\n"
#: src/wayland/meta-wayland-tablet-pad.c:567
#, c-format
msgid "Mode Switch: Mode %d"
msgstr "Moduswechsel: Modus %d"
#: src/x11/meta-x11-display.c:666
#, c-format
msgid ""
"Display “%s” already has a window manager; try using the --replace option to "
@ -646,21 +707,21 @@ msgstr ""
"Bildschirm »%s« hat bereits einen Fensterverwalter. Versuchen Sie die Option "
"»--replace«, um den aktuellen Fensterverwalter zu ersetzen."
#: src/core/screen.c:665
#: src/x11/meta-x11-display.c:1010
msgid "Failed to initialize GDK\n"
msgstr "GDK konnte nicht initialisiert werden\n"
#: src/x11/meta-x11-display.c:1034
#, c-format
msgid "Failed to open X Window System display “%s”\n"
msgstr "X-Window-Systemanzeige »%s« konnte nicht geöffnet werden\n"
#: src/x11/meta-x11-display.c:1117
#, c-format
msgid "Screen %d on display “%s” is invalid\n"
msgstr "Bildschirm %d auf Anzeige »%s« ist ungültig\n"
#: src/core/util.c:120
msgid "Mutter was compiled without support for verbose mode\n"
msgstr "Mutter wurde ohne Unterstützung für den redseligen Modus kompiliert\n"
#: src/wayland/meta-wayland-tablet-pad.c:563
#, c-format
msgid "Mode Switch: Mode %d"
msgstr "Moduswechsel: Modus %d"
#: src/x11/session.c:1815
#: src/x11/session.c:1819
msgid ""
"These windows do not support “save current setup” and will have to be "
"restarted manually next time you log in."
@ -668,7 +729,7 @@ msgstr ""
"Diese Fenster unterstützen das Speichern der aktuellen Einstellungen nicht "
"und müssen bei der nächsten Anmeldung manuell neu gestartet werden."
#: src/x11/window-props.c:559
#: src/x11/window-props.c:565
#, c-format
msgid "%s (on %s)"
msgstr "%s (auf %s)"

View File

@ -5,23 +5,22 @@
# Gareth Owen <gowen72@yahoo.com>, 2004.
# Philip Withnall <philip@tecnocode.co.uk>, 2010.
# Chris Leonard <cjlhomeaddress@gmail.com>, 2012.
# Bruce Cowan <bruce@bcowan.me.uk>, 2011, 2012, 2013.
# Bruce Cowan <bruce@bcowan.me.uk>, 2011, 2012, 2013, 2018.
#
msgid ""
msgstr ""
"Project-Id-Version: mutter\n"
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?"
"product=mutter&keywords=I18N+L10N&component=general\n"
"POT-Creation-Date: 2016-09-07 09:27+0000\n"
"PO-Revision-Date: 2016-09-19 12:10+0200\n"
"Last-Translator: David King <amigadave@amigadave.com>\n"
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/mutter/issues\n"
"POT-Creation-Date: 2018-07-07 09:58+0000\n"
"PO-Revision-Date: 2018-08-19 17:43+0100\n"
"Last-Translator: Bruce Cowan <bruce@bcowan.me.uk>\n"
"Language-Team: British English <en@li.org>\n"
"Language: en_GB\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Gtranslator 2.91.6\n"
"X-Generator: Poedit 2.0.7\n"
"X-Project-Style: gnome\n"
#: data/50-mutter-navigation.xml:6
@ -49,134 +48,118 @@ msgid "Move window to last workspace"
msgstr "Move window to last workspace"
#: data/50-mutter-navigation.xml:24
msgid "Move window one workspace to the left"
msgstr "Move window one workspace to the left"
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace to the right"
msgstr "Move window one workspace to the right"
#: data/50-mutter-navigation.xml:30
msgid "Move window one workspace up"
msgstr "Move window one workspace up"
#: data/50-mutter-navigation.xml:33
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace down"
msgstr "Move window one workspace down"
#: data/50-mutter-navigation.xml:36
#: data/50-mutter-navigation.xml:30
msgid "Move window one monitor to the left"
msgstr "Move window one monitor to the left"
#: data/50-mutter-navigation.xml:39
#: data/50-mutter-navigation.xml:33
msgid "Move window one monitor to the right"
msgstr "Move window one monitor to the right"
#: data/50-mutter-navigation.xml:42
#: data/50-mutter-navigation.xml:36
msgid "Move window one monitor up"
msgstr "Move window one monitor up"
#: data/50-mutter-navigation.xml:45
#: data/50-mutter-navigation.xml:39
msgid "Move window one monitor down"
msgstr "Move window one monitor down"
#: data/50-mutter-navigation.xml:49
#: data/50-mutter-navigation.xml:43
msgid "Switch applications"
msgstr "Switch applications"
#: data/50-mutter-navigation.xml:54
#: data/50-mutter-navigation.xml:48
msgid "Switch to previous application"
msgstr "Switch to previous application"
#: data/50-mutter-navigation.xml:58
#: data/50-mutter-navigation.xml:52
msgid "Switch windows"
msgstr "Switch windows"
#: data/50-mutter-navigation.xml:63
#: data/50-mutter-navigation.xml:57
msgid "Switch to previous window"
msgstr "Switch to previous window"
#: data/50-mutter-navigation.xml:67
#: data/50-mutter-navigation.xml:61
msgid "Switch windows of an application"
msgstr "Switch windows of an application"
#: data/50-mutter-navigation.xml:72
#: data/50-mutter-navigation.xml:66
msgid "Switch to previous window of an application"
msgstr "Switch to previous window of an application"
#: data/50-mutter-navigation.xml:76
#: data/50-mutter-navigation.xml:70
msgid "Switch system controls"
msgstr "Switch system controls"
#: data/50-mutter-navigation.xml:81
#: data/50-mutter-navigation.xml:75
msgid "Switch to previous system control"
msgstr "Switch to previous system control"
#: data/50-mutter-navigation.xml:85
#: data/50-mutter-navigation.xml:79
msgid "Switch windows directly"
msgstr "Switch windows directly"
#: data/50-mutter-navigation.xml:90
#: data/50-mutter-navigation.xml:84
msgid "Switch directly to previous window"
msgstr "Switch directly to previous window"
#: data/50-mutter-navigation.xml:94
#: data/50-mutter-navigation.xml:88
msgid "Switch windows of an app directly"
msgstr "Switch windows of an app directly"
#: data/50-mutter-navigation.xml:99
#: data/50-mutter-navigation.xml:93
msgid "Switch directly to previous window of an app"
msgstr "Switch directly to previous window of an app"
#: data/50-mutter-navigation.xml:103
#: data/50-mutter-navigation.xml:97
msgid "Switch system controls directly"
msgstr "Switch system controls directly"
#: data/50-mutter-navigation.xml:108
#: data/50-mutter-navigation.xml:102
msgid "Switch directly to previous system control"
msgstr "Switch directly to previous system control"
#: data/50-mutter-navigation.xml:111
#: data/50-mutter-navigation.xml:105
msgid "Hide all normal windows"
msgstr "Hide all normal windows"
#: data/50-mutter-navigation.xml:114
#: data/50-mutter-navigation.xml:108
msgid "Switch to workspace 1"
msgstr "Switch to workspace 1"
#: data/50-mutter-navigation.xml:117
#: data/50-mutter-navigation.xml:111
msgid "Switch to workspace 2"
msgstr "Switch to workspace 2"
#: data/50-mutter-navigation.xml:120
#: data/50-mutter-navigation.xml:114
msgid "Switch to workspace 3"
msgstr "Switch to workspace 3"
#: data/50-mutter-navigation.xml:123
#: data/50-mutter-navigation.xml:117
msgid "Switch to workspace 4"
msgstr "Switch to workspace 4"
#: data/50-mutter-navigation.xml:126
#: data/50-mutter-navigation.xml:120
msgid "Switch to last workspace"
msgstr "Switch to last workspace"
#: data/50-mutter-navigation.xml:129
msgid "Move to workspace left"
msgstr "Move to workspace left"
#: data/50-mutter-navigation.xml:132
msgid "Move to workspace right"
msgstr "Move to workspace right"
#: data/50-mutter-navigation.xml:135
#: data/50-mutter-navigation.xml:123
msgid "Move to workspace above"
msgstr "Move to workspace above"
#: data/50-mutter-navigation.xml:138
#: data/50-mutter-navigation.xml:126
msgid "Move to workspace below"
msgstr "Move to workspace below"
#: data/50-mutter-system.xml:6
#: data/50-mutter-system.xml:6 data/50-mutter-wayland.xml:6
msgid "System"
msgstr "System"
@ -188,6 +171,10 @@ msgstr "Show the run command prompt"
msgid "Show the activities overview"
msgstr "Show the activities overview"
#: data/50-mutter-wayland.xml:8
msgid "Restore the keyboard shortcuts"
msgstr "Restore the keyboard shortcuts"
#: data/50-mutter-windows.xml:6
msgid "Windows"
msgstr "Windows"
@ -213,54 +200,50 @@ msgid "Restore window"
msgstr "Restore window"
#: data/50-mutter-windows.xml:18
msgid "Toggle shaded state"
msgstr "Toggle shaded state"
#: data/50-mutter-windows.xml:20
msgid "Close window"
msgstr "Close window"
#: data/50-mutter-windows.xml:22
#: data/50-mutter-windows.xml:20
msgid "Hide window"
msgstr "Hide window"
#: data/50-mutter-windows.xml:24
#: data/50-mutter-windows.xml:22
msgid "Move window"
msgstr "Move window"
#: data/50-mutter-windows.xml:26
#: data/50-mutter-windows.xml:24
msgid "Resize window"
msgstr "Resize window"
#: data/50-mutter-windows.xml:29
#: data/50-mutter-windows.xml:27
msgid "Toggle window on all workspaces or one"
msgstr "Toggle window on all workspaces or one"
#: data/50-mutter-windows.xml:31
#: data/50-mutter-windows.xml:29
msgid "Raise window if covered, otherwise lower it"
msgstr "Raise window if covered, otherwise lower it"
#: data/50-mutter-windows.xml:33
#: data/50-mutter-windows.xml:31
msgid "Raise window above other windows"
msgstr "Raise window above other windows"
#: data/50-mutter-windows.xml:35
#: data/50-mutter-windows.xml:33
msgid "Lower window below other windows"
msgstr "Lower window below other windows"
#: data/50-mutter-windows.xml:37
#: data/50-mutter-windows.xml:35
msgid "Maximize window vertically"
msgstr "Maximise window vertically"
#: data/50-mutter-windows.xml:39
#: data/50-mutter-windows.xml:37
msgid "Maximize window horizontally"
msgstr "Maximise window horizontally"
#: data/50-mutter-windows.xml:43
#: data/50-mutter-windows.xml:41
msgid "View split on left"
msgstr "View split on left"
#: data/50-mutter-windows.xml:47
#: data/50-mutter-windows.xml:45
msgid "View split on right"
msgstr "View split on right"
@ -273,16 +256,21 @@ msgid "Modifier to use for extended window management operations"
msgstr "Modifier to use for extended window management operations"
#: data/org.gnome.mutter.gschema.xml.in:8
#| msgid ""
#| "This key will initiate the \"overlay\", which is a combination window "
#| "overview and application launching system. The default is intended to be "
#| "the \"Windows key\" on PC hardware. It's expected that this binding "
#| "either the default or set to the empty string."
msgid ""
"This key will initiate the \"overlay\", which is a combination window "
"overview and application launching system. The default is intended to be the "
"\"Windows key\" on PC hardware. It's expected that this binding either the "
"default or set to the empty string."
"This key will initiate the overlay, which is a combination window overview "
"and application launching system. The default is intended to be the “Windows "
"key on PC hardware. Its expected that this binding either the default or "
"set to the empty string."
msgstr ""
"This key will initiate the \"overlay\", which is a combination window "
"overview and application launching system. The default is intended to be the "
"\"Windows key\" on PC hardware. It's expected that this binding either the "
"default or set to the empty string."
"This key will initiate the overlay, which is a combination window overview "
"and application launching system. The default is intended to be the “Windows "
"key on PC hardware. Its expected that this binding either the default or "
"set to the empty string."
#: data/org.gnome.mutter.gschema.xml.in:20
msgid "Attach modal dialogs"
@ -317,12 +305,16 @@ msgid "Workspaces are managed dynamically"
msgstr "Workspaces are managed dynamically"
#: data/org.gnome.mutter.gschema.xml.in:41
#| msgid ""
#| "Determines whether workspaces are managed dynamically or whether there's "
#| "a static number of workspaces (determined by the num-workspaces key in "
#| "org.gnome.desktop.wm.preferences)."
msgid ""
"Determines whether workspaces are managed dynamically or whether there's a "
"Determines whether workspaces are managed dynamically or whether theres a "
"static number of workspaces (determined by the num-workspaces key in org."
"gnome.desktop.wm.preferences)."
msgstr ""
"Determines whether workspaces are managed dynamically or whether there's a "
"Determines whether workspaces are managed dynamically or whether theres a "
"static number of workspaces (determined by the num-workspaces key in org."
"gnome.desktop.wm.preferences)."
@ -355,25 +347,32 @@ msgid "Delay focus changes until the pointer stops moving"
msgstr "Delay focus changes until the pointer stops moving"
#: data/org.gnome.mutter.gschema.xml.in:69
#| msgid ""
#| "If set to true, and the focus mode is either \"sloppy\" or \"mouse\" then "
#| "the focus will not be changed immediately when entering a window, but "
#| "only after the pointer stops moving."
msgid ""
"If set to true, and the focus mode is either \"sloppy\" or \"mouse\" then "
"the focus will not be changed immediately when entering a window, but only "
"after the pointer stops moving."
"If set to true, and the focus mode is either sloppy or mouse then the "
"focus will not be changed immediately when entering a window, but only after "
"the pointer stops moving."
msgstr ""
"If set to true, and the focus mode is either \"sloppy\" or \"mouse\" then "
"the focus will not be changed immediately when entering a window, but only "
"after the pointer stops moving."
"If set to true, and the focus mode is either sloppy or mouse then the "
"focus will not be changed immediately when entering a window, but only after "
"the pointer stops moving."
#: data/org.gnome.mutter.gschema.xml.in:79
msgid "Draggable border width"
msgstr "Draggable border width"
#: data/org.gnome.mutter.gschema.xml.in:80
#| msgid ""
#| "The amount of total draggable borders. If the theme's visible borders are "
#| "not enough, invisible borders will be added to meet this value."
msgid ""
"The amount of total draggable borders. If the theme's visible borders are "
"The amount of total draggable borders. If the themes visible borders are "
"not enough, invisible borders will be added to meet this value."
msgstr ""
"The amount of total draggable borders. If the theme's visible borders are "
"The amount of total draggable borders. If the themes visible borders are "
"not enough, invisible borders will be added to meet this value."
#: data/org.gnome.mutter.gschema.xml.in:89
@ -400,14 +399,47 @@ msgstr ""
"When true, the new windows will always be put in the centre of the active "
"screen of the monitor."
#: data/org.gnome.mutter.gschema.xml.in:120
#: data/org.gnome.mutter.gschema.xml.in:107
msgid "Enable experimental features"
msgstr "Enable experimental features"
#: data/org.gnome.mutter.gschema.xml.in:108
msgid ""
"To enable experimental features, add the feature keyword to the list. "
"Whether the feature requires restarting the compositor depends on the given "
"feature. Any experimental feature is not required to still be available, or "
"configurable. Dont expect adding anything in this setting to be future "
"proof. Currently possible keywords: • “scale-monitor-framebuffer” — makes "
"mutter default to layout logical monitors in a logical pixel coordinate "
"space, while scaling monitor framebuffers instead of window content, to "
"manage HiDPI monitors. Does not require a restart."
msgstr ""
"To enable experimental features, add the feature keyword to the list. "
"Whether the feature requires restarting the compositor depends on the given "
"feature. Any experimental feature is not required to still be available, or "
"configurable. Dont expect adding anything in this setting to be future "
"proof. Currently possible keywords: • “scale-monitor-framebuffer” — makes "
"mutter default to layout logical monitors in a logical pixel coordinate "
"space, while scaling monitor framebuffers instead of window content, to "
"manage HiDPI monitors. Does not require a restart."
#: data/org.gnome.mutter.gschema.xml.in:141
msgid "Select window from tab popup"
msgstr "Select window from tab popup"
#: data/org.gnome.mutter.gschema.xml.in:125
#: data/org.gnome.mutter.gschema.xml.in:146
msgid "Cancel tab popup"
msgstr "Cancel tab popup"
#: data/org.gnome.mutter.gschema.xml.in:151
#| msgid "Switch monitor"
msgid "Switch monitor configurations"
msgstr "Switch monitor configurations"
#: data/org.gnome.mutter.gschema.xml.in:156
msgid "Rotates the built-in monitor configuration"
msgstr "Rotates the built-in monitor configuration"
#: data/org.gnome.mutter.wayland.gschema.xml.in:6
msgid "Switch to VT 1"
msgstr "Switch to VT 1"
@ -456,59 +488,167 @@ msgstr "Switch to VT 11"
msgid "Switch to VT 12"
msgstr "Switch to VT 12"
#: src/backends/meta-input-settings.c:1707
#: data/org.gnome.mutter.wayland.gschema.xml.in:54
msgid "Re-enable shortcuts"
msgstr "Re-enable shortcuts"
#: data/org.gnome.mutter.wayland.gschema.xml.in:64
msgid "Allow grabs with Xwayland"
msgstr "Allow grabs with Xwayland"
#: data/org.gnome.mutter.wayland.gschema.xml.in:65
msgid ""
"Allow keyboard grabs issued by X11 applications running in Xwayland to be "
"taken into account. For a X11 grab to be taken into account under Wayland, "
"the client must also either send a specific X11 ClientMessage to the root "
"window or be among the applications white-listed in key “xwayland-grab-"
"access-rules”."
msgstr ""
"Allow keyboard grabs issued by X11 applications running in Xwayland to be "
"taken into account. For a X11 grab to be taken into account under Wayland, "
"the client must also either send a specific X11 ClientMessage to the root "
"window or be among the applications white-listed in key “xwayland-grab-"
"access-rules”."
#: data/org.gnome.mutter.wayland.gschema.xml.in:77
msgid "Xwayland applications allowed to issue keyboard grabs"
msgstr "Xwayland applications allowed to issue keyboard grabs"
#: data/org.gnome.mutter.wayland.gschema.xml.in:78
msgid ""
"List the resource names or resource class of X11 windows either allowed or "
"not allowed to issue X11 keyboard grabs under Xwayland. The resource name or "
"resource class of a given X11 window can be obtained using the command "
"“xprop WM_CLASS”. Wildcards “*” and jokers “?” in the values are supported. "
"Values starting with “!” are blacklisted, which has precedence over the "
"whitelist, to revoke applications from the default system list. The default "
"system list includes the following applications: "
"“@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES@” Users can break an existing grab by "
"using the specific keyboard shortcut defined by the keybinding key “restore-"
"shortcuts”."
msgstr ""
"List the resource names or resource class of X11 windows either allowed or "
"not allowed to issue X11 keyboard grabs under Xwayland. The resource name or "
"resource class of a given X11 window can be obtained using the command "
"“xprop WM_CLASS”. Wildcards “*” and jokers “?” in the values are supported. "
"Values starting with “!” are blacklisted, which has precedence over the "
"whitelist, to revoke applications from the default system list. The default "
"system list includes the following applications: "
"“@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES@” Users can break an existing grab by "
"using the specific keyboard shortcut defined by the keybinding key “restore-"
"shortcuts”."
#. TRANSLATORS: This string refers to a button that switches between
#. * different modes.
#.
#: src/backends/meta-input-settings.c:2325
#, c-format
#| msgid "Mode Switch: Mode %d"
msgid "Mode Switch (Group %d)"
msgstr "Mode Switch (Group %d)"
#. TRANSLATORS: This string refers to an action, cycles drawing tablets'
#. * mapping through the available outputs.
#.
#: src/backends/meta-input-settings.c:2348
msgid "Switch monitor"
msgstr "Switch monitor"
#: src/backends/meta-input-settings.c:1709
#: src/backends/meta-input-settings.c:2350
msgid "Show on-screen help"
msgstr "Show on-screen help"
#: src/backends/meta-monitor-manager.c:514
#: src/backends/meta-monitor-manager.c:907
msgid "Built-in display"
msgstr "Built-in display"
#: src/backends/meta-monitor-manager.c:537
#: src/backends/meta-monitor-manager.c:930
msgid "Unknown"
msgstr "Unknown"
#: src/backends/meta-monitor-manager.c:539
#: src/backends/meta-monitor-manager.c:932
msgid "Unknown Display"
msgstr "Unknown Display"
#. TRANSLATORS: this is a monitor vendor name, followed by a
#. * size in inches, like 'Dell 15"'
#.
#: src/backends/meta-monitor-manager.c:547
#: src/backends/meta-monitor-manager.c:940
#, c-format
msgid "%s %s"
msgstr "%s %s"
#. This probably means that a non-WM compositor like xcompmgr is running;
#. * we have no way to get it to exit
#: src/compositor/compositor.c:463
#: src/compositor/compositor.c:481
#, c-format
#| msgid ""
#| "Another compositing manager is already running on screen %i on display "
#| "\"%s\"."
msgid ""
"Another compositing manager is already running on screen %i on display \"%s"
"\"."
"Another compositing manager is already running on screen %i on display “%s”."
msgstr ""
"Another compositing manager is already running on screen %i on display \"%s"
"\"."
"Another compositing manager is already running on screen %i on display “%s”."
#: src/core/bell.c:194
#: src/core/bell.c:254
msgid "Bell event"
msgstr "Bell event"
#: src/core/delete.c:127
#: src/core/main.c:191
msgid "Disable connection to session manager"
msgstr "Disable connection to session manager"
#: src/core/main.c:197
msgid "Replace the running window manager"
msgstr "Replace the running window manager"
#: src/core/main.c:203
msgid "Specify session management ID"
msgstr "Specify session management ID"
#: src/core/main.c:208
msgid "X Display to use"
msgstr "X Display to use"
#: src/core/main.c:214
msgid "Initialize session from savefile"
msgstr "Initialise session from savefile"
#: src/core/main.c:220
msgid "Make X calls synchronous"
msgstr "Make X calls synchronous"
#: src/core/main.c:227
msgid "Run as a wayland compositor"
msgstr "Run as a wayland compositor"
#: src/core/main.c:233
msgid "Run as a nested compositor"
msgstr "Run as a nested compositor"
#: src/core/main.c:239
msgid "Run wayland compositor without starting Xwayland"
msgstr "Run wayland compositor without starting Xwayland"
#: src/core/main.c:247
msgid "Run as a full display server, rather than nested"
msgstr "Run as a full display server, rather than nested"
#: src/core/main.c:253
msgid "Run with X11 backend"
msgstr "Run with X11 backend"
#. Translators: %s is a window title
#: src/core/meta-close-dialog-default.c:148
#, c-format
msgid "“%s” is not responding."
msgstr "“%s” is not responding."
#: src/core/delete.c:129
#: src/core/meta-close-dialog-default.c:150
msgid "Application is not responding."
msgstr "Application is not responding."
#: src/core/delete.c:134
#: src/core/meta-close-dialog-default.c:155
msgid ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
@ -516,66 +656,31 @@ msgstr ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
#: src/core/delete.c:141
msgid "_Wait"
msgstr "_Wait"
#: src/core/delete.c:141
#: src/core/meta-close-dialog-default.c:162
msgid "_Force Quit"
msgstr "_Force Quit"
#: src/core/display.c:590
#, c-format
msgid "Failed to open X Window System display '%s'\n"
msgstr "Failed to open X Window System display '%s'\n"
#: src/core/main.c:182
msgid "Disable connection to session manager"
msgstr "Disable connection to session manager"
#: src/core/main.c:188
msgid "Replace the running window manager"
msgstr "Replace the running window manager"
#: src/core/main.c:194
msgid "Specify session management ID"
msgstr "Specify session management ID"
#: src/core/main.c:199
msgid "X Display to use"
msgstr "X Display to use"
#: src/core/main.c:205
msgid "Initialize session from savefile"
msgstr "Initialise session from savefile"
#: src/core/main.c:211
msgid "Make X calls synchronous"
msgstr "Make X calls synchronous"
#: src/core/main.c:218
msgid "Run as a wayland compositor"
msgstr "Run as a wayland compositor"
#: src/core/main.c:224
msgid "Run as a nested compositor"
msgstr "Run as a nested compositor"
#: src/core/main.c:232
msgid "Run as a full display server, rather than nested"
msgstr "Run as a full display server, rather than nested"
#: src/core/meta-close-dialog-default.c:162
msgid "_Wait"
msgstr "_Wait"
#: src/core/mutter.c:39
#, c-format
#| msgid ""
#| "mutter %s\n"
#| "Copyright (C) 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
#| "This is free software; see the source for copying conditions.\n"
#| "There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A "
#| "PARTICULAR PURPOSE.\n"
msgid ""
"mutter %s\n"
"Copyright (C) 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
"Copyright © 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
"This is free software; see the source for copying conditions.\n"
"There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A "
"PARTICULAR PURPOSE.\n"
msgstr ""
"mutter %s\n"
"Copyright (C) 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
"Copyright © 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
"This is free software; see the source for copying conditions.\n"
"There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A "
"PARTICULAR PURPOSE.\n"
@ -588,47 +693,79 @@ msgstr "Print version"
msgid "Mutter plugin to use"
msgstr "Mutter plugin to use"
#: src/core/prefs.c:1997
#: src/core/prefs.c:1915
#, c-format
msgid "Workspace %d"
msgstr "Workspace %d"
#: src/core/screen.c:521
#, c-format
msgid ""
"Display \"%s\" already has a window manager; try using the --replace option "
"to replace the current window manager."
msgstr ""
"Display \"%s\" already has a window manager; try using the --replace option "
"to replace the current window manager."
#: src/core/screen.c:606
#, c-format
msgid "Screen %d on display '%s' is invalid\n"
msgstr "Screen %d on display '%s' is invalid\n"
#: src/core/util.c:120
msgid "Mutter was compiled without support for verbose mode\n"
msgstr "Mutter was compiled without support for verbose mode\n"
#: src/wayland/meta-wayland-tablet-pad.c:595
#: src/wayland/meta-wayland-tablet-pad.c:567
#, c-format
msgid "Mode Switch: Mode %d"
msgstr "Mode Switch: Mode %d"
#: src/x11/session.c:1815
#: src/x11/meta-x11-display.c:666
#, c-format
#| msgid ""
#| "Display \"%s\" already has a window manager; try using the --replace "
#| "option to replace the current window manager."
msgid ""
"These windows do not support &quot;save current setup&quot; and will have to "
"be restarted manually next time you log in."
"Display “%s” already has a window manager; try using the --replace option to "
"replace the current window manager."
msgstr ""
"These windows do not support &quot;save current setup&quot; and will have to "
"be restarted manually next time you log in."
"Display “%s” already has a window manager; try using the --replace option to "
"replace the current window manager."
#: src/x11/window-props.c:548
#: src/x11/meta-x11-display.c:1010
msgid "Failed to initialize GDK\n"
msgstr "Failed to initialise GDK\n"
#: src/x11/meta-x11-display.c:1034
#, c-format
#| msgid "Failed to open X Window System display '%s'\n"
msgid "Failed to open X Window System display “%s”\n"
msgstr "Failed to open X Window System display “%s”\n"
#: src/x11/meta-x11-display.c:1117
#, c-format
#| msgid "Screen %d on display '%s' is invalid\n"
msgid "Screen %d on display “%s” is invalid\n"
msgstr "Screen %d on display “%s” is invalid\n"
#: src/x11/session.c:1819
#| msgid ""
#| "These windows do not support &quot;save current setup&quot; and will have "
#| "to be restarted manually next time you log in."
msgid ""
"These windows do not support “save current setup” and will have to be "
"restarted manually next time you log in."
msgstr ""
"These windows do not support “save current setup” and will have to be "
"restarted manually next time you log in."
#: src/x11/window-props.c:565
#, c-format
msgid "%s (on %s)"
msgstr "%s (on %s)"
#~ msgid "Move window one workspace to the left"
#~ msgstr "Move window one workspace to the left"
#~ msgid "Move window one workspace to the right"
#~ msgstr "Move window one workspace to the right"
#~ msgid "Move to workspace left"
#~ msgstr "Move to workspace left"
#~ msgid "Move to workspace right"
#~ msgstr "Move to workspace right"
#~ msgid "Toggle shaded state"
#~ msgstr "Toggle shaded state"
#~ msgid "background texture could not be created from file"
#~ msgstr "background texture could not be created from file"

518
po/eo.po
View File

@ -2,16 +2,16 @@
# Copyright (C) 2011 Free Software Foundation, Inc.
# This file is distributed under the same license as the mutter package.
# Michael MORONI < >, 2011.
# Kristjan SCHMIDT <kristjan.schmidt@googlemail.com>, 2011, 2012, 2015.
# Kristjan SCHMIDT <kristjan.schmidt@googlemail.com>, 2011, 2012, 2015, 2018.
msgid ""
msgstr ""
"Project-Id-Version: mutter\n"
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?product=mutter"
"Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?product=mutter"
"&keywords=I18N+L10N&component=general\n"
"POT-Creation-Date: 2015-02-14 11:06+0000\n"
"PO-Revision-Date: 2015-02-14 22:34+0200\n"
"POT-Creation-Date: 2017-12-18 16:24+0000\n"
"PO-Revision-Date: 2018-01-22 20:12+0200\n"
"Last-Translator: Kristjan SCHMIDT <kristjan.schmidt@googlemail.com>\n"
"Language-Team: Esperanto <gnome-l10n-eo@lists.launchpad.net>\n"
"Language-Team: Esperanto <gnome-eo-list@gnome.org>\n"
"Language: eo\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@ -20,553 +20,675 @@ msgstr ""
"X-Generator: Virtaal 0.7.1\n"
"X-Project-Style: gnome\n"
#: ../data/50-mutter-navigation.xml.in.h:1
#: data/50-mutter-navigation.xml:6
msgid "Navigation"
msgstr "Navigado"
#: ../data/50-mutter-navigation.xml.in.h:2
#: data/50-mutter-navigation.xml:9
msgid "Move window to workspace 1"
msgstr "Movi la fenestron al laborspaco 1"
#: ../data/50-mutter-navigation.xml.in.h:3
#: data/50-mutter-navigation.xml:12
msgid "Move window to workspace 2"
msgstr "Movi la fenestron al laborspaco 2"
#: ../data/50-mutter-navigation.xml.in.h:4
#: data/50-mutter-navigation.xml:15
msgid "Move window to workspace 3"
msgstr "Movi la fenestron al laborspaco 3"
#: ../data/50-mutter-navigation.xml.in.h:5
#: data/50-mutter-navigation.xml:18
msgid "Move window to workspace 4"
msgstr "Movi la fenestron al laborspaco 4"
#: ../data/50-mutter-navigation.xml.in.h:6
#: data/50-mutter-navigation.xml:21
msgid "Move window to last workspace"
msgstr "Movi la fenestron al lasta laborspaco"
#: ../data/50-mutter-navigation.xml.in.h:7
#: data/50-mutter-navigation.xml:24
msgid "Move window one workspace to the left"
msgstr "Movi la fenestron al la maldekstra laborspaco"
#: ../data/50-mutter-navigation.xml.in.h:8
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace to the right"
msgstr "Movi la fenestron al la dekstra laborspaco"
#: ../data/50-mutter-navigation.xml.in.h:9
#: data/50-mutter-navigation.xml:30
msgid "Move window one workspace up"
msgstr "Movi la fenestron al la supra laborspaco"
#: ../data/50-mutter-navigation.xml.in.h:10
#: data/50-mutter-navigation.xml:33
msgid "Move window one workspace down"
msgstr "Movi la fenestron al la suba laborspaco"
#: ../data/50-mutter-navigation.xml.in.h:11
#: data/50-mutter-navigation.xml:36
msgid "Move window one monitor to the left"
msgstr "Movi la fenestron al la maldekstra ekrano"
#: ../data/50-mutter-navigation.xml.in.h:12
#: data/50-mutter-navigation.xml:39
msgid "Move window one monitor to the right"
msgstr "Movi la fenestron al la dekstra ekrano"
#: ../data/50-mutter-navigation.xml.in.h:13
#: data/50-mutter-navigation.xml:42
msgid "Move window one monitor up"
msgstr "Movi la fenestron al la supra ekrano"
#: ../data/50-mutter-navigation.xml.in.h:14
#: data/50-mutter-navigation.xml:45
msgid "Move window one monitor down"
msgstr "Movi la fenestron al la suba ekrano"
#: ../data/50-mutter-navigation.xml.in.h:15
#: data/50-mutter-navigation.xml:49
msgid "Switch applications"
msgstr "Ŝanĝi aplikaĵojn"
#: ../data/50-mutter-navigation.xml.in.h:16
#: data/50-mutter-navigation.xml:54
msgid "Switch to previous application"
msgstr "Ŝalti al antaŭa aplikaĵo"
#: ../data/50-mutter-navigation.xml.in.h:17
#: data/50-mutter-navigation.xml:58
msgid "Switch windows"
msgstr "Ŝanĝi fenestrojn"
#: ../data/50-mutter-navigation.xml.in.h:18
#: data/50-mutter-navigation.xml:63
msgid "Switch to previous window"
msgstr "Ŝalti al antaŭa fenestro"
#: ../data/50-mutter-navigation.xml.in.h:19
#: data/50-mutter-navigation.xml:67
msgid "Switch windows of an application"
msgstr "Ŝanĝi fenestrojn de aplikaĵo"
#: ../data/50-mutter-navigation.xml.in.h:20
#: data/50-mutter-navigation.xml:72
msgid "Switch to previous window of an application"
msgstr "Ŝalti al antaŭa fenestro de aplikaĵo"
#: ../data/50-mutter-navigation.xml.in.h:21
#: data/50-mutter-navigation.xml:76
msgid "Switch system controls"
msgstr "Ŝanĝi sistem-kontrolojn"
#: ../data/50-mutter-navigation.xml.in.h:22
#: data/50-mutter-navigation.xml:81
msgid "Switch to previous system control"
msgstr "Ŝalti al antaŭa sistem-kontrolo"
#: ../data/50-mutter-navigation.xml.in.h:23
#: data/50-mutter-navigation.xml:85
msgid "Switch windows directly"
msgstr "Ŝanĝi rekte fenestrojn"
#: ../data/50-mutter-navigation.xml.in.h:24
#: data/50-mutter-navigation.xml:90
msgid "Switch directly to previous window"
msgstr "Ŝalti rekte al antaŭa fenestro"
#: ../data/50-mutter-navigation.xml.in.h:25
#: data/50-mutter-navigation.xml:94
msgid "Switch windows of an app directly"
msgstr "Ŝanĝi rekte fenestrojn de aplikaĵo"
#: ../data/50-mutter-navigation.xml.in.h:26
#: data/50-mutter-navigation.xml:99
msgid "Switch directly to previous window of an app"
msgstr "Ŝalti rekte al antaŭa fenestro de aplikaĵo"
#: ../data/50-mutter-navigation.xml.in.h:27
#: data/50-mutter-navigation.xml:103
msgid "Switch system controls directly"
msgstr "Ŝalti rekte sistem-kontrolojn"
#: ../data/50-mutter-navigation.xml.in.h:28
#: data/50-mutter-navigation.xml:108
msgid "Switch directly to previous system control"
msgstr "Ŝalti rekte al antaŭa sistem-kontrolo"
#: ../data/50-mutter-navigation.xml.in.h:29
#: data/50-mutter-navigation.xml:111
msgid "Hide all normal windows"
msgstr "Kaŝi ĉiujn normalajn fenestrojn"
#: ../data/50-mutter-navigation.xml.in.h:30
#: data/50-mutter-navigation.xml:114
msgid "Switch to workspace 1"
msgstr "Ŝalti al laborspaco 1"
#: ../data/50-mutter-navigation.xml.in.h:31
#: data/50-mutter-navigation.xml:117
msgid "Switch to workspace 2"
msgstr "Ŝalti al laborspaco 2"
#: ../data/50-mutter-navigation.xml.in.h:32
#: data/50-mutter-navigation.xml:120
msgid "Switch to workspace 3"
msgstr "Ŝalti al laborspaco 3"
#: ../data/50-mutter-navigation.xml.in.h:33
#: data/50-mutter-navigation.xml:123
msgid "Switch to workspace 4"
msgstr "Ŝalti al laborspaco 4"
#: ../data/50-mutter-navigation.xml.in.h:34
#: data/50-mutter-navigation.xml:126
msgid "Switch to last workspace"
msgstr "Ŝalti al lasta laborspaco"
#: ../data/50-mutter-navigation.xml.in.h:35
#: data/50-mutter-navigation.xml:129
msgid "Move to workspace left"
msgstr "Movi al la maldekstra laborspaco"
#: ../data/50-mutter-navigation.xml.in.h:36
#: data/50-mutter-navigation.xml:132
msgid "Move to workspace right"
msgstr "Movi al la dekstra laborspaco"
#: ../data/50-mutter-navigation.xml.in.h:37
#: data/50-mutter-navigation.xml:135
msgid "Move to workspace above"
msgstr "Movi al la supra laborspaco"
#: ../data/50-mutter-navigation.xml.in.h:38
#: data/50-mutter-navigation.xml:138
msgid "Move to workspace below"
msgstr "Movi al la malsupra laborspaco"
#: ../data/50-mutter-system.xml.in.h:1
#: data/50-mutter-system.xml:6 data/50-mutter-wayland.xml:6
msgid "System"
msgstr "Sistemo"
#: ../data/50-mutter-system.xml.in.h:2
#: data/50-mutter-system.xml:8
msgid "Show the run command prompt"
msgstr ""
#: ../data/50-mutter-system.xml.in.h:3
#: data/50-mutter-system.xml:10
msgid "Show the activities overview"
msgstr ""
#: ../data/50-mutter-windows.xml.in.h:1
#: data/50-mutter-wayland.xml:8
msgid "Restore the keyboard shortcuts"
msgstr ""
#: data/50-mutter-windows.xml:6
msgid "Windows"
msgstr "Fenestroj"
#: ../data/50-mutter-windows.xml.in.h:2
#: data/50-mutter-windows.xml:8
msgid "Activate the window menu"
msgstr "Aktivigi la fenestromenuon"
#: ../data/50-mutter-windows.xml.in.h:3
#: data/50-mutter-windows.xml:10
msgid "Toggle fullscreen mode"
msgstr "Baskuligi tutekranan reĝimon"
#: ../data/50-mutter-windows.xml.in.h:4
#: data/50-mutter-windows.xml:12
msgid "Toggle maximization state"
msgstr ""
#: ../data/50-mutter-windows.xml.in.h:5
#: data/50-mutter-windows.xml:14
msgid "Maximize window"
msgstr "Maksimumigi la fenestron"
#: ../data/50-mutter-windows.xml.in.h:6
#: data/50-mutter-windows.xml:16
msgid "Restore window"
msgstr "Restaŭri la fenestron"
#: ../data/50-mutter-windows.xml.in.h:7
#: data/50-mutter-windows.xml:18
msgid "Toggle shaded state"
msgstr ""
#: ../data/50-mutter-windows.xml.in.h:8
#: data/50-mutter-windows.xml:20
msgid "Close window"
msgstr "Fermi la fenestron"
#: ../data/50-mutter-windows.xml.in.h:9
#: data/50-mutter-windows.xml:22
msgid "Hide window"
msgstr "Kaŝi la fenestron"
#: ../data/50-mutter-windows.xml.in.h:10
#: data/50-mutter-windows.xml:24
msgid "Move window"
msgstr "Movi la fenestron"
#: ../data/50-mutter-windows.xml.in.h:11
#: data/50-mutter-windows.xml:26
msgid "Resize window"
msgstr "Ŝanĝi la fenestrograndon"
#: ../data/50-mutter-windows.xml.in.h:12
#: data/50-mutter-windows.xml:29
msgid "Toggle window on all workspaces or one"
msgstr ""
#: ../data/50-mutter-windows.xml.in.h:13
#: data/50-mutter-windows.xml:31
msgid "Raise window if covered, otherwise lower it"
msgstr ""
#: ../data/50-mutter-windows.xml.in.h:14
#: data/50-mutter-windows.xml:33
msgid "Raise window above other windows"
msgstr ""
#: ../data/50-mutter-windows.xml.in.h:15
#: data/50-mutter-windows.xml:35
msgid "Lower window below other windows"
msgstr ""
#: ../data/50-mutter-windows.xml.in.h:16
#: data/50-mutter-windows.xml:37
msgid "Maximize window vertically"
msgstr "Vertikale maksimumigi la fenestron"
#: ../data/50-mutter-windows.xml.in.h:17
#: data/50-mutter-windows.xml:39
msgid "Maximize window horizontally"
msgstr "Horizontale maksimumigi la fenestron"
#: ../data/50-mutter-windows.xml.in.h:18
#: data/50-mutter-windows.xml:43
msgid "View split on left"
msgstr ""
#: ../data/50-mutter-windows.xml.in.h:19
#: data/50-mutter-windows.xml:47
msgid "View split on right"
msgstr ""
#: ../data/mutter.desktop.in.h:1
#: data/mutter.desktop.in:4
msgid "Mutter"
msgstr "Mutero"
#: ../data/org.gnome.mutter.gschema.xml.in.h:1
#: data/org.gnome.mutter.gschema.xml.in:7
msgid "Modifier to use for extended window management operations"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:2
#: data/org.gnome.mutter.gschema.xml.in:8
msgid ""
"This key will initiate the \"overlay\", which is a combination window "
"overview and application launching system. The default is intended to be the "
"\"Windows key\" on PC hardware. It's expected that this binding either the "
"default or set to the empty string."
"This key will initiate the overlay, which is a combination window overview "
"and application launching system. The default is intended to be the “Windows "
"key on PC hardware. Its expected that this binding either the default or "
"set to the empty string."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:3
#: data/org.gnome.mutter.gschema.xml.in:20
msgid "Attach modal dialogs"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:4
#: data/org.gnome.mutter.gschema.xml.in:21
msgid ""
"When true, instead of having independent titlebars, modal dialogs appear "
"attached to the titlebar of the parent window and are moved together with "
"the parent window."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:5
#: data/org.gnome.mutter.gschema.xml.in:30
msgid "Enable edge tiling when dropping windows on screen edges"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:6
#: data/org.gnome.mutter.gschema.xml.in:31
msgid ""
"If enabled, dropping windows on vertical screen edges maximizes them "
"vertically and resizes them horizontally to cover half of the available "
"area. Dropping windows on the top screen edge maximizes them completely."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:7
#: data/org.gnome.mutter.gschema.xml.in:40
msgid "Workspaces are managed dynamically"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:8
#: data/org.gnome.mutter.gschema.xml.in:41
msgid ""
"Determines whether workspaces are managed dynamically or whether there's a "
"Determines whether workspaces are managed dynamically or whether theres a "
"static number of workspaces (determined by the num-workspaces key in org."
"gnome.desktop.wm.preferences)."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:9
#: data/org.gnome.mutter.gschema.xml.in:50
msgid "Workspaces only on primary"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:10
#: data/org.gnome.mutter.gschema.xml.in:51
msgid ""
"Determines whether workspace switching should happen for windows on all "
"monitors or only for windows on the primary monitor."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:11
#: data/org.gnome.mutter.gschema.xml.in:59
msgid "No tab popup"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:12
#: data/org.gnome.mutter.gschema.xml.in:60
msgid ""
"Determines whether the use of popup and highlight frame should be disabled "
"for window cycling."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:13
#: data/org.gnome.mutter.gschema.xml.in:68
msgid "Delay focus changes until the pointer stops moving"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:14
#: data/org.gnome.mutter.gschema.xml.in:69
msgid ""
"If set to true, and the focus mode is either \"sloppy\" or \"mouse\" then "
"the focus will not be changed immediately when entering a window, but only "
"after the pointer stops moving."
"If set to true, and the focus mode is either sloppy or mouse then the "
"focus will not be changed immediately when entering a window, but only after "
"the pointer stops moving."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:15
#: data/org.gnome.mutter.gschema.xml.in:79
msgid "Draggable border width"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:16
#: data/org.gnome.mutter.gschema.xml.in:80
msgid ""
"The amount of total draggable borders. If the theme's visible borders are "
"The amount of total draggable borders. If the themes visible borders are "
"not enough, invisible borders will be added to meet this value."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:17
#: data/org.gnome.mutter.gschema.xml.in:89
msgid "Auto maximize nearly monitor sized windows"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:18
#: data/org.gnome.mutter.gschema.xml.in:90
msgid ""
"If enabled, new windows that are initially the size of the monitor "
"automatically get maximized."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:19
#: data/org.gnome.mutter.gschema.xml.in:98
msgid "Place new windows in the center"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:20
#: data/org.gnome.mutter.gschema.xml.in:99
msgid ""
"When true, the new windows will always be put in the center of the active "
"screen of the monitor."
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:21
#: data/org.gnome.mutter.gschema.xml.in:107
msgid "Enable experimental features"
msgstr ""
#: data/org.gnome.mutter.gschema.xml.in:108
msgid ""
"To enable experimental features, add the feature keyword to the list. "
"Whether the feature requires restarting the compositor depends on the given "
"feature. Any experimental feature is not required to still be available, or "
"configurable. Dont expect adding anything in this setting to be future "
"proof. Currently possible keywords: • “scale-monitor-framebuffer” — makes "
"mutter default to layout logical monitors in a logical pixel coordinate "
"space, while scaling monitor framebuffers instead of window content, to "
"manage HiDPI monitors. Does not require a restart. • “remote-desktop” — "
"enables remote desktop support. To support remote desktop with screen "
"sharing, “screen-cast” must also be enabled. • “screen-cast” — enables "
"screen cast support."
msgstr ""
#: data/org.gnome.mutter.gschema.xml.in:145
msgid "Select window from tab popup"
msgstr ""
#: ../data/org.gnome.mutter.gschema.xml.in.h:22
#: data/org.gnome.mutter.gschema.xml.in:150
msgid "Cancel tab popup"
msgstr ""
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:1
#: data/org.gnome.mutter.gschema.xml.in:155
#, fuzzy
#| msgid "Switch applications"
msgid "Switch monitor configurations"
msgstr "Ŝanĝi aplikaĵojn"
#: data/org.gnome.mutter.gschema.xml.in:160
msgid "Rotates the built-in monitor configuration"
msgstr ""
#: data/org.gnome.mutter.wayland.gschema.xml.in:6
msgid "Switch to VT 1"
msgstr "Ŝalti al VT 1"
msgstr "Ŝalti al virtuala terminalo 1"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:2
#, fuzzy
#: data/org.gnome.mutter.wayland.gschema.xml.in:10
msgid "Switch to VT 2"
msgstr "Ŝalti al VT 2"
msgstr "Ŝalti al virtuala terminalo 2"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:3
#, fuzzy
#: data/org.gnome.mutter.wayland.gschema.xml.in:14
msgid "Switch to VT 3"
msgstr "Ŝalti al VT 3"
msgstr "Ŝalti al virtuala terminalo 3"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:4
#, fuzzy
#: data/org.gnome.mutter.wayland.gschema.xml.in:18
msgid "Switch to VT 4"
msgstr "Ŝalti al VT 4"
msgstr "Ŝalti al virtuala terminalo 4"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:5
#, fuzzy
#: data/org.gnome.mutter.wayland.gschema.xml.in:22
#| msgid "Switch to workspace 5"
msgid "Switch to VT 5"
msgstr "Ŝalti al VT 5"
msgstr "Ŝalti al virtuala terminalo 5"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:6
#, fuzzy
#: data/org.gnome.mutter.wayland.gschema.xml.in:26
#| msgid "Switch to workspace 6"
msgid "Switch to VT 6"
msgstr "Ŝalti al VT 6"
msgstr "Ŝalti al virtuala terminalo 6"
#: ../data/org.gnome.mutter.wayland.gschema.xml.in.h:7
#, fuzzy
#: data/org.gnome.mutter.wayland.gschema.xml.in:30
#| msgid "Switch to workspace 7"
msgid "Switch to VT 7"
msgstr "Ŝalti al VT 7"
msgstr "Ŝalti al virtuala terminalo 7"
#: ../src/backends/meta-monitor-manager.c:364
#: data/org.gnome.mutter.wayland.gschema.xml.in:34
msgid "Switch to VT 8"
msgstr "Ŝalti al virtuala terminalo 8"
#: data/org.gnome.mutter.wayland.gschema.xml.in:38
msgid "Switch to VT 9"
msgstr "Ŝalti al virtuala terminalo 9"
#: data/org.gnome.mutter.wayland.gschema.xml.in:42
msgid "Switch to VT 10"
msgstr "Ŝalti al virtuala terminalo 10"
#: data/org.gnome.mutter.wayland.gschema.xml.in:46
msgid "Switch to VT 11"
msgstr "Ŝalti al virtuala terminalo 11"
#: data/org.gnome.mutter.wayland.gschema.xml.in:50
msgid "Switch to VT 12"
msgstr "Ŝalti al virtuala terminalo 12"
#: data/org.gnome.mutter.wayland.gschema.xml.in:54
msgid "Re-enable shortcuts"
msgstr "Re-ŝalti klavkombinojn"
#: data/org.gnome.mutter.wayland.gschema.xml.in:64
msgid "Allow grabs with Xwayland"
msgstr ""
#: data/org.gnome.mutter.wayland.gschema.xml.in:65
msgid ""
"Allow keyboard grabs issued by X11 applications running in Xwayland to be "
"taken into account. For a X11 grab to be taken into account under Wayland, "
"the client must also either send a specific X11 ClientMessage to the root "
"window or be among the applications white-listed in key “xwayland-grab-"
"access-rules”."
msgstr ""
#: data/org.gnome.mutter.wayland.gschema.xml.in:77
msgid "Xwayland applications allowed to issue keyboard grabs"
msgstr ""
#: data/org.gnome.mutter.wayland.gschema.xml.in:78
msgid ""
"List the resource names or resource class of X11 windows either allowed or "
"not allowed to issue X11 keyboard grabs under Xwayland. The resource name or "
"resource class of a given X11 window can be obtained using the command "
"“xprop WM_CLASS”. Wildcards “*” and jokers “?” in the values are supported. "
"Values starting with “!” are blacklisted, which has precedence over the "
"whitelist, to revoke applications from the default system list. The default "
"system list includes the following applications: "
"“@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES@” Users can break an existing grab by "
"using the specific keyboard shortcut defined by the keybinding key “restore-"
"shortcuts”."
msgstr ""
#. TRANSLATORS: This string refers to a button that switches between
#. * different modes.
#.
#: src/backends/meta-input-settings.c:2260
#, c-format
msgid "Mode Switch (Group %d)"
msgstr ""
#. TRANSLATORS: This string refers to an action, cycles drawing tablets'
#. * mapping through the available outputs.
#.
#: src/backends/meta-input-settings.c:2283
#, fuzzy
#| msgid "Switch system controls"
msgid "Switch monitor"
msgstr "Ŝanĝi sistem-kontrolojn"
#: src/backends/meta-input-settings.c:2285
msgid "Show on-screen help"
msgstr "Montri ekranhelpon"
#: src/backends/meta-monitor-manager.c:900
msgid "Built-in display"
msgstr ""
#: ../src/backends/meta-monitor-manager.c:391
#: src/backends/meta-monitor-manager.c:923
msgid "Unknown"
msgstr "Nekonate"
#: ../src/backends/meta-monitor-manager.c:393
#: src/backends/meta-monitor-manager.c:925
msgid "Unknown Display"
msgstr "Nekonata ekrano"
#. TRANSLATORS: this is a monitor vendor name, followed by a
#. * size in inches, like 'Dell 15"'
#.
#: ../src/backends/meta-monitor-manager.c:401
#: src/backends/meta-monitor-manager.c:933
#, c-format
msgid "%s %s"
msgstr "%s %s"
#. This probably means that a non-WM compositor like xcompmgr is running;
#. * we have no way to get it to exit
#: ../src/compositor/compositor.c:456
#, c-format
#: src/compositor/compositor.c:479
#, fuzzy, c-format
#| msgid ""
#| "Another compositing manager is already running on screen %i on display "
#| "\"%s\"."
msgid ""
"Another compositing manager is already running on screen %i on display \"%s"
"\"."
msgstr "Alia kunmetanta administrilo jam rulas sur ekrano %i de montrilo \"%s\"."
"Another compositing manager is already running on screen %i on display “%s”."
msgstr "Alia kunmetanta administrilo jam rulas sur ekrano %i de montrilo “%s”."
#: ../src/core/bell.c:185
#: src/core/bell.c:194
msgid "Bell event"
msgstr "Sonoril-evento"
#: ../src/core/delete.c:127
#: src/core/display.c:608
#, fuzzy, c-format
#| msgid "Failed to open X Window System display '%s'\n"
msgid "Failed to open X Window System display “%s”\n"
msgstr "Malsukcesis malfermi jenan vidigon de fenestra sistemo X “%s”\n"
#: src/core/main.c:189
msgid "Disable connection to session manager"
msgstr "Elŝalti konekton al la seancoadministrilo"
#: src/core/main.c:195
msgid "Replace the running window manager"
msgstr "Anstataŭigi la nun ruliĝantan fenestromastrumilon"
#: src/core/main.c:201
msgid "Specify session management ID"
msgstr "Specifi identigilon de la seancoadministrilo"
#: src/core/main.c:206
#, fuzzy
msgid "X Display to use"
msgstr "X-Vidigo uzenda"
#: src/core/main.c:212
msgid "Initialize session from savefile"
msgstr "Pravalorizi la seancon el konservita dosiero"
#: src/core/main.c:218
msgid "Make X calls synchronous"
msgstr "Fari X-vokojn sinkrone"
#: src/core/main.c:225
msgid "Run as a wayland compositor"
msgstr ""
#: src/core/main.c:231
msgid "Run as a nested compositor"
msgstr ""
#: src/core/main.c:239
msgid "Run as a full display server, rather than nested"
msgstr ""
#. Translators: %s is a window title
#: src/core/meta-close-dialog-default.c:147
#, c-format
#| msgid "<tt>%s</tt> is not responding."
msgid "“%s” is not responding."
msgstr "“%s” ne respondas."
#: ../src/core/delete.c:129
#: src/core/meta-close-dialog-default.c:149
msgid "Application is not responding."
msgstr "Aplikaĵo ne respondas."
#: ../src/core/delete.c:134
#: src/core/meta-close-dialog-default.c:154
msgid ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
msgstr "Vi povas elekti ĉu atendi iomete por la aplikaĵo aŭ perforte ĉesi ĝin."
#: ../src/core/delete.c:141
msgid "_Wait"
msgstr "_Atendi"
#: ../src/core/delete.c:141
#: src/core/meta-close-dialog-default.c:161
msgid "_Force Quit"
msgstr "Per_forta eliro"
#: ../src/core/display.c:562
#, c-format
msgid "Failed to open X Window System display '%s'\n"
msgstr "Malsukcesis malfermi jenan vidigon de fenestra sistemo X: '%s'\n"
#: ../src/core/main.c:176
msgid "Disable connection to session manager"
msgstr "Elŝalti konekton al la seancoadministrilo"
#: ../src/core/main.c:182
msgid "Replace the running window manager"
msgstr "Anstataŭigi la nun ruliĝantan fenestromastrumilon"
#: ../src/core/main.c:188
msgid "Specify session management ID"
msgstr "Specifi identigilon de la seancoadministrilo"
#: ../src/core/main.c:193
#, fuzzy
msgid "X Display to use"
msgstr "X-Vidigo uzenda"
#: ../src/core/main.c:199
msgid "Initialize session from savefile"
msgstr "Pravalorizi la seancon el konservita dosiero"
#: ../src/core/main.c:205
msgid "Make X calls synchronous"
msgstr "Fari X-vokojn sinkrone"
#: ../src/core/main.c:212
msgid "Run as a wayland compositor"
msgstr ""
#: ../src/core/main.c:220
msgid "Run as a full display server, rather than nested"
msgstr ""
#: ../src/core/mutter.c:39
#: src/core/meta-close-dialog-default.c:161
msgid "_Wait"
msgstr "_Atendi"
#: src/core/mutter.c:39
#, c-format
#| msgid ""
#| "mutter %s\n"
#| "Copyright (C) 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
#| "This is free software; see the source for copying conditions.\n"
#| "There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A "
#| "PARTICULAR PURPOSE.\n"
msgid ""
"mutter %s\n"
"Copyright (C) 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
"Copyright © 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
"This is free software; see the source for copying conditions.\n"
"There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A "
"PARTICULAR PURPOSE.\n"
msgstr ""
"Mutero %s\n"
"Kopirajto (C) 2001-%d Havoc PENNIGTON, Red Hat, Inc., kaj aliaj\n"
"Ĉi tio estas libera programaro; rigardu la fontkodon por pli da informoj.\n"
"Ekzistas neniu GARANTIO; nek por NEGOCEBLO nek por ADAPTADO AL IU APARTA "
"Kopirajto © 2001-%d Havoc PENNIGTON, Red Hat, Inc., kaj aliaj\n"
"Ĉi tio estas libera programaro; rigardu la fontkodon por kondiĉoj pri "
"kopiado.\n"
"Ekzistas NENIU garantio; nek por NEGOCEBLO nek por ADAPTADO AL IU APARTA "
"CELO.\n"
#: ../src/core/mutter.c:53
#: src/core/mutter.c:53
msgid "Print version"
msgstr "Motri version"
#: ../src/core/mutter.c:59
#: src/core/mutter.c:59
msgid "Mutter plugin to use"
msgstr ""
#: ../src/core/prefs.c:2004
#: src/core/prefs.c:1997
#, c-format
msgid "Workspace %d"
msgstr "Laborspaco %d"
#: ../src/core/screen.c:525
#: src/core/screen.c:583
#, c-format
#| msgid ""
#| "Screen %d on display \"%s\" already has a window manager; try using the --"
#| "replace option to replace the current window manager.\n"
#| "Display \"%s\" already has a window manager; try using the --replace "
#| "option to replace the current window manager."
msgid ""
"Display \"%s\" already has a window manager; try using the --replace option "
"to replace the current window manager."
"Display “%s” already has a window manager; try using the --replace option to "
"replace the current window manager."
msgstr ""
"Ekrano \"%s\" jam havas fenestroadministrilon; provu uzi opcion --replace por "
"anstataŭigi la nunan fenestroadministrilon."
"Ekrano “%s” jam havas fenestroadministrilon; provu uzi la opcion --replace "
"por anstataŭigi la nunan fenestroadministrilon."
#: ../src/core/screen.c:607
#, c-format
msgid "Screen %d on display '%s' is invalid\n"
msgstr "Ekrano %d en vidigilo '%s' estas nevalida\n"
#: src/core/screen.c:668
#, fuzzy, c-format
#| msgid "Screen %d on display '%s' is invalid\n"
msgid "Screen %d on display “%s” is invalid\n"
msgstr "Ekrano %d en vidigilo “%s” estas nevalida\n"
#: ../src/core/util.c:118
#: src/core/util.c:120
msgid "Mutter was compiled without support for verbose mode\n"
msgstr "Mutero estis kompilita sen subteno por eksplicita reĝimo\n"
#: ../src/x11/session.c:1815
#: src/wayland/meta-wayland-tablet-pad.c:563
#, c-format
msgid "Mode Switch: Mode %d"
msgstr "Reĝim-ŝaltilo: Reĝimo %d"
#: src/x11/session.c:1815
msgid ""
"These windows do not support &quot;save current setup&quot; and will have to "
"be restarted manually next time you log in."
"These windows do not support save current setup and will have to be "
"restarted manually next time you log in."
msgstr ""
#: ../src/x11/window-props.c:549
#: src/x11/window-props.c:559
#, c-format
msgid "%s (on %s)"
msgstr "%s (ĉe %s)"

398
po/es.po
View File

@ -7,15 +7,14 @@
# Pablo Gonzalo del Campo <pablodc@bigfoot.com>,2002,2003.
# Francisco Javier F. Serrador <serrador@cvs.gnome.org>, 2004, 2005, 2006.
# Jorge González <jorgegonz@svn.gnome.org>, 2007, 2008, 2009, 2010, 2011.
# Daniel Mustieles <daniel.mustieles@gmail.com>, 2011, 2012, 2013, 2014, 2015, 2016, 2017.
# Daniel Mustieles <daniel.mustieles@gmail.com>, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018.
#
msgid ""
msgstr ""
"Project-Id-Version: mutter.master\n"
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?"
"product=mutter&keywords=I18N+L10N&component=general\n"
"POT-Creation-Date: 2017-02-16 01:44+0000\n"
"PO-Revision-Date: 2017-02-17 11:38+0100\n"
"Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/mutter/issues\n"
"POT-Creation-Date: 2018-07-07 09:58+0000\n"
"PO-Revision-Date: 2018-07-23 12:31+0200\n"
"Last-Translator: Daniel Mustieles <daniel.mustieles@gmail.com>\n"
"Language-Team: es <gnome-es-list@gnome.org>\n"
"Language: es\n"
@ -50,134 +49,118 @@ msgid "Move window to last workspace"
msgstr "Mover la ventana a la última área de trabajo"
#: data/50-mutter-navigation.xml:24
msgid "Move window one workspace to the left"
msgstr "Mover la ventana un área de trabajo a la izquierda"
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace to the right"
msgstr "Mover la ventana un área de trabajo a la derecha"
#: data/50-mutter-navigation.xml:30
msgid "Move window one workspace up"
msgstr "Subir la ventana un área de trabajo"
#: data/50-mutter-navigation.xml:33
#: data/50-mutter-navigation.xml:27
msgid "Move window one workspace down"
msgstr "Bajar la ventana un área de trabajo"
#: data/50-mutter-navigation.xml:36
#: data/50-mutter-navigation.xml:30
msgid "Move window one monitor to the left"
msgstr "Mover la ventana una pantalla a la izquierda"
#: data/50-mutter-navigation.xml:39
#: data/50-mutter-navigation.xml:33
msgid "Move window one monitor to the right"
msgstr "Mover la ventana una pantalla a la derecha"
#: data/50-mutter-navigation.xml:42
#: data/50-mutter-navigation.xml:36
msgid "Move window one monitor up"
msgstr "Subir la ventana una pantalla"
#: data/50-mutter-navigation.xml:45
#: data/50-mutter-navigation.xml:39
msgid "Move window one monitor down"
msgstr "Bajar la ventana una pantalla"
#: data/50-mutter-navigation.xml:49
#: data/50-mutter-navigation.xml:43
msgid "Switch applications"
msgstr "Cambiar entre aplicaciones"
#: data/50-mutter-navigation.xml:54
#: data/50-mutter-navigation.xml:48
msgid "Switch to previous application"
msgstr "Cambiar a la aplicación anterior"
#: data/50-mutter-navigation.xml:58
#: data/50-mutter-navigation.xml:52
msgid "Switch windows"
msgstr "Cambiar entre ventanas"
#: data/50-mutter-navigation.xml:63
#: data/50-mutter-navigation.xml:57
msgid "Switch to previous window"
msgstr "Cambiar a la ventana anterior"
#: data/50-mutter-navigation.xml:67
#: data/50-mutter-navigation.xml:61
msgid "Switch windows of an application"
msgstr "Cambiar entre ventanas de una aplicación"
#: data/50-mutter-navigation.xml:72
#: data/50-mutter-navigation.xml:66
msgid "Switch to previous window of an application"
msgstr "Cambiar a la ventana anterior de una aplicación"
#: data/50-mutter-navigation.xml:76
#: data/50-mutter-navigation.xml:70
msgid "Switch system controls"
msgstr "Cambiar entre controles del sistema"
#: data/50-mutter-navigation.xml:81
#: data/50-mutter-navigation.xml:75
msgid "Switch to previous system control"
msgstr "Cambiar al control del sistema anterior"
#: data/50-mutter-navigation.xml:85
#: data/50-mutter-navigation.xml:79
msgid "Switch windows directly"
msgstr "Cambiar entre ventanas directamente"
#: data/50-mutter-navigation.xml:90
#: data/50-mutter-navigation.xml:84
msgid "Switch directly to previous window"
msgstr "Cambiar directamente a la ventana anterior"
#: data/50-mutter-navigation.xml:94
#: data/50-mutter-navigation.xml:88
msgid "Switch windows of an app directly"
msgstr "Cambiar entre ventanas de una aplicación directamente"
#: data/50-mutter-navigation.xml:99
#: data/50-mutter-navigation.xml:93
msgid "Switch directly to previous window of an app"
msgstr "Cambiar directamente a la ventana anterior de una aplicación"
#: data/50-mutter-navigation.xml:103
#: data/50-mutter-navigation.xml:97
msgid "Switch system controls directly"
msgstr "Cambiar entre controles del sistema directamente"
#: data/50-mutter-navigation.xml:108
#: data/50-mutter-navigation.xml:102
msgid "Switch directly to previous system control"
msgstr "Cambiar directamente al control del sistema anterior"
#: data/50-mutter-navigation.xml:111
#: data/50-mutter-navigation.xml:105
msgid "Hide all normal windows"
msgstr "Ocultar todas las ventanas normales"
#: data/50-mutter-navigation.xml:114
#: data/50-mutter-navigation.xml:108
msgid "Switch to workspace 1"
msgstr "Cambiar al área de trabajo 1"
#: data/50-mutter-navigation.xml:117
#: data/50-mutter-navigation.xml:111
msgid "Switch to workspace 2"
msgstr "Cambiar al área de trabajo 2"
#: data/50-mutter-navigation.xml:120
#: data/50-mutter-navigation.xml:114
msgid "Switch to workspace 3"
msgstr "Cambiar al área de trabajo 3"
#: data/50-mutter-navigation.xml:123
#: data/50-mutter-navigation.xml:117
msgid "Switch to workspace 4"
msgstr "Cambiar al área de trabajo 4"
#: data/50-mutter-navigation.xml:126
#: data/50-mutter-navigation.xml:120
msgid "Switch to last workspace"
msgstr "Cambiar a la útima área de trabajo"
#: data/50-mutter-navigation.xml:129
msgid "Move to workspace left"
msgstr "Mover al área de trabajo de la izquierda"
#: data/50-mutter-navigation.xml:132
msgid "Move to workspace right"
msgstr "Mover al área de trabajo de la derecha"
#: data/50-mutter-navigation.xml:135
#: data/50-mutter-navigation.xml:123
msgid "Move to workspace above"
msgstr "Mover al área de trabajo de la arriba"
#: data/50-mutter-navigation.xml:138
#: data/50-mutter-navigation.xml:126
msgid "Move to workspace below"
msgstr "Mover al área de trabajo de abajo"
#: data/50-mutter-system.xml:6
#: data/50-mutter-system.xml:6 data/50-mutter-wayland.xml:6
msgid "System"
msgstr "Sistema"
@ -189,6 +172,10 @@ msgstr "Mostrar el elemento «ejecutar comando»"
msgid "Show the activities overview"
msgstr "Mostrar la vista de actividades"
#: data/50-mutter-wayland.xml:8
msgid "Restore the keyboard shortcuts"
msgstr "Restaurar los atajos de teclado"
#: data/50-mutter-windows.xml:6
msgid "Windows"
msgstr "Ventanas"
@ -214,54 +201,50 @@ msgid "Restore window"
msgstr "Restaurar la ventana"
#: data/50-mutter-windows.xml:18
msgid "Toggle shaded state"
msgstr "Cambiar el estado de enrollado"
#: data/50-mutter-windows.xml:20
msgid "Close window"
msgstr "Cerrar la ventana"
#: data/50-mutter-windows.xml:22
#: data/50-mutter-windows.xml:20
msgid "Hide window"
msgstr "Ocultar la ventana"
#: data/50-mutter-windows.xml:24
#: data/50-mutter-windows.xml:22
msgid "Move window"
msgstr "Mover la ventana"
#: data/50-mutter-windows.xml:26
#: data/50-mutter-windows.xml:24
msgid "Resize window"
msgstr "Redimensionar la ventana"
#: data/50-mutter-windows.xml:29
#: data/50-mutter-windows.xml:27
msgid "Toggle window on all workspaces or one"
msgstr "Conmutar la ventana en todas las áreas de trabajo o sólo en una"
#: data/50-mutter-windows.xml:31
#: data/50-mutter-windows.xml:29
msgid "Raise window if covered, otherwise lower it"
msgstr "Elevar la ventana si está cubierta, de lo contrario, bajarla"
#: data/50-mutter-windows.xml:33
#: data/50-mutter-windows.xml:31
msgid "Raise window above other windows"
msgstr "Elevar la ventana sobre las otras ventanas"
#: data/50-mutter-windows.xml:35
#: data/50-mutter-windows.xml:33
msgid "Lower window below other windows"
msgstr "Bajar la ventana por debajo de otras ventanas"
#: data/50-mutter-windows.xml:37
#: data/50-mutter-windows.xml:35
msgid "Maximize window vertically"
msgstr "Maximizar la ventana verticalmente"
#: data/50-mutter-windows.xml:39
#: data/50-mutter-windows.xml:37
msgid "Maximize window horizontally"
msgstr "Maximizar la ventana horizontalmente"
#: data/50-mutter-windows.xml:43
#: data/50-mutter-windows.xml:41
msgid "View split on left"
msgstr "Ver división a la izquierda"
#: data/50-mutter-windows.xml:47
#: data/50-mutter-windows.xml:45
msgid "View split on right"
msgstr "Ver división a la derecha"
@ -275,11 +258,6 @@ msgstr ""
"Modificador que usar para extender las operaciones de gestión sobre ventanas"
#: data/org.gnome.mutter.gschema.xml.in:8
#| msgid ""
#| "This key will initiate the \"overlay\", which is a combination window "
#| "overview and application launching system. The default is intended to be "
#| "the \"Windows key\" on PC hardware. It's expected that this binding "
#| "either the default or set to the empty string."
msgid ""
"This key will initiate the “overlay”, which is a combination window overview "
"and application launching system. The default is intended to be the “Windows "
@ -328,10 +306,6 @@ msgid "Workspaces are managed dynamically"
msgstr "Las áreas de trabajo se gestionan dinámicamente"
#: data/org.gnome.mutter.gschema.xml.in:41
#| msgid ""
#| "Determines whether workspaces are managed dynamically or whether there's "
#| "a static number of workspaces (determined by the num-workspaces key in "
#| "org.gnome.desktop.wm.preferences)."
msgid ""
"Determines whether workspaces are managed dynamically or whether theres a "
"static number of workspaces (determined by the num-workspaces key in org."
@ -370,10 +344,6 @@ msgid "Delay focus changes until the pointer stops moving"
msgstr "Retrasar el cambio de foco hasta detener el puntero"
#: data/org.gnome.mutter.gschema.xml.in:69
#| msgid ""
#| "If set to true, and the focus mode is either \"sloppy\" or \"mouse\" then "
#| "the focus will not be changed immediately when entering a window, but "
#| "only after the pointer stops moving."
msgid ""
"If set to true, and the focus mode is either “sloppy” or “mouse” then the "
"focus will not be changed immediately when entering a window, but only after "
@ -388,9 +358,6 @@ msgid "Draggable border width"
msgstr "Anchura arrastrable del borde"
#: data/org.gnome.mutter.gschema.xml.in:80
#| msgid ""
#| "The amount of total draggable borders. If the theme's visible borders are "
#| "not enough, invisible borders will be added to meet this value."
msgid ""
"The amount of total draggable borders. If the themes visible borders are "
"not enough, invisible borders will be added to meet this value."
@ -425,14 +392,63 @@ msgstr ""
"Cuando es cierto, las ventanas nuevas se colocarán siempre en el centro de "
"la pantalla activa del monitor."
#: data/org.gnome.mutter.gschema.xml.in:120
#: data/org.gnome.mutter.gschema.xml.in:107
msgid "Enable experimental features"
msgstr "Activar las características experimentales"
#: data/org.gnome.mutter.gschema.xml.in:108
#, fuzzy
#| msgid ""
#| "To enable experimental features, add the feature keyword to the list. "
#| "Whether the feature requires restarting the compositor depends on the "
#| "given feature. Any experimental feature is not required to still be "
#| "available, or configurable. Dont expect adding anything in this setting "
#| "to be future proof. Currently possible keywords: • “scale-monitor-"
#| "framebuffer” — makes mutter default to layout logical monitors in a "
#| "logical pixel coordinate space, while scaling monitor framebuffers "
#| "instead of window content, to manage HiDPI monitors. Does not require a "
#| "restart. • “remote-desktop” — enables remote desktop support. To support "
#| "remote desktop with screen sharing, “screen-cast” must also be enabled. • "
#| "“screen-cast” — enables screen cast support."
msgid ""
"To enable experimental features, add the feature keyword to the list. "
"Whether the feature requires restarting the compositor depends on the given "
"feature. Any experimental feature is not required to still be available, or "
"configurable. Dont expect adding anything in this setting to be future "
"proof. Currently possible keywords: • “scale-monitor-framebuffer” — makes "
"mutter default to layout logical monitors in a logical pixel coordinate "
"space, while scaling monitor framebuffers instead of window content, to "
"manage HiDPI monitors. Does not require a restart."
msgstr ""
"Para activar las características experimentales, añada la palabra clave de "
"la característica a la lista. Depende de la característica que se deba "
"reiniciar o no el compositor. Cualquier característica experimental puede no "
"estar disponible o ser configurable. No espere que lo que se añada en este "
"escenario sirva como prueba futura. Las palabras clave actualmente "
"disponibles son: • \"scale-monitor-framebuffer\" - convierte a mutter en la "
"manera predeterminada de disponer monitores lógicos en un espacio lógico de "
"coordenadas de píxeles, al escalar framebuffers de monitores framebuffers en "
"lugar del contenido de ventana, para administrar monitores HiDPI. No "
"requiere un reinicio. • \"remote-desktop\" — activa el escritorio remoto. "
"Para soportarlo con compartición de pantalla es necesario activar \"screen-"
"cast\" • \"screen-cast\" — activa el soporte de compartición de pantalla."
#: data/org.gnome.mutter.gschema.xml.in:141
msgid "Select window from tab popup"
msgstr "Seleccionar ventana de la pestaña emergente"
#: data/org.gnome.mutter.gschema.xml.in:125
#: data/org.gnome.mutter.gschema.xml.in:146
msgid "Cancel tab popup"
msgstr "Cancelar pestaña emergente"
#: data/org.gnome.mutter.gschema.xml.in:151
msgid "Switch monitor configurations"
msgstr "Cambiar la configuración del monitor"
#: data/org.gnome.mutter.gschema.xml.in:156
msgid "Rotates the built-in monitor configuration"
msgstr "Rota la configuración del monitor empotrado"
#: data/org.gnome.mutter.wayland.gschema.xml.in:6
msgid "Switch to VT 1"
msgstr "Cambiar al VT 1"
@ -481,74 +497,149 @@ msgstr "Cambiar al VT 11"
msgid "Switch to VT 12"
msgstr "Cambiar al VT 12"
#: data/org.gnome.mutter.wayland.gschema.xml.in:54
msgid "Re-enable shortcuts"
msgstr "Volver a activar los atajos"
#: data/org.gnome.mutter.wayland.gschema.xml.in:64
msgid "Allow grabs with Xwayland"
msgstr "Permitir capturas con Xwayland"
#: data/org.gnome.mutter.wayland.gschema.xml.in:65
msgid ""
"Allow keyboard grabs issued by X11 applications running in Xwayland to be "
"taken into account. For a X11 grab to be taken into account under Wayland, "
"the client must also either send a specific X11 ClientMessage to the root "
"window or be among the applications white-listed in key “xwayland-grab-"
"access-rules”."
msgstr ""
#: data/org.gnome.mutter.wayland.gschema.xml.in:77
msgid "Xwayland applications allowed to issue keyboard grabs"
msgstr "Aplicaciones de Xwayland que pueden capturar el teclado"
#: data/org.gnome.mutter.wayland.gschema.xml.in:78
msgid ""
"List the resource names or resource class of X11 windows either allowed or "
"not allowed to issue X11 keyboard grabs under Xwayland. The resource name or "
"resource class of a given X11 window can be obtained using the command "
"“xprop WM_CLASS”. Wildcards “*” and jokers “?” in the values are supported. "
"Values starting with “!” are blacklisted, which has precedence over the "
"whitelist, to revoke applications from the default system list. The default "
"system list includes the following applications: "
"“@XWAYLAND_GRAB_DEFAULT_ACCESS_RULES@” Users can break an existing grab by "
"using the specific keyboard shortcut defined by the keybinding key “restore-"
"shortcuts”."
msgstr ""
#. TRANSLATORS: This string refers to a button that switches between
#. * different modes.
#.
#: src/backends/meta-input-settings.c:1759
#: src/backends/meta-input-settings.c:2325
#, c-format
#| msgid "Mode Switch: Mode %d"
msgid "Mode Switch (Group %d)"
msgstr "Cambiar modo (grupo %d)"
#. TRANSLATORS: This string refers to an action, cycles drawing tablets'
#. * mapping through the available outputs.
#.
#: src/backends/meta-input-settings.c:1781
#: src/backends/meta-input-settings.c:2348
msgid "Switch monitor"
msgstr "Cambiar monitor"
#: src/backends/meta-input-settings.c:1783
#: src/backends/meta-input-settings.c:2350
msgid "Show on-screen help"
msgstr "Mostrar la ayuda en pantalla"
#: src/backends/meta-monitor-manager.c:675
#: src/backends/meta-monitor-manager.c:907
msgid "Built-in display"
msgstr "Pantalla integrada"
#: src/backends/meta-monitor-manager.c:698
#: src/backends/meta-monitor-manager.c:930
msgid "Unknown"
msgstr "Desconocida"
#: src/backends/meta-monitor-manager.c:700
#: src/backends/meta-monitor-manager.c:932
msgid "Unknown Display"
msgstr "Pantalla desconocida"
#. TRANSLATORS: this is a monitor vendor name, followed by a
#. * size in inches, like 'Dell 15"'
#.
#: src/backends/meta-monitor-manager.c:708
#: src/backends/meta-monitor-manager.c:940
#, c-format
msgid "%s %s"
msgstr "%s %s"
#. This probably means that a non-WM compositor like xcompmgr is running;
#. * we have no way to get it to exit
#: src/compositor/compositor.c:471
#: src/compositor/compositor.c:481
#, c-format
#| msgid ""
#| "Another compositing manager is already running on screen %i on display "
#| "\"%s\"."
msgid ""
"Another compositing manager is already running on screen %i on display “%s”."
msgstr ""
"Ya existe un gestor de composición ejecutándose en la monitor %i, pantalla "
"«%s»."
#: src/core/bell.c:194
#: src/core/bell.c:254
msgid "Bell event"
msgstr "Evento de campana"
#: src/core/main.c:191
msgid "Disable connection to session manager"
msgstr "Desactivar conexión al gestor de sesión"
#: src/core/main.c:197
msgid "Replace the running window manager"
msgstr "Reemplazar el gestor de ventanas en ejecución"
#: src/core/main.c:203
msgid "Specify session management ID"
msgstr "Especificar el ID se gestión de sesión"
#: src/core/main.c:208
msgid "X Display to use"
msgstr "Pantalla X que usar"
#: src/core/main.c:214
msgid "Initialize session from savefile"
msgstr "Inicializar sesión desde el archivo de salvaguarda"
#: src/core/main.c:220
msgid "Make X calls synchronous"
msgstr "Hacer que las llamadas a las X sean síncronas"
#: src/core/main.c:227
msgid "Run as a wayland compositor"
msgstr "Ejecutar como compositor Wayland"
#: src/core/main.c:233
msgid "Run as a nested compositor"
msgstr "Ejecutar como compositor anidado"
#: src/core/main.c:239
msgid "Run wayland compositor without starting Xwayland"
msgstr "Ejecutar el compositor wayland sin iniciar Xwayland"
#: src/core/main.c:247
msgid "Run as a full display server, rather than nested"
msgstr "Ejecutar como servidor completo, en lugar de anidado"
#: src/core/main.c:253
msgid "Run with X11 backend"
msgstr "Ejecutar con «backend» de X11"
#. Translators: %s is a window title
#: src/core/delete.c:127
#: src/core/meta-close-dialog-default.c:148
#, c-format
msgid "“%s” is not responding."
msgstr "«%s» no está respondiendo."
#: src/core/delete.c:129
#: src/core/meta-close-dialog-default.c:150
msgid "Application is not responding."
msgstr "La aplicación no está respondiendo."
#: src/core/delete.c:134
#: src/core/meta-close-dialog-default.c:155
msgid ""
"You may choose to wait a short while for it to continue or force the "
"application to quit entirely."
@ -556,64 +647,16 @@ msgstr ""
"Puede elegir esperar un rato para ver si continua o forzar la aplicación "
"para cerrarla completamente."
#: src/core/delete.c:141
#: src/core/meta-close-dialog-default.c:162
msgid "_Force Quit"
msgstr "_Forzar la salida"
#: src/core/delete.c:141
#: src/core/meta-close-dialog-default.c:162
msgid "_Wait"
msgstr "_Esperar"
#: src/core/display.c:608
#, c-format
#| msgid "Failed to open X Window System display '%s'\n"
msgid "Failed to open X Window System display “%s”\n"
msgstr "Ocurrió un error al abrir la pantalla de X Window System «%s»\n"
#: src/core/main.c:189
msgid "Disable connection to session manager"
msgstr "Desactivar conexión al gestor de sesión"
#: src/core/main.c:195
msgid "Replace the running window manager"
msgstr "Reemplazar el gestor de ventanas en ejecución"
#: src/core/main.c:201
msgid "Specify session management ID"
msgstr "Especificar el ID se gestión de sesión"
#: src/core/main.c:206
msgid "X Display to use"
msgstr "Pantalla X que usar"
#: src/core/main.c:212
msgid "Initialize session from savefile"
msgstr "Inicializar sesión desde el archivo de salvaguarda"
#: src/core/main.c:218
msgid "Make X calls synchronous"
msgstr "Hacer que las llamadas a las X sean síncronas"
#: src/core/main.c:225
msgid "Run as a wayland compositor"
msgstr "Ejecutar como compositor Wayland"
#: src/core/main.c:231
msgid "Run as a nested compositor"
msgstr "Ejecutar como compositor anidado"
#: src/core/main.c:239
msgid "Run as a full display server, rather than nested"
msgstr "Ejecutar como servidor completo, en lugar de anidado"
#: src/core/mutter.c:39
#, c-format
#| msgid ""
#| "mutter %s\n"
#| "Copyright (C) 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
#| "This is free software; see the source for copying conditions.\n"
#| "There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A "
#| "PARTICULAR PURPOSE.\n"
msgid ""
"mutter %s\n"
"Copyright © 2001-%d Havoc Pennington, Red Hat, Inc., and others\n"
@ -636,16 +679,22 @@ msgstr "Imprimir versión"
msgid "Mutter plugin to use"
msgstr "Complemento de mutter que usar"
#: src/core/prefs.c:1997
#: src/core/prefs.c:1915
#, c-format
msgid "Workspace %d"
msgstr "Área de trabajo %d"
#: src/core/screen.c:580
#: src/core/util.c:120
msgid "Mutter was compiled without support for verbose mode\n"
msgstr "Mutter fue compilado sin soporte para modo prolijo\n"
#: src/wayland/meta-wayland-tablet-pad.c:567
#, c-format
msgid "Mode Switch: Mode %d"
msgstr "Cambiar modo: modo %d"
#: src/x11/meta-x11-display.c:666
#, c-format
#| msgid ""
#| "Display \"%s\" already has a window manager; try using the --replace "
#| "option to replace the current window manager."
msgid ""
"Display “%s” already has a window manager; try using the --replace option to "
"replace the current window manager."
@ -653,25 +702,21 @@ msgstr ""
"La pantalla «%s» ya tiene un gestor de ventanas; pruebe a usar la opción «--"
"replace» para reemplazar el gestor de ventanas activo."
#: src/core/screen.c:665
#: src/x11/meta-x11-display.c:1010
msgid "Failed to initialize GDK\n"
msgstr "Falló al inicializar GDK\n"
#: src/x11/meta-x11-display.c:1034
#, c-format
msgid "Failed to open X Window System display “%s”\n"
msgstr "Ocurrió un error al abrir la pantalla de X Window System «%s»\n"
#: src/x11/meta-x11-display.c:1117
#, c-format
#| msgid "Screen %d on display '%s' is invalid\n"
msgid "Screen %d on display “%s” is invalid\n"
msgstr "La ventana %d en la pantalla «%s» no es válida\n"
#: src/core/util.c:120
msgid "Mutter was compiled without support for verbose mode\n"
msgstr "Mutter fue compilado sin soporte para modo prolijo\n"
#: src/wayland/meta-wayland-tablet-pad.c:563
#, c-format
msgid "Mode Switch: Mode %d"
msgstr "Cambiar modo: modo %d"
#: src/x11/session.c:1815
#| msgid ""
#| "These windows do not support &quot;save current setup&quot; and will have "
#| "to be restarted manually next time you log in."
#: src/x11/session.c:1819
msgid ""
"These windows do not support “save current setup” and will have to be "
"restarted manually next time you log in."
@ -679,11 +724,26 @@ msgstr ""
"Estas ventanas no soportan «guardar la configuración actual» y tendrán que "
"reiniciarse manualmente la próxima vez que inicie una sesión."
#: src/x11/window-props.c:559
#: src/x11/window-props.c:565
#, c-format
msgid "%s (on %s)"
msgstr "%s (on %s)"
#~ msgid "Move window one workspace to the left"
#~ msgstr "Mover la ventana un área de trabajo a la izquierda"
#~ msgid "Move window one workspace to the right"
#~ msgstr "Mover la ventana un área de trabajo a la derecha"
#~ msgid "Move to workspace left"
#~ msgstr "Mover al área de trabajo de la izquierda"
#~ msgid "Move to workspace right"
#~ msgstr "Mover al área de trabajo de la derecha"
#~ msgid "Toggle shaded state"
#~ msgstr "Cambiar el estado de enrollado"
#~ msgid "background texture could not be created from file"
#~ msgstr "no se pudo crear la textura de fondo a partir de archivo"

1961
po/et.po

File diff suppressed because it is too large Load Diff

Some files were not shown because too many files have changed in this diff Show More