Compare commits

...

1313 Commits

Author SHA1 Message Date
isa
c8892e7e73 Use Super+Tab to change realms 2024-02-15 15:58:16 -05:00
isa
6f159728d3 Add bla bla 2024-02-15 15:40:37 -05:00
d85bd654a3 Don't display label on full-screen windows 2021-12-13 14:21:01 -05:00
7d08587000 Ensure that Main.overview._overview exists before accessing it. 2021-12-13 11:30:43 -05:00
c93e5e6431 Citadel changes to gnome-shell 2021-12-03 14:04:05 -05:00
Florian Müllner
a1b537eebf Bump version to 41.1
Update NEWS.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2022>
2021-11-04 14:09:52 +01:00
Florian Müllner
d3c6dd75bb Revert !1999
The changes introduce crashes, so back out until we
figure those out.

This reverts commits ceee53aa0a and 5d5bfe492c.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2022>
2021-11-04 14:08:05 +01:00
Florian Müllner
a369371519 Revert "layout: Exclude hidden actors from struts"
The change unvealed a series of mutter bugs that for most
users are worse than the issue that was fixed. So revert
the change on stable branches until the mutter side is
fixed.

This reverts commit cd1102ff30.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2022>
2021-11-03 23:50:32 +01:00
Christian Kirbach
03a3ce062a Update German translation 2021-11-03 20:33:48 +00:00
Aleksandr Melman
6456fa0df4 Update Russian translation 2021-11-03 17:53:21 +00:00
Hugo Carvalho
1ec0f01cfc Update Portuguese translation 2021-11-03 11:50:26 +00:00
Kukuh Syafaat
0512d1fff4 Update Indonesian translation 2021-11-03 10:04:19 +00:00
Rafael Fontenelle
ba32dcc16b Update Brazilian Portuguese translation 2021-11-03 01:19:46 +00:00
Anders Jonsson
edcee44c72 Update Swedish translation 2021-11-02 21:05:16 +00:00
Matej Urbančič
be32cab39b Update Slovenian translation 2021-11-02 16:54:37 +00:00
Yuri Chornoivan
f8cdac49c6 Update Ukrainian translation 2021-11-02 16:31:49 +00:00
Florian Müllner
b6b9e755c7 dbusServices/extensions: Only allow one dialog at a time
Showing multiple preference dialogs at the same time (for instance
by repeated `gnome-extensions prefs` calls) may or may not work as
expected, depending on whether any of the dialogs is modal or not
(read: opened via the Extensions app).

The easiest way to address this is to disallow more than a single
dialog at the time. It's arguably also the more predictable behavior,
and means extensions don't have to deal with inconsistent state
caused by multiple dialogs.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4564

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2013>
(cherry picked from commit b93342f72e)
2021-11-02 15:39:08 +01:00
Florian Müllner
1297d8dc30 dbusServices/extensions: Fix shutdown after showing prefs
GTK4 relies entirely on refcounting for cleanup (that is,
there is no longer a destroy() method that forces a dispose
run regardless of the refcount).

Unfortunately that makes cleanup harder in (some) language
bindings, where an object may be kept alive implicitly by
closures etc.

Address this by releasing the hold count when the window
is closed rather than when it is destroyed.

This isn't the most elegant, but it ensure that the service
doesn't get stuck if an extension doesn't carefully clean
up everything in its prefs widget.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4564

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2013>
(cherry picked from commit 4d2b008966)
2021-11-02 15:39:08 +01:00
Florian Müllner
fd60591bb3 extensions-tool/prefs: Log D-Bus errors
We currently ignore any error that may occur when calling the
OpenExtensionPrefs D-Bus method. Right now such an error is highly
unlikely, given that we already checked that we are running under
gnome-shell and the extension in question exists and has prefs.

We'll soon make sure that only one dialog is shown at any time,
which is an error that we can realistically expect, so handle that
properly.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4564

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2013>
(cherry picked from commit 09ed1c533c)
2021-11-02 15:39:08 +01:00
Florian Müllner
1b5ff77d02 extensions-tool: Add missing newline
Unlike g_warning() and friends, g_printerr() does not append
a trailing newline.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4564

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2013>
(cherry picked from commit 79f448958b)
2021-11-02 15:39:08 +01:00
Sebastian Keller
488fb46edf shell/app: Don't move all workspace windows to their startup workspace
Windows from some applications, such as guake, are created as showing on
all workspaces. When these windows are put on the workspaces via
set_workspace_state() during construction, the first time the window is
added to a workspace in the loop triggers the shell app tracker which
then tries to move the window to its startup workspace. This makes the
window unsticky which triggers another set_workspace_state() which
tries to remove the window from all workspaces, but currently it is only
on the first one and then adds it to the startup workspace. Once that is
finished, the first set_workspace_state() continues adding the window
to the remaining workspaces, despite the window now no longer having
on_all_workspaces set to true.

When the window is now unmanaged, the window according to its internal
state is only found on the startup workspace, so it will only be removed
from that. This causes the assertion to fail that checks that the window
is no longer present on any workspace after this.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4720

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2014>
(cherry picked from commit bc32a52108)
2021-11-02 15:38:54 +01:00
Carlos Garnacho
ddf03b5d94 Revert "st: Only use clutter_actor_invalidate_paint_volume() if the API exists"
Since we are past the 40 API change hurdle, it is safe to revert this
commit.

This reverts commit 1cefd589da.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2010>
(cherry picked from commit ff4ff66498)
2021-11-02 15:38:35 +01:00
Florian Müllner
fc680556f5 environment: Apply autoReverse/repeatCount to all transitions
Like the old Tweener API, ease() allows to transition multiple
properties at once. If autoReverse or repeatCount are specified,
they should apply to all transitions, but right now we only set
them for the first one.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2007>
(cherry picked from commit cc5cc0d653)
2021-11-02 15:38:20 +01:00
Carlos Garnacho
a2f6efa5e1 inputMethod: Do not reset invisible preedit on focus_out
If the preedit is in invisible state, the last preedit string that
was sent around is already null, so there is no need to clear the preedit
in that case.

(Cherry-picked from commit 0177560952)
2021-11-01 18:34:57 +01:00
Carlos Garnacho
62fce73aee inputMethod: Do not communicate preedit text change on reset
This is now done in the ClutterInputFocus for us, since
https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1940. There
is no need to duplicate this call, and it happens to cause undesired
scrolling to content in some cases when this reset happens during
a change in the IM focused client state.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4647

(Cherry-picked from commit 047691b0d3)
2021-11-01 18:34:46 +01:00
Carlos Garnacho
b1538fcb20 inputMethod: Equate empty preedit string to null
If we get '' from the IM as the preedit string, it is pretty safe
to handle it as "no preedit" altogether.

(Cherry-picked from commit 286cfdc6d4)
2021-11-01 18:34:27 +01:00
eshagh shahidani
025588b89a Update Persian translation 2021-10-25 20:42:25 +00:00
Rūdolfs Mazurs
ce2ae0642f Update Latvian translation 2021-10-25 17:56:42 +00:00
Selyan Slimane AMIRI
8c5d552cc2 Update Kabyle translation 2021-10-16 14:35:12 +00:00
Florian Müllner
2dcbf5f33b theme: Fix high-contrast switches
Commit 9d6fcfdc85 dropped the different us/intl switches, but
the high-contrast theme was left out at the time (and therefore
ends up with the regular assets now).

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4672

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2000>
2021-10-14 14:12:10 +00:00
Ray Strode
ddb6276a49 st/password-entry: Fix crash when DConf changes after StEntry is destroyed
commit 8721c5db37 made StPasswordEntry
honor the 'disable-show-password' setting.

Unfortunately, it introduced a lifecycle bug where the signal handler
for noticing setting changes can out live the entry itself.

This commit fixes the problem by using g_signal_connect_object

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2004>
2021-10-12 15:27:35 -04:00
Marek Černocký
c1c0b34d77 Updated Czech translation 2021-10-10 17:18:11 +02:00
Carlos Garnacho
4e5ddc5459 ci: Install mutter again on coverity job
This job "needs" the build job and thus gets its artifacts, but
it will not inherit the environment where we already installed
Mutter in /usr. This apparently broke once there was a more
recent mutter-clutter .pc file to look up.

Install Mutter in /usr again in this job, so the new build for
coverity finds all dependencies.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1979>
2021-10-08 16:17:04 +00:00
Ray Strode
ceee53aa0a unlockDialog: Properly reset auth prompt when showing it
If a user hits escape twice really fast when coming back to
their machine to unlock it, they made end up getting presented
with a non-functional unlock screen that doesn't show their
user icon and doesn't ask for a password.

This is because showPrompt assumes that if an auth prompt already
exists, it's ready to go. That may not be true, if it's in the
process of getting torn down at the time because it's in the middle
of a cancel animation.

This commit solves the problem by ensuring the auth prompt is always
in a fresh reset state before showing it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1999>
2021-10-08 11:56:23 -04:00
Ray Strode
5d5bfe492c unlockDialog: Don't create AuthDialog just to finish it
If the the unlock dialog gets finished before an auth dialog is
created, the code currently creates one just to tell it to finish.

This commit changes the code to skip creating the auth dialog in
that case.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1999>
2021-10-08 11:13:11 -04:00
Florian Müllner
4d1ce0de41 notificationDaemon: Fix sound-file support
When commit 25bfe99ed5 replaced the thin libcanberra wrapper
with the (then) new MetaSoundPlayer API, it missed that the latter
expects files as GFile instead of a file path.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1991>
2021-10-06 17:39:01 +00:00
Florian Müllner
a3dcdaae30 screenshot: Unrestrict PickColor
Commit dd2cd6286c restricted callers of the screenshot methods to
portal implementations, gnome-settings-daemon and gnome-screenshot.

That restriction does make sense for the actual screenshot methods,
but `PickColor` is actually used by GTK in its color picker (and
therefore may be called from arbitrary applications).

Fix this by unrestricting access to `PickColor` again. Considering that
the method is always interactive, it's not very privacy/security-sensitive
anyway.

https://gitlab.gnome.org/GNOME/gtk/-/issues/4283

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1990>
2021-10-06 17:34:18 +00:00
Jakub Steiner
82e16a206f Add screen protect status icons
- OSD needs them

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4662

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1996>
2021-10-06 17:29:25 +00:00
Goran Vidović
c0b89381ac Update Croatian translation 2021-10-06 17:08:50 +00:00
Florian Müllner
7f77b6f054 welcomeDialog: Fix title translation
Translators translate the format string ('... GNOME %s'), not the
substituted one ('... GNOME 41').

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4669

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1998>
2021-10-05 15:05:18 +02:00
Christian Hergert
380d2db1d9 inputMethod: Clear preeditStr before reset
Previously, these were performed in a different order before GNOME 41.
During some other changes they were swapped.

However, this causes both GTK 3 and GTK 4 applications to scroll to
incorrect positions from the preedit change.

Fixes #4647
Fixes GNOME/gtk#4289
Fixes GNOME/gnome-builder#1536
Fixes GNOME/gnome-builder#1531

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1993>
2021-09-30 17:12:02 +00:00
Marco Trevisan (Treviño)
2bcc6c09ed st/icon: Ensure icons are updated if theme node is invalid
Icons that are changed while an actor is not mapped may not have a theme
node associated with, and thus we'd end up not updating them at all.
In fact we return early in st_update_icon(), and this was not an issue
until commit 0b1dfbf6f3, because we'd end up to update the icon anyways
once the style was changed (and so with a valid theme node), but since
such change we might not updating the icon if no theme detail changed.

To prevent this, add a flag to require an icon update when the theme
changed, if no successfully update happened earlier.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4568
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1983>
2021-09-30 18:55:11 +02:00
Sveinn í Felli
3685cb15c6 Update Icelandic translation 2021-09-30 13:09:18 +00:00
Yaron Shahrabani
5dfc3c1ef8 Update Hebrew translation 2021-09-27 08:14:57 +00:00
Emin Tufan Çetin
b837ca4031 Update Turkish translation 2021-09-26 12:18:02 +00:00
Ngọc Quân Trần
20c937f5a0 Update Vietnamese translation 2021-09-26 01:29:27 +00:00
Jonas Ådahl
563437de91 Always assume GLSL is supported
The support for GLSL has been advertised as unconditionally supported by
mutter for a while, and has now lost the 'GLSL' feature completely. Lets
remove the checks.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1985>
2021-09-21 16:37:01 +02:00
Марко Костић
1bf446b373 Update Serbian translation 2021-09-20 04:23:46 +00:00
Florian Müllner
0bf515eb10 Bump version to 41.0
Update NEWS.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1981>
2021-09-19 12:47:55 +02:00
Efstathios Iosifidis
8cb689e2c5 Update Greek translation 2021-09-17 18:42:18 +00:00
Jordi Mas
8a5361c05c Update Catalan translation 2021-09-16 21:31:00 +02:00
Alan Mortensen
bee43816f4 Updated Danish translation 2021-09-16 17:06:09 +02:00
Alexander Shopov
f394f2d14a Update Bulgarian translation 2021-09-15 12:04:45 +00:00
Jiri Grönroos
e6c903f4aa Update Finnish translation 2021-09-14 10:18:57 +00:00
Quentin PAGÈS
ffbbdf62fe Update Occitan translation 2021-09-13 19:52:55 +00:00
Nathan Follens
dbdeeff0a0 Update Dutch translation 2021-09-13 14:59:11 +00:00
Piotr Drąg
9cb6d0d4a9 Update Polish translation 2021-09-11 13:49:13 +00:00
Balázs Úr
b1bcf2be7a Update Hungarian translation 2021-09-10 23:09:03 +00:00
Aman Alam
767f2c533a Update Punjabi translation 2021-09-09 03:40:05 +00:00
Jordi Mas
a2d003cde6 Update Catalan translation 2021-09-07 22:32:37 +02:00
Goran Vidović
9ef7e0cf8c Update Croatian translation 2021-09-07 19:49:49 +00:00
Goran Vidović
f8ec7ea1b5 Update Croatian translation 2021-09-07 19:48:16 +00:00
Florian Müllner
72e3e60411 Bump version to 41.rc.1
Update NEWS.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1976>
2021-09-07 15:15:11 +02:00
Florian Müllner
0eff22ebcd build: Add option to turn off tests
St's theme test now requires the libmutter-test library, which is only
built when tests are enabled. Instead of mandating a particular build
configuration in mutter, add a corresponding option in gnome-shell as
well.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1975>
2021-09-07 12:53:47 +00:00
Florian Müllner
2e8fdcd8f1 build: Check sassc errors when generating stylesheets
We currently just call sassc, but don't check its return value. That
means as long as sassc is available, the script (and therefore the
newly added dist CI job) will succeed.

Make sure we fail on failure.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1974>
2021-09-07 12:47:42 +00:00
Daniel Șerbănescu
f6c6523cd4 Update Romanian translation 2021-09-05 09:48:58 +00:00
Florian Müllner
743044291d Bump version to 41.rc
Update NEWS.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1971>
2021-09-05 09:35:45 +02:00
Florian Müllner
e9d6468609 ci: Add dist job
So far, releases are done locally by invoking `meson dist`.

We can do better and leverage the existing CI infrastructure, to get
to the following release workflow:

 - bump version in meson.build, update NEWS etc.
 - open merge request for the release
 - merge when the pipeline (including dist check) succeeds
 - tag the release
 - wait for the tag pipeline to spit out the tarball artifact

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1968>
2021-09-05 01:28:46 +02:00
Florian Müllner
d8b88c24d9 ci: Reindent yaml configuration
Most GNOME projects have settled on a 2-space indentation, so switch
to that. This will ease the ongoing copy+paste between projects :-)

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1968>
2021-09-04 23:46:46 +02:00
Florian Müllner
537f754fb0 build: Move metainfo version check into distscript
The time we really care about current release information in appdata is
when preparing a release, not during regular builds.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1968>
2021-09-04 23:46:46 +02:00
Florian Müllner
418d86a16f build: Check NEWS for version
I don't think this ever happened to me, but it can't hurt enforcing
that every release has a corresponding NEWS entry.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1968>
2021-09-04 23:46:46 +02:00
Changwoo Ryu
4d4f3d25d8 Update Korean translation 2021-09-04 14:59:50 +00:00
Robert Mader
483d1b3177 shell/util: Remove get_content_for_window_actor()
It got replaced by `meta_window_actor_paint_to_content()`.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1879>
2021-09-04 12:10:51 +02:00
Robert Mader
36a1fb78cd windowManager: Use MetaWindowActor.paint_to_content() for window effects
Previously we used `get_image()`, which returned `cairo_surface`,
in order to create a `ClutterContent` with a screenshot of the
`MetaWindowActor`. This added a roundtrip from GPU to CPU memory.

Instead, use the new `paint_to_content()` API which lets us use a
`CoglTexture` directly as source of our `ClutterContent`.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1879>
2021-09-04 10:08:10 +00:00
Carlos Garnacho
46f2c29acc inputMethod: Use update-preedit-with-mode signal
This signal announces the preferred commit mode of the preedit text when
the input context is reset. Keep this mode around, and ensure to honor this
mode (e.g. maybe commit the preedit string) whenever the input method would
be reset.

This is delegated to the internal layers, so propagate this mode via
clutter_input_method_set_preedit_text().

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1929>
2021-09-03 22:32:36 +00:00
Florian Müllner
dd2cd6286c screenshot: Restrict callers
The shell D-Bus API was always meant as a private API for core
components, so enforce that by limiting caller to a list of
allowed well-known names.

Applications that want to request a screenshot can use the corresponding
desktop portal.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3943

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1970>
2021-09-03 21:34:58 +00:00
Florian Müllner
a628bbc485 shellDBus: Restrict callers
The org.gnome.Shell interface provides a private API to other core
components to implement desktop functionalities like Settings or
global keybindings. It is not meant as a public API, so limit it
to a set of expected callers.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3943

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1970>
2021-09-03 21:34:58 +00:00
Florian Müllner
3adad0da81 shellDBus: Implement all methods asynchronously
In order to restrict callers, we will need access to the invocation,
not just the unpacked method parameters.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3943

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1970>
2021-09-03 21:34:58 +00:00
Florian Müllner
2a3e297218 introspect: Split out DBusSenderChecker
Restricting callers to a list of allowed senders is useful for
other D-Bus services as well, so split out the existing code
into a reusable class.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3943

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1970>
2021-09-03 21:34:58 +00:00
Florian Müllner
d474781325 data: Remove now unused "introspect" setting
https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3943

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1970>
2021-09-03 21:34:58 +00:00
Florian Müllner
317f0f5fe0 introspect: Use MetaContext:unsafe-mode instead of setting
The property was added precisely for this purpose, except that its
name isn't tied to the introspect API.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3943

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1970>
2021-09-03 21:34:58 +00:00
Florian Müllner
3b9e672a09 introspect: Make invocation check error-based
If we throw an error when the invocation isn't allowed instead of
returning false, we can simply return that error instead of duplicating
the error handling.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1970>
2021-09-03 21:34:58 +00:00
Florian Müllner
7298ee23e9 shellDBus: Use MetaContext:unsafe-mode to restrict Eval()
The Eval() method is unarguably the most sensitive D-Bus method
we expose, since it allows running arbitrary code in the compositor.

It is currently tied to the `development-tools` settings that is
enabled by default. As users have become accustomed to the built-in
commands that are enabled by the same setting (restart, lg, ...),
that default cannot easily be changed.

In order to restrict the method without affecting the rather harmless
commands, guard it by the new MetaContext:unsafe-mode property instead
of the setting.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3943

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1970>
2021-09-03 21:34:58 +00:00
Florian Müllner
3bee7c7f4b panel: Show warning indicator when unsafe-mode is on
MetaContext added an unsafe-mode property, which we will use to restrict
a number of privileged operations unless it is enabled. It is meant to
only be enabled temporarily for development/debugging purposes, so add
a scary icon to the top bar as a reminder to turn it off again.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3943

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1970>
2021-09-03 21:34:58 +00:00
Boyuan Yang
fb177a1cae Update Chinese (China) translation 2021-09-03 18:09:05 +00:00
Danial Behzadi
eac04888e2 Update Persian translation 2021-09-03 10:47:09 +00:00
Florian Müllner
0fd205ce54 boxpointer: Fix positioning with non-widget sources
Commit 16d371873 lifted the requirement for source actors to be
widgets, then got it wrong :rolling_eyes:

The content box is expected to be in actor coordinates, so the
allocation must be translated to (0, 0).

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4593

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1969>
2021-09-01 20:22:58 +00:00
Aurimas Černius
bc09c1ca24 Updated Lithuanian translation 2021-09-01 23:06:41 +03:00
José Expósito
757e766a11 windowManager: Discard workspace scroll smooth events
Since touchpad smooth scroll events with source finger are handled by
the swipeTracker, the workspace scroll handler can focus on discrete
events.

Thanks to Mutter emulating discrete scroll events, see
meta_seat_impl_notify_scroll_continuous_in_impl in meta-seat-impl.c,
it is safe to ignore smooth scroll in the workspace scroll handler
and handle exclusively discrete events.

In addition, once high-resolution scroll events land in Mutter [1], a
mouse will be able generate non emulated smooth scroll events that
should be ignored in favour of the discrete scroll events.
Otherwise, a single mouse wheel click will scroll through multiple
workspaces at once.

[1] https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1962

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1959>
2021-09-01 17:25:01 +00:00
Florian Müllner
cd1102ff30 layout: Exclude hidden actors from struts
Currently we only exclude hidden actors from the input region,
but not from struts. This is an oversight that went unnoticed
until now, probably because we didn't consider the work area
in the overview until recently.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4569

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1963>
2021-09-01 17:15:40 +00:00
Sebastian Keller
2ee323e37e keyboard: Ensure chrome input region is updated after slide animation
The keyboard is placed outside of the screen when shown and then slides
in via a transition that changes the translate-y property. This
translation does not affect the allocation of the Keyboard actor and as
such does not trigger any of the signals LayoutManager is connected to
to update the input region. This means the input region remains at the
original position of the actor outside of the screen and as a result on
X11 clicks will go through to the underlying window.

There was a workaround for this by queuing a relayout at the end of the
transition, but this stopped working due to optimizations avoiding
unnecessary allocation changes.

This updates that workaround to toggle the visibility of the actor
instead, which is the other signal that LayoutManager reacts to. Once
ClutterActor provides better ways to react to transforms this can
hopefully be removed entirely.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4556
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1955>
2021-09-01 18:37:56 +02:00
Raghuveer Kasaraneni
07579f05f6 dash: Fixes wrong separator position
Sometimes when an icon is dragged and dropped in Dash, one Favourite app icon
can appear to the right of Dash separator. This can happen when available system
resources are low and the PlaceHolder destroy animation is delayed and the
corresponding container child is still present. With this commit the separator
position is calculated correctly, even when the animation is pending.

Fixes #3966, #3799

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1804>
2021-09-01 15:10:14 +00:00
Sebastian Keller
b90a6d6b14 workspace: Move fading minimized windows out of allocation
eee2ccac fixed window opacity being changed outside of transitions but
resulted in the final step of the transition, that would set the window
to fully opaque, being missed.

This change now moves the opacity change entirely out of allocation and
instead follows the adjustment changes directly, which still fixes the
original bug and ensures the opacity is also applied for the last step
in the transition.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4561
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1957>
2021-09-01 15:02:47 +00:00
Evan Welsh
0d8e0025d6 init: Set console log domain
GJS added a console module that extensions may start using. To ensure that
extensions using console.log() and similar functions don't show up as
'Gjs-Console' in users' system logs, we should call setConsoleLogdomain()
with 'GNOME Shell'.

This GJS API addition is only accessible using ECMAScript Modules (ESM),
this commit moves shell startup to a small init.js module and adapts
CI jobs to either handle or ignore it.

We can drop the .jscheckignore file when future versions of SpiderMonkey
allow for compile checks without validating module specifiers.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1958>
2021-09-01 14:55:47 +00:00
Florian Müllner
ef70364e81 cleanup: Replace non-standard ByteArray module
gjs landed support for TextDecoder/TextEncoder. Use those instead
of gjs' own ByteArray module.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1946>
2021-09-01 14:49:30 +00:00
Ivan Molodetskikh
b21b43e318 workspace: Update bg border radius in constructor
Otherwise non-zero initial value of stateAdjustment will produce
incorrect radius.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1964>
2021-09-01 11:01:04 +00:00
Florian Müllner
1d607cf18f build: Add soup2 option
!1940 added support for soup 3, including a fallback to soup 2.4
where the newer version isn't available.

Unfortunately it missed that libgweather has a hidden soup dependency,
and now gnome-shell fails to start if a weather location has been set
up and soup 3 is available.

We don't have a good way to detect that case, so hide the soup 3 support
behind a build option. Distributors are expected to switch it at the
same time as libgweather.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1966>
2021-09-01 12:26:15 +02:00
Luna Jernberg
66ba806838 Update Swedish translation 2021-08-31 20:46:21 +00:00
Charles Monzat
9b896478c9 Update French translation 2021-08-31 19:50:29 +00:00
Florian Müllner
b158e9676d main: Stop handling old 'panel-main-menu' shortcut
It's a shortcut from the GNOME 2 days that few users will remember.
And if anyone really wants to keep it, they can use Settings to
assign <Alt>F1 to 'toggle-overview'.

https://discourse.gnome.org/t/difference-between-show-the-overview-and-show-the-activities-overview-keyboard-shortcuts/6572

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1871>
2021-08-31 19:01:25 +00:00
Dušan Kazik
2f161af85f Update Slovak translation 2021-08-31 13:50:41 +00:00
Matej Urbančič
5eb82cb54f Update Slovenian translation 2021-08-30 19:16:23 +00:00
Philipp Kiemle
66b11171d9 Update German translation 2021-08-29 17:33:10 +00:00
Bruce Cowan
44d61c62f0 Update British English translation 2021-08-28 10:14:51 +00:00
Baurzhan Muftakhidinov
b8f5e384f5 Update Kazakh translation 2021-08-28 06:21:55 +00:00
Emin Tufan Çetin
196fa34fb4 Update Turkish translation 2021-08-27 21:28:23 +00:00
Jiri Grönroos
b73c05c3c7 Update Finnish translation 2021-08-27 17:50:01 +00:00
Źmicier Turok
cd2174e110 Update Belarusian translation 2021-08-27 09:01:12 +00:00
Ivan Molodetskikh
c6bcc74649 notificationDaemon: Remove rewriteRules
It's not really Shell's business to fix bad app notification contents.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1962>
2021-08-26 14:45:19 +03:00
Ivan Molodetskikh
6c4089025f networkAgent: Fix order of _() and format()
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1961>
2021-08-26 08:19:59 +00:00
Daniel Mustieles
a24a7a8690 Updated Spanish translation 2021-08-25 16:55:42 +02:00
Fran Dieguez
79d633a0cc Update Galician translation 2021-08-25 05:57:36 +00:00
Florian Müllner
d562c70f4e environment: Fallback to Soup 2.4
We cannot assume yet that Soup3 is available everywhere. Until that
is the case, allow falling back to Soup 2.4 by imitating the bits
of the Soup3 API we use with monkey-patching.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1940>
2021-08-25 01:54:07 +02:00
Florian Müllner
ae90b50dc7 extensionDownloader: Port to Soup3
After 13 years, Soup will release a new, API-incompatible
version[0]. This is a good thing, make sure we support it.

[0] https://blog.tingping.se/2021/02/23/future-of-libsoup.html

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1940>
2021-08-25 01:54:07 +02:00
Florian Müllner
3ad569f426 extensionDownloader: Use plain Soup.Session
Unlike for the old Soup.SessionSync/SessionAsync classes,
Soup.Session:ssl-use-system-ca-file already defaults to true.

In Soup3, the behavior was made unconditional and the property
removed.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1940>
2021-08-25 01:54:07 +02:00
Florian Müllner
f14960ff03 extensionDownloader: Stop setting proxy resolver explicitly
Quoting the documentation:

  In libsoup 2.44 and later, you can set the session's “proxy-resolver”
  property to the resolver returned by g_proxy_resolver_get_default() to
  get the same effect. Note that for "plain" SoupSessions (ie, not
  SoupSessionAsync or SoupSessionSync), this is done for you automatically.

libsoup 2.44 was released in 2013, so we can safely assume that Soup is
new enough to handle this for us.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1940>
2021-08-25 01:54:07 +02:00
Florian Müllner
50a14caf1b portalHelper: Replace Soup.URI with GLib.Uri
GLib.Uri was added a while ago, and can replace our usage of Soup.URI.
In fact, the upcoming Soup3 drops its own URI type in favor of GLib.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1940>
2021-08-25 01:54:07 +02:00
Florian Müllner
6bf20837c0 extensionDownloader: Use async code for extracting archive
The code that handles extracting extension archives currently uses
an awkward double-callback system. We can do significantly better
by using an async function and exceptions.

Partially based on code from Marco Trevisan.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1940>
2021-08-25 01:54:07 +02:00
Florian Müllner
f16fda5ea1 extensionDownloader: Stop returning distinct errors
Nothing looks at our made-up errors, so we can just as well return
a generic "ExtensionError".

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1940>
2021-08-24 15:48:04 +00:00
Florian Müllner
b3bdcbcf3f extensionDownloader: Fix up style
Move all remaining bits to the new coding style before making
further changes.

The let → const changes are selectively done to the bits that'll
still be around at the end of the patch series.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1940>
2021-08-24 15:48:04 +00:00
Florian Müllner
4bbbee4dd6 ci: Expose meson's Junit test results to gitlab
Turns out meson has been generated Junit XML files of its test
results since 0.55 ...

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1937>
2021-08-24 08:18:26 +00:00
Florian Müllner
06c4929493 subprojects: Use meson compile to generate translations
... for the same cosmetic reasons as the previous commit.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1937>
2021-08-24 08:18:26 +00:00
Florian Müllner
0cd882697a ci: Use backend-agnostic meson commands
There's no alternative backend in sight for us, but it's nice to
only deal with a single build tool.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1937>
2021-08-24 08:18:26 +00:00
Florian Müllner
bf5129adc1 eslint: (Mostly) synchronize configuration with gjs
In addition to the changes in this commit, gjs now
restricts the use of the Format module and initFormat.
We can't really replace those for translatable strings
until xgettext gains support for template strings, so
leave that bit out for now.

The other notable change is that gjs now requires
jsdoc comments. We can't plainly enable those options
without a massive amount of work first, but let's see
how requiring doc comments for new code goes.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1949>
2021-08-24 08:13:19 +00:00
Florian Müllner
a802bfda39 ci: Include eslint-plugin-jsdoc in js image
gjs started to require it in its config, so we need it
if we want to keep our configuration in sync.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1949>
2021-08-24 08:13:19 +00:00
Marek Černocký
f3cbc43f72 Updated Czech translation 2021-08-24 00:14:12 +02:00
Florian Müllner
ea6433b2cb extensions-tool: Remove GNOME Software reference from man page
It no longer manages extensions.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1956>
2021-08-22 19:25:34 +00:00
Florian Müllner
0b8514dc7d messageTray: Do not show low priority notifications
Low priority notifications are meant for information that doesn't require
immediate attention, so it makes sense to not show a banner for them;
they'll still appear in the notification list in the calendar.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4265

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1893>
2021-08-22 19:20:37 +00:00
Kukuh Syafaat
1f3fac047b Update Indonesian translation 2021-08-22 04:45:37 +00:00
Danial Behzadi
5e34dda881 Update Persian translation 2021-08-21 11:26:51 +00:00
Asier Sarasua Garmendia
58722cab8f Update Basque translation 2021-08-20 08:19:41 +00:00
Alexey Rubtsov
80e96b4bd8 Update Russian translation 2021-08-20 07:12:23 +00:00
Daniel van Vugt
88b2c9a046 windowManager: Animate the appearance of new windows after overview closes
So that the animation doesn't get skipped if the overview is visible but
in the process of closing.

In this case the overview being visible also means that it is closing,
because if it's visible and not already closing then `_shouldAnimateActor`
would have returned false and exited `_mapWindow` earlier.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/1814,
       https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3242

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1440>
2021-08-19 15:53:57 +08:00
Daniel van Vugt
956db078c3 overview: Emit 'hidden' after it's *really* hidden
Previously we would emit 'hidden' before the overview was fully hidden,
so any attempts to animate windows on that signal could still fail.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1440>
2021-08-19 15:44:34 +08:00
Daniel van Vugt
ea9c4e589d windowManager: Allow animations to start if the overview is closing
So the `WindowManager._mapWindow` animation doesn't get skipped if the
overview is visible but closing.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1440>
2021-08-19 15:44:34 +08:00
Daniel van Vugt
7c1b30b272 workspace: Ignore new windows that appear while the overview is closing
This can easily happen if an app launches and maps a window faster than
the overview closes. We don't want the window clone appearing and then
suddenly disappearing in that case.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1440>
2021-08-19 15:44:34 +08:00
Daniel van Vugt
74d0b066e9 overview: Add a 'closing' getter
Which better communicates what we are checking for, and is a little more
elegant than repeatedly writing:
```
Main.overview.animationInProgress && Main.overview.visibleTarget == false
```

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1440>
2021-08-19 15:44:34 +08:00
Jordi Mas
3121476436 Update Catalan translation 2021-08-18 19:13:18 +02:00
Daniel van Vugt
af03314f20 magnifier: Avoid painting a desktop that's fully occluded by its clone
This significantly reduces the render time for fullscreen zoom mode.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3305
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1899>
2021-08-18 14:12:34 +00:00
Rafael Fontenelle
5702349c2d Update Brazilian Portuguese translation 2021-08-18 13:27:36 +00:00
Hugo Carvalho
a145361827 Update Portuguese translation 2021-08-18 11:11:55 +00:00
Asier Sarasua Garmendia
124f2961eb Update Basque translation 2021-08-18 09:24:11 +00:00
Quentin PAGÈS
3ce03beb6c Update Occitan translation 2021-08-18 09:12:34 +00:00
Yuri Chornoivan
142492b778 Update Ukrainian translation 2021-08-18 06:35:57 +00:00
Florian Müllner
aec128fdee Bump versiont to 41.beta
Update NEWS.
2021-08-18 01:10:41 +02:00
nitinosiris
a4d2f5d8b4 windowMenu: Use consistent terminology
Because we don't have a dock or panel to minimize to, the `minimize`
shortcut was renamed to `hide` a long time ago.

Likewise, `unmaximize` appears as `restore` in keyboard shortcuts.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4088

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1834>
2021-08-18 00:43:12 +02:00
Daniel Mustieles
91280f7227 Updated Spanish translation 2021-08-17 13:49:29 +02:00
Florian Müllner
b496c9f956 appDisplay: Replace AppIconMenu
We are finally ready to share the app menu between the top bar and
context menus in the dash/app grid. Notably that means that it is
now possible to quit an app from its context menu.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2875

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
414ed9128f appMenu: Support launching on the non-default GPU
Changing the GPU to launch an app on is the last feature from the
app context menu that is still missing. Add support for it now,
and we are ready for some unifying cleanup!

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
bba799a70c appMenu: Remove separator between "new window" and actions
We hide our own "New Window" item if the app itself includes a
"new-window" action. That means that the separator between the
built-in item and desktop actions introduces a small inconsistency
depending on whether a "New Window" item is provided by the desktop
action or ourselves. There's no good reason for that from a user's
perspective, so remove the separator.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
0cde447891 appMenu: Optionally include favorites section
The context menu in the overview includes actions for managing
favorites. Add those to the AppMenu class, but make it another
option as the actions would be slightly weird in the top bar menu.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
e3c06e3c77 appMenu: Update "new-window" item on state changes
Stopped apps can *always* open a new window, so before we start
using the menu for non-running apps, make sure to hide the menu
item as necessary.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
321e07c3c6 appMenu: Only show 'Quit' for running apps
The top bar menu always corresponds to a running app, so it made
sense to include the 'Quit' item unconditionally. That won't be
the case for the overview context menus, so handle app state changes
and show/hide the item as necessary.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
991d9597e0 appMenu: Allow showing the window section for all windows
Since commit fd0da9606f, we only show the "Open Windows" section
if there are at least two windows. That's another subtle difference
with the overview context menus, but while limiting the section to
a minimum of two windows makes sense where the menu always represents
a running app, it is useful to show the section even for single windows
in the dash/app grid.

Account for both uses cases by adding a corresponding option to the
constructor.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
8b1e1834f0 appMenu: Only include non-skip-taskbar windows
There's a subtle difference between the top bar menu and the app
icon context menus in the overview regarding the "Open Window"
section.

The former includes skip-taskbar windows, the latter doesn't. It
clearly doesn't make sense for the context menu to include windows
that aren't shown in the overview, but skip-taskbar windows are
likely also less useful in the top bar menu.

Just settle on the behavior of the context menus and move on.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
c809a87412 appMenu: Do launch animation if supported by source
Likewise any launch actions should animate the corresponding launcher
(if the menu is associated with a launcher).

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
b3861ca693 appMenu: Hide overview when activating apps
This is the expected behavior when activating a window or app. Until
now we could rely on the menu being hidden in the overview, but as
that is about to change, make sure the menu behaves as expected.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
958fb6fddc appsMenu: Add side parameter
In order to re-use the menu in the overview, we must be able to
change the side of the arrow, so expose the parent class parameter.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
0f5881788c appMenu: Delay window sections update when selecting window
App windows are ordered by recency, so a focus change (correctly)
triggers the ::window-changed signal. If we rebuild the section
immediately in response, the activating item will be destroyed
before the menu's ::activate handler, with the result that the
menu remains open.

Defer the section update in that case to allow the menu to process
the ::activate signal first.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
07daa95393 appMenu: Clean up on destroy
For now the menu is only used in the top bar, where we can assume
that it exists "forever". This won't be the case when we start
reusing it elsewhere, so make sure we clean up after ourselves.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
1550976c51 appMenu: Split out from panel
There is a big overlap between the app menu in the top bar and the
context menu of app icons. It makes sense to unify the two both
from a design- and from a code perspective, so split out the more
modern one into a separate module as basis for a shared class.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Florian Müllner
5e90e8d385 appDisplay: Remove unnecessary unmapped handler
Since commit 35494f5d08, all menus are closed when their source
gets unmapped.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1948>
2021-08-16 21:28:22 +00:00
Yaron Shahrabani
2e04f9be8a Update Hebrew translation 2021-08-16 20:19:31 +00:00
Daniel Șerbănescu
e260c24f55 Update Romanian translation 2021-08-16 17:42:24 +00:00
Danial Behzadi
bb907e42b9 Update Persian translation 2021-08-16 12:45:26 +00:00
Sebastian Keller
5791e257e7 screenShield: Asyncify _syncInhibitor()
Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4553
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1952>
2021-08-16 02:44:36 +02:00
Sebastian Keller
85075192f3 screenShield: Close inhibitors that finished creation after uninhibition
There was a potential issue when suspend was inhibited and immediately
uninhibited again before the creation of the inhibitor has finished.
Then the new inhibitor would be kept active.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1927>
2021-08-16 00:28:52 +00:00
Sebastian Keller
fb313033ea screenShield: Don't unnecessarily close or recreate inhibitors
ScreenShield::_syncInhibitor() was closing (and recreating) the
inhibitor everytime it was called, even if no change was needed.
This gets called in various places, including on property changes in
the login1 dbus object. These happen by the time logind already started
suspending at which point new inhibitors can no longer be created. It is
only waiting for existing inhibitors to be closed, so closing the
inhibitor without a new inhibitor will cause the suspending to proceed
immediately if no other inhibitors are present. This can also happen
before the lock screen is shown, which will then complete after resume.

Fix this by keeping track of the expected inhibition state and only
create or close inhibitors if there was a change to that.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3736

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1927>
2021-08-16 00:28:52 +00:00
Luna Jernberg
4a3e3ee1b8 Update Swedish translation 2021-08-15 15:48:27 +00:00
Kukuh Syafaat
2724ecee05 Update Indonesian translation 2021-08-15 11:58:14 +00:00
Florian Müllner
1deb13e1aa extensionUtils: Add gettext convenience helpers
We have initTranslations() for binding an extension's
gettext domain, but nothing to help with using gettext
from an extension.

Such help would be useful though, as an extension that
calls textdomain() like a normal application would
inadvertently changes the default domain for the whole
gnome-shell process.

Instead, extensions have to use domain-specific versions
of the gettext functions:

```js
const Gettext = imports.gettext.domain('my-extension');
const _ = Gettext.gettext;
```

Make this a bit easier by adding those functions directly
to the extensions object when initTranslations() is called,
then expose helper functions for calling them.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2594

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1941>
2021-08-14 18:45:25 +00:00
Florian Müllner
b9f38f95e3 ci: Split POTFILES check between C and JS
Regex are a crude tool for analyzing whether some code *calls* a
particular function. Spidermonkey has Reflect.parse() that returns
the AST of the passed in code, which allows for a much more precise
check for javascript.

The old script is still used for C code, where i18n-affecting changes
are much rarer.

Based heavily on Philip Chimento's mozjs migration script at
https://gitlab.gnome.org/ptomato/moz60tool.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1941>
2021-08-14 18:45:25 +00:00
Alexey Rubtsov
53e623e49c Update Russian translation 2021-08-14 11:56:36 +00:00
Mohammed Sadiq
3495873c90 status/network: Use wwan settings panel for GSM/LTE Modems
GSM/UMTS/LTE modems now have better support with wwan panel in GNOME
Settings.  So, if the modem supports, open wwan panel, otherwise
fallback to opening network panel when "Mobile Broadband Settings"
item is clicked.

See https://gitlab.gnome.org/GNOME/gnome-control-center/-/merge_requests/583

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1942>
2021-08-14 10:39:56 +00:00
Florian Müllner
4b4d422c1e iconGrid: Bail out when not on a monitor
There shouldn't be any code that calls zoomOutActor() without
a monitor, but throwing in an early return doesn't hurt.

CID 351285.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1950>
2021-08-13 15:16:54 +02:00
Florian Müllner
46b0d3f6cc workspacesView: Handle null return value
We are not going to process key events while updating views,
but coverity complains (CID 351269)...

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1950>
2021-08-13 15:16:54 +02:00
Florian Müllner
5b3036a6bf appDisplay: Handle null value
The value can not actually be null at that point, but it's too
hard to spot for tools like coverity:
 - before setting view, we chain up to the parent's acceptDrop()
 - that calls _canAccept(), which we override and check for the view

Still, and extra ? doesn't hurt, and hopefully will make the tooling
happy.

CID 351269

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1950>
2021-08-13 15:16:54 +02:00
Florian Müllner
941419e165 appDisplay: Fix dead error handling
gjs includes an override to turn GSettings' asserts into exceptions,
but we'll have to catch that instead of checking for a null return
value.

Spotted by coverity in CID 351268.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1950>
2021-08-13 15:16:54 +02:00
Florian Müllner
6f7df32b0e boxpointer: Fix coordinate
Eeeks. Spotted by coverity in CID 351259.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1950>
2021-08-13 15:16:54 +02:00
Florian Müllner
474fd47fc0 telepathyClient: Fix a typo
Whoops, that notifiction was never shown.

Spotted by coverity in CID 351223.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1950>
2021-08-13 15:16:54 +02:00
Florian Müllner
f719ea8d69 st/scroll-bar: Remove pointless condition
Both branches are identical (which is correct - orientation or
text direction is irrelevant for the trough).

Spotted by coverity in CID 351261.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1950>
2021-08-13 15:16:54 +02:00
Florian Müllner
506001ebc2 src/shell: Plug some small leaks
Spotted by coverity in CID 351284 and 351288.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1950>
2021-08-13 15:16:54 +02:00
Hugo Carvalho
2fcb7cf3de Update Portuguese translation 2021-08-13 10:08:22 +00:00
Florian Müllner
c6b72ccd15 status/location: Change permission table
There is now a location portal that provides a similar role
as our agent. Settings supports that portal in its application
panel, which allows users to revisit their choice later.

Unfortunately it uses a different permission store table, so
any permissions granted (or denied) through our agent won't
show up there.

To change that, switch to the same table as the portal/Settings.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1945>
2021-08-12 22:39:45 +00:00
Quentin PAGÈS
f313eb08ac Update Occitan translation 2021-08-12 21:19:06 +00:00
Florian Müllner
508442cef2 ci: Update mutter image
Mutter now requires a development version of glib, so bump the
image to satisfy the dependency.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1947>
2021-08-12 21:01:01 +02:00
Jakub Steiner
7af01939eb theme: Adjust focus ring for entries
Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4527

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1936>
2021-08-11 16:13:39 +00:00
Daniel van Vugt
cc2af75fb4 workspace: Remove skip-taskbar windows while the overview is shown
On startup desktop-icons-ng Wayland windows have skip-taskbar==FALSE so
initially pass `_isOverviewWindow` and they get added to the overview,
which is confusing to users. However almost immediately after that they
get `meta_wayland_client_hide_from_window_list` and are removed from
future overviews. So now we respond to `notify::skip-taskbar` immediately
and prevent desktop-icons-ng appearing in the startup overview too.

This is messy and ideally we'd like to know the window type immediately
on creation, but that option only exists in X11 and not Wayland.

https://gitlab.com/rastersoft/desktop-icons-ng/-/issues/137
https://bugs.launchpad.net/bugs/1936643

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1925>
2021-08-11 15:15:03 +00:00
Fionn Kelleher
a8f1722a9f readme: Change "GNOME 3" to "GNOME"
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1944>
2021-08-11 14:41:15 +00:00
Rafael Fontenelle
4649bb008c Update Brazilian Portuguese translation 2021-08-10 12:41:06 +00:00
Boyuan Yang
9fa31d83c8 Update Chinese (China) translation 2021-08-09 19:48:23 +00:00
Matej Urbančič
58dd335b18 Update Slovenian translation 2021-08-09 19:14:19 +00:00
Yuri Chornoivan
9b7181d706 Update Ukrainian translation 2021-08-09 14:40:03 +00:00
Florian Müllner
26dc0fcd32 appDisplay: Avoid a warning
At least the last stable release of gjs has an issue with async
handlers for custom (i.e. defined in JS) GObject signals.

The handler still works, but evoking it prints the following warning:

  JS ERROR: Error: Could not guess unspecified GValue type

We can avoid the warning by using the addAction() convenience
method, which makes for a small nice cleanup anyway.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4531

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1938>
2021-08-09 14:08:09 +00:00
Florian Müllner
19fc6ef5dd powerProfiles: Tweak profile names
After some more discussion, we settled on slightly different
profile names.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4530

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1939>
2021-08-09 13:50:13 +00:00
Kukuh Syafaat
d28ed122a8 Update Indonesian translation 2021-08-08 13:27:17 +00:00
Yaron Shahrabani
ee632fb2d5 Update Hebrew translation 2021-08-07 16:07:08 +00:00
Danial Behzadi
957d5595de Update Persian translation 2021-08-07 14:52:19 +00:00
Emin Tufan Çetin
e49d8162a9 Update Turkish translation 2021-08-06 20:35:27 +00:00
Tjipke van der Heide
9cfc48c0a8 Update Frisian translation 2021-08-05 12:40:30 +00:00
Florian Müllner
6e629c0f10 st/icon: Only get resource-scale after peeking theme node
If an actor is not on any stage view, then it doesn't have a valid
resource scale, which will hit an assert later.

When that is the case (for example when running headless), we expect
that there is no valid theme node (yet) either, so simply moving
the clutter_actor_get_resource_scale() call after peeking at the
theme node is enough to avoid the crash.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4522

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1935>
2021-08-05 10:03:51 +00:00
Rafael Fontenelle
4bf5f7bdb1 Update Brazilian Portuguese translation 2021-08-04 23:20:16 +00:00
Hugo Carvalho
c58c86e01d Update Portuguese translation 2021-08-04 17:06:45 +00:00
Alexey Rubtsov
99199b1379 Update Russian translation 2021-08-03 20:46:35 +00:00
Yuri Chornoivan
717a2d30cb Update Ukrainian translation 2021-08-02 16:36:57 +00:00
Florian Müllner
f1320bd250 status/powerProfiles: Add power mode selection
Settings' power panel gained support for switchable power profiles
in GNOME 40. It's useful to have that functionality more readily
available, so expose it in the system status menu as well.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3944

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1907>
2021-08-02 16:41:06 +02:00
Tjipke van der Heide
770f15207c Add Frisian translation 2021-08-02 10:46:04 +00:00
Florian Müllner
8f42053b5f magnifier: Small cleanup
Use an early return instead of a big if() block to cut down on
indentation.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1932>
2021-07-31 17:18:08 +00:00
Florian Müllner
77b175e763 magnifier: Remove unused return value
Before the introduction of PointerWatcher, the method was used as
a timeout handler. That hasn't been the case since 2012, so drop
the return value.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1932>
2021-07-31 17:18:08 +00:00
Florian Müllner
1ea4d72fe5 magnifier: Don't query pointer unless necessary
The PointerWatcher passes the current pointer position to every watch,
so we don't have to query the pointer again scrollToMousePos() is used
as watch callback.

While that should be the only use, be conservative and still query the
pointer when called without arguments.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1932>
2021-07-31 17:18:08 +00:00
Quentin PAGÈS
3fa5e5963c Update Occitan translation 2021-07-31 13:46:06 +00:00
Quentin PAGÈS
09cb9cd461 Update Occitan translation
(cherry picked from commit 668dcdf3221632d69eee86fb5aaf35dd1a705e31)
2021-07-31 13:42:06 +00:00
Ray Strode
a4123887c1 shellEntry: Don't show "Show Password" menu if entry icon is disabled
Right now the Show Password menu is shown unconditionally for password
entries, ignoring the org.gnome.desktop.lockdown disable-show-password
key.

StShellEntry now honors that key for its peek icon, and there's little
reason for the peek icon and the menu to ever be out of sync.

This commit forces the menu and the icon to always be in sync, and
so makes the menu lock down work automatically, too.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/687>
2021-07-30 14:17:07 +00:00
Ray Strode
8721c5db37 st/password-entry: Honor disable-show-password key
StPasswordEntry provides an optional icon for the user to
show their password in clear text.

This commit disables that icon if password showing is locked
down.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/687>
2021-07-30 14:17:07 +00:00
Ray Strode
162d694d9a st/settings: Add new disable-show-password setting
There's now a setting

org.gnome.desktop.lockdown disable-show-password

that ostensibly lets admins prevent from users from
showing their password in password dialogs.

gnome-shell currently ignores this key.

As a first step, this commit adds the setting to StSettings.

Future commits will use the new setting.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/687>
2021-07-30 14:17:07 +00:00
Ray Strode
4ae06a2879 st/settings: Fix indentation on settings keys
Most of the keys are aligned, but "screen-magnifier-enabled" isn't.

This commit lines all the keys up, giving a little more breathing
room for future keys that have longer names.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/687>
2021-07-30 14:17:07 +00:00
Jonas Dreßler
ba428ed6b0 st/scroll-bar: Remove unneeded style-changed handler
Same reasoning as the last commit, this is already handled in the
default vfunc override of StWidget.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/953>
2021-07-30 13:59:18 +00:00
Jonas Dreßler
85ffb96924 st/scroll-view: Don't emit superfluous style-changed events on children
Since we correctly call the `style_changed` vfunc superclass at the end
of our own function anyway, the style changes will get propagated to the
children of the scrollView inside `st_widget_real_style_changed` anyway.

So remove those unneeded and quite expensive (because they cause the
theme node to be regenerated) calls to `st_widget_style_changed`.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/953>
2021-07-30 13:59:18 +00:00
Jonas Dreßler
f6553ef5f0 st/icon: Chain up to parent vfunc in override
GObject vfunc overrides are always supposed to call their parent vfunc,
this was forgotten here, so fix it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/953>
2021-07-30 13:59:18 +00:00
Jonas Dreßler
0b1dfbf6f3 st/icon: Check icon properties for changes before regenerating texture
Properly compare the new icon properties of StIcon to the old ones on
style-changes and only update the icon texture in case something
changed. This should help reduce the amount of texture cache requests
when we start emitting all "style-changed" signals again.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/953>
2021-07-30 13:59:18 +00:00
Jonas Dreßler
13562033d7 st/icon: Store paint scaled icon size instead of normal size
This makes it easier to track size changes when the paint scale changes,
since in those cases we basically want to do the same thing as when the
normal icon size changes: Request a new texture from the cache.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/953>
2021-07-30 13:59:18 +00:00
Jonas Dreßler
67596e7c83 Revert "workspaceAnimation: Allow long swipes in session"
The behavior when switching workspaces now with the touchpad gesture is
very very weird, it almost always swipes to the last workspace instead
of the next one.

So revert this change again and only swipe a single page per gesture. We
can enable long swipes again when we've figured out a proper way to
detect what the user wants (which is going to be quite challenging), see
https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4355.

This reverts commit dfae3281b9.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1933>
2021-07-30 13:46:35 +00:00
Sebastian Keller
bb8daaeb2f keyboard: Use microseconds for notify_keyval()
ClutterVirtualInputDevice::notify_keyval() expects time to be in
microseconds but Clutter::get_current_event_time() returns the time in
milliseconds. On Wayland the generated event triggers all the warnings
in MetaDisplay::sanity_check_timestamps() due to the event time
seemingly being in the past.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1926>
2021-07-29 20:18:51 +00:00
Florian Müllner
8edd6aef64 ci: Update mutter image
It pulls in a new gsettings-desktop-schemas version for
https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/687.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1931>
2021-07-29 20:10:58 +02:00
Fabio Tomat
6c4b5bf0a0 Update Friulian translation 2021-07-24 07:31:21 +00:00
Boyuan Yang
9c025ba362 Update Chinese (China) translation 2021-07-23 20:42:49 +00:00
Sebastian Keller
eee2ccac7a workspace: Only change opacity of minimized windows during transitions
Dragging a window preview in the overview is supposed to change the
opacity of the dragged actor. This however fails for minimized windows,
because Workspace::allocate() also changes the opacity of those. The
allocation gets triggered by removing the window actor from the
workspace when starting the drag. Avoid this by only changing the
opacity during the overview transitions.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4292

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1847>
2021-07-23 12:38:12 +02:00
Ray Strode
118d556991 unlockDialog: Honor switch user lockdown settings
At the moment user switching functionality is controlled by two
settings:

org.gnome.desktop.lockdown disable-user-switching

for the panel when the session is unlocked, and

org.gnome.desktop.screensaver user-switch-enabled

for the unlock dialog when the session is locked.

Having the lockdown setting not apply when the screen is
locked is counterintuitive.

This commit makes the unlock dialog honor both settings.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1833>
2021-07-22 16:17:29 -04:00
Jakub Steiner
c17601bdee theme: No stroke on entries
- Tobias' mini guadec initiative

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1924>
2021-07-22 14:30:05 +02:00
Fran Dieguez
678b06fc7e Update Galician translation 2021-07-22 06:14:15 +00:00
Alexey Rubtsov
ca32abc150 Update Russian translation 2021-07-21 10:22:24 +00:00
vanadiae
25ece58538 theme: Add focus indication for dnd switch in message list controls
It currently is difficult to see what's being focused in the messages list
currently because of that.

Fixes #2447

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1920>
2021-07-20 20:58:59 +02:00
vanadiae
7dd7714fd2 popupMenu: Remove can_focus=True from Switch
Since this is a bin and not a button, and it doesn't have any click/keyboard
handling on its own (as in that case it needs a parent button wired like in
the messages list controls), it is confusing that it has can_focus set to
True. To avoid any confusion, this commit removes it without breaking anything
since it had no real use.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1920>
2021-07-20 14:11:28 +02:00
Florian Müllner
da11d8d7ef ci: Move FDO_UPSTREAM_REPO to global scope
ci-fairy also uses the variable to set the upstream remote that is used
to build the commit range to check.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1922>
2021-07-19 14:15:22 +00:00
Florian Müllner
bc3ae223f1 ci: Bump ci-templates image
Before building a container image, the code checks that the
repository's container registry is enabled. That check was
broken a while ago, update the image to pull in the fix.

See https://gitlab.freedesktop.org/freedesktop/ci-templates/-/issues/39

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1922>
2021-07-19 14:15:22 +00:00
Sebastian Keller
f579e9dd8e build: Bump gjs dependency to 1.68.1
The changes in 58ed969d need gjs 1.68.1 to work, otherwise this results
in the background image not getting loaded.

Related https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4138
Related https://gitlab.gnome.org/GNOME/gjs/-/merge_requests/595

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1857>
2021-07-18 23:29:26 +00:00
Florian Müllner
b58f057713 docs: Add README section for default branch
We are about to change it, so briefly outline how to update local
checkouts.

(Copied from glib)

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1914>
2021-07-18 21:45:46 +00:00
Florian Müllner
28f64072ba ci: Fallback to HEAD when checking out branch
... instead of hardcoding origin/master as the default branch.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1914>
2021-07-18 21:45:46 +00:00
Florian Müllner
df76c3fd11 Update links to use HEAD instead of master
That way the link will keep working when projects change their
default branch name.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1914>
2021-07-18 21:45:46 +00:00
Florian Müllner
56da0f6561 js: Replace removed Meta.quit()
This one was moved to Meta.Context as well.

I don't know why the `debugexit` command quit with an error code
(it dates back all the way to commit 98bd590a5d). Terminating on
request by the user doesn't sound like an error, so don't replicate
that particular behavior.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1917>
2021-07-18 23:11:43 +02:00
Florian Müllner
d8be637dca main: Replace Meta.register_with_session()
The functionality moved into the new Meta.Context.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1917>
2021-07-18 23:11:43 +02:00
Florian Müllner
e726527604 shell/global: Expose MetaContext as property
We'll likely have to interact a bit with the newly added Meta.Context
object, so add a convenience property that gives us direct access
instead of getting it from the display every time we need it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1917>
2021-07-18 23:11:43 +02:00
Kukuh Syafaat
733a5e1acb Update Indonesian translation 2021-07-17 14:56:16 +00:00
Ian Douglas Scott
e3a1d84992 location: Split Location.Indicator into a seperate GeoclueAgent
Before this, creating a separate instance of `Location.Indicator` failed
because it tries to create export the same DBus path.

This is useful for extensions adding panels on multiple monitors. But
it also seems like a cleaner design to separate the indicator widget
from the logically separate role as a Geoclue agent.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1919>
2021-07-16 17:51:17 -07:00
Ian Douglas Scott
51a8bbddd5 location: Add GObject properties to Location.Indicator
Makes `enabled`, `in-use`, and `max-accuracy-level` GObject properties
that can be used for property binding, etc.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1919>
2021-07-16 16:07:30 -07:00
Marco Trevisan (Treviño)
81a1e294f8 ControlsManagerLayout: Allocate respecting the work area
We build controls layout using the whole monitor vertical space as
available, however extensions or external apps in X11 may reduce the
workarea size horizontally and the shell should always take care of it.

Given that we're already assuming that the allocation is monitor-based
and that we're adjusting it to the workarea, we can just make it more
explicit by using a workarea box that is used as the allocation area.

As per this, we also apply the same logic of applied to the vertical
dimension to the horizontal one.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1892>
2021-07-17 00:25:50 +02:00
Marco Trevisan (Treviño)
2b074882f4 ControlsManagerLayout: Consider workarea height for the available space
We always consider the whole workarea space to be available when
computing the controls manager layout, however this may not be the truth
when using extensions such as Window List which are reducing the work
area size.

So take care of it, reducing the box height.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4330
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1892>
2021-07-17 00:25:50 +02:00
Marco Trevisan (Treviño)
f164e08688 ControlsManagerLayout: Use the workarea size to compute the available height
To compute the available height for the layout we're currently using the
panel position, while this works for the current and default setup, the
shell may be configured to use a different workarea, so we should rely on
it to compute the available space, instead of a specific widget.

So get the current monitor index for the current view and use its coordinates
instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1892>
2021-07-17 00:25:50 +02:00
Marco Trevisan (Treviño)
f30fa1adc7 WorkspaceBackground: Fully take care of workarea geometry on allocation
The background group is currently allocated taking care of the workarea
x, y offset but not of its width/height and this may lead to building a
wrongly sized workspace view when the workarea size is not matching the
monitor size (like when there are struts set).

So, take care of the difference between the workarea and monitor
absolute end coordinates to allocate the background scaled content box.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1892>
2021-07-17 00:25:50 +02:00
Florian Müllner
28a42da947 status/network: Do not disable on login screen
We currently disable all network items on both the lock- and login
screen. While it makes sense to be very restrictive on the lock screen,
there are some (fringe) use cases for being more permissive on the
login screen (like remote home directories only accessible via VPN).

There's precedence with the power-off/restart actions to be less
restrictive on the login screen, and since we started respecting
the `network-control` polkit action, it's possible to restore the
old behavior if desired.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1874>
2021-07-16 22:21:12 +00:00
Florian Müllner
4440a8210b sessionMode: Enable networkAgent on login screen
We will soon enable the network sections in the status menu on the
login screen, so enable the network agent to handle authentication
requests (like wifi/VPN passwords).

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1874>
2021-07-16 22:21:12 +00:00
Florian Müllner
d1333cb249 status/network: Consider network-control action
NetworkManager installs a `network-control` polkit action that can
be used to disallow network configuration, except that we happily
ignore it. Add it to the conditions that turn a network section
insensitive.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1874>
2021-07-16 22:21:12 +00:00
Florian Müllner
d53285d71b status/network: Only list wifi networks that can be activated
Setting up a connection for an Enterprise WPA(2) encrypted wireless
network requires Settings. That's not available when windows are
disabled via the session mode, so filter out affected entries.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1874>
2021-07-16 22:21:12 +00:00
Florian Müllner
25793b9d97 status/network: Disable modem connection when windows aren't allowed
The item launches the corresponding Settings panel when activated, which
doesn't work when windows are disabled by the session mode. Rather than
failing silently, turn the item insensitive.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1874>
2021-07-16 22:21:12 +00:00
Carlos Garnacho
6203668b6c ci: Add job for pushing coverity reports
This job does:
1. Download the coverity bundle and untar it in a cached location
2. Build GNOME Shell using clang and the coverity tool
3. Compress the coverity report
4. Upload for analysis

In a similar setup to that of Mutter.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1913>
2021-07-16 21:49:19 +00:00
Carlos Garnacho
37a6434a4d ci: Funnel package list to be built correctly
It was on one hand using multi-line piping (`|`) and trying to
compensate with \ to escape multiple lines, this lead to:

  No match for argument: \

Also, the quoting around pkgconfig() arguments would lead to
double quoting at the shell level, thus:

  No match for argument: 'pkgconfig(gio-2.0)'

Fix both by using multi-line-turns-single-line piping (`>`)
and dropping the unnecessary quotes.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1913>
2021-07-16 21:49:19 +00:00
Alexander Mikhaylenko
b156cabdc9 swipeTracker: Use unaccelerated deltas
Unaccelerated deltas make sure the gesture works the same regardless of how
fast the fingers move; this is what we were already doing for scrolling.

Remove the swipe multiplier as the deltas already match scrolling other than
the 1/10 multiplier Clutter applies to scrolling specifically.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1763>
2021-07-16 19:37:20 +00:00
Florian Müllner
20d99c69cb search: Exclude hidden results from keynav
Since commit 3fb02843, we no longer skip allocation for
results that don't fit the width, and give them a 0x0
allocation instead.

That has the unintended side effect of those children now
being available to keynav. There are cases where we want
0-sized actors to be part of the focus chain (e.g. FocusTrap),
but this isn't one of them, so explicitly exclude 0-sized
children from keynav.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4470

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1916>
2021-07-15 19:15:36 +02:00
Jonas Ådahl
d265dabe03 main: Take over setting signal handlers and changing dir
MetaContext isn't doing this for us anymore, so do it ourself.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1840>
2021-07-15 12:42:17 +00:00
Jonas Ådahl
5acab6c300 Port to MetaContext
This ports over gnome-shell and the theme test case to MetaContext,
instead of the various functions that were available before.

The test case is changed to use the special test context, used to
construct contexts for testing. It's part of a shared libary separate
from the main libmutter one.

This enables building mutter tests during CI, as the test framework is
needed by some of gnome-shell's tests.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1840>
2021-07-15 12:42:17 +00:00
Jonas Ådahl
4340170e94 st/test-theme: Rename theme context variable
We will later get a pointer to a MetaContext, so avoid that future
naming conflict.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1840>
2021-07-15 12:42:17 +00:00
Danial Behzadi
7f7b515b84 Update Persian translation 2021-07-14 07:22:55 +00:00
Matej Urbančič
df377cc18a Update Slovenian translation 2021-07-13 19:31:32 +00:00
Florian Müllner
6995c2fa9f shellInfo: Don't destroy source on undo
Destroying the source from an action callback will result in the
notification being destroyed twice:

 - source.destroy() destroys all its notifications

 - a notification destroys itself after an action
   was activated

This results in unwanted log spam when attempting to dispose the
notification for a second time.

There is actually no good reason for destroying the source explicitly,
as sources already self-destruct with their last notification.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4457

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1908>
2021-07-13 12:38:51 +00:00
Florian Müllner
1f4eea12a5 messageTray: Always remove destroyed banners
Currently we only mark the banner as removed if it is destroyed
while in SHOWN or SHOWING state, but not if we're already HIDING
(for example in response to `NotificationBanner::done-displaying`).

If this happens, we'll try to destroy the notification again at
the end of the transition, which leads to (harmless but annoying)
log spam since Notifications were turned into GObjects (that are
disposed when destroyed).

Address this by always marking destroyed banners as removed, while
still only triggering a state update while shown (or in the process
of being shown).

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4457

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1908>
2021-07-13 12:38:51 +00:00
Daniel Mustieles
850d2a33a8 Updated Spanish translation 2021-07-13 11:47:20 +02:00
Jordi Mas
607a87738e Update Catalan translation 2021-07-11 21:44:06 +02:00
Yaron Shahrabani
06b454e32a Update Hebrew translation 2021-07-11 19:38:08 +00:00
Alexander Shopov
2eadd0aa32 Update Bulgarian translation 2021-07-11 08:29:16 +00:00
Hugo Carvalho
ae3c36c234 Update Portuguese translation 2021-07-09 14:55:29 +00:00
Florian Müllner
dc1aec5673 overviewControls: Fix warning on shutdown
ClutterActor unsets its layout manager's :container property during
dispose, so the corresponding vfunc should handle being passed NULL.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1909>
2021-07-08 23:17:01 +00:00
Florian Müllner
30e49cc3ca iconGrid: Disconnect signals on destroy
Otherwise the handler will trip over unset properties on an object
that is being disposed. Avoid the resulting log spam by disconnecting
the handler in question.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1909>
2021-07-08 23:17:01 +00:00
Florian Müllner
0e72579364 st/scroll-bar: Fix vertical scrollbars in RTL locales
Commit 0db41a3773 fixed the handling of horizontal scrollbars in
RTL locales, but accidentally applied the translation to *all*
scrollbars when handling handle drags and paging. Fix this by
limiting the mirroring to horizontal bars.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4458

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1910>
2021-07-08 23:12:26 +00:00
Quentin PAGÈS
dc47ca19ba Update Occitan translation
(cherry picked from commit 2d0ee51639b0e267cb5230c841003f0985977cef)
2021-07-08 19:43:48 +00:00
Jonas Ådahl
38d9b35ec8 ci: Bump to F34
This bumps both the mutter image to the F34 one, as well as the one used
for review.

This also bumps ci-templates hashes, so that we can use
FDO_DISTRIBUTION_PACKAGES without installing weak dependencies.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1906>
2021-07-07 17:10:17 +02:00
Robert Mader
3cfbb48f46 main: Use mallinfo2 when available at build time
`mallinfo` has been deprecated in favor of `mallinfo2`:
```
The fields of the mallinfo structure that is returned by the
older mallinfo() function are typed as int.  However, because
some internal bookkeeping values may be of type long, the
reported values may wrap around zero and thus be inaccurate.
```

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1786>
2021-07-07 14:44:30 +00:00
Hugo Carvalho
757501b33a Update Portuguese translation 2021-07-07 13:34:04 +00:00
Rafael Fontenelle
e86871e129 Update Brazilian Portuguese translation 2021-07-06 13:55:00 +00:00
Alexey Rubtsov
df069ca191 Update Russian translation 2021-07-06 10:10:18 +00:00
Yuri Chornoivan
0a42907c77 Update Ukrainian translation 2021-07-06 04:02:36 +00:00
Florentina Mușat
256a929eca Update Romanian translation 2021-07-05 19:23:12 +00:00
Florian Müllner
28045074aa data: Register switch-to-application shortcuts with g-c-c
The <super>1-9 shortcuts to activate dash favorites were a feature
from Ubuntu's Unity that caused some distress as the same shortcuts
were used by some users to activate workspaces.

Registering the new shortcuts with control-center at least gives
those users a GUI option for resolving the conflict.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/1250

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1797>
2021-07-05 18:46:08 +00:00
Alexander Shopov
57d72b9ebc Update Bulgarian translation 2021-07-04 12:47:37 +00:00
Efstathios Iosifidis
ee1db9ba0a Update Greek translation 2021-07-02 20:51:19 +00:00
Daniel van Vugt
374a2b2c51 theme: Remove background-color from .workspace-background
It's not visible because it's covered by the actual wallpaper, so
not rendering it eliminates most of the render time for
`workspace-background`, without changing its appearance.

When animating the overview by tapping Super, this reduces the
shell's overall render time by about 15%.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1904>
2021-06-30 12:28:08 +00:00
Daniel van Vugt
6721710932 st/theme-node-drawing: Render box-shadow independently of background-color
Until now, the absence of a `background-color` would cause `box-shadow`s
to be invisible. That was a bug because `box-shadow` is meant to be either
the color specified in `box-shadow`, or if none was specified then the
foreground `color`.

There is nothing in the spec that says the `box-shadow` rendering should
depend on `background-color`, so separate them. This ensures `box-shadow`
is rendered even when `background-color` is absent or transparent.

https://www.w3.org/TR/css-backgrounds-3/#box-shadow

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1904>
2021-06-30 12:28:08 +00:00
Carlos Garnacho
82450e1060 shell: Drop dependency on ClutterX11 headers/gir
This can be replaced with MetaX11Display nowadays.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1841>
2021-06-29 22:47:41 +00:00
Daniel van Vugt
48d5740443 st/private: Set sampling_radius to match the blur radius
From [the spec](https://www.w3.org/TR/css-backgrounds-3/#shadow-blur):

> the resulting shadow must approximate (with each pixel being within 5%
> of its expected value) the image that would be generated by applying to
> the shadow a Gaussian blur with a standard deviation [sigma] equal to
> half the blur radius

This does not change the value of `sigma`, it only corrects the value of
`sampling_radius` used to size the shadow texture. Since the texture is
no longer being slightly oversized it won't get scaled down when rendered
according to the dimensions provided by `st_shadow_get_box` in
`_st_paint_shadow_with_opacity`.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4409
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1897>
2021-06-29 22:32:24 +00:00
Daniel van Vugt
c08c142f95 st/widget: Include the shadow in the paint volume
Having an inaccurate paint volume didn't matter until ae338af1e8, but
after that having too small a paint volume resulted in apparent clipping.
Not because `clip_to_allocation` is set, but because the offscreen
framebuffer is sized to fit the paint volume only.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1897>
2021-06-29 22:32:24 +00:00
Florian Müllner
f51fb4bed0 ibusCandidatePopup: Use plain actor as dummy cursor
Now that source actors no longer have to be widgets, we can use
a plain actor for the dummy cursor and save a bit of overhead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1903>
2021-06-29 22:47:58 +02:00
Florian Müllner
16d3718735 boxpointer: Handle non-widget source actors
There is no convincing reason why source actors must be widgets,
so lift that restriction.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1903>
2021-06-29 22:47:50 +02:00
Lee
006d206f98 Magnifier: Filter caret tracking in gnome magnifier
Add a check to filter out caret tracking events that result in a caret
location of 0,0.

Fixes #4177

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1823>
2021-06-28 21:28:10 +00:00
Florian Müllner
8430aa59da status/power: Always sync after creating proxy
Otherwise the menu remains in an inconsistent state in case of an
error, until something else triggers a call to _sync() (like a
settings change).

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4431

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1901>
2021-06-28 20:49:43 +00:00
Florian Müllner
9e9ed42263 status/power: Update to new coding style
https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4431

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1901>
2021-06-28 20:49:43 +00:00
Carlos Garnacho
c449058d44 magnifier: Remove needless actor
For the pointer clone, we actually have 2 actors (one that contains
the sprite, another that moves around). These can just be the same.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1902>
2021-06-28 20:53:57 +02:00
Carlos Garnacho
3df4b5ec7c magnifier: Add method to enable/disable crosshairs
These do some some signals connection and monitor layout tracking
that we forget to disconnect when the magnifier is disconnected.
This causes warnings if enabling the magnifier, disabling it,
switching to another tty, and back. (Presumably also happens for
monitor hotplugs).

This signal should just stay connected as long as it's needed,
so add a setEnabled() method on the CrossHairs actor that we
can hook on the magnifier.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1902>
2021-06-28 20:53:36 +02:00
Carlos Garnacho
a363f1343a magnifier: Unset variable holding GSource ID
Otherwise we try to remove the no longer existing GSource
later on.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1902>
2021-06-28 19:54:07 +02:00
Florian Müllner
54a71944ba boxpointer: Disable unredirection while visible
Some popovers like the ibus candidate popover may be requested while
showing an unredirected fullscreen window. Disable unredirection
while the popover is visible so that it can actually be shown.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1900>
2021-06-28 12:07:12 +02:00
Georges Basile Stavracas Neto
f5259a5ce4 introspect: Allowlist GNOME portal
It too implements app listing and introspection, so list it in the allowlist.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1894>
2021-06-21 16:32:50 -03:00
Florian Müllner
158920924d shellDBus: Properly return from D-Bus methods
When implementing a D-Bus method synchronously, regular JS methods are
used. That is, whatever the method returns is passed as return value
to the method invocation.

However for asynchronous implementations, we need to explicitly return
a value to the invocation, otherwise the caller will wait until it times
out eventually.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1891>
2021-06-17 21:03:58 +00:00
Florian Müllner
6813e246cd shellDBus: Remove bogus return statements
g_dbus_method_invocation_return_value() doesn't have a return value.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1891>
2021-06-17 21:03:58 +00:00
Florian Müllner
c90fb27a2f shellDBus: Fix FocusApp()
The appDisplay used to be accessible via the viewSelector, but
that is gone now. Commit c09c070b15 adjusted the code, but the
replacement uses a Main.overview.appDisplay accessor that never
existed, whoops.

Fix this by exposing a new selectApp() method directly on the
overview, so we don't have to shuffle the appDisplay through
controls → overviewActor → overview.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1891>
2021-06-17 21:03:58 +00:00
Florian Müllner
f5be205c09 data: Remove old GConf migration files
The migration happened in GNOME 3.6 over 9 years ago. The chances
that someone migrates from 3.0.x or 3.2.x to 41 are very much zero.
And if it were to happen, it wouldn't work anyway, because we stopped
using a separate overrides schema.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1890>
2021-06-17 20:53:58 +00:00
Julia Dronova
3644bd43ba Update Russian translation 2021-06-17 14:52:00 +00:00
Olivier Fourdan
8be5d33611 windowManager: Remove timeout on starting X11 services
With Xwayland started on demand, mutter/gnome-shell will spawn Xwayland
and GNOME settings daemon Xsettings.

Currently, gnome-shell uses a timeout of 5 seconds before canceling the
launch and declare failure to start X11 services.

While 5 seconds may seem like a lot of time, when this is executed on a
virtual machine part of a QA tests under load, this causes random
failures.

There is no good value here, we could increase the timeout but it will
always remain racy. Instead, remove the timeout, systemd itself already
has a timeout mechanism (with a much longer wait time).

Thanks to Benjamin Berg <bberg@redhat.com> for finding the root cause
and suggesting the fix.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1888>
2021-06-15 11:24:59 +02:00
Chris Mayo
8d042459ee lookingGlass: Use symbolic icons on the toolbar
Replace gtk-color-picker, a private GTK 3 icon, with
find-location-symbolic as used in GTK Inspector.

As suggested by Daniel van Vugt.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1671>
2021-06-14 18:51:30 +00:00
Florian Müllner
3f2db31d7e shell/app: Keep cancellable after cancelled proxy request
When a GTK app is started, we create a corresponding GtkApplication
proxy to monitor the app's busy state. If the app is stopped before
the proxy request finishes, we cancel the cancellable before clearing
the running state.

Usually we clear the cancellable once it is no longer needed, namely
when we got the proxy. However when the request was cancelled, the
cancellable has already been cleared, and if there's a cancellable,
it belongs to another request (because the window was added again,
for example when moving between monitors).

Leave that cancellable alone in that case, so we can cancel the
second request as well if necessary to avoid a crash when trying
to set the proxy on a cleared running state.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/1962

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1885>
2021-06-14 20:37:26 +02:00
Harshad Gavali
177b36f82b overviewControls: Avoid hiding early AppDisplay when transitioning to Session
When transitioning from AppDisplay to Session,
AppDisplay should be visible throughout the transition.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4214

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1886>
2021-06-13 00:51:35 +02:00
Florian Müllner
5be67eb190 lookingGlass: Only pop modal after the transition
Right now we pop the modal immediately when closing, so the key-release
event of the Escape key ends up in the focus window which may consume it
for leaving fullscreen mode or similar.

We can avoid that in many cases by keeping the modal grab until the end
of the transition, as the key-release event will then likely occur while
the grab is still in place (provided animations are enabled).

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1880>
2021-06-10 00:18:00 +00:00
Hugo Carvalho
303fc944d0 Update Portuguese translation
(cherry picked from commit 3e5c7ce5f76fd16e38065c6f4db49fc2676809cf)
2021-06-09 18:28:34 +00:00
Daniel van Vugt
1879ca741e lookingGlass: Avoid a little bit of RedBorderEffect overdraw
The left edge of the box was redrawing the bottom left corner when
the bottom edge had already done so.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1876>
2021-06-09 16:31:19 +00:00
Daniel van Vugt
d8802aafc4 lookingGlass: Paint the RedBorderEffect right edge the correct height
It was being painted one box thickness (`width`) too tall so you could
see a rendering glitch below the bottom right corner until now.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1876>
2021-06-09 16:31:19 +00:00
Florian Müllner
dc0491ade8 dbusServices/screencast: Handle pipeline failures gracefully
If parsing the pipeline fails for some reason, we currently end up
with a zombie session that leads to a stuck recording indicator in
gnome-shell.

Instead, properly tear down the session to allow mutter and gnome-shell
to correctly update their state.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1878>
2021-06-09 15:21:35 +00:00
Jordi Mas
bed0f43967 Update Catalan translation 2021-06-08 19:42:52 +02:00
Georges Basile Stavracas Neto
40543bdd28 portal: Own org.gnome.Shell.Portal for the access portal
org.freedesktop.impl.portal.desktop.gnome will be used for the
GNOME implementation of desktop portals in the future, so make
sure GNOME Shell's implementation of the access portal won't
conflict.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1872>
2021-06-05 21:29:52 -03:00
Daniel van Vugt
a21058e6c9 st/icon: Rebuild shadows when the texture dimensions change
Not when the main actor dimensions change. So now the shadows don't get
constantly regenerated during the overview animation. In my case this
reduces the render time of the overview animation (tapping Super) by
approximately 10% with 2 windows, or 20% with 10 windows.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1869>
2021-06-03 20:27:57 +08:00
Cheng-Chia Tseng
c9558c9afa Update Chinese (Taiwan) translation
(cherry picked from commit e8eabad6ab0e99d893875fa7edad3f9de28b0841)
2021-06-03 02:10:33 +00:00
Georges Basile Stavracas Neto
5339b1e6a2 dnd: Immediately start drag done by pointer devices
Unlike touch screens, pointer devices (e.g. cursor, touchpad) are
basically never used to switch app grid pages, which is the main
use case for the drag threshold. This point was recently raised
as design feedback.

Immediately start drags when using pointer devices.

See https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3802#note_1124701

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4287

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1866>
2021-05-31 10:59:11 -03:00
Georges Basile Stavracas Neto
e89c6179af dnd: Factor out calculation into a variable
Another trivial cleanup. This is in preparation for next commit, that
will expand on this if clause, and will make it a bit more complicated.
Using a variable here makes it easier to read.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1866>
2021-05-30 21:32:54 -03:00
Georges Basile Stavracas Neto
88fa02147e dnd: Return Clutter.EVENT_STOP instead of true
Trivial cleanup.

Clutter.EVENT_STOP is more semantic, and this 'true' is inconsistent
with the 'return Clutter.EVENT_PROPAGATE;' a few lines above.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1866>
2021-05-30 21:27:51 -03:00
Georges Basile Stavracas Neto
dfae3281b9 workspaceAnimation: Allow long swipes in session
As per design feedback, allow long swipes in the session too.

See https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3802#note_1124701

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1865>
2021-05-30 12:02:12 -03:00
Florian Müllner
55fcb3aa00 build: Fix manpage generation at dist time
The AsciiDoc API only exposes the capabilities of asciidoc, but not
the related a2x tool. Fix generating the manpages by shelling out
to the command line tool instead.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4320

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1859>
2021-05-25 18:45:53 +00:00
Leleat
f8cd01c6dc extension-tool: Always print extension location after its creation
The extension location was only printed, if there was no handler for
the newly created extension. This is confusing for new extension
developers. So always print the extension location.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2515.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1856>
2021-05-25 18:30:25 +00:00
Georges Basile Stavracas Neto
e9119c625d workspaceThumbnail: Destroy thumbnails on destruction
Often, when using multiple monitors, the thumbnails box may be
destroyed before the 'hidden' signal of the Overview is emitted,
which leaves a bunch of lingering signal connections to the
workspace manager.

Call this._destroyThumbnails() in the _onDestroy handler, which
disconnects from workspace manager. This fixes the some of the log
spam that GNOME Shell produces with backtraces of destroyed actors.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1860>
2021-05-25 12:43:32 -03:00
Florian Müllner
e6089c83e2 extensions-app: Enable hardware acceleration
GTK4 will make use of it if it's available, so allow it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1854>
2021-05-19 18:23:56 +02:00
Gustavo Noronha Silva
404ca91941 calendar-server: Fix double-free detection abort
app_notify_events_added uses an intermediate builder to construct an
array that is then added to the main variant using g_variant_builder_add
which should clear the intermediate, but doesn't due to the way it is
passed: by value, rather than as a pointer.

This was debugged with the help of Eduardo Habkost, who believes it
works on x86 due to big structs being passed as pointers.

Fixed: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3440
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1848>
2021-05-18 23:06:50 +00:00
Olivier Fourdan
d9239e2cee windowManager: Ignore error without systemd
On systems/setups not using systemd, a failure to start gsd-xsettings
with NOT_SUPPORTED does not denote a failure to start Xwayland, just
that we're not using systemd.

In that case, we should just ignore the error, otherwise it will prevent
Xwayland to start on such systems/setups without systemd.

Thanks to Rose Kunkel (@rosekunkel) for spotting the issue/suggesting
the fix.

Fixes: 019229c40e - windowManager: Return failure to start X11 services
Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4284
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1850>
2021-05-18 14:31:28 +00:00
Jonas Ådahl
08fb067d24 js: Get idle monitor from backend
Its ownership has moved from dangeling to owned by the backend, which
has reflected the API is accessible by. Adapt to this change.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1838>
2021-05-18 13:42:52 +00:00
Quentin PAGÈS
3c6fd75ab7 Update Occitan translation
(cherry picked from commit 2c07918169e6f201a5d87d0a5bc44c1d751cf1aa)
2021-05-16 08:22:59 +00:00
Florian Müllner
cd7572f269 Bump mutter requirement 2021-05-14 17:16:35 +02:00
Florian Müllner
fe466fafce Post-release version bump 2021-05-14 16:54:06 +02:00
Florian Müllner
8e644ec39b Tag release 40.1
Update NEWS.
2021-05-13 16:46:39 +02:00
Quentin PAGÈS
65a35a9c36 Update Occitan translation 2021-05-13 13:47:12 +00:00
Georges Basile Stavracas Neto
0ed1a363a3 workspacesView: Queue relayout when overview adjustment value change
The overview adjustment quite significantly impacts the layout of
SecondaryMonitorDisplay(), and this needs to be accounted for by queueing
a relayout.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1845>
2021-05-12 18:08:55 +00:00
Georges Basile Stavracas Neto
81210f5846 workspacesView: Don't update secondary monitor thumbnails box if hidden
And save quite a few C/JS trampolines. Since the thumbnails box may not
have up-to-date properties, call _updateThumbnailParams() right after
showing the thumbnails box.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1845>
2021-05-12 18:08:55 +00:00
Georges Basile Stavracas Neto
a63c44ba2c workspacesView: Increase secondary monitor workspace scale
The current value, 70%, may end up leaving too much unused space on
secondary monitors. The new value of 80% is completely based on trial
and error, but seems to work slightly better.

Closes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3820

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1845>
2021-05-12 18:08:55 +00:00
Florian Müllner
803b944ffd appDisplay: Add :gesture-modes property
Both the main app grid and folders got a swipe tracker, which is
active in both OVERVIEW and POPUP mode. The result is that two
trackers fight over the same events, and everybody loses.

Address this by adding a :gesture-modes property that determines
the allowed modes for the associated swipe tracker.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4256

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1844>
2021-05-12 01:02:19 +02:00
Carlos Garnacho
6fc93b78bc appDisplay: Improve app grid interaction for touch devices
Currently, handling of touch devices in the app grid is a bit awkward,
paging by dragging the view can only happen if started from the gaps
between icons, trying to drag from an icon will trigger DnD, and popping
up the menu takes over it all.

Instead, have the app grid actions play this game of rock-paper-scissors:
- Fast swipes on icons trigger scrolling, beats DnD and menu
- Slower press-and-drag on icons trigger DnD, beats scrolling and menu
- Long press triggers menu, beats scrolling, is beaten by DnD

This allows quick swipes to handle navigation, while still allowing the
fine grained operations. DnD, when triggered, dismisses the menu, if
shown.

This all could probably be nicer with a more stateful gesture framework,
we're not there yet though.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3849
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1774>
2021-05-11 16:13:49 +00:00
Carlos Garnacho
91a7978711 grabHelper: Propagate events while this._ignoreUntilRelease
Let these events to be handled as usual, so that the grabbing actor
can handle input differently (e.g. trigger DnD) while the grabHelper
is active.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1774>
2021-05-11 16:13:49 +00:00
Carlos Garnacho
ecead8c727 dnd: Add timeoutThreshold setting
This setting (by default, 0) sets a time threshold in order to allow
DnD. If the drag is shorter than this threshold, DnD will be cancelled,
and event handling left to the next handlers.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1774>
2021-05-11 16:13:49 +00:00
Carlos Garnacho
279db3f168 st/button: Consider touch sequences for ::pressed state
We do notify on the ::pressed property after touch begin/end and
recording the event sequence, but we do not return the correct value
if the button was triggered via touch.

Consider the event sequence also in the ::pressed getter, so the
button is considered pressed.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1774>
2021-05-11 16:13:49 +00:00
Sebastian Keller
0a7507c617 altTab: Avoid allocation cycle when showing CyclerHighlight
CyclerHighlight was showing and resizing one of its child widgets when
its own allocation was changed, queuing another relayout, resulting in
allocation cycle warnings. Avoid this by updating the size of the
highlight when the frame rect of window has changes rather than the size
of the CyclerHighlight actor itself.

Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4167
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1842>
2021-05-11 17:36:29 +02:00
Leleat
5423179844 switcherPopups: Correct selection with arrows and scrolling using RTL
The switcherPopups use _next() and _previous() to get the items
in the text direction. I. e. with LTR _next() gets the right item;
on RTL it gets the left item. This doesn't work well with RTL when using
the arrow keys since the text direction doesn't matter in those cases.
Pressing Left Arrow should still move left regardless of text direction.
So use the opposite methods.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2547

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1835>
2021-05-11 14:09:33 +00:00
Olivier Fourdan
019229c40e windowManager: Return failure to start X11 services
If for some reason the xserver failed to start, mutter/gnome-shell
should not attempt to connect to the X11 display otherwise it will
lock up in XCB.

An indication of such a premature failure of the xserver is when the X11
services fail to start.

Return the status so that the caller can cancel the connection in time
and avoid the lockup of mutter/gnome-shell in case of failure.

This, however, makes the X11 services a critical component to start
Xwayland, meaning that a failure to start those services for any other
reason than the xserver failing to start would still prevent Xwayland
and therefore X11 clients to run in Wayland. This is however a lesser
issue than mutter/gnome-shell locking up.

This basically reverts commit a96753f0 - "windowManager: X11 can work
without gsd-xsettings".

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1837>
2021-05-11 14:05:40 +00:00
Florian Müllner
0ccdb4746f appDisplay: Extend faded edges beyond fade area
Now that the fade effect was reverted to the old behavior by default,
the app grid must opt-in extend faded edges beyond the regular fade
area.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1831>
2021-05-11 13:21:40 +00:00
Florian Müllner
3eda672929 st/scroll-view-fade: Add :extend-fade-area property
Since commit f60a469a34, everything outside the fade area is painted
fully transparent. That is required for the fade effect during app
grid navigation, to prevent unfaded parts of surrounding pages
becoming visible on wide-screen displays.

However in most other cases, that behavior is the exact opposite
of what we want: Elements outside the fade area (like scroll bars)
should never fade.

In order to fix the regular case, hide the new behavior behind a
property.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4234

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1831>
2021-05-11 13:21:40 +00:00
Nishal Kulkarni
2b2a71832a windowManager: Hide overview on using hotkey
Change behavior on pressing Super+Number in Activities/Overview mode
so that the overview mode is hidden and application can be used.

This makes it consistent with clicking icon in the dash.

Closes: #4212
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1839>
2021-05-11 12:50:01 +00:00
Sebastian Keller
234024c4f4 workspace: Update WorkspaceLayout workarea on changes
Previously the workarea was only set on construction and then never
updated. As a result the preferred width and height as well as the
allocation were based on an outdated workarea size when it changed after
construction. This for example was happening during the startup
animation, for which the WorkspaceLayout is constructed before the panel
is shown. This caused the workspace in the overview to be slightly
smaller when it is first shown and the overview closing animation to
not expand the workspace to the correct size the first time it is
closed.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3945
Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3816

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1771>
2021-05-11 02:36:54 +02:00
Quentin PAGÈS
a08355931f Update Occitan translation 2021-05-09 18:47:57 +00:00
Jordi Mas
78f82348a2 Update Catalan translation 2021-05-07 18:57:46 +02:00
Jonas Dreßler
954131c1c8 overview: Sync grabs after running startup animation
In the nested session the startup animation sometimes fails, weirdly
that always happens to me when running a freshly built gnome-shell the
first time. The reason it fails is that mutter fails to aquire a pointer
grab from the xserver, XIGrabDevice() is unsuccessful.

A simple workaround for this race condition in the xserver is to just
grab the devices a bit later, that is after the startups animation
instead of before it.

This was also tested with disabled animations, and seems to work just as
well in that case.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1812>
2021-05-04 16:18:30 +00:00
Sebastian Keller
e7780623fe dnd: Don't use transformed size to calculate parent scale when restoring
Some drag actor parents might change their width to 0 after the drag
actor has been removed. If the drag is now canceled and the drag actor
is animated to return to the current parent position and scale, this
scale can not be determined and falls back to 1.0. This might be wrong
and can result in the drag actor being too large/small at the end of the
return animation.

To avoid this calculate the scale of the parent by recursively
calculating the product of its parents individual scales.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4017

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1790>
2021-05-04 15:45:58 +00:00
Jonas Dreßler
bad94ab350 overview: Increase margin-top of the dash slightly
Now that we made window previews overlap the edges of the wallpaper
underneath them, the app icons of those windows are getting quite close
to the dash and there is almost no more spacing.

Let's make it look a little bit better and slightly increase the
margin-top of the dash so that the workspaces move a few more pixels
away from the dash.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1813>
2021-05-04 14:16:46 +00:00
Jonas Dreßler
4e83aaf850 workspace: Extend clip when animating from window picker to app grid
We want to clip the Workspace actor in the appGrid state of the overview
in order to make sure windows that overflow the monitor don't spill out.
So far we had commit b1970b95b8 for that.

Now since the last commit, window previews always slightly overflow the
allocation with their icons. That means a part of the window icon gets
clipped away as soon as the transition to the appGrid starts, which
looks weird.

Fix that bug in the transition by slightly extending the clip downwards
when animating between the window picker and the app grid state. The
extra height we extend the clip by is controlled by the overviewState,
which means we extend the clip by the full icon overlap in the window
picker state, but don't extend the clip at all when in the app grid
state.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1813>
2021-05-04 14:16:46 +00:00
Jonas Dreßler
fcc80407ea workspace: Make window preview overlays overflow the allocation
We want to use as much space as possible for showing window previews in
the overview, and the title and close buttons of those windows are only
visible on hover, so we can show them above anything if we want.

On both primary monitors and secondary monitors, there's a certain free
space available towards the bottom edge of the monitor (on the primary
monitor we show the dash there, and secondary monitors just scale down
the Workspaces). We can make use of this by checking how much free space
there is available from the bottom edge of our allocation to the bottom
edge of the monitor, and then aligning the window previews to make full
use of this space.

So stop adding any padding to the edges of the Workspace, which will
make the windows a lot larger and completely fill the Workspaces
allocation.

The left, top and right monitor edges should always be far enough away
to accomodate the close button and hover scale-up of the window. Only
with the bottom edge of the monitor we have to be a bit more careful
(the overflowing height of the window title is quite big), so there we
check if enough free space is available. If there isn't enough free
space, we simply apply a bit of bottom padding again and shift the
window up.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1813>
2021-05-04 14:16:46 +00:00
Jonas Dreßler
7f90a46f8c workspacesView: Clip the SecondaryMonitorDisplay instead of the view
Make the SecondaryMonitorDisplay a bit more similar to the
ControlsManager container on the primary monitor, and clip that widget
instead of the WorkspacesViews on secondary monitors.

This will allow us to overpaint the WorkspacesView allocation and paint
the WindowPreview overlays like the title and close button outside the
allocation with the next commit.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1813>
2021-05-04 14:16:46 +00:00
Jonas Dreßler
51bf7ec176 screencastService: Improve the gstreamer pipeline for recording
The current gstreamer pipeline performs quite bad on slower machines and
is dropping lots of frames, improve the pipeline by changing a few
things:

- Use threads for videoconvert and improve speed of videoconvert by
disabling some unneeded things
- Add a queue before the encoding step, this allows the encoder to work
at its own pace and will lead to a lot more stability
- Remove the fixed quantizer and only set a max quantizer, this helps
quite a bit with performance
- Change the deadline parameter of vp8enc to 1: This makes the encoder
go into real time mode, which will make it a lot faster
- Set cpu-used to 16, the maximum possible value.
- Set static-threshold to 1000, static-threshold is the motion detection
threshold, and while a value of 100 is recommended for screencasting in
the gstreamer documentation (see [1]), using 1000 appears to perform a
lot better and still outputs fairly good quality
- Set a larger buffer size than the default size, this seems to get a
bit more stability during high load scenarios

All in all, those changes make the pipeline drop no more frames when
recording at 30 FPS and 2K screen resolution. That was tested on a
fairly recent mobile core-i5 processor.

Also, because we now have two %T replacement strings for the number of
threads, we need to switch to replaceAll(). For that to work, we have to
put the %T matching expression into quotes.

[1] https://gstreamer.freedesktop.org/documentation/vpx/GstVPXEnc.html?gi-language=c#GstVPXEnc:static-threshold

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1633>
2021-05-04 13:45:57 +00:00
Simon Schneegans
a8a79c0333 extensionsService: Log error if preferences dialog failed to open
This is helpful for continuous integration checks to see whether the
preferences dialog of an extension can be opened successfully.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1830>
2021-05-01 21:07:36 +00:00
theRealPadster
396c12c925 theme: Move :hover below :focus in %bubble_button
Fix issue where background colour of modal buttons do not update when
hovering over a focused button.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1818>
2021-05-01 20:31:34 +00:00
Pawan Chitrakar
a472657490 Update Nepali translation 2021-05-01 11:11:13 +00:00
Joonas Henriksson
c17dc9c8ec theme: Rotate placeholder for horizontal workspace-thumbnails
On the new horizontal workspace-thumbnails, the old placeholder from
vertical dash appeared too small, and was easily hidden behind the
dragged window/icon. Rotate the placeholder 90 degrees to better fill
the spacing between thumbnails.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1801>
2021-05-01 00:16:29 +03:00
Sebastian Keller
79acae4176 dnd: Don't try to restore to parent location if parent got destroyed
The original parent of a dragged actor might have been destroyed after
the drag has been started. When the drag is canceled and _dragOrigParent
is set, the code is trying to get the current position and size of it
when restoring. With a destroyed parent this however would result in a
crash.

This could happen for example when starting a drag on a window preview
while the overview is hiding and then releasing it once the transition
is done.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4024

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1817>
2021-04-29 18:25:56 +00:00
Sebastian Keller
0e917c3dbf workspaceThumbnail: Only create thumbnails once
`ThumbnailsBox` listens for the `showing` signal from the `Overview` to
create its thumbnails and destroys them on the `hide` signal. Since the
`showing` signal can be emitted multiple times when switching between
the shown and hidden state without ever fully completing the transition,
this will cause `_createThumbnails` to be called multiple times, each
time adding another set of workspaces.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3819
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1828>
2021-04-29 17:58:45 +00:00
Sebastian Keller
77023135ac overviewControls: Stop transitions when starting a gesture
When starting a gesture to open the overview while a transition to hide
the overview is running, Overview._shown will be first set to false when
starting the transition and then to true by the gesture before the
`onComplete` callback is called. The `onComplete` callback in this case
is `Overview._hideDone()` which starts a transition to show the overview
again which also emits the `showing` signal. Since the gesture emits a
`showing` signal as well, this results in two consecutive `showing`
signals without a `hiding` signal in between.

This breaks the `searchControler` which adds a key press handler to
start the search on `showing` and removes it on `hiding`. So every time
this happens a new handler that will never be removed is added,
resulting in the first key press being repeated.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4004
Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3819
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1828>
2021-04-29 17:58:45 +00:00
Leleat
fd0da9606f appMenu: Only show Open Windows, if there are at least 2 windows
It doesn't make sense to show the 'Open Windows' in the app menu,
if the app only has 1 open window to switch between. Hide the
window section in that case.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4199.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1827>
2021-04-29 12:22:38 +02:00
Jakub Steiner
4bf2adb4b9 theme: App group styling
* Use the same style as the dash.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4002

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1800>
2021-04-29 09:51:57 +00:00
Sebastian Keller
401b584384 appDisplay: Don't use symbolic icon at full size for system actions
When attempting to account for scaling in e65e5ede the icon_size of the
StIcon was set to the target size, overriding the icon-size set in the
'system-action-icon' CSS, which was only half the size. The intent of
that commit however was not to scale up the symbolic icon, but the
circle around it. Do this by manually applying the scaling factor.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3940

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1777>
2021-04-29 09:42:40 +00:00
Florian Müllner
dedfdb6d0b dbusServices/screensaver: Disable auto-shutdown
For the screensaver service, it is quite normal that a consumer only
subscribes to the "ActiveChanged" signal without calling any methods.

The result is that we don't know about the consumer, and shut down
the service anyway after we hit the timeout.

If this happens, we break functionality like gnome-settings-daemon's
screen blanking on idle.

Fix this by simply disabling auto-shutdown for the service, which
also reflects the expectation that the screen saver service is
always running in a GNOME session.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4114

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1824>
2021-04-28 18:12:13 +00:00
Benjamin Berg
724291de7f gdm: Remove pending fingerprint verification failure
It can happen that we get a problem report and a verification failure at
the same time. For fingerprint, a problem report can result in an
internal verification failure to be queued.

Remove this queued failure again if we got a failure already from GDM
directly.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1821>
2021-04-28 17:23:01 +00:00
Ray Strode
588dd6d80a gdm: Only disconnect verification signals when not going to retry
At the moment a failure in a background service can lead to the
various verification signals getting disconnected, even though
we still need them for a foreground service.

This commit changes the code to only disconnect when we've run
out of tries.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1821>
2021-04-28 17:23:01 +00:00
Ray Strode
8cfd4c969b gdm: Flip canRetry boolean to doneTrying on verification failure
This commit flips a boolean in the verification failed handler
to make things easier to read.

It also moves the retry logic to the bottom where it makes more
logical sense.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1821>
2021-04-28 17:23:01 +00:00
Ray Strode
a97c4b8945 authPrompt: Don't fail auth prompt until user is out of retries
At the moment we set the state of the auth prompt to failed any
time the user fails an attempt. But verification is still going
on until the user exhausts all attempts, so that's wrong.

This commit changes it to only set the state to failed when the
user is out of tries.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1821>
2021-04-28 17:23:01 +00:00
Ray Strode
a56d508d69 authPrompt: Don't clear querying service unless querying service fails
At the moment we treat a failure in any service as a signal to stop
tracking users responses to service questions.

This commit makes sure we don't stop waiting for answers if a background
service fails.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1821>
2021-04-28 17:23:01 +00:00
Leleat
4e35ca8e26 windowPreview: Make St.Label use single line mode
When a windowPreview is hovered or selected, it will show its window's
title as a caption. That title may contain Newline characters which will
effect the windowPreview size. Make the caption's St.Label use single
line mode to prevent that.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4162

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1822>
2021-04-28 14:29:19 +02:00
Sebastian Keller
380d61dc43 screenshot: Ignore events in SelectArea after making a selection
The grab and actor are only removed after the selection rectangle has
finished fading out. During this time it was possible to still change
the position of the selection rectangle.

Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2761
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1825>
2021-04-28 11:40:19 +00:00
Sebastian Keller
548e18ad7e screenshot: Only select area on button release after a button down
On Wayland it is possible to trigger area selection with a button
already being down. SelectArea would then react to the subsequent button
release without ever having seen a corresponding button down first,
leaving the start coordinates of the selection rectangle uninitialized.

Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2761
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1825>
2021-04-28 11:40:19 +00:00
Carlos Garnacho
82c2f293a0 keyboard: Always emit ::pressed late on keys with variants
When we press a key with variants, we used to prevent an
early ::pressed, because a long press could show the options
popover, and the press be undone.

In addition, this long press could move to one of the suboptions,
and be released there. For this case we also want this late
emission of the ::pressed signal.

This makes the "tap, drag, release" pattern work on the
regular OSK keys, in addition to the emoji panel.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1789>
2021-04-27 22:02:53 +02:00
Carlos Garnacho
40e53492ab keyboard: Allow calling _release() without press on OSK keys with touch
This is already allowed for pointer events, but touch events still expected
that the touch begin and end happen on the same Key actor. Change this
behavior for touch events, this is necessary for the tap-drag-release
pattern to select key variants to work on all input devices.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1789>
2021-04-27 21:58:24 +02:00
Prajna Sariputra
6ee2c4f74c status/power: Always show real percentage in battery label
We currently display the percentage as "100%" if the battery state is
"fully charged", but the actual capacity may be lower than that.

Just show the real percentage, which is consistent with Settings.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3393

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1787>
2021-04-27 21:04:34 +02:00
Jonas Dreßler
1cefd589da st: Only use clutter_actor_invalidate_paint_volume() if the API exists
With commits fab39bbea5 and
62e40a1350 we started depending on a new
ClutterActor API: clutter_actor_invalidate_paint_volume()

Given that this commit was applied to the 40 stable release, it broke
ABI compatibility with mutter, which is something we guarantee between
stable releases. So use GModule to dynamically find the symbol in our
loaded libraries. If it exists, use it and invalidate the paint volume.
If it doesn't exist, libmutter is still at version 40.0 and we don't
need to invalidate the paint volume.

This also adds a dependency on gmodule. We need to link against gmodule
to use g_module_open() and g_module_symbol() APIs.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1807>
2021-04-26 12:18:52 +00:00
Stas Solovey
d7ad8da48d Update Russian translation 2021-04-25 19:52:35 +00:00
Ray Strode
1196532493 loginDialog: Allow timed login with disabled user list
At the moment the timed login feature is implemented in the user list.
If there's no user list, we don't show the indicator anywhere and
don't proceed with timed login.

This commit allows timed login to work when the user list is disabled.
It accomplishes this by putting the timed login indicator on the
auth prompt in that scenario.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1809>
2021-04-23 16:00:39 -04:00
Ray Strode
1410db2470 loginDialog: Realign list of batch tasks
The way the batch tasks are currently aligned doesn't jive with
with eslint likes.

This commit moves it over a bit.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1809>
2021-04-23 15:56:22 -04:00
Sebastian Keller
b93bf2bd69 altTab: Avoid setting GObject property to undefined instead of null
The windowActor in the CyclerHighlight was set to undefined if
this._window was null. This was causing an error when trying to set it
as a property.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4167

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1820>
2021-04-23 15:21:56 +00:00
Florian Müllner
28723ac088 overviewControls: Support double-super when animations are off
When super is pressed again during the overview transition, we shift
up to the app grid. That means that the feature currently doesn't
work when animations are disabled (like in a VM), because there is
no transition in that case.

Address this by adding a time-based fallback in that case, i.e.
shift up when a second super-press occurs within 250ms after the
first one.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4121

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1811>
2021-04-19 20:24:54 +00:00
Florian Müllner
d823141360 dialog: Ensure action callback is called with no arguments
Using the callback directly as signal handler means that it will
receive the signal parameters (in this case: the StButton instance
that emits the signal).

This leaks an implementation detail that is harmless in the best
case, but can break dialogs when using bind() on the callback.

Avoid that trap by explicitly calling the callback without arguments.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4139

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1819>
2021-04-19 19:12:59 +02:00
Florian Müllner
7eba5322b5 audioDeviceSelection: Ensure close() is called with no arguments
This is the same as commit c5b18ee66a, but for the audio device selection
dialog.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4139

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1819>
2021-04-19 19:12:59 +02:00
Florian Müllner
7935da6168 audioDeviceSelection: Move a method to the new coding style ...
... before touching its code in the next commit.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4139

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1819>
2021-04-19 19:12:59 +02:00
Dušan Kazik
6159a91660 Update Slovak translation 2021-04-18 19:19:22 +00:00
Frederic Crozat
d9e953e93c st/scroll-view: Ensure float are used explictly
Pineview needs explicit float to prevent error when shader is compiled.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4127
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1815>
2021-04-16 19:23:06 +00:00
Alexander Mikhaylenko
58ed969dd1 background: Check xml mime type instead of extension
This is required to be able to set animated wallpapers with the wallpaper
portal, which names them 'background' without an extension.

See https://gitlab.gnome.org/bertob/nostalgia/-/merge_requests/12

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1816>
2021-04-16 19:53:53 +05:00
Jonas Ådahl
1f0ef7fb46 workspaceThumbnail: Update monitor index on 'monitors-changed'
For the primary monitor workspace thumbnail, we must keep the monitor
index in sync with what is currently the primary monitor index,
otherwise we might end up trying to move windows to non-existing
monitors.

For example, if the primary monitor index was 1 when the thumbnail box
was created, but later, the primary monitor index changed to 0, with the
other monitor being turned off, moving a window to one of the workspaces
on the workspace thumbnail, gnome-shell would attempt to move it to the
monitor with the index the primary monitor had in the past, with the
problem being that that monitor no longer exists.

Fix this by listening on the 'monitors-changed' signal on the layout
manager, and update the monitor index of the primary workspace
thumbnails box. Make sure to connect to the signal before creating the
thumbnails box, as the thumbnails box itself will listen to the signal
and recreate its actual thumbnails, and it must do this with the up to
date monitor index.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4075
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1810>
2021-04-14 15:43:09 +00:00
Jia Chao
f76e6877c7 keyboard: Fix suggestions box
The suggestions box actor was not being correctly populated.
Make it correctly use the St.BoxLayout add_child() method.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3422
Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2965
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1806>
2021-04-13 10:02:09 +00:00
Jonas Dreßler
62e40a1350 st/widget: Invalidate paint volume on style changes
StWidget is overriding ClutterActors get_paint_volume() vfunc to adjust
for overpaint of things like box shadows that get set in CSS, it does
that by setting the paint volume to the theme nodes paint box.

Since StWidget can't really get notified when the paint box changes, we
just invalidate the paint volume when the theme nodes paint_equal()
returns FALSE.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1484>
2021-04-12 17:08:23 +00:00
Jonas Dreßler
fab39bbea5 st/viewport: Invalidate the cached paint volume of ClutterActor
Since StViewport uses the value of the StAdjustment to create its custom
paint volume, ClutterActors newly introduced proper caching of paint
volumes doesn't get notifed about changes to that paint volume and will
simply reuse the cached old one.

So make use of the newly introduced
clutter_actor_invalidate_paint_volume() method to make sure ClutterActor
will ask for the paint volume again on the next paint.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1484>
2021-04-12 17:08:23 +00:00
Georges Basile Stavracas Neto
eb96288738 overviewControls: Use correct state when updating AppDisplay visibility
When OverviewControls goes from HIDDEN to APP_GRID, it constantly checks
if AppDisplay needs to be visible or not by checking the current overview
state is bigger than WINDOW_PICKER. Turns out in this case this check is
problematic, because when the current state trespasses WINDOW_PICKER, the
layout manager will have already positioned AppDisplay halfway to its final
position.

Use either the final or the current state, whichever is biggest, when updating
the AppDisplay visibility. It optionally allows passing the overview state
params to _updateAppDisplayVisibility() so that we avoid a few trampolines to
recaltulate the adjustment state.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1805>
2021-04-12 12:06:30 -03:00
Andrew Zaech
ce4ece2c44 util: Use fade_margins in ensureActorVisibleInScrollView function
Commit f60a469a34 removed vfade_offset in favor of fade_margins.
Util.ensureActorVisibleInScrollView function needs to be adjusted
accordingly.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4080

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1802>
2021-04-10 15:20:43 +02:00
Jan Tojnar
53dd291aba extensionsService: Really fix copying technical details
gdk_clipboard_set_text() is not introspectable, we have to use
gdk_clipboard_set_value() (shadowed as gdk_clipboard_set())
instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1796>
2021-04-09 20:53:34 +00:00
Emin Tufan Çetin
d3b28e72aa Update Turkish translation 2021-04-09 07:42:21 +00:00
Emin Tufan Çetin
1d8d2344f3 Update Turkish translation 2021-04-09 07:38:16 +00:00
Florian Müllner
dd7d336228 workspacesView: Don't tie PgUp/PgDown to mapped state
Both app grid and window picker are now always visible in the overview,
so their handling of the PgUp/PgDown keys conflicts.

Resolve that by checking for the overview state instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1798>
2021-04-08 20:48:58 +02:00
Florian Müllner
fc54e0bed8 workspacesView: Fix PgUp/PgDown shortcut
We still try to switch to the workspace above/below, which doesn't
do anything since the layout is now horizontal.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1798>
2021-04-08 20:48:58 +02:00
Jonas Dreßler
dda23fc4c6 workspace: Center window previews horizontally and vertically
Window previews looks slightly offset to the left and top right now
because we don't use the same padding on all edges of the Workspace. We
do that because the oversize and overlap of the window previews is
different on all sides (for example the bottom overlap is very large
because there we show the window title).

To make sure window previews are always perfectly centered on the
Workspace, only use the largest one of the oversize values as spacing
and padding, and add the larger one of the overlap values for the
vertical padding in addition.

With this, we now center the window previews on the Workspace while
never overpainting the allocation of that Workspace to show overlays.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3634

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1670>
2021-04-08 17:51:15 +00:00
Sebastian Keller
6f0589313d appDisplay: Ensure icon grid is always aligned with the pixel grid
When adaptToSize was called with an odd width, the calculated padding
was not an integer and as a result the icon grid was no longer aligned
to the pixel grid. Similarly it was possible for the page size to be a
non-integer value, which was causing items to not be aligned for
pages > 1.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4015

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1799>
2021-04-08 16:50:46 +00:00
Jan Tojnar
1b5d71130e extensionsService: Fix copying technical details when extension crashes
This was forgotten when porting to GTK 4, leading to the following error
when user tries to copy the error message produced by an extension:

	JS ERROR: TypeError: Gtk.Clipboard is undefined
	_initActions/<@resource:///org/gnome/Shell/Extensions/js/extensionsService.js:255:31
	run@resource:///org/gnome/Shell/Extensions/js/dbusService.js:177:20
	main@resource:///org/gnome/Shell/Extensions/js/main.js:19:13
	run@resource:///org/gnome/gjs/modules/script/package.js:206:19
	start@resource:///org/gnome/gjs/modules/script/package.js:190:8
	@/nix/store/fwnkwvhwm3kqck4fhkc5y5z853radggg-gnome-shell-40.0/share/gnome-shell/.org.gnome.Shell.Extensions-wrapped:7:17

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1795>
2021-04-08 08:10:36 +02:00
Carmen Bianca BAKKER
3aa3231a9a Update Esperanto translation 2021-04-07 12:00:19 +00:00
Florian Müllner
e6be180df1 main: Use session mode property for welcome dialog
We only want to show the welcome dialog in the user session, not
on the login screen or during initial setup. We currently achieve
that by explicitly checking for those mode names, but there are
other modes like gnome-classic where the dialog is equally un-
helpful. Support those cases by adding a session mode property
that determines whether the welcome dialog should be enabled,
so that modes can opt in or out of the feature themselves.

(Both the 'gdm' and 'initial-setup' modes are based on the
'restricted' mode, so this change does not affect them)

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4026

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1793>
2021-04-06 18:57:39 +00:00
Cédric Valmary
d5af1fa098 Update Occitan translation 2021-04-06 07:14:49 +00:00
arushsharma24
b2a5417c3e theme/panel: Remove spacing between Activities and appmenu
Top bar elements now have more padding, which makes the spacing between those
elements excessive, so remove it.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3769

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1764>
2021-04-02 19:23:06 +00:00
Zander Brown
2f70e524c3 remoteSearch: Fetch enabled/disabled list once
GLib should be caching the values but it seems unnecessary to fetch
and marshal what should be the same lists N times instead of just once

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1791>
2021-04-02 19:07:56 +00:00
Suryashankar Das
4bfb91c5cd overview: Pass state while calling _animateVisible()
Pass OverviewControls.ControlsState.WINDOW_PICKER to the _animateVisible
function in _hideDone().

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3876
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1769>
2021-04-02 10:20:32 +00:00
Nathan Follens
b3f34d12f1 Update Dutch translation 2021-04-01 18:37:20 +00:00
Carlos Garnacho
a7a7ea4af7 appDisplay: Save pages after drag end
In the case that we drop an app in the dash, we take the icon
out of its current page, but we forget to save the page after
that.

This results in oddities dragging further elements around, as
the PageManager does no longer consider them to be in the
positions they actually are.

Related: https://bugzilla.redhat.com/show_bug.cgi?id=1939984
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1775>
2021-03-31 10:35:26 +00:00
Sebastian Keller
dfc44973de status/network: Disconnect signal handler on destroy in NMConnectionItem
Otherwise this can trigger _sync() calls after the objects it is trying
to update have been destroyed.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4013

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1782>
2021-03-31 10:31:12 +00:00
Yuri Konotopov
02b06385ea extensionDownloader: Use POST request for checking updates
Usage of GET requests for checking updates was made deprecated
at website some time ago [1], but REST endpoint was
CSRF-protected until recently [2].
The body of update request may be big enough and thus does not
suitable for GET requests.

[1] 0b38da1b2b
[2] e3ab0c07dc

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1781>
2021-03-31 13:31:00 +04:00
Yaron Shahrabani
687b84c90a Update Hebrew translation 2021-03-29 22:24:43 +00:00
Peng Wu
f563424417 keyboard: Fix display keyboard layout crash with some input methods
Some ibus input method will use the current keyboard layout,
and return "default" as the keyboard layout.
When this happens, display the current keyboard layout instead.

Fixes #3863.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1756>
2021-03-29 09:33:45 +00:00
Yosef Or Boczko
51a7c9a8b8 Update Hebrew translation 2021-03-28 21:17:38 +00:00
Hugo Carvalho
2b4e269a5f Update Portuguese translation 2021-03-27 22:42:06 +00:00
Hugo Carvalho
4b93f15c5e Update Portuguese translation 2021-03-27 22:34:36 +00:00
Ngọc Quân Trần
116ca88b5c Update Vietnamese translation 2021-03-27 07:47:15 +00:00
Dz Chen
75cba51b74 Update Chinese (China) translation 2021-03-26 15:12:50 +00:00
Hannie Dumoleyn
66a0b0a70c Update Dutch translation 2021-03-25 16:48:30 +00:00
Boyuan Yang
463ade049b Update Chinese (China) translation 2021-03-25 02:35:41 +00:00
Carlos Garnacho
4dfc53cade hotplug-sniffer: Drop "volatile" from g_once_init_enter() sentinels
As documented in g_once_init_enter(): "While @location has a volatile qualifier,
this is a historical artifact and the pointer passed to it should not be
volatile.". And effectively this now warns with modern glibc.

Drop this from our logging function.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1770>
2021-03-22 11:12:23 +00:00
Carlos Garnacho
554d76a200 calendar-server: Drop "volatile" from g_once_init_enter() sentinels
As documented in g_once_init_enter(): "While @location has a volatile qualifier,
this is a historical artifact and the pointer passed to it should not be
volatile.". And effectively this now warns with modern glibc.

Drop this from our logging function.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1770>
2021-03-22 11:12:23 +00:00
Timo Jyrinki
8aa7a376c4 Update Finnish translation 2021-03-21 16:42:40 +00:00
Florian Müllner
bf6d668cab Post-release version bump 2021-03-20 13:40:49 +01:00
Florian Müllner
c40d382c56 Tag release 40.0
Update NEWS.
2021-03-20 13:09:53 +01:00
Dušan Kazik
f9db8fd309 Update Slovak translation 2021-03-18 09:34:27 +00:00
Zander Brown
ec071ae4c2 Update British English translation 2021-03-16 17:36:07 +00:00
Florian Müllner
750ade34da extensions-app: Fix broken metainfo
Eeeks, should have put the post-release version bump into a MR.
2021-03-15 16:39:28 +01:00
Florian Müllner
55323e44af Post-release version bump 2021-03-15 16:23:45 +01:00
Florian Müllner
1d5f3f14fa Tag release 40.rc
Update NEWS.
2021-03-15 16:17:06 +01:00
Daniel van Vugt
1f0e4b58ab keyboard: Handle symbolic OSK key codes as explicitly invalid
`key` is an empty string in this case, causing `charCodeAt(0)` to return
`NaN`, which when passed to `Clutter.unicode_to_keysym` now generates an
error in gjs >= 1.67.3:

```
JS ERROR: Error: Argument wc: value is out of range for uint32
```

And the symbolic keys like Backspace, Enter and Caps Lock would have their
presses ignored.

Just skip the call to `charCodeAt` that will fail and allow
`Clutter.unicode_to_keysym` to return its usual error flag.

Fixes: https://bugs.launchpad.net/bugs/1918738
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1758>
2021-03-15 12:41:10 +00:00
Daniel van Vugt
c5b18ee66a status/network: Ensure the Cancel button passes undefined to close()
The parameter to `ModalDialog.close(timestamp)` is optional. But when
invoked via the network dialog's Cancel button it was receiving an
implicit parameter value that's definitely not a timestamp:

```
[0x560f18af0c50 StButton.modal-dialog-linked-button:first-child hover ("Cancel")]
```

And as of today (or gjs >= 1.67.3) that's reported as an error:
```
JS ERROR: Error: Argument timestamp: value is out of range for uint32
popModal@resource:///org/gnome/shell/ui/main.js:638:12
popModal@resource:///org/gnome/shell/ui/modalDialog.js:206:14
close@resource:///org/gnome/shell/ui/modalDialog.js:179:14
```
and so you can't Cancel the dialog anymore.

Make sure `ModalDialog.close()` receives an `undefined` timestamp it
knows how to handle.

Fixes: https://bugs.launchpad.net/bugs/1918666
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1757>
2021-03-15 18:19:04 +08:00
Milo Casagrande
a24c1d28eb Update Italian translation 2021-03-15 08:03:53 +00:00
Florian Müllner
4a7c5890a8 shell/app: Explicitly handle (X11) fallback icon changes
Since commit 770231, StImageContent implements the GIcon interface, which
allowed us to represent all application icons as GIcon (app-info, X11 icon
property or themed fallback icon).

While that change made for a nicer ShellApp API, it did introduce a
conceptual issue in st_texture_cache_bind_cairo_surface_property():
GIcons usually represent static icons, while the ClutterContent
returned by that method updates automatically when the bound property
changes.

Address this by tracking the MetaWindow:icon property in ShellApp, and
update the fallback icon when it changes. With that, a GIcon object
always represents the same icon, and any icon change is reflected
by a corresponding GIcon change.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1761>
2021-03-14 20:36:41 +00:00
Florian Müllner
16b0d0d07c shell/app: Expose icon as property
A property can be more convenient than a method. More importantly,
we are about to allow the icon to change, so a property will be
useful to get notified about those changes.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1761>
2021-03-14 20:36:41 +00:00
Florian Müllner
0cf22f4a1b shell/app: Only release window ref when we are done
We hold a reference to all windows we track for the app. While that
reference is unlikely to be the last remaining one, we still shouldn't
release it until we are done with the window.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1761>
2021-03-14 20:36:41 +00:00
Florian Müllner
07a819f62b st/texture-cache: Split out load_cairo_surface_to_gicon() method
This is essentially st_texture_cache_bind_cairo_surface_property()
without the binding part.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1761>
2021-03-14 20:36:41 +00:00
Florian Müllner
5652550688 st/texture-cache: Fail loading invalid StImageContent
Creating a content object from a cairo surface may fail, in which case
we return an empty content with a 0x0 preferred size.

However when we treat such a content object as GIcon, we happily load
it anyway. Don't do that, so consumers like StIcon can fall back properly
to an alternative.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1761>
2021-03-14 20:36:41 +00:00
Sebastian Keller
f2db9b52c9 iconGrid: Only use page relative coords for orientation in getDropTarget
The x and y coordinates were both adjusted to be page relative, even
though the icon grid can only scroll in one direction. This was leading
to coordinates outside of the icon grid to be considered part of it and
a wrong drop target to be chosen.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3779

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1767>
2021-03-14 18:44:03 +00:00
A S Alam
822340fd86 Update Punjabi translation 2021-03-14 15:17:29 +00:00
Florian Müllner
3c221cea48 overview: Fix showApps() compatibility method
The method is unused in gnome-shell itself, but extensions may still
want to call it, so make sure it actually works.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3873

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1766>
2021-03-14 12:47:42 +00:00
Sebastian Keller
5062c4c9c2 st/texture-cache: Ensure icons keep their aspect ratio when scaled down
Window preview icons can get scaled down if the window they belong to is
very small and/or there are a lot of open windows. When scaled down this
way the icons would get scaled without keeping the aspect ratio. Fix
this by using a content gravity that keeps the aspect ratio.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3865

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1751>
2021-03-14 01:06:30 +00:00
Sebastian Keller
07f2d32087 st/texture-cache: Don't use content size request mode for surface icons
While most GIcons passed to this function cause a StImageContent to be
created with the requested size, cairo surface based icons already are
passed as StImageContent with a preferred size corresponding to the
size of the surface they were created from. As a result icons of window
backed applications were never scaled up like the other icons. Fix this
by ignoring the content size for these case.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1751>
2021-03-14 01:06:30 +00:00
Florian Müllner
d271a51bfd swipeTracker: Remove unused property
The :allow-long-swipes GObject property relies on the automatic
getter/setter added by gjs and is not actually backed by
_allowLongSwipes.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1765>
2021-03-13 22:32:23 +00:00
Jonas Dreßler
d49606bbaa overview: Get rid of panel ghost actor
Right now we use a ClutterClone ghost of the panel simply to add some
spacing to the top monitor edge.

We can remove the panelGhost by adjusting the allocations of all the
parts of the overview ourselves inside ControlsManagers vfunc_allocate,
this should also work with extensions that move the panel somewhere
else.

This makes the initial relayout of the overview significantly faster,
because we now no longer have to relayout the whole panel in the
process.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1755>
2021-03-13 22:13:25 +00:00
Jonas Dreßler
ae23ad372d overviewControls: Return zero preferred size
The OverviewControls actor gets allocated a fixed size by its parent,
the OverviewActor, anyway, so it's pretty useless to go through the size
request machinery and add up all the sizes of items in the iconGrid,
coming up with a preferred size that's wrong anyway.

Instead simply return a min and preferred size of 0 in
get_preferred_height/width of ControlsManagerLayout.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1755>
2021-03-13 22:13:25 +00:00
Jonas Dreßler
9152d6613b workspacesView: Store some variables outside the children-allocate loop
We've seen this to help quite a bit with performance previously, so also
do it here.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1755>
2021-03-13 22:13:25 +00:00
Jonas Dreßler
c239cd398d overviewControls: Hide the appDisplay when it's not shown
Hiding actors allows excluding them from layout, so by hidding the
appDisplay in all the cases where the overviewAdjustment is not actually
showing it, we can save a lot of time on the first frame of painting
the overview because we no longer have to layout the whole appGrid.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1755>
2021-03-13 22:13:25 +00:00
Jonas Dreßler
d21a0b186e iconGrid: Subclass a C actor for BaseIcon
We create a lot of BaseIcons for the appGrid, one for every app, and for
all of those we have to hop through JS to get the preferred width. That
makes it another obvious target for moving to C, so let's do that.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1755>
2021-03-13 22:13:25 +00:00
Jonas Dreßler
36b103525c keyboard: Correctly compare cursor rect to keyboard rect
The logic that decides whether we should shift the window up when the
cursor rectangle overlaps with the keyboard rectangle doesn't work
properly right now, we want it to work like this:

- If the currently focused window is shifted up, keep it shifted up
until the cursor rect no longer overlaps the keyboard rect. To do that
comparison correctly, we need to adjust for the height the cursor rect
is shifted up by (keyboardHeight) and temporarily shift it down again.

- If the currently focused is not shifted up, we want to shift it up as
soon as the focus rect overlaps the keyboard rect. If that's not the
case, want still want to call _setFocusWindow(null) in order to shift
the previously focused window back down.

This fixes two issues: 1) We're currently shifting windows back down at
the wrong position of the cursor (that is y < keyboardHeight). 2) We're
not shifting down previously focused windows when focusing a different
window with the new focus in a specific region (y >= keyboardHeight &&
y + h < monitor.y + monitor.height - keyboardHeight).

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1760>
2021-03-13 18:28:15 +00:00
Jonas Dreßler
95ed7c7a06 keyboard: Add proper tracking of window movements to focus tracker
So far the FocusTracker of the OSK can only recognize grab ops on a
window, that is when the user grabs the window using a mouse or the
touchscreen and actively drags it somewhere.

Window can also be moved using keyboard shortcuts, fullscreen buttons or
other ways which don't rely on grabs. Start also supporting those window
movements by listening to the "position-changed" signal on the currently
focused window and emitting the new "window-moved" signal in that case.

Because the OSK sometimes moves windows by itself, we temporarily
disconnect from that new signal while we move the focused window in
_windowSlideAnimationComplete().

This also takes care of resetting this._focusWindowStartY on movements
of the window.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1760>
2021-03-13 18:28:15 +00:00
Jonas Dreßler
7b990daee2 keyboard: Animate focus window using position instead of translation-y
Commit 8526776b4a changed the OSK to use
the translation-y property of the MetaWindowActor when animating a focus
window, which broke two things:

1) It's not compatible with the obscured region culling we do for
windows in mutter. That's because MetaCullable strictly operates in
integer coordinates and thus has to ignore any transformations
(translation-y is a transformation). Because of this, during the
animation and gesture, window damage is now tracked incorrectly,
introducing painting issues. The best fix for this would probably be
factoring in transformations when tracking damage in MetaCullable, but
that's not feasible right now.

2) It broke the shifting up of maximized and tiled windows, likely that
is because they are positioned using constraints internally, and mutter
enforces those constraints every time meta_window_move_frame() is
called, not allowing the window to move somewhere else.

To fix both issues, go back to the old way of shifting the window for
now, using the fixed y position of the ClutterActor. To make sure the
drag-up gesture still works, store the initial y1 position of the window
and then use that as a reference point for all our animations.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1760>
2021-03-13 18:28:15 +00:00
Jonas Dreßler
2cf8b93a7b keyboard: Allow closing immediately
Just like opening the OSK, make it possible to close it immediately,
we'll make use of this in the next commit.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1760>
2021-03-13 18:28:15 +00:00
Jonas Dreßler
95b83575cb keyboard: Don't move focusWindow back down on window grab
I suggested it myself when reviewing
https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1668, so
here I am reverting that again...

The difference between calling _setFocusWindow(null) and simply
unsetting the focusWindow is that the former animates the window back to
its position before we shifted it up, while the latter simply "lets go
of the window".

In this case we actually want the latter because after the user grabbed
the window, we obviously should not animate it away right underneath the
users pointer/finger.

To ensure the same mistake doesn't happen again, add a small comment
explaining why this code is as it is.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1760>
2021-03-13 18:28:15 +00:00
Alexander Mikhaylenko
f48e58a81a swipeTracker: Reset before emitting 'end' and not after
If the actor is unmapped in the handler, the touch gesture will cancel.
Since we haven't reset the state yet, it will still work and will actually
cancel the gesture, so reset before that instead.

Fixes overview cancelling when trying to open it with a swipe.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1731>
2021-03-13 18:08:24 +00:00
Alexander Mikhaylenko
3c1074085e swipeTracker: Clamp position when long swipes are enabled too
Avoid wrapping back to the first page when swiping forward from the last
page.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1731>
2021-03-13 18:08:24 +00:00
Alexander Mikhaylenko
df4c05f834 swipeTracker: Pass orientation in constructor
When this class was written, all swipes in the shell were vertical, so it
made sense to make the default orientation vertical. This isn't the case
anymore, thus pass make it mandatory to specify orientation when creating
a tracker.

Change the property default values to horizontal as well to match Clutter
instead of the old shell design.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1731>
2021-03-13 18:08:24 +00:00
Alexander Mikhaylenko
c06bc74d6d swipeTracker: Check orientation with a threshold for touchpad
Avoid picking the direction too early.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3755

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1731>
2021-03-13 18:08:24 +00:00
Kjartan Maraas
3d2812063f Update Norwegian Bokmål translation 2021-03-13 16:52:25 +00:00
Florian Müllner
53adc7b733 Revert "theme/panel: Remove spacing between Activities and appmenu"
As minor as the visual change is, it's still a UI change.

This reverts commit 91c4c43a7d.
2021-03-13 01:27:51 +01:00
Jonas Dreßler
b160e44dab keyboard: Stop offsetting the focus rectangle
The focus rectangle of the OSK currently gets stored with an offset that
removes the global coordinates and makes it window-local coordinates.
This offsetting has been applied since the introduction of the
FocusTracker with commit fc5ab44704 and it
seems there's no real reason for it.

By removing this, we also emit position-changed when the window has
moved but the window-local coordinates stayed the same. We really want
to emit position-changed in that case because it might affect whether
the window needs to be shifted up.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1728>
2021-03-12 15:56:12 +00:00
Jonas Dreßler
746230f8b6 keyboard: Ignore focus rects outside the window
Apparently some clients, including gtk don't "clip" the focus rectangle
to their window bounds when scrolling the focus outside the window. This
makes us shift up windows when the focus actually is no longer visible.

This issue needs fixing in GTK, it should probably stop reporting
focus changes when the focus moves outside of the visible view. We can
still do a little bit better on our side though and "clip" the rectangle
to the windows frame rect: If it moves out of the window, we simply stop
updating our focus rect.

The intersection check introduces a small problem though: Some clients
(for example gedit) will give us a cursor rect that has a 0 width or
height. This won't play well with graphene_rect_intersect()
(GrapheneRects never intersect if they are 0-sized), so we set the size
to 1 in case we get a 0-sized rectangle.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1728>
2021-03-12 15:56:12 +00:00
Jonas Dreßler
7c83cbe135 keyboard: Use GrapheneRect in focus tracker
This will be useful in the next commit.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1728>
2021-03-12 15:56:12 +00:00
Jonas Dreßler
3acf840c99 keyboard: Initialize the FocusTrackers current window correctly
The FocusTracker keeps track of the currently focused window using its
internal this._currentWindow property. It will only pick up the focused
window though when receiving a "notify::focus-window" signal, so the
focused window that's set when the FocusTracker is created won't be
picked up.

Fix that by setting the _currentWindow during creation of the
FocusTracker.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1728>
2021-03-12 15:56:12 +00:00
Jonas Dreßler
d8adeba6b6 keyboard: Properly destroy focus manager when destroying keyboard
We're currently leaking this object, so make sure to disconnect
everything properly and plug the leak.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1728>
2021-03-12 15:56:12 +00:00
Jonas Dreßler
6f39d76a3e keyboard: Remove unused argument
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1728>
2021-03-12 15:56:12 +00:00
Jonas Dreßler
9f415f1c89 keyboard: Make a few functions private
Now that we got rid of the external calls to setCursorLocation(), we can
make that private. animateShow() and animateHide() weren't called from
outside anyway, so let's make those private, too.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1728>
2021-03-12 15:56:12 +00:00
Jonas Dreßler
f3f0396b7e keyboard: Clear keyboard rest timer when opening immediately
When immediate is true on open(), we want to show the OSK immediately,
it also makes sense to cleanup the keyboard rest timer in that case.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1728>
2021-03-12 15:56:12 +00:00
Jonas Dreßler
cb68bbee36 keyboard: Rename focusTracker "reset" signal to "window-grabbed"
What this signal does is fire when a window was grabbed. A receiver
might want to do something special when a window was grabbed, whereas
"reset" can mean anything. Rename the "reset" signal to
"window-grabbed".

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1728>
2021-03-12 15:56:12 +00:00
arushsharma24
91c4c43a7d theme/panel: Remove spacing between Activities and appmenu
Top bar elements now have more padding, which makes the spacing between those
elements excessive, so remove it.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3769

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1754>
2021-03-12 13:39:43 +01:00
Changwoo Ryu
a57d66a993 Update Korean translation 2021-03-12 02:14:03 +00:00
Florian Müllner
16c7739170 messageTray: Remove deprecated code
Originally the Source method for showing notifications was "notify",
which had to change when turning it into a GObject subclass to not
clash with g_object_notify().

That change happened during the 3.36 cycle, so extensions have had
two releases (a year) to adapt to the replacement. That seems long
enough, so remove the deprecated compat code.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3848

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1749>
2021-03-10 15:17:52 +00:00
Fabio Tomat
e854b26fa7 Update Friulian translation 2021-03-10 12:26:00 +00:00
Jakub Steiner
db1336120c styling: Update for darker system grey
- darken buttons similarly to the app grid groups
- entries as well
- adjust foreground color of additional elements to
  work for 'light' variant as well

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3847

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1748>
2021-03-10 12:10:18 +00:00
Christian Kirbach
095d7c36f7 Update German translation 2021-03-09 21:18:33 +00:00
Jonas Dreßler
59b97a3095 workspace: Use Util.lerp() instead of actor box for interpolating
Instead of interpolating our workspace and layout boxes for each child
using clutter_actor_box_interpolate(), use our Util.lerp() function and
stay in JS land instead.

This is quite a large performance improvement since it avoids
heap-allocating a new ClutterActorBox for every child. With this, we're
finally at a duration of 1.0 ms to allocate the Workspace with 20
windows.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1743>
2021-03-09 15:40:49 +00:00
Jonas Dreßler
afb56df55c windowPreview: Subclass a C actor
Move the get_preferred_width/height() and allocate() vfunc
implementations of WindowPreview to C, subclassing the C GObject from
JS.

This gets us another significant performance gain, allocating a
workspace with 20 windows now only takes 1.2 ms.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1743>
2021-03-09 15:40:49 +00:00
Jonas Dreßler
650e0960a2 workspace: Get some values outside the children loop when allocating
It turned out that getting properties and saving them to a variable
outside of loops instead of accessing them everytime inside the loop can
have significant impact on performance, so do that in Workspaces
vfunc_allocate().

Here the impact is not that large, about 0.05 ms with 20 open windows,
that still seems worth it though.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1743>
2021-03-09 15:40:49 +00:00
Jonas Dreßler
5792b98f79 workspace: Don't create useless childBox
Creating a ClutterActorBox here is superfluous, we actually create and
assign a new box to this variable inside the loop.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1743>
2021-03-09 15:40:49 +00:00
Jonas Dreßler
ec4b9b8894 workspace: Don't do checks in animateAllocation()
These checks aren't needed since Clutter should enforce this for us
already and skip the implicit transition when possible. This gets our
time spent in vfunc_allocate() down to 2.0 ms with 20 windows

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1743>
2021-03-09 15:40:49 +00:00
Jonas Dreßler
3e9a08a2e1 workspace: Use set_origin/set_size instead of properties when allocating
Setting four properties is more expensive than calling two C functions,
so move to set_origin()/set_size() calls for our ClutterActorBox
handling.

This gets us down to an average time of 2.1 ms spent in vfunc_allocate()
with 20 windows

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1743>
2021-03-09 15:40:49 +00:00
Jonas Dreßler
e75f3a8aed workspace: Iterate windowSlots directly when allocating
We can save a little bit of time in this loop by iterating directly
over the windowSlots array instead of iterating through children and
then performing a search for the windowSlot. This saves more time and we
only spend 2.2 ms instead of 2.3 ms in vfunc_allocate() now.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1743>
2021-03-09 15:40:49 +00:00
Jonas Dreßler
04c781674c Move WindowPreviewLayout from JS to C
This layout manager is used quite often and the time we spend calling
it's allocate and get_preferred_width/heigth functions increases with
every open window.

We can save a lot of precious time during the layout cycle by moving
this layout manager from JS to C, thus avoiding the overhead of
trampolining between C and JS land.

In a measurement where the average time spent in vfunc_allocate() of the
Workspace actor was measured while opening an overview with 20 windows,
the average time spent went down from 3.1 ms to 2.3 ms.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1743>
2021-03-09 15:40:49 +00:00
Jonas Dreßler
3eb40df06b panel: Don't change text color when entering the overview or lockscreen
With the introduction of the transparent panel in the overview, we
started making the panel text/icon color slightly brighter in the
overview and on the lockscreen to ensure best contrast. Now
unfortunately, setting the text color incurred a relayout of the
underlying ClutterText actor (fixed with
https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1750), and
setting the icon color causes the icon texture to get regenerated
(fixed with
https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/932).
Regenerating the icon texture will replace the icon actor, which also
causes a relayout.

This relayout of the panel has been measured to add at least 1
millisecond (the numbers fluctuated a lot) to about 5 ms it takes to
layout the first frame when showing the overview.

Since https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/932 is
unlikely to land this cycle, this commit proposes a different solution:
Simply don't use a different color for text in the overview. To avoid
issues with contrast in the overview, make the default color slightly
brighter and change it from #ccc to #ddd.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1733>
2021-03-09 13:15:09 +00:00
Jonas Dreßler
5de9166f7a panel: Only update appMenu icon when the app actually changed
Right now we always recreate the icon of the appMenu when calling
_sync(). This will relayout the panel everytime we open the overview,
because we call _sync() in that case.

We can easily avoid that by only recreating the icon actor in case the
app that's opened actually changes. This gets us close to doing no more
relayouts of the panel when opening the overview.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1733>
2021-03-09 13:15:09 +00:00
Jonas Dreßler
e6c1db2bc8 panel: Don't completely hide AppMenuButton when invisible
We already set the AppMenuButton to be non-reactive and transparent when
we hide it. Hiding it completely using clutter_actor_hide() will
additionally make it no longer affect layout and thus queue a relayout.

Since we hide the appMenu in the overview and we want to avoid
relayouting the panel when entering and leaving the overview, don't
completely hide the AppMenuButton to avoid queueing this relayout.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1733>
2021-03-09 13:15:09 +00:00
Florian Müllner
fb1ab4f20b windowManager: Limit super-scroll handling to normal mode
The overview has it's own workspace scroll handling, and we don't want
to switch workspaces in other modes. Limiting the scroll-event handler
to NORMAL mode matches the swipe tracker used by WorkspaceAnimation,
and allows for other uses of scroll events (like scrolling in the
alt-tab popup).

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3840

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1746>
2021-03-09 12:28:36 +00:00
Marek Černocký
3669faaa47 Updated Czech translation 2021-03-08 19:38:40 +01:00
Sebastian Keller
b853316498 ctrlAltTab: Fix usage of bind_cairo_surface_property
This updates the use of bind_cairo_surface_property for the changes
from d7cb2eeebc. Now this function returns a StImageContent and not
an Actor like the following code expects, so wrap it in a StIcon.
Also the function lost its size argument.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1718>
2021-03-08 09:21:25 +00:00
Sebastian Keller
99dd5ece55 st/texture-cache: Change bind_cairo_surface_property to transfer full
This is how the code works and how it is already used from the C side.
There would also be no point in keeping this transfer none, because
textures generated from this function will not be shared and are not
kept in the cache.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1718>
2021-03-08 09:21:25 +00:00
Sebastian Keller
19e5f35569 Revert "st: Keep weak ref on texture cache bound texture source"
This reverts commit 87558efbf1.

The commit did not fix the bug it was supposed to fix, it just
complicated the code. The hopefully correct fix is in the previous
commit.

The point of this commit was to ensure everything gets removed when
bind->source gets removed. This however was already the case since the
signal handler was already connected to bind->source and has a
destructor registered that takes care of everything. And since gobject
destroys its signal handlers before it clears the weak refs, this new
weak ref was effectively never being used.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1718>
2021-03-08 09:21:25 +00:00
Sebastian Keller
606ec25f8b st/texture-cache: Don't overwrite existing bind images on texture reset
If the icon surface of a window got updated and its type or format no
longer match what we expect, st_texture_cache_reset_texture() might
overwrite the existing image in the bind with a new image, while still
keeping the weak ref on the old image. Due to this the old image might
trigger a st_texture_cache_on_pixbuf_notify() after the bind has already
been freed by g_signal_handlers_destroy() in the bind source. While this
usually would remove the weak ref, the weak ref it tries to remove is
on the new image, not the old one. The call to
st_texture_cache_on_pixbuf_notify() then tries to read the already
free'd memory from the bind which causes the cast to G_OBJECT to fail,
resulting in the crash.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3785

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1718>
2021-03-08 09:21:24 +00:00
Daniel Mustieles
f6cfefa0be Updated Spanish translation 2021-03-08 09:40:38 +01:00
Rūdolfs Mazurs
1066a1bd08 Update Latvian translation 2021-03-07 18:31:06 +00:00
Sebastian Keller
f9f936e71a shell/app: Avoid adding windows with a startup workspace twice
Changing the workspace of a window causes the window tracker to remove
and add it to the app again. If this happens from within
_shell_app_add_window() before the window has been added to the windows
list, this will cause the check that is supposed to prevent adding the
same window multiple times to fail and the window to be added twice.
The app will then be considered still running after the last window has
been closed. Then when clicking on the corresponding app icon, the shell
would attempt to switch to a NULL workspace for the closed window
instead of starting a new instance, resulting in a crash.

Changing the workspace also needs to happen after increasing the
interesting window count, because otherwise removal of the window by
the window tracker would trigger a uint underflow leading the app to be
considered running with UINT_MAX interesting windows, despite having no
windows, leading to crashes right after launching the app.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3833

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1745>
2021-03-07 16:23:08 +00:00
Piotr Drąg
d4ae968d05 Update Polish translation 2021-03-07 13:41:35 +01:00
Danial Behzadi
aefafc5f2c Update Persian translation 2021-03-07 04:00:44 +00:00
Philipp Kiemle
3d9bfbb0f8 Update German translation 2021-03-06 17:27:55 +00:00
Jonas Dreßler
7a57528bd7 workspaceThumbnail: Update visibility when showing the overview
There's currently a bug that we continue showing the workspace minimap
when the number of workspaces changes back to 1 during the session (ie.
outside the overview). Fix that by also updating the workspaceThumbnails
visibility when entering the overview.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3819

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1741>
2021-03-04 12:39:37 +00:00
Jonas Dreßler
bd7e3f4d6b theme/screen-shield: Use the same background color as in the overview
The overview uses $system_bg_color as its background color, and since we
nowadays show the overview right after starting up, it makes sense to
use the same background color for the login screen.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3812

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1742>
2021-03-04 11:33:03 +00:00
Ivan Molodetskikh
35fb221a7e workspace: Check if index is valid before using it
If the window wasn't in _windowSlots, the index is -1, so the last
element of the array is removed, leading to
https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3547

I logged the stack trace from removeWindow() and it seems that when you
move the window from the second monitor to another workspace like shown
in https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3547,
removeWindow() is called twice for it, presumably once for the second
monitor workspace, and then once for the first monitor workspace for
some reason. It is during that call that _windowSlots doesn't contain
the window, so instead the last element (index -1) is removed, leading
to the animation bug.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1727>
2021-03-03 19:56:45 +00:00
Florian Müllner
ff163a03b9 ci: Update ci-fairy image
Previously the information which commit failed a commit message check
was hidden in parts of the report that don't show up in gitlab's UI.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1740>
2021-03-03 20:29:22 +01:00
Florian Müllner
30f0c9f943 workspaceThumbnails: Update indicator on workspace changes
We block state updates while the indicator for the active workspace
is animating. To track that, we check whether the scroll-adjustment's
value matches the active workspace index. That works as long as the
adjustment's value changes after the active workspace, but not when
switching workspaces via SwipeTracker which only changes the active
workspace after transitioning to the new scroll value.

To fix that, update the indicator on workspace changes as well.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1716>
2021-03-03 18:04:13 +00:00
Florian Müllner
fac50fb50e workspaceThumbnail: Queue state update after expanding
New workspaces are added in two steps, first the minimap expands to make
room for the new thumbnail, then the thumbnail animates in. However we
currently don't queue a state update after the first step, so the second
one only happens after one is queued by some other event (like a workspace
switch).

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3748

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1716>
2021-03-03 18:04:13 +00:00
Jonas Dreßler
7f99655067 iconGrid: Only animate items when we actually need it
Animating items of the iconGrid involves calling a few more C functions,
which is quite slow. Especially calling ClutterActor.set_easing_delay()
is slow because we override that function in JS to adjust for the
animation slow-down factor. So add a small class variable to make sure
we only animate the icons of the grid when we actually need it.

This makes the average time spent in vfunc_allocate() of the iconGrid go
down to about 0.7 ms.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1713>
2021-03-03 17:59:16 +00:00
Jonas Dreßler
7771bf4437 iconGrid: Save class variables to local ones
It's quite slow to access class variables in JS, especially when they're
backed by GObject properties. To avoid accessing them in every iteration
when we're looping through the children of iconGrid, store those values
to another variable and reuse that inside the loop.

This shaves off another 0.2 ms from iconGrids vfunc_allocate(), getting
the average time spent in that function down from 1.3 ms to 1.1 ms.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1713>
2021-03-03 17:59:16 +00:00
Jonas Dreßler
7a5650d868 iconGrid: Bail out of getRowPadding early if we'll return 0
This gets our time spent in vfunc_allocate() down again by ~0.1 ms from
1.4 ms to 1.3 ms.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1713>
2021-03-03 17:59:15 +00:00
Jonas Dreßler
0fd394d4ca iconGrid: Don't update pages in vfunc_allocate()
vfunc_allocate() is a hot path, and we don't want to do expensive stuff
there, so avoid updating the pages, which seems unnecessary anyway.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1713>
2021-03-03 17:59:15 +00:00
Jonas Dreßler
0978b87e65 iconGrid: Get max child size using existing array of visible children
Using a preexisting array to iterate over is much faster than iterating
over the actors children using a "for ... of" loop, that's because the
latter calls into C functions to get the next actor all the time.

Also, stop using array deconstruction here, it turned out that this is
extremely expensive. When profiling this part of the code, it turned out
that only 9% of the time spent in _getChildrenMaxSize() is spent calling
the get_preferred_height/width() methods. When not using array
deconstruction, this time increased to 22%, still not great, but a lot
better.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1713>
2021-03-03 17:59:15 +00:00
Jonas Dreßler
8e93806453 iconGrid: Cache visible children of pages
We need to access the visible children of a page in inside
vfunc_allocate(), and since getting those children is quite slow (it
involves iterating over all the children of the actor) let's avoid that
and cache the array instead.

This reduces average time spent in vfunc_allocate() of the iconGrid from
1.6 ms down to 1.4 ms.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1713>
2021-03-03 17:59:15 +00:00
Jonas Dreßler
b3c46a33c0 iconGrid: Cache max size of children
We call this._getChildrenMaxSize() from the allocate() vfunc of
IconGridLayout. Since the function is quite expensive, it slows the
layout process down a lot, so instead of re-calculating it on every
relayout, cache the max size of children.

This makes the average time spent in vfunc_allocate() of the iconGrid go
down from 2.3 ms to 1.6 ms.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1713>
2021-03-03 17:59:15 +00:00
Ivan Molodetskikh
0a144ee54f workspace: Fix switched arguments
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1738>
2021-03-03 15:08:17 +00:00
Felix Divo
9ebfd0874c Add a link to supported releases in the README and bug template
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1246>
2021-03-03 14:47:20 +00:00
Jonas Dreßler
31d7770eeb workspace: Center-align window previews if there's only a single row
Instead of always aligning window previews vertically at the bottom of
their row, only do that if we have multiple rows. If there's only a
single row of windows, align every window vertically centered.

This is a very small step towards the new layout for window previews in
the overview, but since the release of 40 is getting nearer and nearer,
changing more is not feasible anymore.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3634

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1737>
2021-03-03 15:02:52 +01:00
Jonas Dreßler
9b9be4a1a5 workspace: Decrease spacing between workspaces in the window picker
Use a bit less spacing between the workspaces in the window picker, this
uses more of the available space and makes it easy to take a peek at
adjacent workspaces.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1702>
2021-03-03 12:08:58 +00:00
Jonas Dreßler
99378b6dae workspace: Scale down wallpaper by a fixed number of pixels
To ensure the workspace thumbnails are vertically closer to the window
picker than to the search, scale down the wallpapers by a fixed number
of pixels. Using 24 px for this means we'll take of 12 px at the top and
12 px at the bottom of the wallpaper, that's a better strategy than
always scaling it by a fixed factor since it doesn't change with the
monitor size.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1702>
2021-03-03 12:08:58 +00:00
Jonas Dreßler
df9129b2a0 theme/search-entry: Tweak the margins a bit
Use a bit less margin at the top and add some margin at the bottom of
the search entry. This should ensure the search entry is closer to the
panel than to the workspaces and avoid associating the workspace
thumbnails with the search instead of the window picker.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1702>
2021-03-03 12:08:58 +00:00
Jonas Dreßler
a27009f926 theme/dash: Tweak margins of the dash
The Dash currently has a horizontal margin and a top margin applied. The
horizontal margin isn't necessary since there already is a horizontal
padding applied, and the top margin is a bit large, since the
ControlsLayout enforces a spacing between the different containers
already, so slightly decrease the margin-top here.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1702>
2021-03-03 12:08:58 +00:00
Jonas Dreßler
613efa72f3 theme/overview: Use a spacing of 16px between elements
In the overview we want to make sure window previews are shown as large
as possible, so make the spacings a bit less excessive and only use a
16px spacing.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1702>
2021-03-03 12:08:58 +00:00
Georges Basile Stavracas Neto
9bce2a02be overview: Don't show black panel on startup
The back → transparent transition gives it a very bad look when
booting and running the startup animation.

Use the same transition duration hack to ensure that the panel
starts completely transparent.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1678>
2021-03-02 23:14:07 +00:00
Georges Basile Stavracas Neto
72505227b7 panel: Bind style to corners' style
There's this little hack that we do to match the panel transition from
transparent to black with leaving the overview via swipe down. The only
problem is that, while the duration of the panel transition itself is
matches, the corners don't, and they get out of sync.

This isn't very noticeable with the swipe gesture, but it'll be much
more prominent when booting straight into the overview.

Bind the 'style' property of the panel to the corners', so that the
transition duration hack applies to all of them.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1678>
2021-03-02 23:14:07 +00:00
Georges Basile Stavracas Neto
c4e43efb1e overview: Implement startup animation
The new startup animation consists of rising the Dash from the bottom,
falling the search entry from the ceiling, and going from HIDDEN to
WINDOW_PICKER with an opacity applied.

One little trick from IconGridLayout was added to ControlsManagerLayout,
which is a promises-based wait for allocation. This is required to make
sure that the transformed position of the search entry is valid, which
is only the case right after an allocation.

This animation also ensures that the overview is shown right on startup.

For session modes that do not have an overview, continue using the same
fade + scale animation.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1678>
2021-03-02 23:14:07 +00:00
Georges Basile Stavracas Neto
930d0b6151 overviewControl: Store search entry container
It'll be used by the next commit.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1678>
2021-03-02 23:14:07 +00:00
Georges Basile Stavracas Neto
e3f12e3e23 layout: Update workspace struts even while starting up
We want to avoid updating the input region on startup, since it incurs
in roundtrips to the X server, but not workspaces struts, since they
affect the visible clip of wallpapers in the workspace. Since next
commits will make the overview be the after-boot screen, we really
don't want the wallpaper to be clipped wrongly.

Allow updating regions while starting up, but only workspace struts.
Make sure input is not updated by accounting for 'this._startingUp'
on 'wantsInputRegion'.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1678>
2021-03-02 23:14:07 +00:00
Georges Basile Stavracas Neto
bc0974618f layout: Don't build input region rects on Wayland
This is an X11-specific routine, and building the list of input region rects
on Wayland is a waste, since it incurs in many trampolines only to throw them
in the trash.

Don't build input region rects on Wayland. By modifying the 'wantsInputRegion'
variable, it also skips actors that only update input, which is another small
optimization for Wayland.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1678>
2021-03-02 23:14:07 +00:00
Georges Basile Stavracas Neto
ba0b9239d3 layout: Allow updating struts in Overview
LayoutManager doesn't update struts when there's any modal running. Turns
out, the Overview itself is a modal. That, and the fact that the Overview
will be the startup state, prevents the workarea to be updated.

Allow updating struts when there's no other modal than the Overview.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1678>
2021-03-02 23:14:07 +00:00
Remi Salmon
9cd211a99a status/network: Use the same signal strength values as GNOME Settings
Be consistent and use the same wifi signal strength thresholds that are
used by Settings to ensure that the signal strengths look the same in
Settings and gnome-shell.

See https://gitlab.gnome.org/GNOME/gnome-control-center/-/blob/master/panels/netwo>
for the	values used in Control Center.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/217

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1432>
2021-03-02 23:07:01 +00:00
Florian Müllner
9a273e1db2 shell/app: Handle workspace from startup notifications
Launching applications on a particular workspace works through
launch contexts and startup notifications. While this is no
longer required by a launcher/WM split, in theory this allows
us to reliably identify the correct window to apply startup
properties to.

However in practice we fail more often than not: Missing support in
toolkits, differences between display protocols, D-Bus activation
and single-instance applications all provide their own pitfalls.

So instead, take advantage of the fact that launcher and WM live in
the same process, and go with the unsophisticated approach: Just
remember the last workspace that was requested when launching an
app, then move the next window that is associated with the app to
that workspace.

This will break X11 applications that set an initial workspace, but
that's legacy functionality anyway (given that there's no wayland
protocol for that functionality), and seems a price worth paying
for making launching apps on workspaces more reliable.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1316>
2021-03-02 23:18:58 +01:00
Carlos Garnacho
40b67a140a st/scrollview: Apply correct fade_edges_left/right effect uniforms in RTL
When the setting is false, we apply anyway depending on the adjustment
value. Look for the right value corresponding to that side as per the
locale.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
9b24d9c4c0 appDisplay: Don't reset adjustment on ::pages-changed
Let the goToPage call afterwards to take precedence, instead
of resetting the adjustment (thus the view) on the side.

This resulted in strange state when the last page contains
a single icon, and it is dragged. The last page being emptied
triggers a pages-changed signal, which half resets the view
to the first page while DnD is ongoing.

Letting goToPage do its business means we neatly clamp to the
closest page to currentPage, the last page in that case.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
ec223f31d9 appDisplay: Slide page hints along page switching
When clicking on the page hints, the hint rectangles being visible
in place and not moving together with the page is a bit too
distracting.

Since the page hints are not part of the iconGrid hierarchy and
we have just 2 general ones for prev/next page (i.e. no page
associated), do this sliding via some smoke and mirrors: We don't
slide the page hints, but a parent container for both of them, and
we also control opacity so that the container is fully transparent
mid-page. At the point it is transparent, the container can be
snapped to the other side of the page, and faded back in as it
slides together with it, so it always looks like it goes away and
comes from the right sides.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
9e5b357b0b appDisplay: Adapt to available extra space showing icon grids
Depending on the available horizontal space, we may want to manipulate
the icon grid and scroll view spacing to result in an optimal layout
that has space left to preview prev/next pages.

The main change here is that, when adapting to the available size, the
space given to a page does not necessarily match the available space,
as we need to be able to show more than one page at a time.

With this decoupling of available and page sizes in place, we now know
how much space there is available in order to extend the padding between
pages, or the fade effect applied to the previewed pages.

Underneath, we rely a bit less on hardcoded CSS paddings, and a bit more
on the StScrollView::content-padding property.

All put together, gives us proper space management from ultra-wide
displays, to display ratios that are close to the optimal grid ratio.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
ffe11e0560 appDisplay: Add carousel arrows to app grid
These only show during navigation (not DnD), along with the
previewed page.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
c15dce242e theme: Improve look of FolderDialog wrt page previews
Remove padding on left and right of the contained widgetry, so
there's no seams animating things from the border. Also, remove
the padding between IconGrid pages, so the nest/prev pages are
visible given the dialog width.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
a00db66ffe js/appDisplay: Implement side page previews while DnDing
When DnDing an icon, we show both previous/next page, and optionally
a "placeholder" actor to allow creating new pages. These sides on the
scrollview are drop targets themselves, allowing to drop an app onto
the next/prev page without further navigation.

Still, preserve the checks to maybe switch to prev/next page without
finishing the DnD operation, for finer grained operations.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
d75ed55ed8 js/appDisplay: Implement navigation of pages by hovering/clicking edges
Add the necessary animations to slide in the icons in the previous/next
pages, also needing to 1) drop the viewport clipping, and 2) extend scrollview
fade effects to let see the pages in the navigated direction(s).

The animation is driven via 2 adjustments, one for each side, so they
can animate independently.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
f31c49c40e js/appDisplay: Generalize app scrollview CSS
We want to show left/right side pages during navigation, also in
FolderViews. Let this scrollview use the same style than the "all
apps" one, and generalize the name a bit.

This will compress the scrollview horizontally, so there's actual
overflow space to show these pages.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
0d62dadfbc st/scrollview: Add ::content-padding property to StScrollView
This will be needed for fine tuning of the visible area for appGrid
navigation purposes. We most nominally can let it happen via CSS as
the size calculations happen on size allocate, so we want to avoid
triggering relayouts while adapting to the given size.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
f60a469a34 st/scroll-view: Make fade effect take ClutterMargin
Instead of taking just vertical/horizontal offsets, take a ClutterMargin
to allow us set the fade offsets on each direction specifically. Also,
handle negative values in margins, the fade effect will run in the negative
space left by the scrollview padding instead. Another difference now is
that areas outside the extents of the effect will be transparent, instead
of the effect ending abruptly past the given extents.

This will be used by the app grid, in order to selectively let see either
of next/prev pages while navigating.

While at it, fix code style issues in st_scroll_view_update_fade_effect(),
and clean up unused variables from the GLSL code.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Carlos Garnacho
8cb3825d48 st/viewport: Add clip-to-view property
This property controls whether the viewport clips the content to its own
allocation or not. This will be necessary in special modes that we want to
render past the viewport inside a scrollview.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1630>
2021-03-02 22:02:56 +00:00
Florian Müllner
260f5b0b8d workspacesView: Add minimap on secondary monitors
The workspace minimap is much less prominent than the old workspace
switcher, and serves primarily as an indicator.

That means that duplicating it on secondary monitors (if workspaces
on non-primaries are enabled) is harder to mistake for per-monitor
workspaces, so make some people happy by including the minimap on
every monitor.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1735>
2021-03-02 21:56:30 +00:00
Florian Müllner
082eedd968 workspacesView: Decrease workspaces size on external monitors
Now that the backgrounds was moved into workspaces, the fullscreen
views on secondary monitors are visually inconsistent with the
primary view, as there's no dash or search entry that reduces the
available height and allows adjacent workspaces to peek in.

Address this by adding padding above and below the view, so that
it is limited to 70% of the available height.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1735>
2021-03-02 21:56:30 +00:00
Florian Müllner
a8e6403045 workspacesView: Split out SecondaryMonitorDisplay
Right now the handling of external monitors is relatively simple, and
consists of putting either an extra workspace or a full view on the
monitor, depending on the workspaces-only-on-primary setting.

We are about to tweak the behavior on secondary monitors, prepare for
that by splitting out an intermediate actor that manages the views on
non-primaries.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1735>
2021-03-02 21:56:30 +00:00
Florian Müllner
40121bbe4b workspacesView: Center extra workspace
At the moment views on non-primary monitors take up the entire work area,
so simply allocating the available size works. However we'll soon shrink
the views a bit to match the visuals on the primary monitor. As workspaces
keep the ratio, reducing their height will also reduce the width; override
the default allocate() to keep the extra workspace horizontally centered.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1735>
2021-03-02 21:56:30 +00:00
Florian Müllner
2731d35723 workspaceThumbnails: Pass monitor index to constructor
We'll soon add workspace thumbnails on secondary monitors as well,
so set the monitor explicitly instead of assuming the primary one.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1735>
2021-03-02 21:56:30 +00:00
Florian Müllner
4eb31e4e18 workspaceThumbnails: Immediately initialize should-show
At the moment, we only get the initial :should-show value when populating
the thumbnails. That only happens when entering the overview, so any
listeners to notify::should-show will perceive it as a change rather
than an initialization, which can result in unwanted transitions.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1735>
2021-03-02 21:56:30 +00:00
Florian Müllner
09afaf0745 workspaceThumbnail: Initialize porthole to work area
We currently initialize the porthole to the screen size instead of
the monitor's work area we actually want. At the moment this doesn't
matter, as the minimap is created during initialization with the rest
of the overview, so we can expect a work area change that updates the
porthole to the correct values.

That won't be true for minimaps we put on secondary monitors, so make
sure we initialize the porthole to the actual values.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1735>
2021-03-02 21:56:30 +00:00
Florian Müllner
945e947a54 workspaceThumbnails: Disconnect signals on destroy
The minimap is currently created once when populating the overview,
and kept around until the end of the session. That will change when
we start to also show it on secondary monitors, so do proper clean
up when destroyed.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1735>
2021-03-02 21:56:30 +00:00
Tim Sabsch
767ee518f5 Update German translation 2021-03-02 19:49:29 +00:00
Florian Müllner
f28f7eddb1 overviewControls: Shift up on double-super
Right now a second super press during the overview transition hides
the overview again. Change that behavior to shift up to the app grid
instead, which is more useful.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1736>
2021-03-02 15:36:26 +01:00
Florian Müllner
1ad45a8232 overviewControls: Handle overlay key
It's where all the fun state is handled now, so move the super-key
handling there as well, in preparation of making it a bit more
sophisticated.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1736>
2021-03-02 15:36:26 +01:00
Carlos Garnacho
46361c9a04 appDisplay: Move onto the correct page while DnD on both LTR/RTL
Look up the next page correctly for the overshoot coordinates, given
the text direction. We don't need to look whether there is a next
page either, as goToPage() checks that it's the case.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3778
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1734>
2021-03-01 18:34:46 +01:00
Sebastian Keller
a6588d054f windowPreview: Unset selected if window was clicked to switch workspaces
This is used to detect whether a click was short enough to select a
window and activate it or long enough to start a drag. Usually when
clicking on a window and selecting it, this leaves the overview, but
when clicking on a window on a neighboring workspace, the overview is
kept open, but selected is not unset in this case. So all attempts at
dragging the window after using it to switch workspaces will fail.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3783

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1717>
2021-03-01 14:45:50 +00:00
Jakub Steiner
6390265ba1 style: App folder styling
Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3754

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1714>
2021-03-01 14:16:04 +00:00
Florian Müllner
e2c1407153 overview: Unset visibleTarget on gesture end
The property describes the target visibility (that is, the visibility
that will be set after the ongoing transition), and is therefore updated
at the start of the transition rather than from hideDone().

The overview gesture currently misses resetting it at the end, so it
is only updated to the correct state the next time the overview is
entered.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3798

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1726>
2021-03-01 13:38:42 +00:00
Guillaume Bernard
a05005e86e Update French translation 2021-03-01 07:10:37 +00:00
Alexander Mikhaylenko
8eda12e6d7 overviewControls: Use easeOutCubic transition for overview
Swipe tracker duration is intended to be used with easeOutCubic only.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1732>
2021-02-28 19:57:53 +05:00
Asier Sarasua Garmendia
404bb7a638 Update Basque translation 2021-02-27 08:53:00 +00:00
Марко Костић
37672cfbb1 Update Serbian translation 2021-02-27 07:07:59 +00:00
Christian Kirbach
70ab99452d Update German translation 2021-02-26 23:00:23 +00:00
Florian Müllner
fe4fa1d2b0 extension-tool/create: Update for new versioning scheme
The "shell-version" field generated by the create command still
uses the old even/odd schema instead of the new "alpha", "beta"
etc. one.

Do that now, and also drop the different behavior for stable/unstable
releases (that is, always use only the major number, i.e. "40").

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3787

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1719>
2021-02-26 23:06:43 +01:00
Florian Müllner
95806c6a58 extensionUtils: Simplify version check
When adapting the check to the new versioning check, we just blindly
copied the old behavior for stable/unstable versions:

 - stable releases must have matching major numbers
 - unstable releases must match major and minor ("alpha", "beta", "rc")

That worked for the old even/odd scheme, but now has the absurd effect
that we consider an extension that lists "40.alpha" in its shell-version
incompatible with "40.beta", but compatible with "40.2".

At least this provides us with a good opportunity to reconsider the
behavior. While it is true that breakage is much more likely between
unstable releases, in practice extensions are either following shell
development closely or update once around the time of a stable release.

For the former, the stricter check isn't usually too useful (as the
extension releases around the same time as gnome-shell anyway).

For the latter, it's annoying that ".rc" is treated differently from
".0" and requires an update to become compatible.

The latter is also by far the more common case, so update the check
to only match on the major version regardless of whether a release
is stable or unstable.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3787

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1719>
2021-02-26 23:06:40 +01:00
Abderrahim Kitouni
48ae38c52d windowManager: Use Clutter default text direction
This code was copied from workspacesView which used the widget's text
direction, but it is no longer in a widget

Fixes #3780

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1724>
2021-02-26 18:10:16 +01:00
Florian Müllner
175175fac8 ci: Add commit rule to not end subject with punctuation
I recently forgot to fill in the subject after the prefix. Add a
commit rule for catching this and other cases where subject lines
end in punctuation (except ...)

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1722>
2021-02-26 14:59:07 +01:00
Florian Müllner
49b7973177 workspaceThumbnail: Consider porthole offsets
Since commit 9980c80619, the porthole position is ignored. As a result,
previews are only shown if the primary monitor is located at (0, 0).

To fix this, we either need to propagate the porthole to every thumbnail,
use a custom layout manager that applies an offset to all children, or
add an intermediate actor that offsets the contents.

The last option is the simplest and doesn't require calls into JS on
every allocation, so pick that one.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3781

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1721>
2021-02-26 14:36:39 +01:00
Abderrahim Kitouni
c90bde464a js: Require Soup 2.4
Soup 3.0 is a thing now

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1720>
2021-02-26 12:28:21 +00:00
Goran Vidović
6e384271c3 Update Croatian translation 2021-02-26 12:02:47 +00:00
Baurzhan Muftakhidinov
cf9ac841d2 Update Kazakh translation 2021-02-26 10:35:22 +00:00
Balázs Meskó
daa019c2e2 Update Hungarian translation 2021-02-25 23:00:58 +00:00
Fran Dieguez
85d0f87067 Update Galician translation 2021-02-24 23:04:34 +00:00
Fran Dieguez
49cc0d64ca Update Galician translation 2021-02-24 21:15:02 +00:00
Michael Terry
8850c579da endSessionDialog: Only show logout inhibiting apps
Apps that only inhibit other kinds of activity (like idle or suspend)
don't need to be shown to user when they are logging out.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3119

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1424>
2021-02-24 15:31:03 +00:00
Sebastian Keller
ef5b92c596 windowPreview: Ensure scaling is limited to defined size increase
The preview was getting scaled up by a factor based on what is needed to
increase the width by activeExtraSize pixels. With windows that are
wider than than they are tall, this means that the size of the window
will not increase any more than activeExtraSize in any direction, but
for windows that are taller than they are wide, the vertical scaling
can exceed this. This would break some of the assumptions in the
reported size for the preview chrome and could for very narrow windows
result in a rather large scale.

To fix this, calculate the scaling factor based on whatever is larger,
the height or the width.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1707>
2021-02-24 09:58:31 +00:00
Florian Müllner
ef777426d2 lightbox: Fix shader effect
Since commit 0f1b566918, we use gjs' automatic getters/setters for
the shader properties. Those handle the properties on the JS and
GObject side, but they don't update the corresponding uniform,
whoops.

Revert the lightbox bits of commit 0f1b566918 to get the effect back.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1712>
2021-02-24 09:52:45 +00:00
Jonas Ådahl
7f466551fa main: Move NO_AT_BRIDGE hack to mutter
There is no guarantee that it'll have effect, since the time anything
that'll look at that environment variable is not known by gnome-shell.
Let mutter carry this burden instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1710>
2021-02-23 18:24:35 +01:00
Allan Day
80e22740a1 schemas: Define default app grid arrangement
Specify the default app grid arrangement. This makes the app grid
more useful since the interesting apps are prioritised. It also
communicates that the app grid can be customised.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/3122

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1700>
2021-02-23 12:10:20 +00:00
Florian Müllner
5cd7434abd Post-release version bump 2021-02-23 00:22:58 +01:00
Florian Müllner
706d7beed7 Tag 40.beta
Update NEWS.
2021-02-23 00:09:33 +01:00
Florian Müllner
e0c0662164 overviewControls: Remove superfluous max()
We don't need to call Math.max() to figure out the maximum of a
single value :-)

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1709>
2021-02-22 13:10:02 +01:00
Aurimas Černius
ea5efbbd52 Updated Lithuanian translation 2021-02-21 21:22:13 +02:00
Jonas Dreßler
63a96a7111 workspacesView: Take scale factor into account to calculate spacing
This is a statically defined size and we need to adjust for scaleFactor
ourselves, so do that and multiply those two values by the scale factor.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1701>
2021-02-21 16:25:17 +00:00
Jonas Dreßler
2d954c07fb workspace: Don't limit workspaceBox size when doing app grid animation
In the allocate() vfunc of WorkspaceLayout we use a small trick to make
the nonlinear animation paths when opening the overview less jarring:
Because a window might get smaller than its target size during the
animation, we make sure the size never drops below the final size
calculated by the layout strategy.

In the app grid the Workspace is very small though, and the size of a
window slot calculated by the layout strategy might actually be larger
than the workspaceBox. This means we might use the window slot size
instead of the workspaceBox size and end up with a window that's at the
correct position, but its size is too large.

Fix this by only applying this trick when we're animating towards or
from the state where we actually expect the workspaceBox to be larger
than the window slot, that is during the the transition from the session
to the window picker (or the other way round).

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1698>
2021-02-21 17:03:09 +01:00
Jonas Dreßler
9e8ceeae9d workspace: Actually apply top overlap to the top
The top overlap is accidentally being applied to the left edge right
now, fix that and apply it correctly to the top edge.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1698>
2021-02-21 17:01:07 +01:00
Jonas Dreßler
51348c6020 workspace: Properly handle zero spacing in the WorkspaceLayout
It should be allowed to set this._spacing to 0 and thus pass 0 as
rowSpacing or colSpacing to this._adjustSpacingAndPadding(). The current
if-condition there won't add the oversize to the spacing in case 0 is
passed though.

So change that if-condition and explicitely check for null instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1698>
2021-02-21 17:01:07 +01:00
Georges Basile Stavracas Neto
adc5f2d81f workspace: Scale down background
Scale down the background to 0.94 when in floating mode.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1691>
2021-02-21 15:47:12 +00:00
Georges Basile Stavracas Neto
b1970b95b8 workspace: Clip window previews
Window previews can spill out of the container when their position in the
session overflows the monitor boundaries. In the past, Workspace didn't have
a visible background, and was (almost) always fullscreen, which would mask
this particular problem. However, nowadays, it is very much noticeable when
this situation happens.

Clip the window previews container to its allocation when the overview state
is bigger than WINDOW_PICKER. That is, between HIDDEN and WINDOW_PICKER states,
inclusive, no clipping is applied.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1691>
2021-02-21 15:47:12 +00:00
Georges Basile Stavracas Neto
1819e34f29 workspace: Move border radius handling to WorkspaceBackground
Let WorkspaceBackground itself manage its background radius.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1691>
2021-02-21 15:47:12 +00:00
Georges Basile Stavracas Neto
a17c4283ea workspace: Add WorkspaceBackground to Workspace itself
Instead of adding it to the window previews container, add it to Workspace
itself. This requires expanding WorkspaceBackground, so add the relevant
x and y expand flags.

Since the background is beneath the window previews, create and add it before
the window preview container.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1691>
2021-02-21 15:47:12 +00:00
Georges Basile Stavracas Neto
37bcd3d428 workspace: Move window previews to a child container
Currently, Workspace is a single actor that contains both the background,
and all window previews, and is managed by WorkspaceLayout. In the future,
this concentrating aspect of it will bite us; we want the window previews
to be clipped to the allocation, but not the background, since it will
have shadows.

Make Workspace subclass St.Widget with a ClutterBinLayout as layout manager,
and move window previews to a child actor. To reduce the impact of this
extra actor, it's a ClutterActor instead of a StWidget, and the spacing is
still set on Workspace itself.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1691>
2021-02-21 15:47:12 +00:00
Georges Basile Stavracas Neto
b05280a2cd workspace: Update background on workarea changes
The WorkspaceBackground class has specific code to clip the background
to the workarea. However, it doesn't monitor for workarea changes, which
means it cannot react after being created.

Connect to 'workareas-changed', and update the workarea, the radius bounds,
and relayout when workareas change.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1691>
2021-02-21 15:47:12 +00:00
Georges Basile Stavracas Neto
9d4f017248 workspacesView: Only clip non-primary workspace views
The primary workspace is displayed in the overview, and clipping it
ends up clipping the shadows too. Since Overview's ControlsManager
itself clips to allocation, no windows in the primary monitor spill
to other monitors. However, not clipping non-primary monitors might
end up in situations where their windows spill into the primary one.

Make sure to only clip workspace views of non-primary monitors.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1691>
2021-02-21 15:47:12 +00:00
Jiri Grönroos
a976fe90e4 Update Finnish translation 2021-02-21 13:41:18 +00:00
Kukuh Syafaat
52c21c32d5 Update Indonesian translation 2021-02-21 13:22:01 +00:00
Daniel Șerbănescu
3c126f4422 Update Romanian translation 2021-02-21 11:30:45 +00:00
Evan Welsh
9a50240bbc schema: Enable extension version validation by default
Previously this was disabled to avoid requiring extensions to manually
update on each release. For 40 this behavior will likely be too unstable
for most users.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1706>
2021-02-20 12:25:00 -08:00
Emin Tufan Çetin
fcb70ff654 Update Turkish translation 2021-02-19 22:12:55 +00:00
Anders Jonsson
0ede01e676 Update Swedish translation 2021-02-19 22:08:24 +00:00
Enrico Nicoletto
3208cc68f6 Update Brazilian Portuguese translation 2021-02-19 21:10:35 +00:00
Hugo Carvalho
f55196e7fb Update Portuguese translation 2021-02-19 20:55:11 +00:00
Jordi Mas
433ba92c43 Update Catalan translation 2021-02-19 20:21:59 +01:00
Florian Müllner
55e08a3a2f welcomeDialog: Hide overview when taking tour
The dialog is shown at session start, which right now means in the
regular session, however the plan is to start the session in the
overview. When that happens, the "Take the Tour" button should get
the user to the Tour without additonal actions.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1699>
2021-02-19 17:18:50 +01:00
Jonas Dreßler
bc034d5553 windowPreview: Add scaled extra size to chromeWidths() and chromeHeights
Right now the rowSpacing and columSpacing of the layout strategy is
calculated by looking at the overlapping sizes of the close button and
the app icon of the WindowPreview, plus a constant spacing read from CSS
by the WorkspaceLayout that's added to that. We're not factoring in the
extra size of the scaled-up WindowPreviews here and instead depend on
the constant spacing being large enough. If we don't want to depend on
the spacing here, we should add the scaled-up extra size to the sizes
returned by chromeWidths() and chromeHeights().

Since the last commits all previews scale up by the same amount of
pixels, so we can now just add that size to the values returned by
chromeWidths() and chromeHeights().

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1692>
2021-02-19 11:23:07 +00:00
Jonas Dreßler
7d40930cd6 windowPreview: Scale up by the same extra size for every window
Scaling differently sized WindowPreviews by a constant factor will
result in smaller windows getting enlarged by a smaller amount of pixels
than larger windows (1000*1.02=1020 but 100*1.02=102, one will grow by
20 pixels and the other one by 2), this can look a bit weird because
smaller windows don't scale up as much as larger windows.

So introduce a constant extra size to use when scaling windows up, we
set only the half size there because we want to ensure that the size
added on both sides is not fractional and we remain aligned to the pixel
grid.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1692>
2021-02-19 11:23:07 +00:00
Jonas Dreßler
3795ccbcf3 windowPreview: Use a proper spacing between icon and title
Right now the spacing between icon and title works using a little trick
that doesn't really seem intended: The title is offset by
(icon-height * ICON_OVERLAP), when the icon is actually overlapping the
preview by ICON_OVERLAP, and *overflowing* the preview by
(1 - ICON_OVERLAP).

So correct that and offset the title by
(icon-height * (1 - ICON_OVERLAP)), and since now there's no spacing
anymore, add a proper ICON_TITLE_SPACING to that offset.

Also add the new ICON_TITLE_SPACING to the overlapHeight, where the
spacing was ignored so far.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1692>
2021-02-19 11:23:07 +00:00
Florian Müllner
ece5220b42 windowManager: Keep a minimum number of workspaces
The scaled down workspace in the window picker looks lonely when there's
no adjacent workspace peeking in. Avoid that by always keeping a minimum
of two workspaces.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3739

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1696>
2021-02-19 01:13:05 +01:00
Florian Müllner
2fdee8e444 workspaceThumbnails: Only show for more than two workspaces
As adjacent workspaces now peek into the window picker, the first
two workspaces are already accessible without the minimap. Hide
it in that case to give more space to the window picker, and to
not clutter the overview for users who aren't using workspaces.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3739

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1696>
2021-02-19 01:13:05 +01:00
Florian Müllner
d3a1557864 workspaceThumbnail: Do not update scale while collapsing
The scale property tracks the relative size at which we display thumbnails
given the space we have available.

That assumes that the allocation represents that available space, but it will
actually be smaller while the minimap itself is collapsing.

Luckily we have an easy option to avoid a distorted scale: Just don't update
it while collapsing. We expect scale changes when adding or removing thumbnails,
but as we freeze those during transitions, we can do the same with the scale.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3739

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1696>
2021-02-19 01:13:05 +01:00
Florian Müllner
7b1b04f95a workspaceThumbnails: Delay workspace removal while collapsing
Animating a thumbnail removal while also collapsing the minimap
itself doesn't look good, so keep the stale thumbnail until the
minimap is hidden.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3739

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1696>
2021-02-19 01:13:05 +01:00
Florian Müllner
a2751a1b26 workspaceThumbnails: Don't animate thumbnail additions while hidden
This is not just an obvious mini-optimization, it also ensures that we
don't start showing the minimap with an ongoing thumbnail transition.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3739

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1696>
2021-02-19 01:13:05 +01:00
Florian Müllner
a73bea02e8 workspaceThumbnails: Animate showing/hiding
Right now the minimap only hides itself in case of a single static
workspace. That's not only an edge case, but also not expected to
change while the overview is visible, so changing the visibility
without a transition is fine.

However that is about to change, and we'll hide the minimap as well
when there are fewer than three workspaces. As that condition is
very much expected to change from within the overview, the transition
should be animated.

Implement that via a new :collapse-fraction property on ThumbnailsBox,
and use that to transition both the height of the box itself and the
scale of the individual thumbnails.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3739

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1696>
2021-02-19 01:13:02 +01:00
Florian Müllner
f239179682 workspaceThumnails: Add :should-show property
We currently have two components that show or hide the minimap:

 - the thumbnails hide themselves in case of a single static workspace
 - overview controls show the minimap when no search is active

That obviously doesn't work correctly.

To fix this, change thumbnails to set a new :should-show property instead
of the visibility, and let the overview controls take it into account
when changing the visibility.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3739

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1696>
2021-02-19 01:08:48 +01:00
Florian Müllner
bf8e762178 workspaceThumbnail: Base n-workspaces on number of thumbs
It's what we base our size request on, and what we actually allocate.
The difference usually doesn't matter right now, but will soon when
we animate the minimap itself.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3739

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1696>
2021-02-19 01:08:48 +01:00
Florian Müllner
2e9715c97e workspaceThumbnails: Actually use vscale parameter
We pass two scales to setScale(), but only use the first one for
both horizontal and vertical scaling. We'll soon have a use case
for using a different scale for each dimension, so start using
both parameters.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3739

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1696>
2021-02-19 01:08:48 +01:00
Jonas Dreßler
267c5f84a8 theme/window-picker: Fixup box-shadow of overview workspace backgrounds
A small mistake snuck in right before landing the previous commit and
the box-shadow was moved 4px vertically above the wallpaper instead of
below it. Fix that and put it 4px below the wallpaper.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1697>
2021-02-18 22:10:02 +01:00
Jonas Dreßler
135c9194cd theme/window-picker: Add box-shadow to the workspace background
According to the GNOME 40 mockups, add a box-shadow to the workspace
background. For this to work, we also need a background-color (St
limitations), and to make sure that background-color doesn't bleed over
the rounded corners of the wallpaper, we also need to tell St to use a
border-radius and clip the background-color painting using a rounded
path.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1651>
2021-02-18 20:59:30 +00:00
Jonas Dreßler
63cf60b731 workspace: Round the corners of the wallpaper
As planned and shown in the mockups for GNOME 40, round the corners of
the background wallpaper of workspaces.

To do that we use the new rounded-clipping support of
MetaBackgroundContent and we animate the radius by attaching it to the
stateAdjustment just like everything else.

Because we show only a part of the wallpaper and "cut away" the area of
the panel in WorkspaceBackgrounds vfunc_allocate(), we also need to set
the rounded clips bounding rect to the rectangle we're actually showing,
otherwise the texture would be rounded in the region that's cut away.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1651>
2021-02-18 20:59:30 +00:00
Yuri Chornoivan
4ba48b02e8 Update Ukrainian translation 2021-02-18 20:27:11 +00:00
Matej Urbančič
494db57d8c Update Slovenian translation 2021-02-18 20:24:21 +00:00
Florian Müllner
f4b88aac04 overviewControls: Add shortcut for shifting through overview
This is the same as the vertical swipe gesture, but for keyboard
junkies: Analoguous to the <super><alt>left/right shortcuts for
switching between workspaces, add <super><alt>up/down to shift
between session, window picker and app grid.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1695>
2021-02-18 19:55:31 +00:00
Georges Basile Stavracas Neto
ac6337848f workspacesView: Disable mouse drag to switch workspaces
During the user research, it was found that users would instinctively
drag the workspace horizontally but would often, in the process,
accidentally drag a window.

Disable dragging workspaces using the cursor for now.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3742
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1694>
2021-02-18 09:43:02 -03:00
Rafael Fontenelle
718a87554f Update Brazilian Portuguese translation 2021-02-18 01:31:36 +00:00
Florian Müllner
c769a2f6f0 dash: Put the dot back into its box
When commit 3a9acb96 moved around padding to extend the clickable
area to the screen edge, it reduced the inner padding too much and
the running indicator ended up outside the highlighted area.

Adjust the padding to put it back into its place.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1693>
2021-02-17 22:09:22 +01:00
Matej Urbančič
bf15ad7f69 Update Slovenian translation 2021-02-17 18:54:50 +00:00
Carlos Garnacho
0b16565e70 keyboard: Handle edge drag gesture cancellation
Hide the keyboard again if the gesture happens to stay/return
within it's activation threshold.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1668>
2021-02-17 15:45:01 +00:00
Carlos Garnacho
c62177e669 keyboard: Make OSK follow gesture progress
With all other gestures offering live feedback of progress, seems
to make sense to update the "swipe from bottom edge to show OSK"
gesture as well.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1668>
2021-02-17 15:45:01 +00:00
Carlos Garnacho
8526776b4a keyboard: Use translation-y property for focus window animations
Just the intermediate state, we still need to synchronize visual and
real window position after the animation.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1668>
2021-02-17 15:45:01 +00:00
Carlos Garnacho
3346e9923b keyboard: Move monitor management to KeyboardController
Instead of setting it deep down, manage it at the higher level.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1668>
2021-02-17 15:45:01 +00:00
Carlos Garnacho
0a12405e01 keyboard: Simplify focus window tracking
Keep the focus window in a single field, and optionally animate
depending on keyboard visibility.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1668>
2021-02-17 15:45:01 +00:00
Carlos Garnacho
a6a4e0a504 edgeDragAction: Add signal to notify about progress
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1668>
2021-02-17 15:45:01 +00:00
Carlos Garnacho
8e73143b24 keyboard: Drop layoutManager's keyboard-visible-changed
Since now the signal is emitted and handled all within keyboard.js,
use an internal signal to manage keyboard visibility and gesture
enablement.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1668>
2021-02-17 15:45:01 +00:00
Carlos Garnacho
0580fe6eff windowManager: Move OSK gesture to KeyboardManager
It would be nice to get finer control over the keyboard slide
gesture and animation. Move the gesture bits so they are together
at keyboard.js.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1668>
2021-02-17 15:45:01 +00:00
Carlos Garnacho
f52cafeb4a layout: Move keyboard slide animation to keyboard
The animation handling is kinda split between layout (for the
keyboard slide), and keyboard (for the focus window slide). It
would be nice to have more fine grained control on those, so
move the animation handling altogether to keyboard.js as a start.

This is roughly similar, except that transformations apply to
the Keyboard actor, instead of the keyboardBox (its parent). We
now queue a relayout after the animation in order to update the
chrome tracking.

The only layering break now is that we emit
layoutManager::keyboard-visible-changed in keyboard.js, its
purpose will be dropped in future commits, so leave it there for
now.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1668>
2021-02-17 15:45:01 +00:00
Carlos Garnacho
76836fe388 overview: Synchronize panel opacity with overview leave animation
Gestures leaving the overview from a short distance result in an
ugly effect with the panel opacity transitionhaving a fixed duration.
Make this transition have the same duration (although in a hackish
way) so we avoid the ugly effect.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1643>
2021-02-17 14:06:11 +01:00
Carlos Garnacho
f7f46ca9ac overview: Clean up dead code
These unused functions accessed undefined functions on a now undefined
variable/class. This vestigial code can go away.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1643>
2021-02-17 14:06:11 +01:00
Carlos Garnacho
cd506d45ef overview: Make 3fg vertical swipes bring overview and app grid
The gesture internally manipulates the main adjustment so one swipe
up brings up the overview, and a second swipe up brings the app
grid. The gesture also works in the other direction to get out of
the overview.

Internally, this is delegated on the OverviewControls, so the
adjustment is not leaked out of there. This however meant open
coding the gesture interaction so it can be directed from
overview.js code.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1643>
2021-02-17 14:06:11 +01:00
Carlos Garnacho
ddb8782179 overviewControls: Add "gesture-in-progress" property on the state adjustment
This will be set whenever an event controller is manipulating the adjustment.
It should enter the same transitional state it does for animations. This
will be used by the overview gesture.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1643>
2021-02-17 14:06:11 +01:00
Carlos Garnacho
f69727464c workspacesView: Initialize/update swipe orientation before gesture
Separate this logic from _switchWorkspaceBegin() and ensure it is set
before this call. The SwipeTracker code uses the orientation to determine
whether the gesture should begin at all, so changing the orientation on
gesture begin was a bit too late.

But also, that meant the SwipeTracker was left at the default orientation,
which was vertical (unlike workspaces, and like the overview gesture).
This made both swipe trackers try to handle the same swipe, with the
WorkspacesView being doubly unfortunate (for triggering in the first place,
and for happening after the other gesture did queue relayouts on it).

Taking this logic outside of _switchWorkspaceBegin() and having the right
orientation beforehand results in both gestures looking for their direction,
and not meddle with each other.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1643>
2021-02-17 14:06:11 +01:00
Carlos Garnacho
a498d8577e workspacesView: Check for primaryView being null
This is possible according to the getter, and triggers warnings
seen when going back from overview via gestures.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1643>
2021-02-17 14:06:11 +01:00
Carlos Garnacho
ea881ed077 swipeTracker: Reject touch swipes in the wrong directions
We now have multiple touch swipe gestures with matching fingers and
different directions set on the overview hierarchy. Accepting all
touch swipes without checking the direction makes one of these gestures
take control of input, without other gestures having a say on this.

So, look for the direction of the touch events and look if it matches
the expected orientation before accepting the gesture.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1643>
2021-02-17 14:06:11 +01:00
Carlos Garnacho
504ca7d4c3 swipeTracker: Try harder to start touchpad gestures with a direction
Make the touchpad gesture keep track of its state, and enter in a
rejected state if the swipe is happening in the wrong direction.

Effectively, this means touchpad gestures are locked on a single
direction, and horizontal+vertical swipeTrackers won't be handling
events at the same time.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1643>
2021-02-17 14:06:11 +01:00
Florian Müllner
e135f077fb swipeTracker: Reject touchpad swipes in the wrong directions
We now have multiple touch swipe gestures with matching fingers and
different directions set on the overview hierarchy. Accepting all
touchpad swipes without checking the direction makes one of these gestures
take control of input, without other gestures having a say on this.

So, look for the direction of the swipe events and look if it matches
the expected orientation.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1643>
2021-02-17 14:06:11 +01:00
Sebastian Keller
8edfe1dcf6 dnd: Remove pointless scale factor from restore position
Since 629b7394 we don't use the preferred size anymore, but the original
allocation, so this scale factor would always be 1.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1687>
2021-02-17 10:12:00 +00:00
Sebastian Keller
a24a16c5ac dnd: Also consider indirect scaling of dnd actor
Some actors don't have the scale applied to them directly but are
children of a scaled parent. In those case just retaining the scale will
not be enough and the scale of the actor itself needs to be adjusted
when reparenting. This could for example be seen when dragging windows
from the workspace thumbnails.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1687>
2021-02-17 10:12:00 +00:00
Marco Trevisan (Treviño)
cf41f4a527 searchController: Get rid of activePage reference in key handling
Even if activePage has been removed as part of commit 27627bd40, we've
still a reference of it in key press handler.

Given that there's no anymore an active page to redirect input to,
remove these references, so that can be handled in the proper view to
implement key-navigation.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1688>
2021-02-17 02:31:32 +01:00
Sebastian Keller
c01973055f workspace: Ensure that _createBestLayout() always returns a layout
When opening a large number of windows, the computed space and scale for
a layout can become negative due to the per-row/per-column spacing. This
is smaller than the initial values of lastSpace and lastSpace, leading
to a null return which then causes all sorts of other issues resulting
in the workspace becoming invisible.

This change ensures that the function always returns a layout, even if
it may look a bit broken and does not conform to the scale/space
requirements which are impossible to fulfill for the given number of
windows. It's better than displaying nothing, since it allows users to
move/close windows and restore this to a more usable state.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3730

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1685>
2021-02-16 21:24:27 +00:00
Sebastian Keller
901ecfb619 theme: Use the same style for dash tooltips as for window captions
Both serve a similar function but had different styles. Since these two
can now be seen next to each other, the visual difference is quite
noticeable.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3727

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1681>
2021-02-16 19:27:15 +00:00
Marco Trevisan (Treviño)
b74900b3a3 gdm: Override any other lower-priority service message on error
When we got an error, all the other HINT or INFO messages are not useful
anymore and delaying to show them is just a waste of time and may be
even wrong in scenarios with fast authentication devices.

An example are the fingerprint devices, where the user may touch the
sensor repeatedly while we may still show the "touch the sensor" hint
instead of notifying of possible errors.

So, in case we got an error override all the other errors coming from
the same service with lower priority.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1683>
2021-02-16 18:00:10 +00:00
Marco Trevisan (Treviño)
45a5171a95 gdm: Filter service non-error messages on verification stopped or failed
Once the verification has been stopped or has failed all the messages
that are not of error type are just not needed or wrong to show.
For example, in the fingerprint case we may still show the hint to swipe
or touch the device, while the fingerprint PAM service has already been
stopped.

So filter them by adding a new function that adds a null message to the
queue, overriding all the messages that have a lower priority.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1683>
2021-02-16 18:00:10 +00:00
Marco Trevisan (Treviño)
1cc20ca6b6 gdm: Add ability to queue a message overriding ones with less priority
There are cases in which a service may want to override a message with
one coming with higher priority, for example an info or hint message
isn't useful anymore if we've already got an error message.

In the same way when a service has been stopped we don't care anymore
showing its info or hint messages, while it still may be relevant to show
errors.

An example is the fingerprint service that may emit errors quickly while
the hints messages should not be kept around when an error is already
queued or when the service has been stopped.

So, add function that allows to override queued messages based by their
type that follows this policy:
 - Messages coming from different services are always preserved in
   their original order.
 - Messages (from the same service) with a priority equal or higher than
   the last queued one are preserved.
 - Messages matching completely the last queued are dropped in favor of
   this one.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1683>
2021-02-16 18:00:10 +00:00
Marco Trevisan (Treviño)
ef10bb6229 gdm: Keep messages in queue until we've not fully processed them
It can be convenient to get the currently showing message in order to
replace or remove it in case it's not needed anymore.

So simplify the message queue handling by only depending on a single
local variable (_messageQueue) and redefining hasPendingMessages
depending on its content.

Now messages are kept in queue till they are not fully processed and the
first message is always the one currently shown.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1683>
2021-02-16 18:00:10 +00:00
Marco Trevisan (Treviño)
9ecc1a4cd7 gdm: Compress fingerprint failures events using a timeout
When a fingerprint failure event happens we may also soon receive a
conversation-stopped event with an error message (such as in the case
we hit the MAXRETRIES value), but this is going to be ignored in case we
are too quick in consider the first failure a verification-failed event
because that implies disconnecting from all the events and then ignoring
such signals.

To prevent this, add a small timeout before failing the verification so
that if we get a further event we will process it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1683>
2021-02-16 18:00:10 +00:00
Marco Trevisan (Treviño)
1ee9278786 gdm: Don't try to retry authenticating when the service is unavailable
In the case a service is not available (as it can be in the fingereprint
case when a supported reader is available but has not enrolled prints)
we were trying indefinitely to restart it, however this can lead to
troubles since commit 7a2e629b as when the service conversation was
stopped we had no way to figure out this case and we'd end up to
eventually fail the whole authentication.

However, in such cases the PAM services are expected to return a
PAM_AUTHINFO_UNAVAIL and gdm to handle it, emitting service-unavailable
signal.

So connect to ::service-unavailable and keep track of the unavailable
services so that we can avoid retrying with them.
In case such service is not the foreground one, we can just silently
ignore the error as we did before commit 7a2e629b, without bothering
failing the whole verification.

In case we got a valid error message on service-unavailable, we also
show it, this is normally not happening unless GDM isn't redirecting
here other kind of problems (such as MAXTRIES) which are supposed to
stop the authentication stopping any further retry.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3734
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1683>
2021-02-16 18:00:10 +00:00
Jonas Dreßler
e65e5edee6 appDisplay: Use icon-size instead of width/height for system actions
When creating an icon for the system actions search provider, set the
icon size using StIcons own icon-size property instead of ClutterActors
width and height property. That ensures the scale factor is applied and
the icon will be properly scaled on hiDPI screens.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1686>
2021-02-16 13:56:20 +00:00
Jonas Dreßler
8f9d6a4c13 appDisplay: Use new indentation style
Otherwise eslint will complain about the next commit.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1686>
2021-02-16 13:56:20 +00:00
Sebastian Keller
1bd2b0123e windowPreview: Consider chrome overlaps when offscreening for opacity
The icon and close button might be overlapping the window actor but
were not considered in has_overlaps() which gets used to decide whether
to offscreen the actor for transparency. Since currently the icon is
visible when the preview is dragged and the whole actor is turned
transparent, the opacity will not be applied to everything as a whole
but the child actors individually. This leads to the window becoming
visible behind the icon.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1684>
2021-02-16 13:29:00 +00:00
Sebastian Keller
8d5fb73695 workspacesView: Don't invalidate allocation before using it for gesture
Calling startTouchGesture() on the workspacesViews can change the
visibility of the workspaces if not all of them are already shown, such
as when there are more than 3 workspaces or for 3 workspaces if we are
not on the central one. This invalidates the allocation and the width
used as distance for the gesture would become 0, resulting in drag
gestures immediately jumping to the first or last workspace due to a
division by 0.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3721

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1682>
2021-02-16 03:50:52 +01:00
Sebastian Keller
629b7394f7 dnd: Set dnd actor size instead of scaling it when reparenting
Previously the actor could end up using its natural size and then get
scaled down to its allocation before reparenting. This however could
affect the layout of the widget due to the larger size. To ensure the
widget looks the same after reparenting set the size to its original
size.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3717

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1680>
2021-02-16 01:07:23 +01:00
Carlos Garnacho
87558efbf1 st: Keep weak ref on texture cache bound texture source
We don't keep any ref on it, so it might leave us with a dangling
pointer here.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3491
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1672>
2021-02-15 21:09:53 +00:00
Marco Trevisan (Treviño)
7a2e629bd0 gdm: Fail and restart verification on conversation stopped for all services
Currently when the foreground service conversation stops we increase the
verification failed count and try to start it again, while if a
background service has been stopped we just ignore it.

This is causing a various number of issues, for example in the case of
the fingerprint authentication service, it is normally configured to die
after a timeout, and we end up never restarting it (while the UI still
keeps showing to the user the message about swipe/touch the device).

So, in such case let's just consider it a "soft" verification failure
that doesn't increase the failures count but will cause us to reset the
UI and try to restart the authentication (and so the affected service).

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1652>
2021-02-15 16:58:50 +00:00
Marco Trevisan (Treviño)
ed1ace1d99 authPrompt: Bump the user verifier timeout when wiggling the message
Wiggle may make the error message to be visible for less time so provide
the auth prompt an API to increase the timeout to be used for showing a
message in some cases.

This could be reworked when we'll have a proper asyn wiggle function so
that we could just make the user verifier to "freeze", then await for
the wiggle transition to complete and eventually release the verifier.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1652>
2021-02-15 16:58:50 +00:00
Marco Trevisan (Treviño)
75a1798e75 authPrompt: Wiggle error messages coming from the Fingerprint service
When error messages are coming from the fingerprint service they are actual
failures due to an user input in some device, in so in such case we
can highlight this by using a wiggle effect.

This mimics what has been done in gnome-control-center fingerprint panel
and part of [1].

[1] https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/56

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1652>
2021-02-15 16:58:50 +00:00
Marco Trevisan (Treviño)
19c4dce322 authPrompt: Only wiggle the entry on failures coming from the querying service
Currently whenever an authentication failure happens we wiggle the
entry, however this may not be related to the service which failed.

For example if the fingerprint authentication failed for whatever reason,
there's no point to wiggle the text input as it's something unrelated to it.

So, only apply the wiggle effect to the entry in case the failure is
coming from the querying service.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1652>
2021-02-15 16:58:50 +00:00
Marco Trevisan (Treviño)
526f0711f1 gdm: Expose the source serviceName for messages and verification failures
By giving to the AuthPrompt information regarding the source service
name (and so the ability to know whether it's a foreground service) can
give it the ability to behave differently.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1652>
2021-02-15 16:58:50 +00:00
Marco Trevisan (Treviño)
6ccd289691 gdm: Count fingerprint authentication failures in fail counter
Fingerprint PAM module can have multiple failures during a runtime
and we rely on the pam module configuration for the maximum allowed
retries.

However, while that setting should be always followed, we should never
ignore the login-screen's allowed-failures setting that can provide
a lower value.

So, once we have a fingerprint failure let's count it to increase our
internal fail counter, and when we've reached the limit we can emit a
verification-failed signal to our clients.

As per this we need also to ignore any further 'info' messages that we
could receive from the fingerprint service, as it may be configured to
handle more retries than us and they might arrive before we have
cancelled the verification session.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1652>
2021-02-15 16:58:50 +00:00
Marco Trevisan (Treviño)
1158e98913 gdm: Increase the verification failed counter once we've a failure
Decouple the verification failure count increase from
_verificationFailed as there are some cases in which we may want to
increase it without emitting a verification-failed signal.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1652>
2021-02-15 16:58:50 +00:00
Marco Trevisan (Treviño)
53db4b99b8 gdm: Always show fingerprint error messages
When the login/lock screen is shown the error messages for background
services are always ignored.

However, in case the service is the fingerprint authentication method
we still want to be able to show error messages to inform the user
about what failed, and eventually that the max retries (that may be
different from the login screen configuration) has been reached.

This handles partially the design issue [1] related to the login/lock
screen fingerprint authentication.

Eventually we want to use pam extensions to use clearer and parse-able
messages, however in the case of the fingerprint service we can be sure
that the fprint PAM module will only send errors on auth failures.

[1] https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/56

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1652>
2021-02-15 16:58:50 +00:00
Marco Trevisan (Treviño)
f7685dc224 ShellUserVerifier: Add method to check if the service name is fingerprint
We have multiple places where we check if we're handling a fingerprint
event, so let's add a common public function so that it can be used also
by the authPrompt.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1652>
2021-02-15 16:58:50 +00:00
Jonas Dreßler
09602ae2ae blur-effect: Don't use stage view when drawing off-stage
When we're painting off-stage, for example because we're screencasting
or taking a screenshot, there won't be a stage-view associated with the
paint context. The BlurEffect previously didn't handle that case and
would crash.

Fix that and handle that case by assuming the scale is 1 and not
offsetting the rectangle we blit from the draw framebuffer.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1673>
2021-02-15 13:17:08 +01:00
Daniel Mustieles
c592a06911 Updated Spanish translation 2021-02-15 10:48:39 +01:00
Марко Костић
736f1bc5fc Update Serbian translation 2021-02-15 08:16:57 +00:00
Carlos Garnacho
2f446548b1 shell: Drop shell_global_sync_pointer()
This is now unused, and shouldn't be used anymore.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1556>
2021-02-14 13:57:56 +00:00
Carlos Garnacho
863ba76675 messageTray: Drop hack to keep track of X11
This is here to cater for lost events while the pointer wanders
into untracked shell UI (thus not part of the input region under
X11). Let mutter handle this situation instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1556>
2021-02-14 13:57:56 +00:00
Carlos Garnacho
2799760244 windowManager: Drop sync_pointer() after relayouts
We should trust the Clutter machinery here, as it has code to trigger
focus changes triggered by relayouts.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1556>
2021-02-14 13:57:56 +00:00
Carlos Garnacho
2445212e35 messageList: Drop sync_pointer() after relayouts
We should trust the Clutter machinery here, as it has code to trigger
focus changes triggered by relayouts.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1556>
2021-02-14 13:57:56 +00:00
Carlos Garnacho
cbde13fc65 overview: Avoid sync_pointer after pop_modal()
This is only necessary for the X11 backend (as grabs triggered by other
clients leave GNOME Shell oblivious of the actual pointer position), but
is now handled inside Mutter.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1556>
2021-02-14 13:57:56 +00:00
Carlos Garnacho
0141b66d23 grabHelper: Avoid sync_pointer after pop_modal()
This is only necessary for the X11 backend (as grabs triggered by other
clients leave GNOME Shell oblivious of the actual pointer position), but
is now handled inside Mutter.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1556>
2021-02-14 13:57:56 +00:00
Carlos Garnacho
f1437506ea dnd: Avoid sync_pointer after pop_modal()
This is only necessary for the X11 backend (as grabs triggered by other
clients leave GNOME Shell oblivious of the actual pointer position), but
is now handled inside Mutter.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1556>
2021-02-14 13:57:56 +00:00
A S Alam
b9207e0e19 Update Punjabi translation 2021-02-14 00:50:19 +00:00
Balázs Meskó
1e422faeb8 Update Hungarian translation 2021-02-13 23:32:09 +00:00
Sebastian Keller
2501bc5c8f st/scroll-view-fade: Fix vertical top fading
The fade for the vertical top edge was calculating the fade ratio for a
larger height (up to where the bottom fade starts) than it was
displaying.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1674>
2021-02-13 21:00:46 +00:00
Panawat Wong-kleaw
8a76508f71 osk-layouts: Add additional keys to Thai layout
Add Anghankhu (๚), Fongman (๏), Khomut (๛), and Yamakkan ( ๎) keys.

These keys do not exist in most, if not all, Thai physical keyboards,
but may be used by those who study ancient Thai texts. However,
they are an optional part of the TIS-820-2538 spec[0].

[0] https://www.nectec.or.th/it-standards/std820/std820.html

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3106

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1427>
2021-02-13 17:28:23 +00:00
Panawat Wong-kleaw
478b45084c osk-layouts: Add a shift level to Thai layout
It is currently missing entirely from the generated layout.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3106

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1427>
2021-02-13 17:28:23 +00:00
Carlos Garnacho
28f73a175c windowManager: Do not set Wacom LED state through g-s-d
This piece of machinery is going away, in favor of the own kernel's
support.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1075>
2021-02-13 15:52:55 +01:00
Lucas Werkmeister
bbf1fc28ca lookingGlass: Let history trim input
Checking whether the item is empty is now the history’s job, per the
previous two commits. The history also trims the input for us.

The effect of this is that we call _history.addItem(), and thereby move
to the end of the history, even if the input is empty (or consists only
of whitespace); clearing the input field and pressing Enter becomes a
quick way to jump back to the end of the history. (The current history
item is not overwritten if the input is empty.)

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1653>
2021-02-13 08:58:20 +00:00
Lucas Werkmeister
df94055c58 runDialog: Let history trim input
Checking whether the item is empty is now the history’s job, per the
previous commit. The history also returns the trimmed input for us, so
we can avoid doing that work twice.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1653>
2021-02-13 08:58:20 +00:00
Lucas Werkmeister
d31f805817 history: Trim input and ignore if empty
This ports the runDialog changes of [1] to the underlying history
component, where they can benefit looking glass as well: the history is
now responsible for trimming the input and deciding that it shouldn’t be
stored if empty. (Note that _setPrevItem and _setNextItem already
skipped updating the history if the entry was empty.)

Since both users, runDialog and lookingGlass, also need the trimmed
input for other reasons – runDialog to avoid issues when interpreting
the command as a file path (if it can’t be executed as a command),
lookingGlass to decide whether a command should be run at all – have
addItem return the trimmed input. (runDialog and lookingGlass are not
yet changed to take advantage of this – that will be done in separate
commits.)

[1]: https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1442

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1653>
2021-02-13 08:58:20 +00:00
Lucas Werkmeister
30203f2694 history: Use strict equality checks
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1653>
2021-02-13 08:58:20 +00:00
Jakub Steiner
5dafc26b6d HC: Set legible app icons for window thumbnails
Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3692

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1657>
2021-02-13 08:34:43 +00:00
Marco Trevisan (Treviño)
829a096ba1 gdm: Restart only the service that failed at verification-failure
When verification failed using a specific authentication service we're
currently restarting the whole user authentication system, which leads
to lots of unneeded operations (reinitializing a new user verifier proxy,
restarting all the gdm workers with the relative PAM modules and so on).
And this makes also debugging of login problems more complicated, given
we're cluttering the journal with repeated data.

However, at reauthentication failure GDM has already set up for us an
user verifier that we can use reuse to start only the service that had a
failure. So when possible, just start a new service instead of rebooting
the whole authorization process.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Marco Trevisan (Treviño)
85ad1157df gdm: Pass source serviceName to verification failures
Depending on the service name we got the failure from we could react
differently, so let's pass the value to the verification failure
handler.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Marco Trevisan (Treviño)
80a7a8ddb9 gdm: Ensure we cancel all the previously running services on auth retry
When retrying the authentication we should make sure that all the
previously initiated services are stopped in order to begin a new
authentication session with all the configured services.

Unfortunately at the current state we only dispose the currently used
user verifier, but we don't make it to stop all the relative gdm workers
and then they'll stay around potentially blocking any further usage of
them (as it happens with the fingerprint one, that has unique access to
the device).

So, cancel the currently running authentication before starting a new
one if we're explicitly retrying.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Marco Trevisan (Treviño)
ca912f55cc gdm: Include the failed service name when in reporting errors
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Marco Trevisan (Treviño)
36fba1a184 gdm: Do not fail the whole authentication if a background service failed
In case a background service such as the fingerprint authentication
fails to start we'd just mark the whole authentication process as
failed.

Currently this may happen by just putting a wrong password when an user
has some fingerprints enrolled, the fingerprint gdm authentication
worker may take some time to restart leading to a failure and this is
currently also making the password authentication to fail:

    JS ERROR: Failed to start gdm-fingerprint for u: Gio.DBusError:
        GDBus.Error:org.freedesktop.DBus.Error.Spawn.Failed:
            Could not create authentication helper process
        _promisify/proto[asyncFunc]/</<@resource:///org/gnome/gjs/modules/core/overrides/Gio.js:435:45
        ### Promise created here: ###
        _startService@resource:///org/gnome/shell/gdm/util.js:470:42
        _beginVerification@resource:///org/gnome/shell/gdm/util.js:495:18
        _getUserVerifier@resource:///org/gnome/shell/gdm/util.js:405:14
        async*_openReauthenticationChannel@resource:///org/gnome/shell/gdm/util.js:378:22
        async*begin@resource:///org/gnome/shell/gdm/util.js:194:18
        _retry@resource:///org/gnome/shell/gdm/util.js:561:14
        _verificationFailed/signalId<@resource:///org/gnome/shell/gdm/util.js:584:30
        _emit@resource:///org/gnome/gjs/modules/core/_signals.js:133:47
        finishMessageQueue@resource:///org/gnome/shell/gdm/util.js:268:14
        _queueMessageTimeout@resource:///org/gnome/shell/gdm/util.js:273:18
        _queueMessageTimeout/this._messageQueueTimeoutId<@resource:///org/gnome/shell/gdm/util.js:288:65

Given that background services are ignored even for queries or any kind
of message, we should not fail the authentication request unless the
default service fails.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Marco Trevisan (Treviño)
0ccb8e27d4 gdm: Disconnect user verifier signals on destruction and verification failed
When a verification session has failed we may want to wait for the user
to have completed all the waiting queries and to have read all the
incoming messages, however during such time an user verifier should
not be allowed to queue further messages to the UI, as we're about to
completely stop the identification or start a new one.

Unfortunately this is not true because we're still connected to the
identifier signals, and so we may still show messages.
This is particularly true when using the fingerprint PAM module as it
may restart the authentication while we're in the process of stopping
it.

So, keep track of all the signals we've connected to, and disconnect on
verification failed and during cancel/clear operations.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Marco Trevisan (Treviño)
c936ca3ea0 gdm: Don't try answering query if the user verifier has been deleted
Answering a query may be delayed to the moment in which we've not any
more messages in the queue, however this case can also happen just after
we've cleared the UserVerifier and in such case we'd have nothing to
answer, but we currently throw an error:

    JS ERROR: Exception in callback for signal: no-more-messages:
      TypeError: this._userVerifier is null
    answerQuery/signalId<@resource:///org/gnome/shell/gdm/util.js:249:17
    _emit@resource:///org/gnome/gjs/modules/core/_signals.js:133:47
    finishMessageQueue@resource:///org/gnome/shell/gdm/util.js:266:14
    _clearMessageQueue@resource:///org/gnome/shell/gdm/util.js:301:14
    clear@resource:///org/gnome/shell/gdm/util.js:223:14
    cancel@resource:///org/gnome/shell/gdm/util.js:205:18
    reset@resource:///org/gnome/shell/gdm/authPrompt.js:482:32
    cancel@resource:///org/gnome/shell/gdm/authPrompt.js:569:14
    vfunc_key_press_event@resource:///org/gnome/shell/gdm/authPrompt.js:128

So handle this case more gracefully keeping track of the current
cancellable and checking whether it is still valid before trying to answer
a query or do a delayed action.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Marco Trevisan (Treviño)
c8bb45b41c gdm: Limit verification cancellations to be conform to allowed-failures
As per previous commit the user can cancel an ongoing authentication via
Escape key and that will always send the user back to the clock view in
lockscreen or user-selection view in login prompt.

However, we can be a little more permissive and don't switch view to be
able to restart the authentication without further action.

To avoid this to be abused though, we consider the user verification
cancellation via escape key to be a "soft-failure", so once the
configured "allowed-failures" gsettings value has been reached, we'd
just act as before, ignoring any further request (until we don't get
back to the user auth view).

In this way we still make brute-force attacks harder to do, while still
giving the well-behaving user some ability to fix mistakes.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Marco Trevisan (Treviño)
7e77881717 authPrompt: Handle Escape key to cancel ongoing verification
Escape key is supposed to cancel a verification, however if the user
already hit Enter to begin the authentication the Escape key won't work
until the verification completed.

This may be quite inconvenient when an user did a typo while writing and
wants to cancel the already started auth.

So, while authenticating (or in general while the entry is unsensitive)
give the key focus to the authpromt itself so that we can still get the
input events and cancel an user action.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Marco Trevisan (Treviño)
3e96952fde authPrompt: Don't begin a new authentication session on lockscreen cancel event
When a cancel event in the user lockscreen happens we first emit a reset
signal and immediately a cancelled one.

This lead to start a new gdm worker for each enabled authentication
method and then immediately to stop it.
As per the previous commit, we don't have anymore dangling gdm workers
around, but still we should not even start a new one in such case.

So, when the user explicitly cancelled the authentication session, first
emit a cancelled event and only emit a reset event with a begin request
if we are outside the lockscreen.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Marco Trevisan (Treviño)
b916df1110 gdm: Cancel user verification on UserVerifier destruction
When we cancel an user authentication via Escape key or cancel button on
AuthPrompt we reset the view and we emit a 'cancelled' signal that leads
to destroying the auth prompt and the user verifier.

However, the verifier may still have an operation in progress and its
completion may take some time (as in the case of gdm-fingerprint), but
we just leave the gdm worker running until its pam module completes
(potentially never) clearing and disposing its handle.

So, instead of just clearing the verify, actually cancel and clear it.
In case the user verifier is set, clearing the relevant data will happen
anyway as part of the cancel() call.

Ideally this would have been handled by gdm itself, but unfortunately we
can't fix it there because the verifier itself is a class generated by
gdbus-codegen, so we can't handle this automatically on disposal nor we
can automatically monitor when the caller proxy is stopped on our side.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3654
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1622>
2021-02-12 20:26:00 +00:00
Florian Müllner
2beca14b8d windowPreview: Tie icon scale to overview state
Scaling the icons all the way from/to 0 is a relatively big transition,
which is fairly distracting when playing simultaneously for multiple
previews after reaching the WINDOW_PICKER state.

Instead, tie the scale to the overview state itself, so that the animations
runs in parallel.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1654>
2021-02-12 19:48:43 +00:00
Fran Dieguez
74575ee330 Update Galician translation 2021-02-12 19:10:40 +00:00
Аляксей
338862f3e6 Update Belarusian translation 2021-02-12 16:18:19 +00:00
Bruno Lopes da Silva
ee330eabbd Update Brazilian Portuguese translation 2021-02-12 15:12:52 +00:00
Kukuh Syafaat
f788962473 Update Indonesian translation 2021-02-12 12:01:04 +00:00
Daniel Șerbănescu
df9766a239 Update Romanian translation 2021-02-12 10:20:30 +00:00
Georges Basile Stavracas Neto
c0a4d90847 overviewControls: Limit Dash height to 15% of the overview's
Back when the Dash was vertical, the size of each item was calculated
solely based on the available height. After making the Dash horizontal,
this was swapped by the available width. However, when the height of the
Dash decreases, the current code results in never scaling them up ever
again.

Fix that by making ControlsManagerLayout explicitly pass the maximum Dash
sizes. Remove the 'notify::width' handler that served the same purpose.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3651

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1638>
2021-02-11 22:31:50 +00:00
Georges Basile Stavracas Neto
1b51ae150d searchController: General cleanup
Fix style issues, such as indentation and == → ===. Simplify
getTermsForSearchString() by removing one variable.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1667>
2021-02-11 21:14:36 +00:00
Georges Basile Stavracas Neto
c8f1dca3c7 Rename ViewSelector to SearchController
Rename ViewSelector to SearchController, since ViewSelector now effectively
only handles search. Rename the file correspondingly as well.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1667>
2021-02-11 21:14:36 +00:00
Georges Basile Stavracas Neto
27627bd40a viewSelector: Cleanup pages
Remove the dummy applications page that was introduced as a temporary
step. Replace the 'page-changed' and 'page-empty' signals with a 'search-active'
boolean property.

Remove ViewSelector.ViewsPage since it's now unused, and all the page handling
mechanism. At last, since we don't use any ShellStack features anymore, simply
make it a St.Widget with a ClutterBinLayout as the layout manager.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1667>
2021-02-11 21:14:36 +00:00
Yuri Chornoivan
692b6d2577 Update Ukrainian translation 2021-02-11 20:40:03 +00:00
Anders Jonsson
960f87ede6 Update Swedish translation 2021-02-11 19:46:04 +00:00
Jonas Dreßler
3510b88bdc screenshot: Remove shooter from sender in finally block
We do this in both the try{} and the catch{} block, so we might as well
put it into a finally{} block.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1658>
2021-02-11 18:51:40 +00:00
Jonas Dreßler
c1bfdd74d8 screenshot: Fix slow audiovisual feedback on when taking screenshot
Add a "screenshot-taken" signal from the screenshot service's internal C
implementation, and use that to trigger the camera flash visual effect
and the click sound, allowing them to run in parallel with the PNG
compression instead of waiting until the file is complete to start.

This significantly improves perceived latency on high res setups such as
4K, 5K, or dual 4K screens.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/512

Co-authored-by: Brion Vibber <bvibber@wikimedia.org>
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1658>
2021-02-11 18:51:40 +00:00
Jonas Dreßler
461c65c93b screenshot: Replace template strings with .format()
CI will complain when we add screenshot.js to the POTFILES in the next
commit because gettext doesn't like template strings, so make CI happy
and switch to .format() instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1658>
2021-02-11 18:51:40 +00:00
Brion Vibber
f9652aab82 Fix for screenshots when pictures path is unavailable
On my local jhbuild setup some local stuff is not set up and
there's no pictures folder. This fixes a regression where it
blew up instead of saving to the home dir in this situation.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1658>
2021-02-11 18:51:40 +00:00
Georges Basile Stavracas Neto
86cefd906b workspace: Disable overlay for inactive workspaces too
In addition to disabling the overlay when the state is not 1,
disable it also when not in the active workspace.

Make the Workspace class track the workspace's active state,
and resync the overlays when it changes.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1645>
2021-02-11 17:21:48 +00:00
Georges Basile Stavracas Neto
2e817d3fa8 workspace: Always leave overview when in app grid state
The behavior of workspaces is different depending on whether
the overview is in window picker state, or app grid state.

When in window picker state, clicking on adjacent workspaces
should only activate them, without hiding the overview; and
clicking on the active workspace hides the overview. When in
app grid state, clicking on a workspace must always hide the
overview.

Pass the overview adjustment to Workspace, and leave overview
if the overview state is bigger than WINDOW_PICKER.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1645>
2021-02-11 17:21:48 +00:00
Florian Müllner
d6a1414a94 extensions-app: Use development profile for nightly build
https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3612

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1661>
2021-02-11 17:47:27 +01:00
Florian Müllner
5069572f85 extensions-app: Stop prefixing .desktop file
Adding prefixes like (Nightly) is discouraged nowadays in favor of
the radioactive icon overlays.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3612

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1661>
2021-02-11 17:47:27 +01:00
Florian Müllner
6bea1e7a47 extensions-app: Include commit hash in nightly version
It's useful information for development snapshots, so include
it when building from a git checkout.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3612

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1661>
2021-02-11 17:45:00 +01:00
Florian Müllner
60d640189b extensions-app: Support building a separate Devel app
Follow the pattern used by most GNOME applications and add a profile
build option that allows building a Devel app instead of the regular
release.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3612

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1661>
2021-02-11 17:45:00 +01:00
Florian Müllner
e8ca92a0ff extensions-app: Pick up app ID from package
This will allow us to build different applications from the
same sources (namely "Extensions" and "Extensions Nightly").

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3612

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1661>
2021-02-11 17:45:00 +01:00
Georges Basile Stavracas Neto
bf1fa3879f workspacesView: Interpolate against relative workspace boxes
The overview transition consists of getting the initial and final
states of the overview adjustment, derivating various other internal
states from them (such as the fit mode, opacities, translations, etc),
and finally interpolating the allocation boxes.

When interpolating between the fit mode, WorkspacesView uses the current
allocation box to derivate the SINGLE and ALL fit mode boxes. However,
that creates a curved path during overview transitions. What we really
want to do here is calculate the fit mode box relative to the corresponding
overview state. For example:

 +----------------+----------+------------------------+
 | Overview State | Fit Mode | Workspaces geometry    |
 +----------------+----------+------------------------+
 | HIDDEN         | SINGLE   | Cover entire screen    |
 | WINDOW PICKER  | SINGLE   | Between minimap & Dash |
 | APP GRID       | ALL      | 15% screen height      |
 +----------------+----------+------------------------+

Using the table above as the reference, when the overview transitions
between WINDOW PICKER and APP GRID, we must interpolate between
(SINGLE fit mode @ between minimap & Dash) and (ALL fit mode @ 15% screen
height). That way, we always interpolate the final boxes, which corrects
the odd path that workspaces follow during this transition.

Make the WorkspacesView of the primary monitor use these cached boxes
when the overview is in the middle of a transition, and the fit modes of
the initial and final state differ, to calculate the workspaces positions.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
9c6d8e2aad overviewControls: Cache workspaces boxes
Next commit will need to access the allocated workspaces boxes, so
cache them at allocation time.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
6870f3ccb4 theme: Adjust app grid visuals
So that at least in 1366x768 it doesn't switch to 32px icons.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
ca066a4ba6 workspacesView: Use calculated workspace state for progress
It works just like before, except that this has the nice side effect
of not changing the workspace mode when leaving the overview from
the app grid state.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
87645652e5 overviewControls: Make AppDisplay rise from the bottom
It makes more sense in a spatial overview that the app grid
comes and goes to somewhere in the screen, instead of fading
in and out into the void.

Make the app grid rise from the bottom of the screen.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
a9f11b1f5a workspacesView/workspacesDisplay: Remove parent opacity hack
Now, we set WorkspacesDisplay's opacity directly, so there's no
need to have this parent → child glue code anymore. Remove it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
c09c070b15 overviewControls: Incorporate ActivitiesContainer
Move AppDisplay, WorkspacesDisplay, and ThumbnailsBox from ViewSelector to
ControlsManager. This allows to always allocate the correct size for AppDisplay,
and will enable for a plethora of further improvements. The end goal is to
completely remove ViewSelector, and let ControlsManager handle the layout of
everything that's visible in the overview.

For now, replace the apps page with a dummy actor in ViewSelector.

Adjust various callers around the codebase to not access the ViewSelector
directly from the overview anymore.

Bind the opacity of the primary workspace to WorkspaceDisplay's opacity. This
allows removing the parent opacity hack in place, which will be done by the
next commit.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
83127bf805 overviewControls: Use specialized class for Overview adjustment
It'll be useful for the next commits to have a handy 'getState' method
that calculates the progress of any particular transition.

Move the St.Adjustment to a specialized subclass.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
4cf5898d85 viewSelector: Remove pinch gestures
It'll be replaced by a 3 finger gesture that sticks to fingers
and progressively transitions between states.

Remove both pinch and touchpad pinch gestures from ViewSelector.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
cbe0180f47 viewSelector: Drop edge drag gesture
It doesn't use any ViewSelector's API anymore, and its functionality will be taken
over by the 3 finger gesture.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
80d258b20f viewSelector: Move 'toggle-applications-view' to ControlsManager
Move the shortcut handling into ControlsManager, and reimplement
the callback in such a way that it behaves correctly with the
current overview machinery.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
b32f414919 viewSelector: Remove showApps()
Now that Overview is able to ease into any state, be it window
picker or app grid, we can move this ViewSelector method to
Overview itself, which is its rightful place to live.

Remove ViewSelector.showApps(), and make all callers call
Main.overview.show(ControlsState.APP_GRID). Also make sure the
show apps button is correctly toggled.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
8089d7cbf7 overivew: Propagate target state when animating to overview
Next commits will requires ControlsManager to animate to different
states, depending on how Overview is called. Add a new 'state'
parameter to ControlsManager's, and OverviewActor's animateToOverview,
and Overview.show().

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
bce67a27cc viewSelector: Move 'toggle-overview' shortcut to overview
It is handled there already, there's no reason for it to continue
to be in ViewSelector.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
22f4a6b7f6 workspace, workspacesView: Cleanup animation methods
Remove Workspace.zoomTo/FromOverview(), they're unused now. Rename
everything up to ControlsManager to prepareToEnter/LeaveOverview(),
since these classes don't run the animation anymore.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
d221215ab6 workspacesView: Derive workspace mode from overview state
WorkspacesView uses the floating layout when the overview is in window
picker mode, and the session layout when the overview is in app grid
mode. Up until now, the fit mode adjustment was used to derive the
workspace mode, but it is incomplete as it doesn't have the full range
of workspace states.

Make ViewSelector cascade the overview adjustment to WorkspacesDisplay,
and use the overview adjustment itself to derive the workspace mode.

Extra workspaces don't have to account for the fit mode, and thus are
basically a clamp(state, 0, 1) of the overview state. However, don't
call animateTo/FromOverview() anymore, since they ease the workspace
mode adjustment.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Florian Müllner
741d6abb97 workspacesView: Add primary view to workspaces display
Boy, does this commit feel good.

While the workspaces view on the primary monitor *appears* as part of
the overall overview hierarchy, this hasn't actually been the case
until now. We synchronized its size and (stage) position to match
the workspaces display, but actually kept in a separate layer for
the transitions to and from the overview.

But now that the new layout manager slides out completely during the
overview transitions, the workspaces display starts out covering the
entire work area, which is exactly what we need for the transition.

So finally stop faking it, and actually make the primary workspaces
view a child of the workspaces display.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
1ad1db406e overview: Don't fade OverviewActor
Now that the workspace display is properly allocated for each frame,
we don't want to fade the entire overview anymore.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
b6337a7bf1 overviewControls: Ease main adjustment when animating to/from overview
Instead of delegating it to ViewSelector, make the transition to and from
overview ease the main state adjustment.

This commit temporarily breaks these animations, but on the other hand
introduces an important feature: ViewSelector is always allocated to the
actual size. This will finally allow for adding WorkspacesView as a child
of WorkspacesDisplay, and finally remove the actual geometry hack, which
is what next commit is about.

This commit also effectively reverts b64103efc.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
0a8aeebd30 overview: Reorganize animateTo/FromOverview()
Instead of directly accessing ViewSelector and calling these methods
there, cascade the calls to OverviewActor, ControlsManager, and finally
ViewSelector. Also move the opacity transition to OverviewActor.

This commit has no functional change.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
e6e5a93dec viewSelector: Use state adjustment for apps page
Currently, ActivitiesContainer reacts to showAppsButton and
transitions between app grid and window picking states on
its own. In the future, we want full control over this.

ControlsManager already has a state adjustment that represents
all possible overview states. Propagate this adjustment up to
ActivitiesContainer, and use it to drive the transition.

This requires moving the callback to the showAppsButton to
ControlsManager, since now it control the state adjustment
itself, not ActivitiesContainer's adjustment.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
3887253823 overviewControls: Use adjustment to control layout
Right now, the adjustment is fixed at ControlsState.WINDOW_PICKER,
but soon it will be propagated to ViewSelector to control the
transitions.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
55510e9cdf overviewControls/controlsManager: Use a custom layout manager
In the future, we want to tightly control the state of the
layout throught gestures, which requires hooking everything
together with adjustments. This is the first step in this
direction.

Add a new custom layout manager for ControlsManager that
allocates the search entry, the view selector, and the Dash,
vertically.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Georges Basile Stavracas Neto
301686ee5f overview: Move search entry to ControlsManager
Next commit will tie all these widgets up with a single
layout manager, and we need to control the search entry
position.

Move it to OverviewControls.ControlsManager.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1624>
2021-02-11 15:50:31 +00:00
Pascal Nowack
d02612e790 ui/windowManager: Fix horizontal scrolling when smooth events are used
Currently, gnome-shell uses the wrong scrolling direction for
horizontal scrolling events.
When dx < 0 for a smooth scroll event, then the scrolling direction is
supposed to be Clutter.ScrollDirection.LEFT, instead of
Clutter.ScrollDirection.RIGHT, as dx is smaller than 0.

Fix this issue by swapping the values LEFT and RIGHT.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1665>
2021-02-11 15:43:19 +01:00
Florian Müllner
21faae480e polkitAgent: Ensure cleanup if dialog wasn't shown
It is possible for an initiated session to complete without
a request if polkit can authenticate the action without user
input. We fail to clean up after ourselves in that case, as
the cleanup is done after the dialog is closed.

The dialog can still be shown when the code that hides existing
dialogs while the screen is locked shows it on unlock. But as
the session was closed, the dialog is now defunct and cannot
be dismissed by the user.

Fix this by running the cleanup on close() when the dialog
wasn't shown.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3701

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1662>
2021-02-11 13:48:54 +01:00
Leleat
9fcbf3d0f9 extensions-app: Add description tooltip to rows
... to allow showing the full description in case the label is ellipsized.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1663>
2021-02-11 11:20:30 +01:00
Hugo Carvalho
0aab90bb7f Update Portuguese translation 2021-02-10 19:04:34 +00:00
Florian Müllner
3a9acb9602 dash: Re-fittsify
Now that the dash is no longer attached to a screen edge, it lost
its "infinite width" (Fitts' law). Restore it by moving the visible
bar into a separate layer underneath the actual icons, extend the
icons to the bottom edge, and replace the margin around the dash
with padding inside the icons.

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/89

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1660>
2021-02-10 15:46:00 +00:00
Florian Müllner
5c31ef6ae2 dash: Reindent some more code
Again we're about to touch it.

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/89

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1660>
2021-02-10 15:46:00 +00:00
Florian Müllner
73b94c3901 overviewControls: Remove DashFader
By now there is so little left of the old sliding controls that the
split from the actual dash makes little sense.

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/89

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1660>
2021-02-10 15:46:00 +00:00
Jakub Steiner
0173a6646f stylesheet: Increase app dropshadows
Increase the app icon dropshadow to separate the icon from the window thumbnail.
The shadow change is global, but due to perfomance implications, the icon-dropshadow
class is only used on the thumbnail view.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3670

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1656>
2021-02-10 16:19:23 +01:00
Florian Müllner
9aa25eaa0b dash: Consider additions for separator visibility
The children variable holds the icons that were originally in
the dash. For the separator visibility, we should consider the
icons that are in the dash after the update, so we must consider
additions as well as removals.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1659>
2021-02-10 09:09:34 +00:00
Matej Urbančič
6a2ed852e7 Update Slovenian translation 2021-02-09 20:44:37 +00:00
Jordi Mas
504f2b20ef Update Catalan translation 2021-02-09 20:28:34 +01:00
Daniel Mustieles
218642b807 Updated Spanish translation 2021-02-09 16:13:59 +01:00
Abderrahim Kitouni
9aae1df7a6 workspacesView: Fix off-by-one error
This is basically 9f0e7632a6 ported over ed1170906b which was dropped this
fix when copying things around.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1655>
2021-02-09 09:40:29 +00:00
Florentina Mușat
8e6191b436 Update Romanian translation 2021-02-09 09:31:30 +00:00
Yuri Chornoivan
bc3c1ea6e3 Update Ukrainian translation 2021-02-09 06:47:34 +00:00
Marco Trevisan (Treviño)
a19e6573e1 loginDialog: Fill UserListItem layout to show the timed login indicator
When the timed indicator is shown the UserListItem layout should fill
so that the timed indicator can expand to use the whole item space.

So, always use the default value for x-align that will make it to fill
the available space without causing any regression when the timed
indicator is hidden.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3675
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1644>
2021-02-09 06:08:55 +00:00
Fran Dieguez
fe3c9be5ab Update Galician translation 2021-02-08 22:45:32 +00:00
Alexander Mikhaylenko
2b9cf73309 workspacesView: Enable long swipes
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1647>
2021-02-08 22:20:26 +00:00
Alexander Mikhaylenko
16f74ebc57 swipeTracker: Add allowLongSwipes property
Since we now have the ability to support swiping through multiple pages,
expose it as a property.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1647>
2021-02-08 22:20:26 +00:00
Alexander Mikhaylenko
10cafc55c1 swipeTracker: Rework end point calculation
Previously we used a bunch of heuristics for this. We checked if velocity
was directed towards the nearest snap point and its value was larger than
a threshold. If it is, we completed the swipe, otherwise we cancelled it.

This was good enough at the time, because this code was originally written
for back/forward swipe. Since then, the swipe tracker was extended to
handle arbitrary snap points and not just 0 and 1, or -1 and 0, depending
on text direction. After that it was iterated on, but never significantly
redone.

This worked well enough, but had two problems:

1. In some cases, notably overview, it may be wanted to be able to swipe
   through multiple pages at once. This wasn't really possible because we
   always picked the adjacent snap point.

2. Since we can't do that well, we want to restrict swipes to one page at a
   time. It was done in a rather hacky way by clamping the position into
   [-1, 1] range from the place where we started the swipe. This works
   if we start the swipe from idle position, but if an animation was
   already going, the range would be clamped to arbitrary values, and very
   likely containing only one snap point, which we already swiped past at
   this point. In this case, finishing the swipe would cancel it regardless
   of velocity. This means that if one tries to quickly move through
   carousel pages via swiping, half of the swipes will be inexplicably
   cancelled.

We'll use the deceleration formula from
https://medium.com/@esskeetit/how-uiscrollview-works-e418adc47060#10ce
to calculate then projection point, then pick the nearest snap point and
calculate the duration as we did before. It works well enough for short
distances, but has two problems:

1. It caps the maximum distance at a pretty low value - about 5 pages in my
testing.

2. With how we pick the nearest snap point, it's too easy to accidentally
cancel the swipe,

To combat the first problem, we can modify the curve: only use linear
function at small distances, and smoothly transition it to a parabola
further.

For the second problem we can add two special cases: first, if the swipe
ended up between the initial snap point and the next one, we always prefer
the latter. Second, a good old velocity threshold for cancelling.

We'll also use a slightly smaller deceleration value for touchpad: 0.997
instead of 0.998.

Now that we can pick any snap point, the [-1, 1] clamping doesn't make
sense anymore, so instead let's replace it with a more flexible
mechanism: if we're near a snap point, pick its adjacent snap points.
Otherwise, take the two nearest snap points, and take their adjacent
snap points. This way we have 3 snap points to choose from when
starting a swipe from an idle position, and 4 if we start during an
ongoing transition.

This way, if we've just swiped from snap point n to n+1, the transition
will pick snap points n-1, n, n+1, n+2 and if we swipe again, we will
likely land on n+2. During that transition, if we swipe again, it will
likely have already passed the snap point n+1, so this time the available
snap points will be n, n+1, n+2, n+3, so we can swipe again and it will
still complete, and so on.

This will make it easy to allow multi-page swipes as well, by just
removing the clamping.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1647>
2021-02-08 22:20:26 +00:00
Alexander Mikhaylenko
cf87ab04aa swipeTracker: Calculate velocity using scroll history
In some cases we may get anevent with very low delta at the end of the
swipe. While we can't completely ignore them, we can smooth them using a
scroll history, similarly to what GTK kinetic scrolling does: keep track
of the last 150ms of events, and sum their deltas when calculating the
velocity.

The logic is based on what GTK does in GtkGestureSwipe and
GtkEventControllerScroll.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1647>
2021-02-08 22:20:26 +00:00
Anders Jonsson
a767e568ea Update Swedish translation 2021-02-08 21:50:37 +00:00
Razze
aa392d45c9 fingerprint: Show different strings depending on type
Fprintd knows if the fingerprint reader is of the swipe or press type. We now show different labels depending on that.

Closes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2011

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1572>
2021-02-08 19:19:14 +00:00
Razze
824cdc9177 fingerprint: Use makeProxyWrapper for fprintManager
The reason this wasn't using the Gio.DBus.makeProxyWrapper() convenience API is that it passes custom flags to the proxy, and that wasn't supported by the wrapper at the time.

As this is now possible, this commit migrates us to the new API.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1572>
2021-02-08 19:19:14 +00:00
Florian Müllner
f19c75d9c3 st: Test for :insensitive styling
Commit 473e77e2c5 fixed applying the :insensitive pseudo class to
initially unreactive widgets, and adjusted the style test to work
with that.

In hindsight, we can do better than just making the test work, and
include a test case for the :insensitive styling as well (namely
the issue the previous commit was fixing).

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1649>
2021-02-08 15:41:08 +01:00
Florian Müllner
39d5d6ad13 ci: Bump mutter image
Needed for mutter's bumped pipewire dependency.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1650>
2021-02-08 15:21:17 +01:00
Rafael Fontenelle
5212ac25de Update Brazilian Portuguese translation 2021-02-08 11:33:54 +00:00
Lucas Werkmeister
6ac32f1fc0 runDialog: Trim input before processing
This way, whitespace-only (nonempty) input gets the same treatment of
not being added to the history (see previous commit), which seems nice.

Part of https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3183.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1442>
2021-02-08 08:14:46 +00:00
Lucas Werkmeister
cb26a636e8 runDialog: Don’t add empty input to history
If the input is empty, there’s no point in adding it to the history –
it’ll just be mildly annoying when the user has to skip past it next
time they consult the history.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3183.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1442>
2021-02-08 08:14:46 +00:00
Lucas Werkmeister
7bea63ae4b runDialog: Don’t treat empty input specially
Let empty input result in an error, just like other invalid commands
(bad syntax, nonempty whitespace, etc.). GLib already has an error
message “Text was empty (or contained only whitespace)” which it shows
for whitespace-only input, so letting that message apply also to empty
input makes sense.

This requires some tweaks further down the file to avoid interpreting
empty input as an empty path (relative to the home directory) and then
opening the home directory.

Part of https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3183.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1442>
2021-02-08 08:14:46 +00:00
Florian Müllner
473e77e2c5 st/widget: Fix applying :insensitive to initially unreactive widgets
We are applying the :insensitive pseudo class to unreactive widgets,
or at least we are supposed to. As we currently only update the style
on notify, we don't apply it to initially unreactive widgets.

This was covered up partially until recently when Clutter started to
use G_PARAM_EXPLICIT_NOTIFY. Before that, the notify handler would run
when explicitly setting :reactive to FALSE at construction time.

Make sure we always apply the pseudo class correctly by updating it
after construct properties have been set.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3685

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1648>
2021-02-07 23:48:32 +01:00
TerraAr
d75b64b88f shell-util: Use early-return in shell_util_get_week_start()
Cleanup shell_util_get_week_start() a little bit and use an early-return
instead of setting the week_start variable to 0.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1546>
2021-02-07 14:46:27 +00:00
Daniel Șerbănescu
b90e270dc6 Update Romanian translation 2021-02-07 14:08:24 +00:00
Sebastian Keller
9e86cdbe71 st/theme-node-drawing: Fix inner shadow fast path condition
We want to use the fast path of filling the entire area if either the
left and right shadows would overlap or the top and bottom shadows. The
latter check was wrong due to a typo resulting in the regular path
being used in some cases it couldn't (and shouldn't) handle.

This was causing the inset shadow used to highlight panel buttons to
not appear for buttons above a certain width.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1646>
2021-02-07 01:00:05 +00:00
Fran Dieguez
0a35735ba0 Update Galician translation 2021-02-07 00:07:52 +00:00
Hugo Carvalho
89af7e228a Update Portuguese translation 2021-02-06 21:47:55 +00:00
Marek Černocký
697cccf5da Updated Czech translation 2021-02-06 09:37:37 +01:00
Marek Černocký
02ff0f57e9 Updated Czech translation 2021-02-06 08:28:11 +01:00
Yuri Chornoivan
86b50a103e Update Ukrainian translation 2021-02-05 20:23:04 +00:00
Anders Jonsson
ec3d94e426 Update Swedish translation 2021-02-05 18:42:39 +00:00
Bastien Nocera
865337fe0f data: Fix grammar and wording in new GSettings key
The description for the 'welcome-dialog-last-shown-version' key
must have been written quite late in the day, as it's full of grammar
mistakes, typos and British English.
*sips coffee*
I can say that, because I wrote it.
*sips coffee*
Anyway, that might be a bit better.

*sips coffee* and Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1641

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1641>
2021-02-05 16:13:07 +01:00
Bastien Nocera
512016dcb5 main: Show welcome dialogue on first start
This hooks the recently added welcome dialogue to be shown the first
time a new session is started, and disabled after that.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3632
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1619>
2021-02-05 13:41:26 +00:00
Bastien Nocera
b0a48fad57 util: Add a GNOME version comparison function
Add a function that can compare GNOME versions, including the new naming
scheme for GNOME 40 and later.

Used in https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3632

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1619>
2021-02-05 13:41:26 +00:00
Bastien Nocera
af4e54bfc9 welcomeDialog: Add “welcome” dialog
As designed at:
https://gitlab.gnome.org/Teams/Design/os-mockups/-/blob/master/greeter/welcome-dialog.png

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3632
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1619>
2021-02-05 13:41:26 +00:00
Jakub Steiner
53ea9ba805 theme: Space dash items
- don't nuke separator
- space appropriately

Fixes a fix for https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3640

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1636>
2021-02-05 12:06:30 +00:00
Jakub Steiner
97b9cdc720 theme: Legible thumbnail close button
- prominent close button
- legible yet stylish thumbnail labels

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3669
2021-02-05 12:51:23 +01:00
Florian Müllner
49690f3962 data: Update custom close icon
The existing asset has a nice black rectangle on top of the
intended shape.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1640>
2021-02-05 01:01:09 +01:00
Florian Müllner
29e2b15236 data: Rename custom close icon
Resource icons are added to the fallback icon theme, so they won't
get used if a matching icon is found in the configured theme.

That includes fallback names, so Adwaita's "window-close-symbolic"
takes precedence over "window-close-24-symbolic" in hicolor.

Fix this by using a custom name for a custom icon.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1640>
2021-02-05 01:01:09 +01:00
Florian Müllner
b0e6972cb7 data: Move custom close icon into actions/
Adwaita uses ui/ for the corresponding icon, but GTK treats icons
from a resource path as part of the hicolor theme that doesn't
have such a subdir. And as GTK determines subdirs by enumerating
the theme directory, any subdirs that only exist in the resource
are ignored, whoops.

Make sure the icon can be found by moving it to a standard subdir.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1640>
2021-02-05 01:01:09 +01:00
Sebastian Keller
0f46a1d650 theme: Scale media player button padding with font size
The total width of the MediaMessage scales with the font size, but the
padding of the media player buttons do not, which can become an issue
with text-scaling-factor < 1.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3664

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1632>
2021-02-04 22:42:08 +00:00
Sebastian Keller
c61e1e5c2c mpris: Hide unused elements to leave more space for the title
The Message class this is derived from unconditionally adds a close
button with 0 opacity that only gets shown on hover for messages that
can actually be closed. The MPRIS MediaMessage however can never be
closed and having a close button can cause the title to be cut short
unexpectedly.

Similarly the secondary text which other notifications use to display
the notification time is always left empty here as well.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3664

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1632>
2021-02-04 22:42:08 +00:00
Marco Trevisan (Treviño)
e641547ddf appDisplay: Do not bind popdown call to grabHelper onUngrab
grabHelper is passing a boolean argument to onUngrab() callback function
and since commit 1acbdcc9b3 we'd end up adding it to to the callback list or
we'd try to invoke it:

 (gnome-shell:3490851): Gjs-CRITICAL **: 17:19:20.460: JS ERROR:
  TypeError: func is not a function
  onComplete/<@/media/M2/GNOME/gnome-shell/js/ui/appDisplay.js:2407:56
  onComplete@/media/M2/GNOME/gnome-shell/js/ui/appDisplay.js:2407:40
  _makeEaseCallback/<@/media/M2/GNOME/gnome-shell/js/ui/environment.js:85:13
  _easeActor/<@/media/M2/GNOME/gnome-shell/js/ui/environment.js:170:64

Use an arrow function so that we can control the parameters we pass
to popdown.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1635>
2021-02-04 21:55:34 +01:00
Razze
f5b622a703 panel: Align left and right margin for status panel item
We now set a padding for the left and right
side of the pill. We also got rid of the padding on the icon.

Probably broken due to the removal of the dropdown arrow
which likly handled the padding the right side of this item before.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1615>
2021-02-04 20:08:29 +00:00
Razze
ed628b90d7 accessibility/keyboard: Align the panelMenu button style
This get's rid of the single-indicator introduced in one of the latest
commits. This was causing the accessibility pill in the top panel
 to have different padding from the keyboard layout pill.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1615>
2021-02-04 20:08:29 +00:00
Florian Müllner
7aa36ad239 windowManager: Allow switching workspaces with super-scroll
So far, we couldn't allow workspace scrolling outside the overview
because scroll events were always sent to clients. However mutter
was changed recently to pass on scroll events when the mouse button
modifier (usually super) is pressed, which allows us to enable the
same workspace scrolling as in the overview now.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1612>
2021-02-04 20:04:15 +00:00
Florian Müllner
ac8246050d swipeTracker: Optionally require modifiers for scrolling
The design now calls for super-scroll for workspace switching
in the session, however it is currently only possible for
SwipeTracker to either handle scroll events or not.

In order to support the new use case, add a new :scroll-modifiers
property that allows specifying modifiers for which scroll events
are handled.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1612>
2021-02-04 20:04:15 +00:00
Florian Müllner
26a39bdf78 workspacesView: Move workspace scroll code to windowManager
This will allow sharing the code for the new super-scroll functionality.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1612>
2021-02-04 20:04:15 +00:00
Jonas Ådahl
463000d04d Change all g_memdup() to g_memdup2()
Using g_memdup() is dangerous due to the type of the size argument. See
https://gitlab.gnome.org/GNOME/glib/-/issues/2319 and
https://gitlab.gnome.org/GNOME/glib/-/merge_requests/1926 for details.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1637>
2021-02-04 20:17:04 +01:00
Sebastian Keller
96d66def8c dnd: Update actor position after scaling even when animations are off
The code to update the actor position based on the cursor and current
scale was run in a 'new-frame' handler. This is working fine when
animations are enabled, but when they are turned off this does not work.
This is because the 'new-frame' signal is emitted before the changes for
that frame are applied. So with animations off the position was only
ever updated with the starting values. As a result the shrunk actor was
not being dragged by the position where it was clicked, but by where it
was clicked in the original size, which is likely not even on the shrunk
actor.

This change now also updates the position in the onComplete handler
which gets run with the final scale, even if the duration is 0.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/1699

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1627>
2021-02-04 16:39:55 +00:00
Jakub Steiner
30b6816a86 theme: Adjust dash icon spacing
- slight separation between favorites and the app-well icon

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3640

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1634>
2021-02-04 17:16:50 +01:00
Georges Basile Stavracas Neto
1adcbaab46 workspacesView: Derive workspace state from fit mode
Derive the workspace state WorkspacesView's workspaces from the fit mode.
Extra workspaces still run the zoom animations as before.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1613>
2021-02-03 20:30:30 +00:00
Georges Basile Stavracas Neto
176ea3b1ef workspace: Split preparation steps from zoomFromOverview
Next commit will bind the workspace state adjustment to the snap
adjustment in WorkspacesView, and we'll need the preparation
steps but not the easing of the state adjustment.

Split preparation steps from zoomFromOverview() into a new method
prepareToLeaveOverview().

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1613>
2021-02-03 20:30:30 +00:00
Georges Basile Stavracas Neto
4cf5b4a6d8 workspacesView: Scale inactive workspaces
As per the latest mockups, then horizontally snapping, the active
workspace should be highlighted. Because WorkspacesView clips to
allocation, we cannot simply scale up the active one. Instead,
scale down the inactive ones.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1613>
2021-02-03 20:30:30 +00:00
Georges Basile Stavracas Neto
b64103efca workspacesView/workspacesDisplay: Don't sync geometry when animating
Synchronizing the actual geometry while animating from / to the overview can
break the animation. Let's prevent that. This code will go away soon anyway,
but to not lose bisectability, it's better not to leave it misbehaving until
then.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1613>
2021-02-03 20:30:30 +00:00
Georges Basile Stavracas Neto
ed1170906b workspacesView: Center active workspace in allocation
When vertically snapping, WorkspacesView currently allocates workspaces
side-by-side, then applies an extra step of translation to center to
the active workspace. This extra step, however, gets in our way because
now we need tighter control of the workspaces positions in allocation,
in order to properly interpolate them.

Move the translation of workspaces to the allocation code itself, and
remove the extra translation step.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1613>
2021-02-03 20:30:30 +00:00
Georges Basile Stavracas Neto
1359b272a4 viewSelector: Tie workspace fit mode to adjustment
Tie the fit mode adjustment of WorkspacesDisplay to the
state adjustment of AppPagesContainer, and transition to
the ALL fit mode when the app grid is visible.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1613>
2021-02-03 20:30:30 +00:00
Georges Basile Stavracas Neto
26c5434222 workspacesView: Use side-by-side layout
Currently, WorkspacesView positions each workspace on a
per-page layout, each page with the allocated width and
height of WorkspaceView. This layout doesn't work well
with horizontal workspaces.

Layout workspaces side by side, instead of per page. The
layout is influenced by a "fit mode", which reflects the
different behaviors exposed in the mockup. This fit mode
represents whether a single or all workspaces will fit
available geometry.

The single fit mode is always used for now. Next commits
will make it switch to the all fit mode when in the app
grid state.

The translation_{x,y} also needed to reflect the switch to
a side-by-side layout, and use the geometry of the workspaces
to determine the offset. Notice that, when the fit mode is ALL,
there's no translation applied.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1613>
2021-02-03 20:30:30 +00:00
Florian Müllner
3abfc25858 workspacesView: Always use ZOOM transition
Workspaces are now always shown, so the code path to fade windows
instead of zooming out is dead now; remove it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1613>
2021-02-03 20:30:30 +00:00
Florian Müllner
252f2f5144 cleanup: Define GObject accessors in camelCase
gjs is smart enough to match a propertyName getter/setter to the
corresponding property-name GObject property, so use that and get
rid of the eslint camelcase rule exceptions.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1611>
2021-02-03 20:19:29 +01:00
Florian Müllner
0f1b566918 js: Use gjs-defined GObject accessors where possible
Nowadays gjs allows to omit get/set accessors for read-write properties,
and will define reasonable defaults in that case. In many cases we don't
need anything more than the default handling, let gjs handle those props.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1611>
2021-02-03 20:19:29 +01:00
Florian Müllner
a41e294e21 workspaceThumbnails: Remove obsolete property
Since commit f55ff01239, the property has been replaced by
an adjustment.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1611>
2021-02-03 20:19:29 +01:00
Florian Müllner
0064412359 appDisplay: Remove obsolete property
Since commit f09fbb19c, all app grids use pagination and the old
property is meaningless.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1611>
2021-02-03 20:19:29 +01:00
Florian Müllner
3ff71ac40e iconGrid: Use correct default values in pspecs
The defaults are set in the code right now, but this is about to change.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1611>
2021-02-03 20:19:29 +01:00
Florian Müllner
a9cbbd8017 pageIndicators: Remove animated indicators
Nothing uses them anymore, so clean out the code.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1629>
2021-02-03 09:55:29 +01:00
Georges Basile Stavracas Neto
5c7436be3e appDisplay: Never use animated indicators
The app grid itself now is horizontal, and is displayed beneath
workspaces, above the dash. This makes the indicator animations
out of place, as they're not coming from the edge anymore.

Use PageIndicators for both FolderView and AppDisplay.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1629>
2021-02-03 09:55:14 +01:00
Sebastian Keller
454394a267 workspace: Handle window-added and removed signal after window tracker
The new window preview overlay requires getting the app icon for a
window from the window tracker when it gets initialized. The window
tracker listens for the same 'window-added' signal on the MetaWorkspace
that the gnome-shell Workspace listens for to add the window preview.

The window tracker however reconnects all its signal handlers whenever
the number of workspaces changes, which means that its signal handlers
get called after the ones in Workspace ones. So by the time the
'window-added' handler in Workspace is called, the window tracker does
not have an app associated with the window.

To fix this ensure that all window related signal handlers in Workspace
are run after the ones in the window tracker.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3656

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1625>
2021-02-02 23:11:06 +01:00
Alexander Mikhaylenko
9ce666ac13 workspaceAnimation: Move background to WorkspaceGroup
Make each wallpaper have a wallpaper and clip it. Add a separate background
to MonitorGroup and add spacing between each workspace

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3635,
      https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/945,
      https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/948

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Alexander Mikhaylenko
ae4dab761e workspaceAnimation: Disable unredirection during the gesture
Make sure fullscreen apps can't block the animation.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Alexander Mikhaylenko
bca654851c workspaceAnimation: Support multiple screens
Currently, there's one animation for the whole canvas. While it looks fine
with just one screen, it causes windows to move between screens when
switching workspaces. Instead, have a separate animation on each screen,
and sync their progress so that at any given time the progress "fraction"
is the same between all screens. Clip all animations to their screens so
that the windows don't leak to other screens.

If a window is placed between every screen, can end up in multiple
animations, in that case each part is still animated separately.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/1213

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Alexander Mikhaylenko
8eba759932 workspaceAnimation: Group sticky windows and moving window
Since the transitions consists of window clones now, all the clones appear
above sticky windows. Clone sticky windows as well, and treat them same as
moving window instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Alexander Mikhaylenko
ee5564015a workspaceAnimation: Use a workspace strip
Currently, the workspace swipe transition only has one workspace in each
direction. This works until you try to do multiple swipes in quick
succession. The second swipe would continue the existing transition, which
only has 2 or 3 workspaces in it, and will hit a wall.

To prevent this, take all workspaces and arrange them into a column or row,
depending on the layout, and use that as a transition.

For the transition that happens when focusing a window on another workspace
(for example, via Alt+Tab), still use only two workspaces instead of all of
them.

Since we don't support layouts other than single rows/columns anymore,
diagonal transitions aren't supported anymore, and will be shown as
horizontal or vertical instead.

Since nw alt-tab and gesture transitions are different, don't allow to do
both at once, that is, disable swipe tracker when a programmatic transition
is going. This will also conveniently cancel a gesture transition if a
programmatic one is initiated while a gesture is in progress.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2612

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Alexander Mikhaylenko
9cf300c972 workspaceAnimation: Use window clones
Instead of reparenting windows, clone them. This will allow to properly
support multi-monitor setups in subsequent commits.

Block window mapping animation while the animation is running to prevent
new windows appearing during the animation from being visible at the same
time as their clones.

Fixes https://gitlab.gnome.org/GNOME/mutter/issues/929

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Alexander Mikhaylenko
0f99d46f87 workspaceAnimation: Add a background
In future we will need to use window clones to better support multiple
monitors. To avoid having to hide every window, show wallpapers behind
the workspace transition: one per monitor.

Put the wallpaper into a separate class right away, later it will be
useful to make the animation per-monitor.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Alexander Mikhaylenko
2f78d32921 workspaceAnimation: Add to uiGroup insead of window_group
This will allow to hide window group completely in the following commits.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Alexander Mikhaylenko
e32ec73315 workspaceAnimation: Extract WorkspaceGroup
Simplify the code a bit. The workspace group is relatively self-contained,
so split it from the general animation. Reimplement _syncStacking().

This will help a lot later, with workspace strip and multi-monitor support.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Alexander Mikhaylenko
269c5ca957 workspaceAnimation: Stop depending on shellwm
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Alexander Mikhaylenko
bebd612a8f workspaceAnimation: Split from WindowManager
It's already too complex, and will get more complex in future, split it
out. Update the code style.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1326>
2021-02-02 19:35:07 +00:00
Florian Müllner
42c2bf709e windowPreview: Overhaul chrome style
- increase close button size
 - use custom close icon that's better suited
   for the non-default 24pxp size
 - use translucent light gray for both close button
   and window caption

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/81

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1605>
2021-02-02 10:06:23 +01:00
Florian Müllner
30f27412c2 windowPreviews: Replace border with scale effect
We currently use a thick border to indicate the hovered/focused preview. It
works well for that purpose, but is a bit in the face. Slightly scaling up
the preview still provides a clear indication, but in a more subtle and
elegant way.

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/81

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1605>
2021-02-01 21:06:13 +01:00
Florian Müllner
27a427421e workspace: Add some padding around window previews
Commit 059ea64 removed the workspace padding after moving the
background into the workspace. However some whitespace around
window previews is still a good idea, and will be necessary
soon as we are about to indicate focus by slightly scaling up
the active preview, and don't want previews to be clipped by
the workspace in that case.

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/81

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1605>
2021-02-01 21:06:13 +01:00
Florian Müllner
2bd91e738e workspace: Adjust spacing
Icons are always visible, so in order to not have overlays overlap
with other previews, we need to consider the sum of top- and border
oversizes rather than the maximum.

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/81

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1605>
2021-02-01 21:06:13 +01:00
Florian Müllner
56c118de87 windowPreview: Keep borderCenter always visible
We need it to position the icon now, which isn't hidden with the
border.

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/81

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1605>
2021-02-01 21:06:13 +01:00
Florian Müllner
efa3585bcc windowPreview: Add (back) application icons
The overview is less visually-busy nowadays, so add back application
icons to make identifying window previews easier.

Fun fact: Removing the icons was part of my very first gnome-shell
contribution!

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/81

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1605>
2021-02-01 21:06:13 +01:00
Florian Müllner
5e10bed458 windowPreview: Allow titles to overlap other previews
We are about to add additional chrome, but still want to use
as much space as possible for the previews. Allowing titles
to overlap other previews should help keeping the additional
whitespace requirement low.

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/81

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1605>
2021-02-01 21:06:13 +01:00
Florian Müllner
bc6849c7a2 windowPreview: Track overlay state separately
We currently express the state as a combination of border visibility
and the eventual transition state. That's tedious, in particular if
we want to use the state outside the show()/hide() methods.

Just track the requested visibility in a separate property.

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/81

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1605>
2021-02-01 21:06:13 +01:00
Florian Müllner
de299f0a90 workspaceThumbnails: Center thumbnails in workspace navigator
We always request a natural width based on the maximum thumbnail scale,
but may very well use a smaller scale when allocating. This currently
results in thumbnails being off center, fix this by distributing any
extra space evenly before allocating thumbnails.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1620>
2021-02-01 16:34:37 +01:00
Guilherme Silva
779e66ae88 notificationDaemon: Fix icon-choosing logic
'image-data' (or 'image-path') should take precedence over 'app-icon',
even when both are sent by the application (e.g. Google Chrome).

Fixes #3616.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1616>
2021-02-01 13:58:20 +00:00
Jonas Dreßler
6ae49092c1 workspace: Use Util.lerp() instead of own _interpolate()
Use the utility function we newly introduced instead of having our own
private _interpolate() in workspace.js.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1617>
2021-02-01 13:12:43 +00:00
Jonas Dreßler
959639bdc9 windowPreview: Cache the boundingBox of the layout manager
Accessing GObject properties from JS has proven to be quite slow because
of the JS->C->JS roundtrip involved. With the WindowPreview this
actually has an impact since we're accessing those properties very often
while creating new layouts.

So cache the boundingBox and the windowCenter properties of the
WindowPreview using a this._cachedBoundingBox JS object. This might
speed up opening the overview with lots of open windows significantly.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1617>
2021-02-01 13:12:43 +00:00
Jonas Dreßler
a4bf44734d workspace: Don't store strategy on layout object
We're making the layout object fully owned by the layout strategy, so
store the current strategy somewhere else, that is as a private property
of the class.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1617>
2021-02-01 13:12:43 +00:00
Jonas Dreßler
39e844ac0c workspace: Refactor layout scale and space calculation
Make computeScaleAndSpace() return an array including scale and space so
we no longer have to access the layout object from outside.

With this we also no longer need to set layout.space, since only the
scale property is needed in computeWindowSlots().

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1617>
2021-02-01 13:12:43 +00:00
Jonas Dreßler
8d9a92fe98 workspace: Make computeLayout() return a layout object
Start cleaning up the whole mess around the layout object a bit and
return a new object in the LayoutStrategies computeLayout()
implementation. This object is supposed to be opaque to the API user and
will only be passed to the layout strategy.

For now, keep setting a few things on that object from outside, we'll
clean that up later.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1617>
2021-02-01 13:12:43 +00:00
Jonas Dreßler
ac7dc62da6 workspace: Move more things to LayoutStrategy subclass
Only keep computeLayout, computeWindowSlots, computeScaleAndSpace and
the contructor in the superclass, the rest is actually layout specific
and won't apply anymore when we introduce the new vertical layout
strategy.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1617>
2021-02-01 13:12:43 +00:00
Jonas Dreßler
c635ff490a workspace: Pass params object to LayoutStrategy
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1617>
2021-02-01 13:12:43 +00:00
Florian Müllner
ec0d8e3a72 extensions-tool: Remove menu arrow from extension template
We stopped putting arrows into the top bar, so we shouldn't encourage
new extensions to still do that.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1618>
2021-02-01 11:40:03 +00:00
Florian Müllner
add6dfe2e4 status/dwellClick: Remove menu arrow
This was missed in commit db9a008.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1618>
2021-02-01 11:40:03 +00:00
A S Alam
ba2f198b86 Update Punjabi translation 2021-01-31 17:40:16 +00:00
Rafael Fontenelle
1a96fba415 Update Brazilian Portuguese translation 2021-01-30 15:03:41 +00:00
Abderrahim Kitouni
698e67c486 workspacesView: Fix scroll direction in RTL locales
Scrolling up or down (using the mouse wheel) should scroll to right
or left respectively (rather than the other way around).

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1608>
2021-01-30 11:45:22 +00:00
Florian Müllner
151a104f9a dash: Only show separator when there are running apps
The separator is only really needed to distinguish favorite apps
from running apps, the show-apps button is distinct enough already.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1610>
2021-01-30 09:44:11 +00:00
Jakub Steiner
1f3a364ffa theme: Desaturate system color
- avoid the color tint for the system grey background

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1599>
2021-01-29 21:56:05 +00:00
Georges Basile Stavracas Neto
059ea648f8 style: Remove workspace padding
It makes the background jump when animating from the session.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1599>
2021-01-29 21:56:05 +00:00
Florian Müllner
9062d5dc78 workspace: Clip background
So that windows don't overflow the workspace background.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1599>
2021-01-29 21:56:05 +00:00
Georges Basile Stavracas Neto
8eb81ae649 overview: Move background to Workspace
Move the background to the Workspace class by introducing a new container
called WorkspaceBackground, which handles clipping the background to the
workarea.

Move the click action from WorkspaceDisplay into each workspace.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1599>
2021-01-29 21:56:05 +00:00
Georges Basile Stavracas Neto
cfc1f1fd9c background: Add option to not use background content size
Will be used by next commit to draw workspaces at a different size of the
background itself.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1599>
2021-01-29 21:56:05 +00:00
Georges Basile Stavracas Neto
862b5be7a2 background: Trivial style cleanup
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1599>
2021-01-29 21:56:05 +00:00
Florian Müllner
b84eb2437d workspaceThumbnails: Expand workspaces before scale-in animation
When the original animation was implemented, workspaces would only
ever be added at the end. We therefore got away with not having a
separate EXPANDING stage corresponding to the existing COLLAPSING
one when animating out.

Since support for creating in-between workspaces via DND was added,
this is no longer the case. And now that the thumbnails are centered,
the jump is quite noticeable.

Address this by adding new transitional states, so that we can
expand new thumbnails before scaling them in.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1609>
2021-01-29 17:55:44 +01:00
Florian Müllner
ac3faac38c overviewControls: Remove intermediate box
Now that the workspace switcher moved into the view selector, the
box only holds a single child. Cut out the middle man and add that
directly to the parent.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1609>
2021-01-29 17:49:52 +01:00
Georges Basile Stavracas Neto
6e13dbac11 theme: Adjust workspaces thumbnails visuals
Remove the borders, and make each thumbnail have a background color
that matches other elements like the Dash.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
9db9445b0f workspaceThumbnail: Scale workspaces in and out
Make the slide property control the workspace scale, so that new workspaces
scale up, and destroyed workspaces scale down. The scale is done horizontally,
and only slightly vertically, as per design direction.

Rework the state tracking mechanism to remove the COLLAPSING state, since there's
no split between sliding out and collapsing anymore. Also remove the corresponding
'collapse-fraction' property from WorkspaceThumbnail.

Make ThumbnailsBox.vfunc_get_preferred_width() consider the slide-position property.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
df2181c913 workspaceThumbnail: Use current number of workspaces for sizes
There are situations where MetaWorkspaceManager and ThumbnailsBox disagree
on the number of workspaces, for example when animating them out. It's more
important to follow the visible number of workspaces while they're updated.

Make vfunc_get_preferred_width() and vfunc_get_preferred_height() use the
current number of workspace thumbnails to calculate their sizes, instead of
MetaWorkspaceManager's n-thumbnails property.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
d368bae503 workspaceThumbnail/thumbnailsBox: Set pivot point
Set the pivot point at the center of the ThumbnailsBox so that scaling
in and out looks better.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
451ba5b03a workspaceThumbnail: Remove wallpaper
They'll be replaced by a stylized background color to make them look
symbolic.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
0d4bce9fa7 workspaceThumbnail: Reduce maximum scale to 5%
As per design direction, reduce the maximum workspaces thumbnails to 5% of the
primary monitor size.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
9980c80619 workspaceThumbnail: Allocate final thumbnail sizes
ThumbnailsBox currently allocates each workspace thumbnail using their
porthole size, and scales them down using scale-x and scale-y. This is
slightly problematic since it doesn't allow for properly styling these
thumbnails through CSS.

Rework ThumbnailsBox to allocate workspace thumbnails at their actual
sizes, and scale down the '_contents' actor inside WorkspaceThumbnail.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
3ad7b85e25 workspaceThumbnail: Make it horizontal
Allocate workspace thumbnails horizontally. This requires introducing code
to handle the RTL direction. Do a small rewrite of the DnD hover method to
be simultaneously simpler and easier to follow, and work correctly on RTL.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
99d1529e8c overviewControls: Simplify DashFader
Merge FaderControl and DashFader, since it's the only subclass, and
remove all overview connections that aren't useful for it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
f17d9676f8 overviewControls: Move workspaces thumbnails to ViewSelector
This is now all centralized in the apps page, so move the workspaces
thumbnails to ViewSelector's apps page. This allows us to remove
all the slider controls too, since they're now unused.

The transition between showing the workspaces, and the app grid, is
based on the most recent mockups: scale and move it down, and fade it
out.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
456b446394 viewSelector: Rework Ctrl+Alt+Tab support
Now that there's only a ACTIVITIES and a SEARCH page, the old method of handling
keyboard tabbing (extra parameters to ViewSelector._addPage()) limits what we can
do.

Manually set up the Ctrl+Alt+Tab support for each element.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
de15eb3bbc viewSelector: Merge WINDOWS and APPS pages
Add them both in a StBoxLayout subclass with a vertical layout. This
new ActivitiesContainer class already contains an adjustment controlling
the transition between workspaces and app grid states, and althought it
is internal to it, it'll be easy to integrate with gestures in the
future.

Notice that AppDisplay is added before WorkspacesDisplay. That's because
we want the paint order to paint WorkspacesDisplay on top of AppDisplay.

Switch the ViewsPage enum to call this page ACTIVITIES, and adjust the
only caller in OverviewControls to it. At last, rename '_appsPage' to
'_activitiesPage' to also reflect the name change.

The usefulness of organizing this code in pages is lost here, but this
is a transitional state, and pages will be removed in future changes.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
07c970d90c util: Add lerp function
We're going to lerp a lot in the future, to it's worthy sharing
this simple but effective interpolation function.

Add Util.lerp().

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
a29e002a41 workspacesView: Add API to hide workspaces without destroying
This will be used by the next commit to hide workspaces when ViewSelector
switches to the search page, without destroying the workspaces so their
state is preserved.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
78f886f42c windowManager: Switch to horizontal workspaces
Do so by removing the workspace override.

Requires https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1684

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Georges Basile Stavracas Neto
0d4eaa6f19 theme: Make Dash background color solid
This is the same color that the Dash currently has, except
it isn't transparent.

The reason for this change is that the app grid coming from
the bottom and passing below the Dash looks odd with the
transparency there.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1593>
2021-01-29 15:01:03 +00:00
Florian Müllner
55d85cd55b dash: Add separator between favorite and running apps
Only the area used by favorite apps can be used as drop targets, it
is not possible to add new favorites between the running apps at the
end. While that behavior makes sense, it is currently impossible to
distinguish the two areas with confusing results.

Address this by adding a visual separator between favorites and
running apps.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1606>
2021-01-29 00:30:20 +00:00
Florian Müllner
fec745ffb8 screenshot: Clean up when creating stream failed
Otherwise the tracked screenshot operation will block all future
requests from the same sender.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3618

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1589>
2021-01-28 21:47:50 +00:00
Florian Müllner
0efa82acf0 screenshot: Return error if stream creation failed
When we fail for some reason to open a stream to write the screenshot
to, we currently return `false` to the sender. That's not wrong, but
doesn't provide any hints on what caused the failure, so return the
underlying error instead.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3618

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1589>
2021-01-28 21:47:50 +00:00
Florian Müllner
1aee0516d6 screenshot: Use separate error when disk writes are locked down
The most likely reason for rejecting a screenshot request is that
there's an ongoing operation from the same sender. Still, we shouldn't
assume that that is the case and return an appropriate error when
writing to disk is disabled via lockdown settings.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3618

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1589>
2021-01-28 21:47:50 +00:00
Razze
c853de20eb loginDialog: Keep hint string from pushing the login box higher
When we display the hint string for e.g. (or swipe finger), the login
box gets pushed up. This is leftover from older styling and should be
removed. The padding-top is unnecessary and can also be removed, so just
remove the whole line styling login-dialog-message-hint from the
stylesheet.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1582>
2021-01-28 20:26:38 +00:00
Georges Basile Stavracas Neto
08ac3c7750 workspacesView/workspacesDisplay: Handle smooth events
On X11, the scroll handler can receive smooth events, which should
trigger a workspace switch. Handle smooth events by checking their
scroll delta, and adjusting the direction depending on these deltas.

Fixes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1614
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1603>
2021-01-28 15:11:56 +00:00
Georges Basile Stavracas Neto
cffad8b749 workspacesView/workspacesDisplay: Scroll on horizontal layouts
WokspacesDisplay simply remaps the scroll direction into the next
workspace, but that doesn't account for the new horizontal layout.

Scroll horizontally on horizontal layouts when scroll direction is
on the vertical axis.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1603>
2021-01-28 15:11:56 +00:00
Sebastian Keller
0882074ecc screenshot: Still remove select/pick actor if grab promise was rejected
If the grab promise is rejected due to for example on X another app
already having the grab, an error is thrown and the code that would
revert the cursor and hide the actor is not run. This actor then
prevents all mouse interactions with the shell and the windows beneath
it.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2869

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1600>
2021-01-28 02:49:13 +00:00
Florian Müllner
9f0e7632a6 workspacesView: Fix off-by-one error
The scroll adjustment's upper value corresponds to the number of
workspaces, not to the last workspace index. We want the latter
when mirroring the layout in RTL locales, so subtract 1.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1598>
2021-01-26 22:07:15 +01:00
Robert Mader
7462347905 ci: Fix typo
This made us fall back to a normal debug build, not catching certain
warnings.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1597>
2021-01-26 20:40:30 +00:00
Robert Mader
e8f46f169c blur-effect: Silence compiler warning
Building with `debugoptimized` throws:
`'paint_opacity' may be used uninitialized in this function`

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1596>
2021-01-26 21:29:57 +01:00
Florian Müllner
ddc2e0f4cb extensionSystem: Fix opening Extensions app from notification
Launching the app is implemented by the source's open() method, but
only external notifications are hooked up to call into the source
when no default action was provided.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1595>
2021-01-26 17:12:04 +01:00
Doan Nam Long Vu
db9a008e8a panel: Remove drop down arrows from standalone indicators
The keyboard/language selector area is the smallest element
on the panel. Additional margin about 6px inside the a11y
and language items to make them comfortable to click targets.

With that, we can remove the remaining arrows.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3567

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1583>
2021-01-26 16:53:42 +01:00
Doan Nam Long Vu
022cd683c4 panel: Remove drop down arrows from AppMenu and AggregateMenu
Following #3567, the design team decided to remove the drop down arrows
from both AppMenu and AggregateMenu.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3567

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1583>
2021-01-26 16:53:42 +01:00
Florian Müllner
55439713f4 appDisplay: Handle dropped app favorites
Now that apps either appear in the dash or the app grid, it makes
sense to allow DND between the two components to add and remove
favorites.

Currently this only works for adding items to the dash, update the
app grid code to also accept drops from the dash.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1594>
2021-01-26 11:36:34 +01:00
Florian Müllner
9f1eb6da2b dash: Replace custom actor with layout manager
We use a custom actor to make sure that the show-apps button remains
visible even when there's not enough space to show all icons.

We can achieve the same result with much less code, by using a custom
BoxLayout layout manager for the icons to override the minimum width.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1592>
2021-01-25 22:53:34 +00:00
Florian Müllner
2e9a2e68b7 dbusServices/screencast: Use GTK4
The separate screencast service has some minimal GTK usage, which
we can trivially move to GTK4.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1591>
2021-01-25 21:09:22 +01:00
Georges Basile Stavracas Neto
62baf524af appDisplay/appFolderDialog: Don't constrain to workarea
With the transparent top bar in the overview, constraining to the
primary monitor's workarea causes the (now visible) area beneath
the top bar to not have the darker background, which causes a visual
discontinuity in the layout.

Don't constrain to the primary monitor workarea.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1590>
2021-01-25 13:10:37 -03:00
Daniel van Vugt
bbb2f2603a shell/util: Don't compile in unused code when !HAVE_SYSTEMD
Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3620
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1588>
2021-01-25 17:09:21 +08:00
Georges Basile Stavracas Neto
eb4f6740c3 workspacesView: Center workspaces of primary display
Currently workspaces are left-aligned to the allocation, which looks
odd after moving the Dash to the bottom.

Allocate workspaces centered both horizontally and vertically.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1587>
2021-01-24 10:52:24 -03:00
Razze
bc2cb9d910 appDisplay: Animate opening app icons menu
Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2335

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1585>
2021-01-23 20:44:11 +01:00
Danial Behzadi
1eec8eebdc Update Persian translation 2021-01-22 14:36:51 +00:00
Sebastian Keller
18cd24e6f4 appDisplay: Fix app folder icon subicon spacing
The code previously was using CSS to define row/column spacing and
padding which was combined with a subicon size computed in code relative
to the requested icon size.

In smaller icon sizes it was possible for the CSS spacing+padding + the
size of the two subicons to exceed the requested icon size. This then
would lead to the label being pushed down for app folders compared to
other icons.

Another more severe issue caused by this would happen if the first item
in an icon grid was an app folder. Then the calculation for the maximum
allowed icon size could be off, leading to all icons in the grid
becoming smaller than actually necessary.

This commit changes this to use homogeneous row and column layouts to
evenly distribute the remaining spacing instead of using a fixed CSS
value.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3069

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1581>
2021-01-21 21:05:30 +00:00
Florian Müllner
8c792969bb appDisplay: Do not duplicate app favorites
With the new position, the dash is now stronger connected to the
app grid than it used to; reflect that by showing apps either
in the grid or the dash, not both (except for non-favorite
running apps).

https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/88

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1580>
2021-01-21 17:17:47 +00:00
Sebastian Keller
c57a299d57 workspacesView: Disable swipe tracker when animating from overview
It was possible to switch workspaces by quickly dragging the workspace
immediately after clicking on a window during the transition from the
overview. This is unlikely something that is intentionally used but can
be confusing and look bad when triggered accidentally.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2993

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1578>
2021-01-21 02:44:13 +01:00
Florian Müllner
a5730d7b30 overviewControls: Make sure dash is positioned at the bottom
We don't want the dash to expand, but if it's given more space
than requested, we want it to be positioned at the bottom.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1577>
2021-01-20 11:34:43 +00:00
Sebastian Keller
353483b052 automountManager: Remove unused volume queue
This is some leftover from code that was used to keep track of volumes
added/removed while the screen was locked before the move to a
components system in 2a800e4c. All that the remaining code does is
filter devices from an empty list.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1579>
2021-01-19 20:55:11 +00:00
Balázs Úr
de4ac8841e Update Hungarian translation 2021-01-19 20:40:42 +00:00
Florian Müllner
b3c13d6128 overviewControls: Simplify dash placement
Now that the dash is always visible, it doesn't make sense to keep
it in a separate layer from the main overview group and use a
separate spacer actor as a placeholder.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1575>
2021-01-19 15:06:58 +01:00
Jakub Steiner
827c137391 theme: Theme dash closer to mockup
- use a light, nostroke dash
- boost border radius globally

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1559>
2021-01-19 13:47:06 +00:00
Georges Basile Stavracas Neto
1e2532cf25 dash/dashIcon: Popup menu above the icon
Now that the Dash is horizontal, the popup menu of the Dash icons must
show up, instead of left/right.

Make AppIcon.popupMenu() receive an optional parameter with the side
to show the menu, using St.Side.LEFT as default. Override this method
in DashIcon to always pass St.Side.TOP.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1559>
2021-01-19 13:47:06 +00:00
Abderrahim Kitouni
0a23721364 dash: Fix 'All apps' button position in RTL locales
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1559>
2021-01-19 13:47:06 +00:00
Georges Basile Stavracas Neto
97eb4560ef Make Dash horizontal
And move it to the bottom of the overview. Change the height-based calculation
of the icon sizes to be width-based. Put the DashFader in a vertical box, and
make all corners of the Dash equally rounded.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1559>
2021-01-19 13:47:06 +00:00
Georges Basile Stavracas Neto
bd850c3110 overviewControls: Split FaderControl from SlidingControl
The Dash will need only the fading aspect of SlidingControl in the
next commit.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1559>
2021-01-19 13:47:06 +00:00
Georges Basile Stavracas Neto
ea02aa399d overviewControls: Show DashSpacer in apps page as well
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1559>
2021-01-19 13:47:06 +00:00
Florian Müllner
5070e6405c Post-release version bump (again) 2021-01-18 17:46:04 +01:00
Florian Müllner
40ac6143a4 Tag release 40.alpha.1.1
Like the mutter 40.alpha.1.1 release, we missed adjusting to a
GSettings schema move from g-s-d to gsettings-desktop-schemas,
resulting in an abort on startup with the latest released
gnome-settings-daemon.
2021-01-18 17:41:04 +01:00
Florian Müllner
a32df6b7a3 extensionsService: Fix setting prefs dialog parent
Between the GTK4 port and the latest GTK4 version, calling realize()
on a newly created window to force its surface to be created stopped
working.

So instead, wait for the window to get realized regularly to set its
parent.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1574>
2021-01-18 11:40:46 +00:00
Fabio Tomat
1a9478c740 Update Friulian translation 2021-01-17 13:39:09 +00:00
Marek Černocký
6c3547d3c2 Updated Czech translation 2021-01-16 10:48:22 +01:00
Florian Müllner
4ff91aa1ce st/settings: Adjust to moved GSettings schema
Mouse settings moved from gnome-settings-daemon to
gsettings-desktop-schemas, and we missed adjusting
the shell side.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1573>
2021-01-15 16:55:05 +00:00
Marek Černocký
4686c25a5c Updated Czech translation 2021-01-15 12:48:50 +01:00
Марко Костић
fc7c08d931 Update Serbian translation 2021-01-15 01:21:52 +00:00
Georges Basile Stavracas Neto
c5e5514c51 weather: Pass providers after application-id and contact-info
It now requires both application-id and contact-info to properly
set the enabled providers.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1571>
2021-01-14 16:47:52 -03:00
Florian Müllner
40b65f21f3 Post-release version bump 2021-01-14 18:34:05 +01:00
Florian Müllner
605d2b56a3 Tag version 40.alpha.1
Update NEWS.
2021-01-14 18:29:01 +01:00
Florian Müllner
5d65a424a8 st/scroll-view-fade: Don't assume fade area at (0,0)
The shader code currently only accounts for padding for the
bottom and right fades, but not for top and left.

As a result, we only fade the right edge when swiping through app
picker pages, whoops.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1569>
2021-01-14 17:28:01 +01:00
Florian Müllner
ecf5e3d3ee ci: Bump mutter image
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1570>
2021-01-14 17:16:52 +01:00
Florian Müllner
edd34c50d9 Port extensions app and portal to GTK4
With the previous preparations in place, it is time to take the plunge.

As both the app and the portal use the same small library for handling
external windows, port everything at once to avoid the hassle of building
and installing two versions of the library.

With the portal using GTK4 now, all extensions must port their preference
widgets as well.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
ba039bcce5 dbusServices/extensions: Remove event box
In GTK4, all widgets are reactive, and therefore GtkEventBox has
been removed. In order to make the upcoming GTK4 port a bit cleaner,
remove the expander's event box now.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
99a796e426 dbusServices/extensions: Stop stacking frames
We currently use separate frames for the details expander and the
expanded details. That layout works as long as frames are boxy (as
in the default GTK3 style), but breaks down with rounded corners
(as in the default GTK4 style).

In order to work with either style, adapt the layout to use a single
surrounding frame and appropriate borders as separator.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
9bb91ca875 dbusServices/extensions: Stop using GtkToolbar
Toolbars have been removed from GTK4, so just use a regular GtkBox
for the error details bottom bar.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
1016b919f0 dbusServices/extensions: Stop using GtkContainer API
The interface has been removed in GTK4, so use widget-specific API
for adding children where possible.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
a450550e5f dbusServices/extensions: Stop using :margin shortcut
The property has been removed in GTK4, so prepare for a port by
setting the four individual margin properties instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
2189dc61fb dbusServices/extensions: Use consistent style for property names
GtkBuilder understands both dashes and underscores in property names,
and we currently use a mix of both. The actual properties use dashes,
so settle on that.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
9d14b0c682 dbusServices/extensions: Set title on window instead of headerbar
GTK4 will remove the GtkHeaderBar:title property, so stop using it
and set the window's title property instead, as that's what headbars
use in both GTK3 and GTK4 unless explicitly overridden.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
618762ebe0 dbusServices/extensions: Minor cleanup
There's little point in setting properties to their default value,
so stop doing that.

(GtkFrame:shadow-type actually defaults to "edged-in" rather than "in",
but all types other than "none" are treated the same nowadays)

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
1bb0e1b9fc extensions-app: Explicitly dispose window when removed
Unlike in previous GTK version (or Clutter), destroy() no longer
breaks reference cycles but just releases the reference held by
GTK itself.

So any reference we hold - either the explicit property or any signal
handlers that bind the window as `this` - prevents the window from
being disposed when closed, and the application won't quit.

Work around this by explicitly running dispose() on the window when
it is removed from the application.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
3af90918a3 extensions-app: Stop using :margin shortcut
The property has been removed in GTK4, so prepare for a port by
setting the four individual margin properties instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
ad6fbaa245 extensions-app: Don't use deprecated margin-left/right properties
Use the text-direction-aware start/end variants instead.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
8eb1792d39 extensions-app: Use consistent style for property names
GtkBuilder understands both dashes and underscores in property names,
and we currently use a mix of both. The actual properties use dashes,
so settle on that.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
20a68a609c extensions-app: Set title on window instead of headerbar
GTK4 will remove the GtkHeaderBar:title property, so stop using it
and set the window's title property instead, as that's what headbars
use in both GTK3 and GTK4 unless explicitly overridden.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
c9c7629753 extensions-app: Remove stray angle brackets
Not sure how those sneaked in. GtkBuilder apparently ignores them,
but that's no reason for keeping them.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Florian Müllner
eb0339e223 shew: Use Xlib to set transient hint
The GDK API for setting the hint has been removed in GDK4, so prepare
for a port by using the underlying Xlib API directly.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1495>
2021-01-14 13:03:21 +00:00
Razze
f87f9848c3 status/volume: Allow changing input volume by scrolling
Previously scrolling on the volume or input indicator would always
change the volume. This change lets you change the input volume if
you scroll over the input indicator.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3273

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1566>
2021-01-14 01:13:17 +01:00
Jonas Dreßler
d1468f7f6d panel: Make the panel fully transparent while in the overview
The overview is using a heavily darkened background image nowadays.
Since the contrast provided by this is always good enough, this makes it
possible to always have a fully transparent panel while showing the
overview.

So change the theme to always make the panel fully transparent while the
overview is shown. The duration of the animation for that is 250ms
because that's the duration of the show and hide animation of the
overview.

Also add special handling for the high-contrast theme, where we always
make the panel opaque.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1397>
2021-01-13 23:06:48 +00:00
Jonas Dreßler
87103374fd overview: Increase SHADE_ANIMATION_TIME a bit
The SHADE_ANIMATION_TIME variable sets the duration of the animation of
the background shading that is done when showing the overview. As
explained in the code-comment, that value must be smaller than the
animation time of the overview.

Now since we're going to start animating the background color of the
panel when showing the overview and we're going to use the overviews
animation time for that, we want to make sure the shading of the
background image and the animation of the panel are kept "in sync",
otherwise the transitions would look bad.

So slightly increase the value of SHADE_ANIMATION_TIME to 240 (the
overviews animation time is 250) to make sure those happen in the same
timeframe.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1397>
2021-01-13 23:06:48 +00:00
Jonas Dreßler
0cbccf7403 panel: Animate opacity changes of the panel corner
This is a requirement for fading the transparent panel in and out
smoothly.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1397>
2021-01-13 23:06:48 +00:00
Jonas Dreßler
c894ec95cd panel: Indicate focus using a pill-shaped background
The current way of indicating focus of elements in the panel does not
work very well with a fully-transparent panel, a line at the bottom of
the panel doesn't make too much sense if there is no real panel, but
only the text and icons.

To make the indicators look better in this case, switch to a pill-shaped
background color to indicate the focus of items in the panel.

For this to look good, there has to be a small black border above and
below the background, this also requires increasing the height of the
panel (from 1.86em to 2.2em) for visual purposes.

Also, since we now no longer need to color the lower bottom of the
panel, we can remove the custom drawing code for the border of the
panels corner, so do that.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1397>
2021-01-13 23:06:48 +00:00
Jonas Dreßler
a44686affe theme/panel: Slightly increase horizontal padding on activities button
The activities button doesn't have an icon, which makes its horizontal
padding appear a bit smaller than the padding of most other items in the
panel.

We're going to indicate hover and focus of items in the panel using a
pill-shaped background color, which means the padding of those items
will get more visible. So give the activities button a special treatment
and slightly increase its padding to make sure the new indicator will
look good.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1397>
2021-01-13 23:06:48 +00:00
Ivan Molodetskikh
d82dcd6f67 workspace: Don't unfreeze layout during overview animation
During overview closing animation the allocation expands more or less
every frame. Unfreezing the layout then leads to windows snapping to
their new position if e.g. a window was closed which doesn't look nice.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3216

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1550>
2021-01-13 21:40:22 +00:00
Matej Urbančič
8f9cc4b5c2 Update Slovenian translation 2021-01-13 21:22:35 +00:00
Mike Gerow
7222bffdf8 loginDialog: Make notListedButton accessible
Without this a screen reader just calls the notListedButton a
"push button" instead of also including the "Not listed?" text.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1567>
2021-01-13 22:10:03 +01:00
Florian Müllner
d5ca1bc62f weather: Provide application-id and contact-info
Those are now required in order to use any online providers.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3577

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1565>
2021-01-13 21:03:35 +00:00
Florian Müllner
7458d5ad07 weather: Adjust to renamed provider
https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3577

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1565>
2021-01-13 21:03:35 +00:00
Florian Müllner
42ce04b108 Revert "WeatherClient: Set enabled providers after setting a valid location"
libgweather changed to not do any implicit network traffic in property setters,
so this is again safe to pass to the constructor.

This reverts commit 73b7d9ace4.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3577

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1565>
2021-01-13 21:03:35 +00:00
Daniel Șerbănescu
52d271f5c1 Update Romanian translation 2021-01-13 16:17:43 +00:00
Kjartan Maraas
5a028cafa3 Update Norwegian Bokmål translation
(cherry picked from commit 5d2a28ee9a5ab69a0166ba34129194d3cb48d5a0)
2021-01-13 14:28:39 +00:00
Kukuh Syafaat
a1175ba5e2 Update Indonesian translation 2021-01-13 13:25:33 +00:00
Fran Dieguez
db049818d2 Update Galician translation 2021-01-12 00:12:37 +00:00
Jonas Ådahl
1685c77931 workspacesView: Update scroll position but not workspace on allocate
Not updating the scroll position on allocate caused a glitch, where a
window on a workspace that is not the first one would would be
transparent for one frame when showing the overview.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3507
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1545>
2021-01-11 17:23:26 +01:00
Florian Müllner
15aabdf287 ci: Add some more commit message rules
Mutter added some additional rules, for instance to enforce proper
capitalization style in commit messages. That's a good idea, and
now that adding rules is easy, let's adapt them to gnome-shell.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1544>
2021-01-11 14:01:44 +01:00
Florian Müllner
da09c67600 ci: Replace custom commit-log script with ci-fairy
ci-fairy now supports checking commit messages for required/disallowed
patterns. Use that to replace our custom commit-log script.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1544>
2021-01-11 14:01:44 +01:00
Jordi Mas
33f166b44e Update Catalan translation 2021-01-10 22:54:57 +01:00
Georges Basile Stavracas Neto
35d8041656 swipeTracker: Switch to 3-finger gestures
As per design feedback, it's time to switch to 3-finger gestures.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3528

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1562>
2021-01-08 14:28:39 -03:00
Georges Basile Stavracas Neto
1134afd12a swipeTracker: Use AFTER trigger edge for TouchSwipeGesture
Otherwise, we can get stray 'begin' signals from the touch gesture.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1562>
2021-01-08 14:27:02 -03:00
Florian Müllner
c5019dbf62 screenShield: Tie LockedHint to locked state
Currently the hint reflects the `active` state, which effectively
corresponds to the screen blank. That's a bit surprising considering
the name, plus the `active` state is already exposed by the ScreenSaver
D-Bus interface for anyone interested.

It seems reasonable that the `LockedHint` property reflects the lock
state, so change the handling to do exactly that.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/351

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1561>
2021-01-07 22:43:42 +01:00
Florian Müllner
543261e6eb appDisplay: Disable built-in mouse scrolling
We want to either handle a scroll event ourselves, or delegate it
to the swipe tracker. What we never want is StScrollView's default
handler that doesn't have any knowledge of pages, so disable it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1560>
2021-01-07 14:04:03 +00:00
Georges Basile Stavracas Neto
57f96b28ab workspacesView: Make sure to destroy non-existing workspaces
Even if they're in the end of the list. So far we've managed to not be affected
by this bug because until GNOME 3.38, workspaces didn't have a background, and
there was no way to navigate to these leftover workspaces, but with the proposed
overview changes for GNOME 40 it'll be very much visible.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1560>
2021-01-07 14:04:03 +00:00
Georges Basile Stavracas Neto
499af2dd81 workspacesView/workspacesDisplay: Ignore emulated events
When handling all scroll directions, it is imperative to ignore emulated
events. Otherwise we may get the wrong scroll direction, e.g. when natural
scrolling is enabled.

Ignore pointer emulated events in WorkspaceDisplay._onScroll().

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1560>
2021-01-07 14:04:03 +00:00
Daniel van Vugt
eefed95fa7 st/private: Don't scale the framebuffer, only the blur pixels
Just as we did before e59069c012.

Callers already ensure the framebuffer is scaled so by scaling a second
time in `_st_create_shadow_pipeline` we actually got resource_scale² which
was visibly incorrect.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3505,
       https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3560

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1543>
2021-01-07 15:35:55 +08:00
Ivan Molodetskikh
b51be0e389 st/texture-cache: Move icon theme lookup out of the hot path
It was showing up on profile traces over at
https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1547#note_996417
After this change it no longer does.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1558>
2021-01-05 16:50:59 +03:00
Ivan Molodetskikh
e73204b9fa st/texture-cache: Make key g_autofree
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1558>
2021-01-05 16:50:59 +03:00
Fran Dieguez
9e47fd3da5 Update Galician translation 2021-01-04 22:50:29 +00:00
Georges Basile Stavracas Neto
c48d3dc063 theme: Adjust app grid spacing
As per design feedback.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1554>
2021-01-04 15:37:45 +00:00
Georges Basile Stavracas Neto
2d0ef0ed84 theme: Reduce spacing between pagination dots
Now folder dialogs and the app grid have the same styling
for the pagination dots.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1554>
2021-01-04 15:37:45 +00:00
Georges Basile Stavracas Neto
47cd3c5b57 appDisplay: Cleanup BaseAppView
All subclasses of BaseAppView now are horizontal, thus we
don't need to deal with the vertical case anymore.

Remove the corresponding parameter from the BaseAppView
constructor, and move the StBoxLayout that both AppDisplay
and FolderView have in common into the base class.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1554>
2021-01-04 15:37:45 +00:00
Georges Basile Stavracas Neto
be279abe9e appDisplay: Make the app grid horizontal
Horizontal pagination is more natural than vertical, but for
historical reasons we ended up with a vertically paginated
app grid.

Make the app grid horizontal.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1554>
2021-01-04 15:37:45 +00:00
Sebastian Keller
b3d57dc4bd calendar-server: Remove unused functions
These have been unused since tasks support was dropped when the calendar
integration was moved out of process in e9e30138. GCC did not complain
about this, because the functions were inlined.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1557>
2020-12-30 11:01:44 +01:00
Florian Müllner
eafbfdfa07 theme: Pre-generate stylesheets as well
Since commit 9ef9a5ff8a, man pages are generated at dist time to reduce
build dependencies when building from a released tarball.

Do the same for the stylesheets to also remove the sassc dependency.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1555>
2020-12-29 00:40:47 +01:00
Florian Müllner
9ef9a5ff8a build: Pre-generate man pages at dist time
The man pages don't change very often, but draw in both docbook and
asciidoc. The latter is particularly problematic, as some distros
still ship only a python2 version of the tool.

Address this by generating the man pages at dist time, and including
the result in the tarball.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1553>
2020-12-28 02:25:24 +01:00
Florian Müllner
88ac08b542 man: Update options
The man page hasn't been updated in years, so the list of options ended
up being quite outdated. Most notably it's missing all wayland-related
options.

Remove obsolete options and add all the missing ones so that the list
is up to date again.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1553>
2020-12-28 02:25:17 +01:00
Florian Müllner
3fc5c4c180 man: Use asciidoc for main man page as well
We already use asciidoc for the gnome-extensions man page, while
the main man page is generated from docbook XML. The former is a
much friendlier source format, so use it for both man pages.

Hopefully the plain text format encourages updates, to prevent the
page from getting as badly out of sync again as it is currently.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1553>
2020-12-28 02:19:18 +01:00
LuK1337
1989a2f9f9 screenshot: Grab screenshot during paint on X11 for area type too
Turns out that shell_screenshot_screenshot_area was affected
by the same issue that shell_screenshot_screenshot used to have.
Adapting code changes from commit id c09be8b0:
"screenshot: Grab screenshot during paint on X11" fixes it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1549>
2020-12-27 22:17:48 +00:00
Ivan Molodetskikh
c401759c1a workspacesView: Fix copy-paste error
Calling both window-drag handlers on drag begin messes up our tracking,
and prevents the swipe tracker from being disabled during drag operations.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1551>
2020-12-27 22:12:08 +01:00
Philipp Kiemle
3f49c886fa Update German translation 2020-12-27 11:52:23 +00:00
Florian Müllner
93115c3d8f Change upcoming version (again)
The extension website doesn't handle the chosen scheme correctly,
so use 40.alpha.1 instead.
2020-12-25 23:30:25 +01:00
Sebastian Keller
eb95f6a0fa networkAgent: Use VPN specific method to add VPN secrets
Use the method introduced in the previous commit to add VPN secrets
instead of adding them as regular secrets/passwords. This ensures
correct serialization of these secrets.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2105

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1535>
2020-12-25 11:43:13 +01:00
Sebastian Keller
087bd863b3 shell/network-agent: Add method to add VPN secrets to agent response
While most secrets are serialized as individual settings with a string
value, all VPN secrets are serialized together as a string dict which is
the value of a single setting. Incorrect serialization causes VPN
secrets to not be remembered by NetworkManager.

This commit adds a new method that allows adding secrets as VPN secrets
specifically such that they can be correctly serialized.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1535>
2020-12-25 11:43:13 +01:00
Sebastian Keller
f0deb03bd4 shell/network-agent: Fix setting leak in get_secrets_keyring_cb
The setting GVariant was not consumed by anything in the VPN case.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1535>
2020-12-25 11:43:13 +01:00
Jordi Mas i Hernandez
7b50c38d6d Update Catalan translation 2020-12-22 12:59:15 +00:00
Florian Müllner
e85d127ae3 dateMenu: Fix temperature edge case
We currently format the temperature with a precision of 0, that is
with no digits after the decimal-point. As a result, a temperature
like -0.2 shows up as -0.

Math.trunc() has the same effect as `%.0f` and handles that edge
case correctly, but while at it, we can just as well round the
value properly.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3441

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1548>
2020-12-22 09:27:45 +00:00
Florian Müllner
adaa5ec6bd build: Change upcoming version to 40.alpha2
I messed up and released 40.alpha at the same time as 3.38.2, when it's
supposed to be in January. In order to re-align with the schedule, change
the upcoming version to 40.alpha2 so we don't have to skip a release and
will be back on track in time of 40.beta.
2020-12-22 01:46:14 +01:00
Hugo Carvalho
8eda814e39 Update Portuguese translation 2020-12-22 00:34:06 +00:00
Jonas Dreßler
fc1d1e5362 st/widget: Switch to the new API to get actor from inputdevice
clutter_input_device_get_actor() was removed in favour of
clutter_stage_get_device_actor(), so use that.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1537>
2020-12-18 15:21:29 +01:00
Fabio Tomat
8f6477be0a Update Friulian translation 2020-12-18 10:07:44 +00:00
Joonas Henriksson
a7c343292e theme: Don't draw border around symbolic user-icon
Recent commit [1] added a strong light border around user avatar
icons, in accordance with design mockups.

As a probably unintentional side-effect, the border was also added
around the symbolic fallback icon, which is displayed whenever the
user avatar is not available. This doesn't work well with the current
design, as the strong border makes the subtle fallback icon
background indistinguishable. Additionally, it doesn't match the
design mockups for the symbolic avatar icon [2].

Correct this by adding a style class for when avatar image is used,
and apply the border only for that case.

[1] 498710c2ec
[2] https://gitlab.gnome.org/Teams/Design/os-mockups/-/blob/master/lock-login/username-based-login.png

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1490>
2020-12-17 21:46:41 +01:00
Joonas Henriksson
6b9f277081 theme: Define default user-icon sizing in SASS
The default sizing for user-icon style was not defined in the theme,
but it simply used the default Avatar iconSize from UserWidget.js.

This didn't work with the current fallback avatar styling (i.e. when
the avatar icon is not set for an user account, and a symbolic icon
is displayed in its place), as the fallback StIcon was not scaled
to align inside the circle shaped user-icon properly.

Define the user-icon and corrected fallback StIcon sizes in the
stylesheet to correct this. The default 64px user-icon size is based
on default UserWidget.Avatar iconSize. The sizing for the StIcon is
taken from `.user-widget.horizontal .user-icon` styling, which uses
the same base icon-size.

Additionally, the special `.user-widget.horizontal .user-icon`
styling is removed, as it is now redundant.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1490>
2020-12-17 21:46:32 +01:00
Georges Basile Stavracas Neto
fe90da82b4 st: Rename and fix blur sampling calculation
What the blur shader does is going n_steps in each direction (e.g. in case
we're in the horizontal pass that means left and right direction), sampling
the adjacent texels of the texel we're currently blurring. That means
n_steps actually is the amount of texels we're sampling in one direction,
not in both directions.

Make n_steps match what the blur shader does, and rename it to sampling_radius
to match what it really means. Do that for both st-theme-node-drawing.c and
st-private.c

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1542>
2020-12-17 11:39:38 -03:00
Georges Basile Stavracas Neto
ec1b099017 st: Fix painting unblurred texture
ClutterActorBox encapsulates (x1, y1, x2, y2), but the
second pair of values to the texture node are width and
height, leading to incorrectly rendering the unblurred
texture.

Fix that by properly making these values be x2 and y2.

Closes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3497

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1542>
2020-12-17 11:15:05 -03:00
Georges Basile Stavracas Neto
e59069c012 st: Use blur node to render shadow pipeline
It is generally faster than downloading the texture, blurring
with the CPU, and uploading the blurred texture. Notice that
'n_values' is calculated differently from the blur_pixels()
function; that's because it needs to match Clutter's blur
shader interpretation of sigma [1].

[1] https://gitlab.gnome.org/GNOME/mutter/-/blob/master/clutter/clutter/clutter-blur.c#L89

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1539>
2020-12-15 17:43:20 -03:00
Georges Basile Stavracas Neto
80a5b55a7a shell: Adapt to ClutterEffect vfunc changes
Add the new ClutterPaintNode argument to the vfuncs. No other
change is needed.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1350>
2020-12-15 15:38:43 +00:00
Georges Basile Stavracas Neto
534f74b065 st/scroll-view-fade: Adapt to paint_target() API changes
It now receives a ClutterPaintNode to paint on. Fortunately,
StScrollViewFade doesn't do any drawing itself, so no changes
are needed.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1350>
2020-12-15 15:38:43 +00:00
Georges Basile Stavracas Neto
715d39870d invert-lightness-effect: Switch to create_pipeline vfunc
Pretty much the exact same changes of the previous commit, applied
to the ShellInvertLightnessEffect subclass.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1350>
2020-12-15 15:38:43 +00:00
Georges Basile Stavracas Neto
99935c746a glsl-effect: Switch to create_pipeline vfunc
This new ClutterOffscreenEffect vastly simplifies subclasses
by allowing them to hand the parent class a CoglPipeline to
use.

Override the create_pipeline() vfunc and return the (cached)
pipeline. Remove the paint_target() override and the now
unnecessary texture size fields from the structure.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1350>
2020-12-15 15:38:43 +00:00
Jonas Ådahl
c09be8b0a9 screenshot: Grab screenshot during paint on X11
We might not be able to directly paint the stage to an offscreen, if
there currently is a fullscreen unredirected window. To make it possible
to take a screenshot in this situation, disable unredirecting, queue a
frame, and take a screenshot after having painted that frame, before we
go back being unredirected.

Don't do this on Wayland because it's a waste.

Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1453
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1534>
2020-12-14 15:21:03 +01:00
Georges Basile Stavracas Neto
f7019bdd0d blur-effect: Use ClutterBlurNode
With ClutterBlurNode available, we can remove our own implementation
and delegate the blur shader and framebuffers. This simply replaces
the pair of layer nodes (vblur and hblur) with a ClutterBlurNode,
and removes all dead code.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1528>
2020-12-14 13:32:49 +00:00
Florentina Mușat
52ccf86599 Update Romanian translation 2020-12-12 18:37:02 +00:00
Georges Basile Stavracas Neto
e3542d5849 dash: Allow icon sizes equal to the available space
When checking for a suitable icon size, Dash currently checks which
of the hardcoded icon sizes is smaller than the calculated available
size.

On some circumstances, however, when the calculated available size
is exactly equal to the hardcoded icon sizes, Dash selects a smaller
size. This cascades (the next icon size is exactly the smaller size,
etc) and ends up with always Dash selecting smallest size available,
even with plenty of available space.

Check if the calculated available size is smaller or equal to the
hardcoded icon sizes.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1533>
2020-12-11 17:42:56 +00:00
Georges Basile Stavracas Neto
99b78d3ee8 Revert "appDisplay/baseAppView: Cleanup animate()"
This reverts commit cd8269185. It turns out this seemingly
harmless cleanup introduced a regression:

 * Open overview
 * Press Meta+A twice
 * Close overview
 * Press Meta+A
 * Enjoy an invisible grid

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3451

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1532>
2020-12-11 13:24:28 -03:00
Florian Müllner
ad9c2dd817 ci: Use correct variable name
Whoops, the last changes accidentally changed the CI_COMMIT_REF_NAME
variable to something that's not actually defined.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1531>
2020-12-11 15:59:11 +01:00
Florian Müllner
ca0ad6d94b ci: Only fetch history for branch tips
We don't need any history, so we can save a bit of bandwidth by
omitting it, and only fetch the refs we are actually interested in.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1529>
2020-12-11 15:05:46 +01:00
Florian Müllner
3cccd829f2 ci: Fix checking out mutter for tag pipelines
$CI_COMMIT_REF_NAME can be a branch name or a tag, depending on the
pipeline, but our checkout script only deals with the former at the
moment.

Address this by rather than looking for a remote branch name, just
try to fetch the ref like we do for merge request pipelines.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1529>
2020-12-11 14:46:58 +01:00
Florian Müllner
3cf35ce6df ci: Improve checkout script output
We are currently not very good at communicating what's going in,
in particular for non-merge request pipelines where the output
is usually just "Using origin/master instead" (instead of what?).

Improve this by consistently communicate what we are looking for,
whether we found it, and what we end up doing.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1529>
2020-12-11 14:44:07 +01:00
Georges Basile Stavracas Neto
0c6df924be lookingGlass: Port to paint nodes
Override vfunc_paint_node(), and add paint nodes to the
root node instead of directly calling CoglFramebuffer APIs.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1339>
2020-12-10 16:15:49 +00:00
Georges Basile Stavracas Neto
71807a4f10 blur-effect: Port to paint nodes
Port the blur effect to the new ClutterEffect.paint_node() vfunc.
Update the function names to match what they do, e.g. "apply_blur()"
now creates the blur subtree and thus was appropriately renamed to
"create_blur_nodes()".

There are 3 subtrees that can be generated by the blur effect:

 1. Actor mode (full subtree; no cache)

      Root
       |
       |
    Layer (brightness)
       |
    Layer (horizontal blur)
       |
    Layer (vertical blur)
       |
    Layer (actor)
       |
    Transform (downscale)
       |
     Actor

 2. Actor mode (partial subtree; cached contents)

      Root
       |
     Pipeline
  (final result)

 3. Background mode

      Root
       |-----------------------
       |                       |
    Layer (brightness)        Actor
       |
    Layer (horizontal blur)
       |
    Layer (vertical blur)
       |
    Layer (background)
       |
      Blit

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1339>
2020-12-10 16:15:49 +00:00
Jonas Ådahl
78d6b13c29 workspacesView: Don't update scroll position when allocating
Updating scroll position may have significant side effects, e.g.
switching workspace; this should never happen during allocation, as
we're in the middle of painting a frame. So, put it in an idle callback
if we're doing it from an allocation to have the side effects happen the
right time.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1527>
2020-12-09 22:09:39 +01:00
Jonas Ådahl
4e57119f40 st/viewport: Don't trigger relayout when picking
Calling clutter_actor_get_allocation_box() might still implicitly
trigger a full relayout, which has many side effects not expected to
occur during picking. Avoid a particular case which caused a reentry
issue by using the current allocation instead of forcing a relayout when
picking in StViewport.

Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1436
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1527>
2020-12-09 22:09:39 +01:00
Hans Ulrich Niedermann
d263f5731c Clarify comments on ConditionEnvironment placement
Clarify the comments on ConditionEnvironment= by mentioning that a
ConditionEnvironment= line must be located in the [Unit] section.

The comments suggesting using ConditionEnvironment= themselves are
in the [Service] section, which implicitly and wrongly suggests
that ConditionEnvironment= could be defined right there as well.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1472>
2020-12-09 15:08:15 +00:00
Hans Ulrich Niedermann
38d642541c Correct the systemd version required for ConditionEnvironment=
According to systemd's NEWS file, the ConditionEnvironment= setting
has only been introduced in systemd 246, not in 245 like the comment
in the services files claimed.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1472#note_942075

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1472>
2020-12-09 15:08:15 +00:00
Tom Levy
feb3c6b618 shellDBus: Remove stray backslashes in D-Bus interface
Those are left-over from when the interfaces were defined as inline
strings.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1526>
2020-12-09 15:58:41 +01:00
Florian Müllner
af5aff3251 dbusServices/screensaver: Split out public ScreenSaver service
Commit 799bbdb50 split out the public Fdo notification service, so
that any app with permission to talk to org.freedesktop.Notifications
will in fact be limited to that service.

To a somewhat lesser extent this applies to the org.gnome.ScreenSaver
service as well, which some applications still use instead of the
Inhibit portal.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3452

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1520>
2020-12-07 16:24:19 +00:00
Florian Müllner
adfcd45bff workspace: Lower maximum window preview size again
In commit 1218e68 we allowed full-sized window previews under the
assumption that we had enough other clues (like the vignette effect)
to differentiate the overview from the regular session.

That didn't hold up in testing, so make the maximum preview size
slightly smaller again.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3464

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1525>
2020-12-07 15:24:37 +01:00
Florian Müllner
cb8b19939d magnifier: Stop exposing D-Bus interface
Screen magnification is the compositor's business, not that of "random"
unprivileged tools. And for cases where a more specialised behavior is
wanted, an extension likely does a better job than a consumer of the
D-Bus API.

In addition to that, exporting the interface has been broken for an
unknown time, because the object that holds the implementation isn't
referenced and thus ends up being garbage collected, whoops.

And last but not least, this gets rid of the last public D-Bus name
that isn't clearly in the system namespace (org.gnome.Shell,
org.gnome.Mutter, org.gtk).

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3452

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1523>
2020-12-06 06:18:07 +01:00
Florian Müllner
f54ab9c9ee main: Stop owning the org.gnome.Panel name
This is a relict from the pre-3.0 days, when it was common to
replace a running GNOME 2 session with gnome-shell. There has
been no good reason to claim the name for many years, time to
drop it.

If someone really wants to run gnome-panel alongside the shell,
they probably know what they are doing. Or cannot be helped anyway.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1521>
2020-12-04 22:02:55 +01:00
Florijan Hamzic
659df23ad3 lookingGlass: Sort extensions alphabetically
Extensions are currently listed in random order, which is hardly
user-friendly. Instead, sort them alphabetically to make the list
easier to parse.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1516>
2020-12-04 02:29:44 +00:00
Georges Basile Stavracas Neto
3e74b5ae9b theme: Add some horizontal padding to folder view
So that folders also have a slight fade when scrolling. Do that by actually
dropping the CSS to remove the inherited horizontal padding.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1519>
2020-12-03 14:34:03 -03:00
Georges Basile Stavracas Neto
aca61ad3ee appDisplay/baseAppView: Reinstate fade effect
Bring back the fade effect that was dropped by commit 4e05bcd3b6.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1519>
2020-12-03 14:27:51 -03:00
Georges Basile Stavracas Neto
9c10c34b07 appDisplay/baseAppView: Also consider its own content box when adapting
Otherwise setting margins and paddings from CSS may result in the grid
being adapted to the wrong size.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1519>
2020-12-03 14:24:18 -03:00
Georges Basile Stavracas Neto
cd82691859 appDisplay/baseAppView: Cleanup animate()
Simplify the opacity dance to simply setting it to the initial value
before animating (0 when animating in, and 255 when animating out),
and to the final value after the spring animation is done (vice-versa).

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1518>
2020-12-02 22:43:04 +00:00
Georges Basile Stavracas Neto
b730875012 iconGrid/iconGrid: Wait for icon sizes before running spring animation
To run the spring animation, IconGrid uses the transformed position and size
of the icons. This works okay when IconGridLayout doesn't need to update the
icon sizes, but looks bad when IconGridLayout selects a different icon size.

Wait for the icon sizes to be recalculated, and the icons  beallocated, before
running the spring animation. If no icon size update is pending, run the spring
animation directly.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1518>
2020-12-02 22:43:04 +00:00
Georges Basile Stavracas Neto
10d91b52e7 appDisplay/baseAppView: Update page indicators on page-changed
The number of pages doesn't depend on the allocated size anymore. Move updating
page indicators from BaseAppView.adaptToSize() to a IconGrid::pages-changed
callback.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1518>
2020-12-02 22:43:04 +00:00
Georges Basile Stavracas Neto
b120b17d01 iconGrid/iconGridLayout: Simplify _findBestIconSize()
The 'bestSize' variable isn't necessary anymore, remove it in favor of
simply returning the 'size' or, if no suitable size found, IconSize.TINY.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1518>
2020-12-02 22:43:04 +00:00
Georges Basile Stavracas Neto
7d4ac04a78 appDisplay/baseAppView: Use a separate flag for animated indicators
In the future, both AppDisplay and FolderView will be horizontal, and thus
using the orientation to determine whether to use animated indicators won't
be enough.

Use a different flag to control that, and make FolderView not use animated
page indicators.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1518>
2020-12-02 22:43:04 +00:00
Georges Basile Stavracas Neto
3f09876463 pageIndicator/animatedPageIndicators: Implement vertical animation
It is basically the same of animating horizontally, except on the Y axis, and
based on the height of the indicators.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1518>
2020-12-02 22:43:04 +00:00
Georges Basile Stavracas Neto
853644d7fe appDisplay: Properly destroy SwipeTracker on destroy
SwipeTracker connects to signals of the stage, but doesn't disconnect on
destroy, leaving them hanging and potentially running callbacks for
destroyed objects.

This is visible when removing a folder by dragging all icons out, and
running the swipe gestures, which will produce a bunch of warnings.

Explicitly destroy, remove, and disconnect the swipe tracker.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1518>
2020-12-02 22:43:04 +00:00
Georges Basile Stavracas Neto
c9a6424f2e overviewControls: Simplify DashSpacer
Make it subclass ClutterActor, since we don't need any of StWidget's
features. Pass the source actor of the bind constraint in the
constructor, and remove the extra method to set the source actor.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1518>
2020-12-02 22:43:04 +00:00
Georges Basile Stavracas Neto
491a69a5a2 overviewControls: Remove ControlsLayout
ControlsLayout is a tiny layout manager whose only purpose
is emit "allocation-changed" after allocation. This signal
was listened to update the workspaces actual geometry.

However, since d66cd0d206, ControlsManager doesn't listen
to this signal anymore, rendering the class useless.

Remove ControlsLayout.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1518>
2020-12-02 22:43:04 +00:00
Florian Müllner
f2ee1587da Post-release version bump 2020-12-02 20:40:04 +01:00
Florian Müllner
12d9761c29 Tag version 40.alpha
Update NEWS.
2020-12-02 18:44:14 +01:00
Florian Müllner
40e22eb524 cleanup: Use optional chaining and ?? operator
Those operators have been supported since gjs switched to mozjs78
last cycle. While not ground-breaking, using it makes for a nice
cleanup here and there.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1517>
2020-12-02 15:10:29 +00:00
Daniel Mustieles
c9df2f9370 Updated Spanish translation 2020-12-02 14:18:26 +01:00
Daniel van Vugt
5492309755 st-theme-node-drawing: Render all shadow sections with thickness > 0
In some styles the top or left sections of box-shadows would go missing
even though they had non-zero thickness. This was because the inner
local coordinates could become very slightly negative and were then
incorrectly judged to be invisible.

Negative coordinates should not be ignored because that's where the
entire top/left sections of shadow are meant to exist. It's only the
sections of shadow with zero thickness that we should skip.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1417>
2020-12-02 00:01:30 +01:00
Florian Müllner
595359afa5 messageTray: Default to generic policy
How and if notifications are shown is controlled by NotificationPolicy
objects. But ever since 098bd45, only notification daemon sources or
notifications associated with an app are hooked up to GSettings.

The hardcoded default policy for built-in notifications (including
those provided by extensions) arguably made sense back then, but
now that the main setting has been rebranded as "Do Not Disturb"
and is exposed prominently in the calendar drop-down, following
GSettings is a better default.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3291

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1511>
2020-12-01 20:02:02 +00:00
Georges Basile Stavracas Neto
4863c498b2 iconGrid/iconGridLayout: Make sure to always update best size
When selecting the best icon size for the available area, we
iterate from the biggest icon size to the smallest one, and
stop when finding a size that fits the available area.

However, the 'bestSize' variable is only updated when the
available area is positive. This is problematic in super bad
cases like when none of the icon sizes actually fit the availabe
area, which was hit with a previous iteration of this branch.

Make sure to update the best size while iterating, so that the
smallest size is selected even in such bad cases.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1510>
2020-12-01 18:57:49 +00:00
Georges Basile Stavracas Neto
34e38a835c iconGrid/iconGridLayout: Floor children position
So that we don't end up with positions misaligned from the pixel grid.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1510>
2020-12-01 18:57:49 +00:00
Georges Basile Stavracas Neto
c589f40faa theme: Add page padding to the icon grid
Add padding to the app grid pages. Values adjusted as per
design feedback.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1510>
2020-12-01 18:57:49 +00:00
Georges Basile Stavracas Neto
e667406984 iconGrid/iconGrid: Fill pages by default
Use the Clutter.ActorAlign.FILL alignment by default, which
expands the grid until max-row|column-spacing is hit. This
was the behavior we originally wanted for the icon grid, and
it's finally being realized.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1510>
2020-12-01 18:57:49 +00:00
Georges Basile Stavracas Neto
4ad32ab662 iconGrid/iconGrid: Hook page-padding with CSS
Add support for setting the page padding of the icon grid
through CSS. Unfortunately, each side needs to be specificied
manually, since it's not a regular padding property.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1510>
2020-12-01 18:57:49 +00:00
Georges Basile Stavracas Neto
5b6686095a iconGrid/iconGridLayout: Add support for page-padding
This is a new property to control the padding around each page,
as opposed to the padding around the entire container.

Following the original design of IconGridLayout [1], changing
the page-padding property doesn't trigger relayouts; the container
is responsible for queueing a relayout appropriately.

[1] 3555550d5e

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1510>
2020-12-01 18:57:49 +00:00
Kjartan Maraas
588457cb73 Update Norwegian Bokmål translation
(cherry picked from commit 0936821ee3a70ad728e27fd324c1440a1c90ed53)
2020-11-30 13:01:01 +00:00
Anders Jonsson
a63ef3885e Update Swedish translation 2020-11-28 22:00:27 +00:00
Florian Müllner
ef807619e9 credentialManager: Shut up a JS warning
Plain classes are private to their file, so accessing them from
another module results in the following warning:

    That property was defined with 'let' or 'const' inside the module.
    This was previously supported, but is not correct according to the
    ES6 standard.

Fix by assigning the class to a public variable instead.

(Eventually switching to ES6 modules with proper imports/exports will
fix this as well)

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1512>
2020-11-26 14:17:26 +01:00
Daniel van Vugt
244c266c9f st-bin: Disallow st_bin_set_child with already-parented children
Not checking for this would result in `clutter_actor_add_child`
failing, but StBin keeping a copy in `priv->child`. So later on,
`st_bin_remove` would never be called on it and this assertion
would fail and crash the whole shell:

```
static void
st_bin_destroy (ClutterActor *actor)
{
  StBinPrivate *priv = st_bin_get_instance_private (ST_BIN (actor));

  if (priv->child)
    clutter_actor_destroy (priv->child);
  g_assert (priv->child == NULL);

```

By disallowing spurious `st_bin_set_child` calls we now prevent StBin
from entering such a corrupt state and the above assertion won't fail
anymore.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1507>
2020-11-26 13:47:11 +01:00
Georges Basile Stavracas Neto
ee0f250662 appDisplay: Don't update multiline for search results
The grid icons in the search results page doesn't expand to
acommodate the multiline label, resulting in the multiline
label to overflow behind the list search results. However,
after 548d3b62d, it was possible to trigger this behavior
with keyboard focus.

Don't update multiline labels for search results.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1509>
2020-11-25 16:52:50 -03:00
Jonas Dreßler
a314c05fec workspace: Handle child not being present in the window slots array
Adding children to the WorkspaceLayout without calling addPreview() is
not supported, so let's log an error in case that happened.

We also have to allocate that child an empty ClutterActorBox, otherwise
Clutter will complain loudly.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1481>
2020-11-24 20:20:45 +00:00
Jonas Dreßler
3fb0284358 Make sure to allocate all children in allocate vfuncs
Clutter expects actors overriding the allocate vfunc to allocate all
mapped children of the actor, otherwise bad things happen.

So make sure we actually allocate all our visible children in our custom
allocation functions, and since we don't want to give them a real
allocation, just pass them an empty ClutterActorBox.

It would be nice if we had a way to hide children during the allocation
process where no relayout is queued like gtk allows with
gtk_widget_set_child_visible(), then we could avoid those weird empty
ClutterActorBoxes.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3098

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1481>
2020-11-24 20:20:45 +00:00
Florian Müllner
e8893f4fa4 ci: Bump ci-fairy template include
This fixes the check-merge-request job when MR branch and target branch are
on the same repo.

See
https://gitlab.freedesktop.org/freedesktop/ci-templates/-/merge_requests/66

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1508>
2020-11-24 18:00:29 +01:00
Jonas Dreßler
96dc6d19dd windowManager: Check whether metaWindow is NULL after destroy animation
When logging out or terminating gnome-shell, mutter will unmanage all
open windows, triggering the window-close animation in gnome-shell and
very quickly after that emitting "kill-window-effects". That means we'll
call _destroyWindowDone() to cleanup our animation data, but at this
point the MetaWindow of the window is already gone, so we get an error
that get_meta_window() returns NULL.

Fix that by checking whether get_meta_window() returned NULL and if it
did, don't access the window.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2018

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1483>
2020-11-21 23:40:53 +01:00
Jordan Petridis
07fd0d3f2e ci: Replace only/except with rules
only/except keywords where deperecated in favor of rules.

Since we started using GNOME/gnome-shell!1492 it introduced
a second pipeline being run for each commit.

Detached pipelines are the only way to access CI_MERGE_REQUEST_*
variables, and if we disable normal pipelines you will need to
create wip/spam MRs in order to run the tests.

This reworked rules makes it so, the normal pipeline needs manual
interaction to be started, and the detached/MR pipleines is always
run.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1503>
2020-11-21 00:24:25 +01:00
Jordan Petridis
b64020f84b ci: Set some sensible defaults
* Allow for all jobs to be cancelled if a newer commit is pushed
* Automatically retry jobs if they fail due to some infrastructure issue

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1503>
2020-11-21 00:24:22 +01:00
Jonas Ådahl
250bab0115 ci: Check that merge requests have the right settings
This will catch the missing "allow write access for maintainers" check
box being checked.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1506>
2020-11-20 23:24:03 +01:00
Jonas Ådahl
1aa7a23427 ci: Use ci-fairy image for commit log check
It's much much smaller.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1506>
2020-11-20 23:24:03 +01:00
Florian Müllner
e81cab540f ci: Update mutter image
Mutter now produces an image as part of its CI pipeline. Use that
instead of the now outdated manually built image.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1504>
2020-11-20 20:33:56 +01:00
Florian Müllner
1fbf62f0c6 ci: Use the CI image produced by the pipeline
The newly-added eslint_mr job still uses the manually built
extension image instead of the image that is built as part
of the pipeline.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1504>
2020-11-20 20:33:40 +01:00
Jonas Ådahl
408c922148 ci: Fix check-commit-log test failure count
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1505>
2020-11-20 17:34:19 +01:00
Jonas Ådahl
2e976cd9bf ci: Generate junit report if project doesn't enable the registry
The image registry must be enabled for the CI to work, as the container
image from the upstream registry is placed (as a reference, more or
less) in the local registry.

Recently, ci-templates got a bit more helpful if this happened, and will
fail up front and generate a JUnit report with a message describing the
issue.

Update to this version.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1505>
2020-11-20 17:34:11 +01:00
Jonas Ådahl
e203278d74 ci: Bump ci-templates to include registry path fix
ci-templates had a bug where it failed to find the ready-built container
images on the upstream repository due to invalid assumptions about the
relationship between upstream repository and image registry. This
resulted in the container image to be rebuilt, wasting valuable CPU
cycles and storage space. Bump the included ci-templates template to
include the fix for this.

See https://gitlab.freedesktop.org/freedesktop/ci-templates/-/issues/22.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1502>
2020-11-20 11:32:12 +01:00
Sebastian Keller
330b44ede5 st/button: Remove unused spacing member from private struct
It is only ever written, but never used anywhere.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1489>
2020-11-18 21:26:53 +01:00
Sebastian Keller
237e470238 st/entry: Don't set font twice on style changes
Setting the font is already handled by _st_set_text_from_style() since
be76b19300.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1489>
2020-11-18 21:26:53 +01:00
Jonas Ådahl
e026e3bc9f ci: Use ci-templates for building image
This rebuilds the automaticaly whenever the image tag changes. Whenever
something in the image needs to change, alter the installation script
and change the tag to the current date.

This removes the -s (strict) argument from js68, as it doesn't exist in
js78.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1492>
2020-11-17 19:07:42 +00:00
Carlos Garnacho
51ff9ce444 js/shellDbus: Do not forward device IDs
We already pass the device event node path for identification purposes,
we can stop doing that here.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1501>
2020-11-17 19:07:30 +01:00
Jonas Ådahl
6272490b0d gnome-shell.doap: Make marge-bot a maintainer
This is so that the merge button can be restricted to maintainers, thus
decreasing the risk of merging using the merge button.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1491>
2020-11-17 17:29:56 +00:00
Jonas Ådahl
e2945a525c ci: Wait for 'check-commit-log' before continuing
The check-commit-log is quick, and to get a result early is helpful as
one can then more quickly check for failures via the report provided via
the JUnit report.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1491>
2020-11-17 17:29:56 +00:00
Jonas Ådahl
09a09dd102 ci/check-commit-log: Generate JUnit report
This means the merge request will see the commit log review issues
causing the pipeline to fail without having to dig through CI log files.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1491>
2020-11-17 17:29:56 +00:00
Jonas Ådahl
5f7615d3fc ci/check-commit-log: Reverse the merge request URL check
Instead of making sure there is a reference to a bug or merge request,
make sure there isn't. The reason for this is that marge-bot will always
append a merge request URL in the end of the commit message.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1491>
2020-11-17 17:29:55 +00:00
Florian Müllner
3567820a87 lint: Sync configuration with gjs
gjs updated its eslint configuration, so sync our copy.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1498
2020-11-16 18:04:23 +00:00
Florian Müllner
8a47f1c667 cleanup: Remove empty leading/trailing lines in blocks
gjs added a new rule to its eslint ruleset that forbids "block padding",
so make sure we conform to that rule before syncing up the configuration.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1498
2020-11-16 18:04:23 +00:00
Florian Müllner
7521b9c4b2 extensionUtils: Stop using Lang.copyProperties()
It is now deprecated, so use object destructuring instead.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1498
2020-11-16 18:04:23 +00:00
Yuri Chornoivan
adb984cec7 Update Ukrainian translation 2020-11-15 07:59:15 +00:00
Georges Basile Stavracas Neto
548d3b62d7 appDisplay: Expand titles on keyboard focus as well
In addition to hover, expand wrapped app titles when keyboard
focus is in as well. This gives keyboard users a chance to
read the app name.

Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3333

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1496
2020-11-13 23:29:14 +00:00
Georges Basile Stavracas Neto
5d27a5a42a appDisplay: Factor out function
The function to update the multiline state of the title label
will be reused by the next commit, so move it into a separate
method.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1496
2020-11-13 23:29:14 +00:00
Georges Basile Stavracas Neto
47dc3043df appDisplay: Adjust label collapse and expand times
As per design feedback, these times are too slow.

Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3333

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1496
2020-11-13 23:29:14 +00:00
Florian Müllner
25ca8826ed ci: Enforce non-legacy style for new code
We have been transitioning to the new coding style for a while now,
and there has been reasonable progress. So hopefully it is not too
intrusive at this point to enforce non-legacy style for all lines
that are changed in a merge request. If it turns out to be still too
annoying, we can always reconsider and turn off the additional job.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1497
2020-11-13 22:40:45 +01:00
Florian Müllner
4401c8fae7 ci: Use junit output format
Gitlab has built-in support for junit reports, so switch eslint's
output to that format.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1497
2020-11-13 22:32:50 +01:00
Florian Müllner
8c13e3855e ci: Use node-js script for running eslint
This is unnecessary hard in shell when compared to a proper programming
language. It becomes even easier with a node-js script, as that gives us
access to the underlying ESLint module rather than just the CLI interface.

Besides that, node-js has the added benefit that we don't need to add
more dependencies to the CI image.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1497
2020-11-13 22:32:50 +01:00
Florian Müllner
9ef59b3b4f extensions-app: Add extension filtering
It's possible for the list of installed extension to get long
enough to make searching more convenient than scrolling.

Support that by implementing the standard search pattern[0]
with a hidden search bar and a toggle in the headerbar.

[0] https://developer.gnome.org/hig/stable/search.html.en

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3382
2020-11-12 22:05:46 +00:00
Daniel García Moreno
8eec7ae2d8 appDisplay: don't change grid page on adaptToSize
If the adapt to size occurs after the grid page has been changed the
page is set to zero. This patch just keep the current page with the same
value that it has before.

Fix https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3388
2020-11-12 16:47:11 +01:00
Juliano de Souza Camargo
d886d31bf0 Update Portuguese translation
(cherry picked from commit e93b8263b03ed8bbb3829ad82ebf3664197740c9)
2020-11-11 14:29:25 +00:00
Popax21
461bbcff15 modemManager: Add property getters
gjs improved its default property getter/setters, and as a result it
is no longer possible to set read-only properties.

Add proper getters (backed by private properties) to fix the resulting
errors.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3203
2020-11-03 16:35:43 +01:00
Olav Vitters
62d0c3a661 gnome-shell.doap: Mailing list moved to Discouse per #3253 2020-11-02 14:45:13 +01:00
Ask Hjorth Larsen
0d26472ce6 Updated Danish translation 2020-11-01 14:18:43 +01:00
Asier Sarasua Garmendia
197aef3e40 Update Basque translation 2020-10-31 17:00:06 +00:00
Ian Douglas Scott
c86c294d2a appDisplay: Only show add/remove favorite when shouldShowApp() is true
`shouldShowApp()` is called in `_addFavorite`, so adding a favorite when
this isn't true won't work. Also, it seems when this is false, favorites
that do exist won't be shown anyway.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3342
2020-10-30 11:20:45 -07:00
Florian Müllner
8d43deaad5 extensions-app: Add quit action
It's good practice to support the standard <ctrl>-q shortcut, so
add a corresponding action and set its accel accordingly.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3335
2020-10-28 21:45:18 +01:00
Carlos Garnacho
a9a54ba2a3 magnifier: Avoid cursor visibility changes on startup
When initializing the shell, we create the magnifier, and (normally)
let it disabled. This still toggles cursor visibility on, which is
not right since there's other considerations to take during
initialization.

Only do this after actual changes to the magnifier state, so
initialization is left unperturbed.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1486
2020-10-28 20:59:07 +01:00
Florian Müllner
709c226fc3 messageTray: Don't play sound when banners are disabled
When support for notification sounds was added, it made some sense
to keep the 'enable-sound' setting independent from 'show-banners'.

However that changed when 'show-banners' was rebranded in the UI as
"Do Not Disturb", as sounds are at least as disturbing as the banners.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2873
2020-10-27 01:12:07 +01:00
Georges Basile Stavracas Neto
69516a52c6 Adapt to pick changes
It turns out, StViewport's pick implementation was broken, since
Clutter stopped reading clipping from the framebuffer. Rejoice with
bugfixing by removing code!

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1470
2020-10-26 13:34:40 +00:00
Jonas Dreßler
0b2430128a windowPreview: Handle case where window already is part of layout
We sometimes add dialogs multiple times to the WindowPreview, for
example for modal dialogs we receive both the "window-added" and the
"window-entered-monitor" signal, which means we call
WindowPreview.addDialog() twice.

We handle that fine already in the WindowPreviewLayout and return NULL
in case the window already was added, so simply handle that NULL return
value and bail out of WindowPreview.addDialog() in this case.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1482
2020-10-26 03:40:19 +00:00
Harry Míchal
d318bf539d mpris: Switch text in title and body
Most media players have a media player that shows the title of a song
and artists in the song. In those media players the title is
highlighted (bold text) and the list of artists is under the title.
Shell does the exact opposite in the player in the notification area.

Example media players: Spotify, Rhythmbox, GNOME Music

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1480
2020-10-26 04:02:14 +01:00
Jonas Dreßler
012af56b37 tests/background-size: Remove ClutterActor::paint signal handler usage
The background-size interactive test includes a test-case which uses the
ClutterActor::paint signal to hijack the painting of the actor. We're
removing that signal from Clutter, so remove that signal handler and
paint the outer border unconditionally to mark the boundaries of the
widget (the outer border actually never worked to force the cairo/cogl
path). To fix the test, change it to not paint a border on the inner
container in the useCairo=false case, which should make sure the cogl
path gets used.

Also remove the useless useCairo argument from addTestLine().

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1479
2020-10-24 23:21:39 +02:00
Florian Müllner
f5d1a2858d telepathyClient: Promisify the right class
send_message_async() is a method of TpTextChannel, not the generic
TpChannel parent class.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3226
2020-10-22 21:11:01 +02:00
Daniel Mustieles
f940b0b139 Updated Spanish translation 2020-10-22 08:56:43 +02:00
Georges Basile Stavracas Neto
b244274d48 appDisplay: Don't expand title for search results
It creates quite a nasty visual inconsistency where the
search results' icon title overflows beneath the next
search section.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1477
2020-10-21 19:44:39 -03:00
Georges Basile Stavracas Neto
efd1e06fec appDisplay: Let icon labels be multiline when hovered
When hovered, remove constraints from the icon labels that
limit the number of lines. Do that inside a saved easing
state so that the allocation can ease the label.

This helps with applications with long titles.

Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/363

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1477
2020-10-21 19:44:39 -03:00
Georges Basile Stavracas Neto
4fcbf6c974 iconGrid: Allocate preferred sizes if bigger than child size
IconGridLayout uses the biggest minimum size to allocate its
children. Next commit will make app icons with long names show
not ellipsize on hover, and it is important that the icon itself
is able to follow that.

Use preferred size if it's bigger than the minimum size.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1477
2020-10-21 18:54:56 -03:00
Georges Basile Stavracas Neto
b3659221bd iconGrid: Trivial style cleanup
Turns out, we only needed a gentle push to get this whole
file fit in.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1477
2020-10-21 18:46:54 -03:00
Florian Müllner
5cfec80e9d audioDeviceSelection: Center-align icons
When the icon area gets allocated additional space, we want the
icons centered rather than left-aligned. This may happen in locales
with long-ish translations for the title or buttons when only a
subset of possible icons is shown.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3307
2020-10-21 03:29:18 +02:00
Jonas Dreßler
d19683a84c dnd: Get transformed size for scaling before unparenting drag actor
Commit de610a13f1ad1e7e34d4b9a81df58d4da3693059 in mutter made it
impossible to access the actors last allocation after unmapping it,
this broke the scale-up/down animation when starting a drag.

Fix that animation again by saving the actors transformed size before
unparenting (and therefore unmapping) the actor instead of afterwards.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1475
2020-10-21 01:15:21 +02:00
Carmen Bianca BAKKER
0e21904557 Update Esperanto translation 2020-10-20 08:57:06 +00:00
Robert Mader
22f691939c Stop using GSlice
It has been inofficially deprecated for years, is known to cause issues
with valgrind and potentially hides memory corruption.
Lets stop using it.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1473
2020-10-19 20:18:11 +02:00
Florian Müllner
d72da7d246 screenshot: Handle window screenshot failures gracefully
meta_window_actor_get_image() may return NULL. Instead of crashing,
catch that case and return a proper error.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3258
2020-10-19 15:00:04 +00:00
Fabio Tomat
6273654376 Update Friulian translation 2020-10-18 14:48:26 +00:00
Jonas Ådahl
bd710ff4fd Adapt to CoglFramebuffers turning into GObjects
Requires some more explicit type casting as things turned into 'void *'
less. Also memory management changes, as we can't use CoglObject
functions anymore for these objects.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1465
2020-10-16 16:18:48 +00:00
Florian Müllner
a9349fbd3f data: Remove unused GSettings key
We no longer have multiple app picker views, so there's no point
in remembering the last one.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1469
2020-10-15 19:10:46 +02:00
Jonas Ådahl
a0e87b53ff remoteAccess: Ignore all but the screen record handles on X11
We still want to show the red dot when recording the screen on X11, so
only drop the "screen-is-shared" handles when using the X11 session.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3279

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1466
2020-10-13 21:45:59 +00:00
Jan Tojnar
6c7ab4f00d
docs: Unify on single DocBook version
DocBook 4.5 is backwards compatible.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1464
2020-10-13 03:02:13 +02:00
Akarshan Biswas
b2a2ea7868 Update Bengali (India) translation
(cherry picked from commit 296af6e1e8c80d400cec91926adcf71b4ec1aec1)
2020-10-11 07:05:05 +00:00
Juliano de Souza Camargo
d9480428b9 Update Portuguese translation
(cherry picked from commit 59dd5d58ae6952c599f8fc73d4e0fc27d8363892)
2020-10-10 00:22:03 +00:00
Florian Müllner
9d5165b1aa polkitAgent: Drop separate user icon style
It should use the same style as used elsewhere (like the lock screen),
so stop using a separate style class to pick up the defaults.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3252
2020-10-09 13:23:05 +00:00
Fabio Tomat
5ece14e558 Update Friulian translation 2020-10-09 11:49:53 +00:00
Ray Strode
6758746f25 screenShield: Fix pointer motion signal handler leak
The screen shield code listens for motion events on the stage
so that it can hide the pointer until the user moves the mouse.

Unfortunately, if the user never moves the mouse, the signal
handler connection gets leaked.

This commit makes sure the connection gets disconnected when the
shield goes away.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1459
2020-10-08 09:46:12 -04:00
Ray Strode
2b44fa893f screenShield: Use identity operator when matching for motion events
The screen shield watches for motion events to know to display
the pointer when the user wiggles their mouse.

It checks for motion events by looking at the event type and
seeing if it is of type `Clutter.EventType.MOTION`.  To do this
comparison it uses the equality operator (==).  Using the equality
operator isn't considered best practice, because it can returns true
when comparing disparate types, if those types happen to be equivalent
after coersion.

From a code resiliance point of view, it's better to use the
identity operator (===), which requires both sides of the comparison
to be of the same type.

As a policy, any legacy code that gets changed or moved should be
switched away from the equality operator to the identity operator, if
appropriate.

This commit makes that change as prep work for a fix to that part of
the code.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1459
2020-10-08 09:45:51 -04:00
Daniel van Vugt
6ba3ca5f95 windowManager: Avoid calling meta_window_actor_thaw when not frozen
Because that tends to crash in:
```
g_error ("Error in freeze/thaw accounting");
```

Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1431

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1453
2020-10-08 14:27:58 +08:00
Andre Moreira Magalhaes
cc9f66d784 environment: Handle @content for property transitions
When using `Actor.ease_property` if the property starts with '@' and the
duration of the transition is zero (which may happen if the actor is not
mapped even if a non-zero duration was passed to `ease_property`), the
impl will try getting the actual target object where the property should
be set.

This works fine for most cases but it currently throws an error when
passing '@content.*' properties. Fix this by handling '@content' as
a property of `actor.content` (used by MetaBackgroundActor when
showing the overview).

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1461
2020-10-07 20:49:09 -03:00
Ray Strode
b41ef2f6e3 panel: Disconnect destroy signal handler when needed
The panel corners try to match their style to the buttons closest
to them. In order to make sure the corner styles stay in sync with
their neighboring buttons, they connect to the style-changed signals
of the buttons.

In order to make sure the style-changed signal handler isn't leaked,
it gets disconnected when the button is destroyed.

Unfortunately, the destroy signal handler connection itself gets leaked!

This commit ensures the destroy signal handler gets disconnected any
time the neighboring button is re-determined.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1460
2020-10-07 17:03:52 -04:00
Joonas Henriksson
9963f7ce84 unlockDialog: Use unique unlock-dialog style class
Allows styling the unlock dialog elements individually from the GDM
login dialog.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1421
2020-10-07 16:16:57 +00:00
Juliano de Souza Camargo
0c14ac7052 Update Portuguese translation
(cherry picked from commit 9f247879a88024478c81dae19c1899eee7668092)
2020-10-07 12:56:11 +00:00
Carlos Garnacho
ff6c0ca68c shell: Update to MetaCursorTracker API change
The pointer coordinates in meta_cursor_tracker_get_pointer() are now
returned as a graphene_point_t.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1405
2020-10-06 18:17:30 +02:00
Georges Basile Stavracas Neto
2321ce2864 Replace CoglMatrix by graphene_matrix_t
Replace both the types, and the cogl_matrix_* API calls
with the corresponding graphene_matrix_* ones.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1436
2020-10-06 11:00:36 -03:00
Florian Müllner
6b1e2df589 extensionUtils: Adjust version check
With the new versioning scheme, the previously-minor version gets
shifted up to major, and unstable releases are marked by non-numeric
"versions" rather than uneven numbers. Reflect that in the extension
version check.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1456
2020-10-06 15:06:09 +02:00
Florian Müllner
deb78b9ada Bump version to 40.alpha
The GNOME project has adopted a new versioning scheme[0], and
GNOME 3.38 will be followed by GNOME 40.

Open the new development cycle by switching to the new scheme, as
well as to post-release bumps as recommended.

[0] https://discourse.gnome.org/t/new-gnome-versioning-scheme/4235

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1456
2020-10-06 15:06:03 +02:00
Florian Müllner
b3c106c63b Bump version to 3.38.1
Update NEWS.
2020-10-05 20:36:03 +02:00
Florian Müllner
da36506ea5 workspacesView: Work around Clutter optimization
Clutter nowadays omits reallocations when only the stage position
changed, that is when the allocation relative to the parent changed.

As a result (apart from better performance of course), workspaces
in the overview may now end up with an outdated "actual geometry"
in case the overview moved to a new primary monitor (of equal size
as the previous one).

Work around that by emitting a signal from the overview on allocation
changes, and use that to update the cached geometry.

We can revert that change once workspaces become part of the regular
overview hierarchy.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3211
2020-10-05 14:11:55 +02:00
Georges Basile Stavracas Neto
d04daf6a1c appDisplay: Protect against source icon destruction
When dragging icons out of a folder dialog, there is a very peculiar
combination of steps that may break GNOME Shell:

 1. Open an app folder dialog
 2. Start dragging an icon to outside the grid
 3. Wait until the popdown animation starts
 4. Before it finishes, drop the icon
 5. See the warnings / crash

That's caused by the source icon being destroyed after the delayed
move timer starts, and before it finishes.

Protect against the source icon being destroyed before the delayed
move timeout triggers by connecting to the 'destroy' signal and
removing the timeout on the callback. Use a single field, called
'_delayedMoveData', to store all data related to delayed moves.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:48 +00:00
Georges Basile Stavracas Neto
aaff88a6bb appDisplay: Remove icon from folder when dragging out
When dragging an icon outside of a folder dialog, there's a small delay
before the dialog pops down. If the icon is dropped during this delay,
the drag is cancelled, and the icon continues to be in the folder.

However, this behavior turned out to be problematic, and it was a common
point of failure that throwing icons outside folders wouldn't work.

Remove the icon from the folder when dragging it to outside the dialog.

Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3092

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:48 +00:00
Georges Basile Stavracas Neto
1acbdcc9b3 appDisplay: Allow passing callback to AppFolderDialog.popdown()
Next commit will allow removing icons from the folder, and we want to
do that effectively after the dialog pops down.

Add an optional callback to AppFolderDialog.popdown().

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:48 +00:00
Georges Basile Stavracas Neto
33bd038af2 appDisplay: Don't change opacity on destruction
At the end of BaseAppView._clearAnimateLater(), the '_grid' actor's opacity is
set to 255. As it turns out, _clearAnimateLater() is called, among others, by
vfunc_unmap(). However, unmapping is part of the destruction process, and at
the time it is called, '_grid' is already destroying, which makes GJS complain
about accessing an invalid object.

Don't change opacity on BaseAppView._clearAnimateLater(), and instead move it
to the couple of places outside vfunc_unmap() that call it.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:48 +00:00
Georges Basile Stavracas Neto
59549e0b13 appDisplay: Save pages when folder apps change
After dragging an icon to inside a folder, we do not save the grid layout,
leaving the icon's position stored when it actually isn't there anymore.

Fix that by saving pages whenever folder apps change.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:48 +00:00
Georges Basile Stavracas Neto
7dafd25ef4 appDisplay: Don't emit 'apps-changed' when deleting folder
To delete a folder, FolderView needs to reset all keys under that particular
folder's GSettings path. That generates 5 'changed' signals, all of which
end up calling AppDisplay._redisplay(), which is costly.

Don't emit 'apps-changed' when deleting a folder.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:47 +00:00
Georges Basile Stavracas Neto
31591ff029 appDisplay: Only change excluded-apps when not deleting folder
It is useless to update the 'excluded-apps' list when we know we're going
to delete the folder entirely.

Only update 'excluded-apps' when not deleting the app folder.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:47 +00:00
Georges Basile Stavracas Neto
75a8697671 appDisplay: Trivial const-correctness fix
https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:47 +00:00
Georges Basile Stavracas Neto
1709592811 appDisplay: Adjust folder position
If you try and drop an icon that's in the same page, but before the
drop target, it'll be one position ahead of where it should be -
because we just removed one icon before the target position.

Adjust the final position of the to-be-created folder.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:47 +00:00
Georges Basile Stavracas Neto
8d84e05a2a appDisplay: Reduce folder dialog popdown timeout
1500ms is too long of a delay, and it confuses people more than it
helps with accidental drops.

Reduce the timeout to 500ms as per design feedback.

Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3092

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:47 +00:00
Georges Basile Stavracas Neto
cc3519332c appDisplay: Lighten folder dialog background when dragging out
As per design feedback, make the app folder dialog background lighter when
hovering it with an icon. This gives the visual feedback to show that that
region is a target.

Use the new DIALOG_SHADE_NORMAL variable in the other places where its color
was hardcoded.

Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3092

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:47 +00:00
Georges Basile Stavracas Neto
062c014223 appDisplay: Use new moveItem API to move items
This uses the API added in the previous commit. The intent here
is to avoid removing and readding actors when moving them around.

Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3165

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:47 +00:00
Georges Basile Stavracas Neto
ffdff07eaf iconGrid: Add moveItem
This new public API moves items without removing and readding
them, which allows us to avoid some tricky behavior. Noticeably,
following the original design described at 3555550d5, the new
IconGridLayout.moveItem() method does not call `layout_changed`.
This is done by IconGrid itself, queueing a relayout.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:47 +00:00
Georges Basile Stavracas Neto
bfd4d0f7aa appDisplay: Factor out linear position calculation
When adding an item to the app grid, the item is added to
a sorted array. This is calculated by adding all visible
items in pages before the one being modified. Future commits
will need this to move items without reparenting them, so
factor this code into a separate function.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1447
2020-10-05 12:06:47 +00:00
Florian Müllner
ab9aa5b1f2 workspacesView: Update workspace visibility when entering overview
This was missed in commit 96f63b08c2 when splitting the combined
layout+scrolling method into allocation and translation.

Add it back to prevent windows from other windows leaking into view
during the transition.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3208
2020-10-02 19:56:01 +02:00
Florian Müllner
6ce4605c3a workspacesView: Always clip to allocation
We couldn't clip workspaces views during the overview transition
when we used the "porthole" approach, but as view's allocation
now always matches the expected visible area, we can just apply
the clip unconditionally.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3208
2020-10-02 19:49:40 +02:00
Florian Müllner
432c2863ab dash: Restore icon's expected DND behavior
Commit ff3d32dd18 added a custom DashIcon subclass that disables
all DND methods from ancestors, including canceling the context
menu timeout and emitting the overview's item-drag-begin signal.

All we want is opting out of the parent's scale-and-fade behavior,
so override those methods instead.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3209
2020-10-02 15:41:04 +00:00
Carlos Garnacho
daa3ddac94 shell: Do not use stack-allocated ClutterEvents
All events should be allocated.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1451
2020-09-30 22:47:11 +02:00
Yosef Or Boczko
a9e5004eab Update Hebrew translation 2020-09-28 17:20:09 +00:00
Florian Müllner
84cff89205 docs: Remove obsolete ShellRecorder include
It joined the invisible choir, so trying to build with gtk-docs
enabled is currently broken (mea culpa for not having caught that
during distcheck).

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1448
2020-09-25 18:37:22 +02:00
Florian Müllner
494e628c38 dateMenu: Do not ellipsize date header
Currently the width of the calendar column is solely determined
by the calendar, while other elements are ellipsized as necessary.

While that is the desired behavior for the events-, world clocks-
and weather sections, we don't want to cut off the date in the
header. However switching to bold text made that more likely in
non-English locales or when using large text, so explicitly take
it into account for the width negotiation.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2230
2020-09-25 12:00:40 +02:00
yun341
3fb321fd21 authPrompt: set value of beginRequestType to 'DONT_PROVIDE_USERNAME'
Commit 809f820c introduct vmware SSO service to gnome-shell, the value
beginRequestType should be set to 'DONT_PROVIDE_USERNAME', otherwise
vmware sso will fail. This patch will fix it.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1443
2020-09-23 15:42:51 +00:00
Cheng-Chia Tseng
7a25d5fd89 Update Chinese (Taiwan) translation 2020-09-22 15:06:54 +00:00
Christopher Davis
498710c2ec CSS: Add border around avatars
Avatars in https://gitlab.gnome.org/Teams/Design/os-mockups/-/blob/master/lock-login/lock-screen.png
have a white circular border around them.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/379
2020-09-22 13:51:13 +00:00
Charles Monzat
30d8164ddc Update French translation 2020-09-22 11:59:10 +00:00
Florian Müllner
82da51d5a1 authPrompt: Hide password when insensitive
The purpose of password peeking is to spot and correct errors;
the latter isn't possible when the entry is non-editable, so
we can hide the password again while authentication is ongoing.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3138
2020-09-21 22:51:48 +02:00
Florian Müllner
76b03647b3 st/entry: Only handle primary/secondary icon clicks when reactive
Just like the internal ClutterText, the icon actors are part of the
entry. It therefore makes sense for the icons to not react to clicks
when the entry itself is non-reactive; again, just like the text.

That behavior is also consistent with icons in GTK entries.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3138
2020-09-21 22:51:48 +02:00
Bastien Nocera
3029119c9a subprojects: Update libgvc
This update is necessary to add support for recent UCM related changes
in ALSA and PulseAudio.

See https://gitlab.gnome.org/GNOME/libgnome-volume-control/-/merge_requests/10

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1444
2020-09-21 15:08:46 +02:00
Juliano de Souza Camargo
0dd355543d Update Portuguese translation 2020-09-20 02:40:32 +00:00
Yacine Bouklif
69901a783e Add Kabyle translation 2020-09-19 11:25:42 +00:00
Georges Basile Stavracas Neto
5014d7e9fc appDisplay: Disconnect from parental controls on destroy
BaseAppView not disconnecting from the 'app-filter-changed'
signal means parental controls may trigger callbacks on
a destroyed grid, which tries to access destroyed icons,
which spams the journal with stack traces.

Disconnect from parental controls when BaseAppView is destroyed.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1441
2020-09-16 14:57:02 -03:00
Juliano de Souza Camargo
ff9001d0a4 Update Portuguese translation 2020-09-15 17:50:42 +00:00
Daniel García Moreno
92d3c6e051 appDisplay: Don't iterate over all pages in page manager
In getAppPosition it's not needed to continue looking for an app in the
page manager if the app is found in a page.

This patch breaks the search loop just after the first ocurrence is
found.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1434
2020-09-15 09:33:53 +00:00
Florian Müllner
386d25e6f8 dbusServices/screencast: Add recordings to recent items
This is useful functionality that got lost when replacing the built-in
recorder with an external screencast service; bring it back.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3171
2020-09-14 21:15:13 +00:00
Florian Müllner
b2d6c11ec3 systemActions: Filter out empty (folded) terms
We split the search string into words using whitespace, while
GLib.tokenize_and_fold() splits on any non-alphanumeric characters.

That is, a valid search term like ',' will be tokenized as [], so
the original non-empty terms may get mapped to an empty array.

And as [].every() returns true for any condition[0], we end up
matching *all* system actions in that case. We want the exact
opposite and not return any results, so handle that case explicitly.

[0] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/every

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3169
2020-09-14 21:10:58 +00:00
Florian Müllner
59ade00b94 systemActions: Flatten folded search terms
GLib.str_tokenize_and_fold() returns an array rather than a string
(the "tokenize" bit), so flatten the folded search terms like we
do for keywords.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3169
2020-09-14 21:10:58 +00:00
Florian Müllner
de78ed980c Bump version to 3.38.0
Update NEWS.
2020-09-14 17:56:13 +02:00
Florian Müllner
8ddaa851a4 aggregateMenu: Move remote-access indicator to the front
It's best to not mix transient indicators with (probably) permanently
visible items, so move the remote-access indicator (which also handles
screencasts now) to the position of the old screen recorder icon.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1438
2020-09-14 17:13:27 +02:00
Rūdolfs Mazurs
7e0e551ef2 Update Latvian translation 2020-09-12 09:36:38 +00:00
Aron Xu
8745a61e40 Update zh_CN translation 2020-09-10 22:34:02 +08:00
Milo Casagrande
e1fa6b5348 Update Italian translation 2020-09-10 08:12:05 +00:00
Juliano Camargo
976fbabd54 Update Portuguese translation 2020-09-10 00:26:54 +00:00
Jiri Grönroos
e32ae0a332 Update Finnish translation 2020-09-09 21:59:48 +00:00
Claude Paroz
c68b1d7f97 Update French translation 2020-09-09 09:43:12 +02:00
Tim Sabsch
7991dd85f4 Update German translation 2020-09-09 06:06:49 +00:00
Andy Holmes
ee3eaf0c0e StAdjustment: note when 'changed' is not emitted
Like `GtkAdjustment`, `StAdjustment:changed` is not emitted for the
`value` property except when changed with `st_adjustment_set_values()`.

Note this behaviour in the signal documentation

closes https://gitlab.gnome.org/GNOME/gnome-shell/issues/3147
2020-09-07 15:58:14 -07:00
Alan Mortensen
26a2e389db Updated Danish translation 2020-09-07 19:58:28 +02:00
Dušan Kazik
35d9609247 Update Slovak translation 2020-09-07 09:56:15 +00:00
Balázs Úr
5b6d72552f Update Hungarian translation 2020-09-06 23:31:31 +00:00
Anders Jonsson
5970018b6c Update Swedish translation 2020-09-06 12:58:39 +00:00
Florian Müllner
2ab6edda03 Bump version to 3.37.92
Update NEWS.
2020-09-06 01:04:54 +02:00
Florian Müllner
7f402c1c6b workspace: Cap scaled floating size to target layout size
A window preview's floating geometry is scaled down according to the
workspace's allocation, while the layout geometry is computed directly
for the available space.

For previews that maintain their real size in the layout geometry,
that scaling leads to a distracting size bounce when transitioning
between both layouts.

Address that by not allowing the scaled floating size to drop below
that layout size (which is at most equal to the unscaled floating size).

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2968
2020-09-05 16:12:08 +00:00
Carlos Garnacho
497f10178c systemActions: Use PanelOrientationManaged to manage autorotation
Track this new org.gnome.Mutter.DisplayConfig property, so the
autorotation UI is shown/hidden according to both accelerometer
availability and touch-mode.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1311
2020-09-05 07:24:54 +00:00
Mitar
f7bcde6325 altTab: Support cycle-group cycling only over windows in the workspace
This is consistent with the filtering done for switch-group when
org.gnome.shell.app-switcher current-workspace-only is set to true.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3116
2020-09-04 19:48:33 +02:00
Jordi Mas
f9ad8a378d Update Catalan translation 2020-09-03 22:50:24 +02:00
Daniel van Vugt
206d1fa650 dash: Hide the tooltip when an item is clicked
So that when the 'Show Applications' button is clicked the icons don't
fly *through* the tooltip.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1423
2020-09-03 15:25:19 +00:00
Florian Müllner
b3f35912be dbusServices/screencast: Save under resolved file path
... instead of using the original template as file name.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3097
2020-09-02 16:28:48 +02:00
Daniel Mustieles
f8c043800b Updated Spanish translation 2020-09-02 14:50:26 +02:00
Thibault Martin
ec53df0dc3 Update French translation 2020-09-02 12:01:39 +00:00
Dušan Kazik
cf997b3230 Update Slovak translation 2020-09-02 11:52:36 +00:00
Florian Müllner
69e81e4511 Revert "appDisplay: Add drop shadow to icons"
The shadows are hardly visible in the darkened overview, but have
a noticeable impact on performance.

This reverts commit 4e195d789a.
2020-09-02 11:12:47 +02:00
Georges Basile Stavracas Neto
998e3e62ad appDisplay: Connect to GSettings after reading key
As per GSettings documentation, it is necessary to read a particular
key at least once before being able to connect to the corresponding
'changed::' signal.

Read the 'app-picker-layout' key before connecting to the changed
signal.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1428
2020-09-01 17:12:56 -03:00
Georges Basile Stavracas Neto
95645e155e appDisplay: Only emit layout-changed when not updating pages
It is wasteful to emit layout-changed when updating pages, because
the caller (AppDisplay) already has an updated state by the time
this is called.

Only emit 'layout-changed' if the GSettings notification doesn't
come from AppDisplay updating the pages.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1428
2020-09-01 16:45:54 -03:00
Georges Basile Stavracas Neto
f1bc87bf6d appDisplay: Redisplay on layout changes
This was an overlook from e1ea1d2954.

We never connected to the 'layout-changed' signal, which means
changing the GSettings externally wouldn't trigger a redisplay.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1428
2020-09-01 16:45:54 -03:00
Daniel Mustieles
f7886ac695 Updated Spanish translation 2020-09-01 11:04:12 +02:00
Florian Müllner
4e195d789a appDisplay: Add drop shadow to icons
The shadow is barely visible on dark backgrounds, but it's not
wrong to be consistent with Settings, Software and GNOME Classic.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3123
2020-08-31 21:04:39 +02:00
Марко Костић
838428838d Update Serbian translation 2020-08-31 08:25:35 +00:00
Kukuh Syafaat
1bc100c9fb Update Indonesian translation 2020-08-31 08:17:01 +00:00
Changwoo Ryu
a593f84f91 Update Korean translation 2020-08-30 07:46:04 +00:00
Fabio Tomat
6cab57b43c Update Friulian translation 2020-08-28 10:43:42 +00:00
Marek Černocký
8e936a271a Updated Czech translation 2020-08-28 10:11:00 +02:00
Kukuh Syafaat
eb0276a27d Update Indonesian translation 2020-08-27 02:59:04 +00:00
Aurimas Černius
360aeba9e3 Updated Lithuanian translation 2020-08-26 22:33:56 +03:00
Kukuh Syafaat
6550bca2ba Update Indonesian translation 2020-08-26 12:33:30 +00:00
Danial Behzadi
b8ca1fa7a1
Update Persian translation 2020-08-25 19:03:18 +01:00
Nathan Follens
6aed9485ec Update Dutch translation 2020-08-25 15:35:47 +00:00
Rafael Fontenelle
99bfe20316 Update Brazilian Portuguese translation 2020-08-25 01:53:19 +00:00
Zander Brown
35346e9511 Update British English translation 2020-08-24 18:20:23 +00:00
Yuri Chornoivan
77b725c3d2 Update Ukrainian translation 2020-08-24 17:17:19 +00:00
Florian Müllner
852303f71b Bump version to 3.37.91
Update NEWS.
2020-08-24 17:56:01 +02:00
Florian Müllner
ba804de15e status/bluetooth: Fix label for >1 connected devices
Eeeks, we want two strings here, not one with embedded double quotes.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3073
2020-08-24 15:37:08 +00:00
Zephaniah E. Loss-Cutler-Hull
093603b35e unlockDialog: Defend against absence of blur effect
widget.get_effect(...) can return null while locking the screen, resulting
in a TypeError. In this situation the screen ends up black with a cursor
but never going to sleep, and moving the mouse brings the old screen
contents up but does not allow unlocking.

unlockDialog.js assumes that widget.get_effect will return non-null,
but other places such as getWindowDimmer in windowManager.js go out of
their way to be more careful.

[smcv: Add commit message, remove hard tabs, add missing semicolon]

Resolves: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3071
Bug-Debian: https://bugs.debian.org/968440
2020-08-24 17:27:14 +02:00
Daniel Mustieles
b436f3ebcb Updated Spanish translation 2020-08-24 12:07:07 +02:00
Boyuan Yang
efea769bbe Update Chinese (China) translation 2020-08-23 15:14:07 +00:00
Matej Urbančič
0e1622af9e Updated Slovenian translation 2020-08-23 13:21:16 +02:00
Joonas Henriksson
b1f4ac10da
calendar: Vertically center align week numbers
The labels were previously aligned by using top-padding, which was
relative to font-size, and therefore didn't always align the text
correctly when font scaling was enabled.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1415
2020-08-21 21:40:22 +03:00
Björn Daase
2fc6384bca *: Fix spelling mistakes found by codespell
https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1416
2020-08-21 18:25:09 +00:00
Benjamin Berg
6ad9c99040 data: Fix description of org.gnome.Shell.target
The target is generic between X11 and wayland now, so remove the
reference to wayland.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1418
2020-08-20 08:11:11 +00:00
Benjamin Berg
56b6e65317 data: Only unset environment when the service actually ran
ExecStopPost= is executed even if ExecCondition= fails. As such, we need
to add a guard as we would otherwise clear environment variables on X11
sessions (rendering them utterly useless).

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1418
2020-08-20 08:11:11 +00:00
Goran Vidović
b80b22e78d Update Croatian translation 2020-08-19 22:33:40 +00:00
Goran Vidović
4917b0423b Update Croatian translation 2020-08-19 22:32:20 +00:00
Jiri Grönroos
abfbf1f972 Update Finnish translation 2020-08-18 19:11:26 +00:00
Danial Behzadi
283e50ab7c Update Persian translation 2020-08-18 17:19:24 +00:00
Will Thompson
1c0be1a36b polkitAgent: Add missing space to log string
In my journal, I have:

> JS LOG: polkitAuthenticationAgent: Received 2identities that can be
> used for authentication. Only considering one.

There should be a space after the number.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1413
2020-08-18 13:58:20 +00:00
Andre Moreira Magalhaes
00437750ed authPrompt: Properly get oVirt service name
Commit 809f820cd moved the definition of OVIRT_SERVICE_NAME to
'js/gdm/oVirt.js' but missed updating one occurrence. This
commit fixes it.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1414
2020-08-18 13:31:23 +00:00
sicklylife
32b1e8d0eb Update Japanese translation 2020-08-18 10:03:28 +00:00
sicklylife
51cdd34a4b Update Japanese translation 2020-08-18 09:46:34 +00:00
Emin Tufan Çetin
9dce262192 Update Turkish translation 2020-08-16 23:26:00 +00:00
Rafael Fontenelle
03cc09126f Update Brazilian Portuguese translation 2020-08-16 10:11:59 +00:00
Piotr Drąg
6d9c6ba577 Update Polish translation 2020-08-16 11:53:46 +02:00
Baurzhan Muftakhidinov
cbc24b4205 Update Kazakh translation 2020-08-15 18:11:21 +00:00
Akarshan Biswas
c85273fa6b Update Bengali (India) translation 2020-08-15 11:43:38 +00:00
Akarshan Biswas
d6d5c42e4b Update Bengali (India) translation 2020-08-14 15:48:13 +00:00
Florentina Mușat
fce14a43b9 Update Romanian translation 2020-08-14 15:48:03 +00:00
Georges Basile Stavracas Neto
7fcaf63291 appDisplay: Cache app ids in FolderView
Instead of reading a GSettings and building the app ids list
every single time FolderView needs to check for something,
cache it before redisplay and reuse this cached list everywhere.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1409
2020-08-13 23:28:51 +00:00
Florian Müllner
990c171bed networkAgent: Add missing Uint8Array => string conversion
When promisifying async operations in commit 764527c8c, the
finish function for read_line_async() was sneakily changed from
read_line_finish_utf8() to read_line_finish().

That is, the call returns a Uint8Array now that requires an
explicit conversion to string.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1407
2020-08-13 23:00:21 +00:00
Florian Müllner
112b139a9e cleanup: Remove old compatibility code
Since gjs moved to mozjs60, return values of int8_t arrays can
no longer be treated as strings. We originally made the conversion
conditional to keep working with the (then) stable gjs release.

That was two years ago and we require a more recent gjs nowadays,
so there's no good reason for keeping the old code path.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1407
2020-08-13 23:00:21 +00:00
Florian Müllner
923d926345 st: Remove invalid introspection annotation
(optional) is only valid for (out) or (inout) parameters (that are
marked as such).

However GError** arguments appear as throws="1" in the GIR anyway
instead of an explicit parameter, so we don't need any annotation
at all here.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1408
2020-08-13 22:44:45 +00:00
Florian Müllner
3c6f59ae6d st: Fix typo in doc comment
Spotted by g-ir-scanner.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1408
2020-08-13 22:44:44 +00:00
Fran Dieguez
84bbedb3b3 Update Galician translations 2020-08-14 00:39:36 +02:00
Georges Basile Stavracas Neto
f541562acc iconGrid: Properly remove pages
When the last item of an IconGridLayout page is removed,
the page itself is removed too. However, the indexes of
items of next pages are not updated, which mess up the
layout manager state.

Update the page index of the items at forward pages when
removing a page.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1406
2020-08-13 18:15:11 -03:00
Jonas Ådahl
beddbc0583 st/test-theme: Use stage from mutter
Clutter application style stages not supported anymore.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1359
2020-08-13 12:46:22 +00:00
Daniel Mustieles
2f840174cb Updated Spanish translation 2020-08-13 10:41:32 +02:00
Daniel Mustieles
015559a207 Updated Spanish translation 2020-08-13 10:33:26 +02:00
Jordi Mas
98d6c4e8dd Update Catalan translation 2020-08-13 09:26:56 +02:00
Fran Dieguez
1675b54738 Updated Galician translations 2020-08-13 01:40:06 +02:00
Michael Catanzaro
44cbd1e718 libcroco: Limit recursion in block and any productions (CVE-2020-12825)
If we don't have any limits, we can recurse forever and overflow the
stack.

This is per https://gitlab.gnome.org/Archive/libcroco/-/issues/8

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1404
2020-08-12 15:06:27 -05:00
Florian Müllner
0dc1e1e99a perf: Add basic run tests
While the performance framework was originally written to collect
performance metrics, driving the shell by an automated script is
also useful to ensure that basic functionality is working.

Add such a basic test, initially checking top bar menus, notifications
and the overview.

Eventually it would be nice to separate the automatic scripting from
gathering performance metrics, but IMHO that can wait until we switch
from gjs' custom imports system to ES modules.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1396
2020-08-12 15:43:39 +00:00
Florian Müllner
1029e683d3 perf-tool: Expose --x11 option
Running with the X11 backend is no longer as easy as not specifying
wayland, so expose mutter's --x11 option to allow enforcing the X11
backend for testing.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1396
2020-08-12 15:43:38 +00:00
Florian Müllner
cf1d09b482 environment: Mark transitions as "work"
global.run_at_leisure() is used from automated scripts to schedule
a callback when the shell is idle. However since we moved away from
Tweener, animations are no longer taken into account; fix this by
marking transitions as "work" if the convenience ease() functions
are used.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1396
2020-08-12 15:43:38 +00:00
Florian Müllner
a436226266 scripting: Switch to standard async/await pattern
The original scripting framework was based on SpiderMonkey's
pre-standard generators, and was simply translated to the
corresponding standard syntax when updating it to work with
recent JS versions.

We can do even better by using the standard async/await pattern
instead of generators/yield.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1396
2020-08-12 15:43:38 +00:00
Florian Müllner
33ff3dc44f Bump version to 3.37.90
Update NEWS.
2020-08-11 17:41:51 +02:00
Asier Sarasua Garmendia
2e77ed712c Update Basque translation 2020-08-11 14:01:34 +00:00
Florian Müllner
9d6ccb6072 dbusServices/screencast: Quote filename in pipeline
Otherwise Gst fails to parse the pipeline string if the filename
contains spaces, as all words following the first are interpreted
as additional Gst elements.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1403
2020-08-11 11:50:44 +00:00
Yuri Chornoivan
5091eab280 Update Ukrainian translation 2020-08-11 06:24:22 +00:00
Michael Catanzaro
6d38bc69ca endSessionDialog: default to not installing updates on low battery
If the user's battery power is low, we should not check the checkbox to
install updates by default. Rationale: if the user's battery is not low,
it's very unlikely to run out during a normal system upgrade. Low
battery is defined as any level below 30%, matching our battery status
indicator.

We'll also change the battery warning to only display when battery is
actually low. However, we will still always warn on battery for full
system upgrades, since these are expected to take a long time.

Future improvement: it would be nice to make the checkbox insensitive
when on low power. However, I don't think we currently have a proper
style for insensitive checkboxes. I was unable to make it look good.

Lastly, note that I did not test this on a laptop. I tested this by
mocking the return values of _isDischargingBattery() and
_isBatteryLow().

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2717
2020-08-10 23:55:14 +00:00
Emin Tufan Çetin
adc8b1ba89 Update Turkish translation 2020-08-10 22:14:14 +00:00
Yuri Chornoivan
38777b41a5 Update Ukrainian translation 2020-08-10 18:08:16 +00:00
Florian Müllner
263320696e status/system: Add separate 'Restart' item
A side effect of removing the action buttons in favor of a regular
submenu is that we are a lot less constrained by size. So instead
of lumping "Restart" in with "Power Off", make it a separate menu
item.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2202
2020-08-10 15:36:26 +00:00
Florian Müllner
e6153bb578 status/system: Swap power- and user-related items in session menu
Quoting Allan:
"It's been niggling me that log out is closest to hand,
as opposed to suspend"

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2202
2020-08-10 15:36:26 +00:00
Florian Müllner
c723a1b72a status/system: Use new indentation style
... before moving stuff around.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2202
2020-08-10 15:36:26 +00:00
Florian Müllner
0b56416d30 sytemActions: Add separate 'restart' action
In order to split restart and power-off in the system menu, we need
to separate the underlying actions as well.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2202
2020-08-10 15:36:26 +00:00
Florian Müllner
0c5716b018 systemActions: Reindent properties
... so we can add another property using the new coding style
without making surrounding code terribly inconsistent.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2202
2020-08-10 15:36:26 +00:00
Florian Müllner
1fa1333e13 endSessionDialog: Remove "Restart" option from shutdown dialog
Restart will be exposed as a separate action instead of being part
of the shutdown dialog.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2202
2020-08-10 15:36:26 +00:00
Florian Müllner
6edd3c4b93 endSessionDialog: Support updates in restart dialog
We will split off restart from the existing shutdown dialog, and
instead offer it as a separate menu item in the session submenu.
But before doing that, make sure that the existing restart dialog
exposes the same feature set as power off.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2202
2020-08-10 15:36:26 +00:00
Florian Müllner
72a8522a10 endSessionDialog: Reindent dialog configs
We are about to make some changes, so make them conform to the
new indentation style first.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2202
2020-08-10 15:36:26 +00:00
Rafael Fontenelle
b91903555a Update Brazilian Portuguese translation 2020-08-10 11:53:38 +00:00
Emre Uyguroglu
6b78f58a75 keyboard: Fix missing icons in Keypad
This is more fallout from commit 57669bca1b.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3007
2020-08-09 15:59:34 +02:00
Yuri Chornoivan
e62c0757c3 Update Ukrainian translation 2020-08-08 14:57:38 +00:00
Andy Holmes
9168f6055e St Documentation: add and improve documentation for public classes
Much of St is undocumented, aside from input/output arguments. This is
no doubt because a lot of it parallels Gtk closely, but is worth
improving since many new programmers are not familiar with Gtk.

closes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2983
2020-08-08 11:26:41 +00:00
Florian Müllner
8993de76f0 ci: Remove pot file test
A recent Docker image update broke the test, as xgettext now prints
the following warning:

warning: a fallback ITS rule file '/usr/share/gettext-0.21/its/metainfo.its'
is used; it may not be in sync with the upstream

That is completely unrelated to what the test is meant to catch and
could be fixed by adding appstream to the image, but considering that

 - the test didn't actually catch the last template string regression
 - we no longer allow template strings in files that include translatable
   strings (and enforce that with a CI job)
 - as of gettext 0.20.2, the template handling really really is fixed
   (we'll see)

let's remove the test rather than piling up more stuff in the container
image.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1399
2020-08-07 21:52:00 +02:00
Emin Tufan Çetin
01fedeed8f Update Turkish translation 2020-08-07 14:35:48 +00:00
Jonas Ådahl
757e4b6731 shell-screenshot: Change to use clutter_stage_paint_to*() API
This eliminates the need to wait for redraws, drawing cursors, and
stiching together cairo images in case the screenshot covers multiple
monitors.

All of that is now handled by mutter itself.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1383
2020-08-06 16:26:59 +00:00
Hans de Goede
c2b70101f2 endSessionDialog: Support rebooting into the bootloader menu aka ("Boot Options")
This implements the "Alt" behavior for the "Reboot" button as outlined in
the design here: https://wiki.gnome.org/Design/OS/BootOptions

Note I've tried implemeting this with the AltSwitcher class from
js/ui/status/system.js first, but that puts the button in a St.Bin()
which causes the button to think it is the only button on the dialog
and makes it have rounded corners on both of its bottom corners.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/199
2020-08-06 15:14:45 +02:00
Hans de Goede
9d4a3a614d endSessionDialog: Immediately add buttons to the dialog
Immediately add buttons to the dialog instead of first building an
array of button-info structs.

This is a preparation patch for adding support changing the "Reboot"
button into a "Boot Options" button when Alt is pressed.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/199
2020-08-06 15:14:45 +02:00
Hans de Goede
2af7264cff LoginManager: Add canRebootToBootLoaderMenu and setRebootToBootLoaderMenu methods
Add wrappers for the new logind Manager CanRebootToBootLoaderMenu and
SetRebootToBootLoaderMenu dbus methods.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/199
2020-08-06 15:14:42 +02:00
Florian Müllner
a96c8d91b5 ci: Explicitly specify job dependencies
We can speed up CI a bit by allowing build jobs to run in parallel
with review jobs, and don't have test jobs wait for the flatpak build.

See https://gitlab.gnome.org/help/ci/yaml/README.md#needs for details.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1391
2020-08-04 14:12:11 +00:00
Olivier Fourdan
3541a57570 cleanup: remove controversial naming
Replace "whitelist" and "blacklist" with "allow" and "deny" in variable
naming, which better represents the purpose of those variables.

There is no functional change.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1393
2020-08-04 13:24:50 +02:00
Jonas Dreßler
18155fc6ea st/private: Multiply position in fb coordinates with resource scale
The framebuffer we use for rendering shadows is scaled by the resource
scale, that means we also need to offset coordinates when translating
them to the framebuffers coordinate system.

So far we forgot to do that when translating the framebuffer using the
position of the actor, which lead to small rendering bugs of
text-shadows for actors allocated at non-zero origins. To fix that,
simply multiply those positions with the actors resource scale.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1390
2020-08-03 21:57:50 +00:00
Jonas Dreßler
b83c93ad62 appDisplay: Return false in acceptDrop when not accepting the drop
Fix what is probably a copy-paste error and return false instead of a
CONTINUE DragMotionResult which is only meant for dragMotion events, not
drop events. This makes sure we don't create a folder when dropping an
app over the drag leeways of another icon.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1389
2020-08-03 21:48:44 +00:00
Florian Müllner
d0dab5a6d1 style: Swap text-align in RTL locales
https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3037
2020-08-03 16:26:37 +00:00
Florian Müllner
c9708b140c status/network: Use D-Bus to launch Settings panels
For more obscure network configurations, we need to launch the
corresponding Settings panel with additional parameters, so we
cannot simply launch the .desktop file.

However we can do better than spawning a command line: Control center
exposes an application action we can use instead, so the process is
launched with the appropriate activation environment and startup
notification support.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1385
2020-08-03 16:17:40 +00:00
Andre Moreira Magalhaes
dd846f1ba2 rfkill: Always sync state on construction
This fixes an issue where the indicator can be out of sync until the
RfkillManager (used by it) properties change.

The problem is that multiple instances of the indicator will use
the same RfkillManager instance (getRfkillManager() returns a singleton)
that only guarantees to emit the changed signal in two scenarios:
when the D-Bus proxy connects and when the proxy properties change.

If by the time an indicator is instantiated the RfkillManager's D-Bus
proxy is already connected, that indicator would only sync its state
when the RfkillManager properties change.

Let's fix that by always syncing the state on construction - in the worst
case scenario the RfkillManager's D-Bus proxy won't have connected yet
and the indicator state will be temporarily out of sync but once it gets
connected the indicator will sync again with the correct state.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1386
2020-08-02 19:57:11 +00:00
Piotr Drąg
ec3653240a Update POTFILES.skip
It silences false positives on https://l10n.gnome.org/module/gnome-shell/

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1387
2020-08-01 14:33:13 +02:00
Benjamin Berg
b689b35b7d data: Place the shell into session.slice when using systemd
This way we conform more to https://systemd.io/DESKTOP_ENVIRONMENTS

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/895
2020-07-31 13:53:31 +00:00
Benjamin Berg
01a927f388 windowManager: Wait for X11 services using systemd
To do this, we now wait for the start/stop job to complete. We also have
two targets in gnome-session to ensure that everything is working as
expected.

In order to start the services, we simply request the
gnome-session-x11-services-ready.target unit, and wait for it to become
available. To stop, we use the gnome-session-x11-services.target unit
which should stop all services in a way that is entirely race free.

This requires both gnome-session and gnome-settings-daemon changes to
work (which are in the corresponding merge requests).

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/895
2020-07-31 13:53:31 +00:00
Benjamin Berg
41d5b1455f data: Create generic org.gnome.Shell.target
Move the GNOME shell service file adapation for x11/wayland into the
target/service files. This means that the session definition can simply
pull in org.gnome.Shell.target, without having to care about whether it
is starting an X11 or wayland session.

Note that this currently requires fork'ing to do the test. This will
however not be needed in the long term when ConditionEnvironment becomes
available (see https://github.com/systemd/systemd/pull/15817).

We technically do not need to use template units. But doing so means
that the unit can be translated to the app id more easily (though it is
not yet completely clear how this should look like in the long term).

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/895
2020-07-31 13:53:31 +00:00
Benjamin Berg
b710c6e275 data: Remove unused, commented and obsolete Conflicts lines
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/895
2020-07-31 13:53:31 +00:00
Benjamin Berg
4c9f42eea9 data: Use org.gnome.Shell prefix for systemd units
In general we want to move towards using reverse domain names for
systemd units. Doing this also means we have a consistent name between
desktop file and systemd unit, allowing us to create a generator that
pulls in the unit as defined in the sessions RequiredComponents.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/895
2020-07-31 13:53:31 +00:00
Jonas Ådahl
2b0731ab81 Move screencasting into a separate service process
Move the screencasting into a separate D-Bus service process, using
PipeWire instead of Clutter API. The service is implemented in
Javascript using the dbusService.js helper, and implements the same API
as was done by screencast.js and the corresponding C code.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1372
2020-07-31 10:51:12 +02:00
Jonas Ådahl
a9b803f075 introspect: Introspect screen size
To be used by the screen cast service.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1372
2020-07-31 10:51:12 +02:00
Jonas Ådahl
73436b5276 dbusService: Queue shutdown check on startup
If something started the service, but crashed before managing to make a
method call, we'd end up with the service running indefinitely. Fix this
by queueing a shutdown check immediately on startup.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1372
2020-07-31 10:51:12 +02:00
Jonas Ådahl
20dcc8aa87 status/remote-access: Visualize recordings as screen recording
If a remote access is marked as a recording, visualize it the same way
as a built in recording. Also don't stop it if there is an actual screen
sharing going on, so that one can use a plain "recording" while still
disabling what is an actual screen sharing.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1372
2020-07-31 10:51:12 +02:00
Carlos Garnacho
fdac0602db background: Mark pattern backgrounds as loaded
Otherwise we don't let GNOME Shell startup to proceed. Noticed
by accidentally running on the memory GSettings backend.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1381
2020-07-30 11:48:13 +02:00
Emin Tufan Çetin
e5272c84d7 Update Turkish translation 2020-07-29 21:57:19 +00:00
Florian Müllner
1812db7aa8 panelMenu: Destroy menu before chaining up
This avoid some (harmless but annoying) warnings, and is closer to
the original code prior to commit fc342fe8c5 and 557b232c89.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3022
2020-07-29 19:40:54 +00:00
Florian Müllner
260405a49e popupMenu: Ungrab when removing active menu
While we do have some handling for removing the active menu, it has
been a no-op for years. The bit that we really care about from the
PopupMenuManager's point of view is the existing grab though. Drop
that instead of calling _closeMenu() directly; ungrabbing will still
call the method indirectly, and it will still be a no-op :-)

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3022
2020-07-29 19:40:54 +00:00
Daniel García Moreno
71d37bffdf util: Remove shell_util_get_transformed_allocation
This helper function could be replaced with the new
clutter_actor_get_transformed_extents, that does the same.

See https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1386

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1380
2020-07-29 18:09:53 +02:00
Daniel Mustieles
95436a08b5 Updated Spanish translation 2020-07-29 12:42:11 +02:00
Ray Strode
13137aad9d loginDialog: Reset auth prompt on vt switch before fade in
At the moment, if a user switches to the login screen vt,
the login screen fades in whatever was on screen prior, and
then does a reset.

It makes more sense to reset first, so we fade in what the
user is going to interact with instead of what they interacted
with before.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2997
2020-07-27 16:18:44 -04:00
Florian Müllner
71f55643b2 layout: Only show ripple animation when overview was toggled
On X11, clients can grab keyboard on pointer (for example for popup
menus), and as a result the pushModal() call when opening the overview
fails.

However when the hot corner was used to toggle the overview, we still
show the ripple animation in that case, which is confusing as the action
did not actually happen.

Fix this by only showing the ripples if the overview is animating after
calling toggle(), as that should be a reliable indication of whether
the call was successful.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3005
2020-07-27 13:13:14 +00:00
Florian Müllner
5c550daecb backgroundManager: Always emit 'loaded' signal
As backgrounds are cached, it is possible that we never emit the
'loaded' signal added in commit f386103bc1. We are relying on the
signal though, so do the same as Background and emit the signal
from an idle if the background was already loaded.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1371
2020-07-22 11:02:24 +00:00
Jordi Mas
4e0492c517 Update Catalan translation 2020-07-22 08:47:17 +02:00
Michael Catanzaro
f386103bc1 Delay login animation until after wallpaper has loaded
Currently, the login animation can occur before the user's wallpaper has
been loaded. When this happens, we wind up displaying a solid blue
background for half a second or so before the proper background is
displayed. This looks jarring and bad. It's great that we can start
GNOME quickly, but starting up before the wallpaper is ready is *too*
quickly.

I've been meaning to fix this since 2014. Better late than never! We can
just have BackgroundManager emit a loaded signal the first time it loads
its first background, and have the startup animation code wait for that
before proceeding.

Some of this code is by Florian, who helped with promisifying. Thanks!

https://bugzilla.gnome.org/show_bug.cgi?id=734996
2020-07-21 20:25:31 -05:00
Olivier Fourdan
26e66aa4fd popupMenu: Handle keypress if numlock is enabled
On Wayland, navigating menus with the keyboard would not open drop-down
menus when NumLock is enabled.

That's old issue (gnome-shell#550) that was not completely fixed with
commit 88556226 because the lock mask needs to be filtered out in
_onKeyPress() as well.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/550
2020-07-21 16:38:15 +02:00
420 changed files with 71195 additions and 41537 deletions

View File

@ -1,3 +1,8 @@
extends:
- ./lint/eslintrc-gjs.yml
- ./lint/eslintrc-shell.yml
overrides:
- files:
- js/ui/init.js
parserOptions:
sourceType: module

View File

@ -1,133 +1,288 @@
include: 'https://gitlab.gnome.org/GNOME/citemplates/raw/master/flatpak/flatpak_ci_initiative.yml'
include:
- remote: 'https://gitlab.gnome.org/GNOME/citemplates/raw/HEAD/flatpak/flatpak_ci_initiative.yml'
- remote: 'https://gitlab.freedesktop.org/freedesktop/ci-templates/-/raw/bbe5232986c9b98eb1efe62484e07216f7d1a4df/templates/fedora.yml'
- remote: 'https://gitlab.freedesktop.org/freedesktop/ci-templates/-/raw/bbe5232986c9b98eb1efe62484e07216f7d1a4df/templates/ci-fairy.yml'
stages:
- review
- build
- test
- deploy
- pre_review
- prep
- review
- build
- test
- analyze
- deploy
default:
# Cancel jobs if newer commits are pushed to the branch
interruptible: true
# Auto-retry jobs in case of infra failures
retry:
max: 1
when:
- 'runner_system_failure'
- 'stuck_or_timeout_failure'
- 'scheduler_failure'
- 'api_failure'
variables:
BUNDLE: "extensions-git.flatpak"
JS_LOG: "js-report.txt"
POT_LOG: "pot-update.txt"
FDO_UPSTREAM_REPO: GNOME/gnome-shell
BUNDLE: "extensions-git.flatpak"
JS_LOG: "js-report.txt"
LINT_LOG: "eslint-report.xml"
LINT_MR_LOG: "eslint-mr-report.xml"
.only_default: &only_default
only:
- branches
- tags
- merge_requests
image: registry.gitlab.gnome.org/gnome/mutter/fedora/34:x86_64-2021-09-04.1
workflow:
rules:
- if: '$CI_MERGE_REQUEST_IID'
- if: '$CI_COMMIT_TAG'
- if: '$CI_COMMIT_BRANCH'
.pipeline_guard: &pipeline_guard
rules:
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
- if: '$CI_COMMIT_TAG'
- if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH'
- if: '$CI_COMMIT_BRANCH =~ /^gnome-[0-9-]+$/'
- when: 'manual'
.gnome-shell.fedora:34:
variables:
FDO_DISTRIBUTION_VERSION: 34
FDO_DISTRIBUTION_TAG: '2021-08-12.0'
FDO_DISTRIBUTION_PACKAGES: >
findutils mozjs78-devel nodejs npm meson
pkgconfig(gio-2.0) pkgconfig(gio-unix-2.0)
pkgconfig(gnome-autoar-0) pkgconfig(json-glib-1.0)
FDO_DISTRIBUTION_EXEC: |
# For static analysis with eslint
npm install -g eslint eslint-plugin-jsdoc &&
dnf group install -y 'Development Tools' \
'C Development Tools and Libraries' &&
./.gitlab-ci/install-meson-project.sh \
-Dman=false \
https://gitlab.gnome.org/GNOME/gnome-shell.git \
3.38.0 \
subprojects/extensions-tool/ \
./generate-translations.sh &&
dnf clean all
check_commit_log:
image: registry.gitlab.gnome.org/gnome/mutter/master:v4
stage: review
variables:
GIT_DEPTH: "100"
script:
- ./.gitlab-ci/check-commit-log.sh
only:
- merge_requests
extends:
- .fdo.ci-fairy
stage: pre_review
variables:
GIT_DEPTH: "100"
script:
- if [[ x"$CI_MERGE_REQUEST_TARGET_BRANCH_NAME" != "x" ]] ;
then
ci-fairy check-commits --junit-xml=commit-message-junit-report.xml ;
else
echo "Not a merge request" ;
fi
<<: *pipeline_guard
artifacts:
expire_in: 1 week
paths:
- commit-message-junit-report.xml
reports:
junit: commit-message-junit-report.xml
check-merge-request:
extends:
- .fdo.ci-fairy
stage: pre_review
script:
- if [[ x"$CI_MERGE_REQUEST_TARGET_BRANCH_NAME" != "x" ]] ;
then
ci-fairy check-merge-request --require-allow-collaboration --junit-xml=check-merge-request-report.xml ;
else
echo "Not a merge request" ;
fi
<<: *pipeline_guard
artifacts:
expire_in: 1 week
paths:
- check-merge-request-report.xml
reports:
junit: check-merge-request-report.xml
build-fedora-container:
extends:
- .fdo.container-build@fedora@x86_64
- .gnome-shell.fedora:34
stage: prep
js_check:
image: registry.gitlab.gnome.org/gnome/gnome-shell/extension-ci:v2
stage: review
script:
- find js -name '*.js' -exec js68 -c -s '{}' ';' 2>&1 | tee $JS_LOG
- (! grep -q . $JS_LOG)
<<: *only_default
artifacts:
paths:
- ${JS_LOG}
when: on_failure
extends:
- .fdo.distribution-image@fedora
- .gnome-shell.fedora:34
stage: review
script:
- find js -name '*.js' $(printf "! -wholename %s " $(cat .jscheckignore)) -exec js78 -c '{}' ';' 2>&1 | tee $JS_LOG
- (! grep -q . $JS_LOG)
artifacts:
paths:
- ${JS_LOG}
when: on_failure
eslint:
image: registry.gitlab.gnome.org/gnome/gnome-shell/extension-ci:v2
stage: review
script:
- ./.gitlab-ci/run-eslint.sh
<<: *only_default
artifacts:
paths:
- reports
when: always
extends:
- .fdo.distribution-image@fedora
- .gnome-shell.fedora:34
stage: review
script:
- export NODE_PATH=$(npm root -g)
- ./.gitlab-ci/run-eslint --output-file ${LINT_LOG} --format junit
artifacts:
reports:
junit: ${LINT_LOG}
when: always
potfile_check:
image: registry.gitlab.gnome.org/gnome/gnome-shell/extension-ci:v2
stage: review
script:
- ./.gitlab-ci/check-potfiles.sh
<<: *only_default
eslint_mr:
extends:
- .fdo.distribution-image@fedora
- .gnome-shell.fedora:34
stage: review
script:
- export NODE_PATH=$(npm root -g)
- ./.gitlab-ci/run-eslint --output-file ${LINT_MR_LOG} --format junit
--remote ${CI_MERGE_REQUEST_PROJECT_URL}.git
--branch ${CI_MERGE_REQUEST_TARGET_BRANCH_NAME}
only:
- merge_requests
artifacts:
reports:
junit: ${LINT_MR_LOG}
when: always
potfile_c_check:
extends:
- .fdo.distribution-image@fedora
- .gnome-shell.fedora:34
stage: review
script:
- ./.gitlab-ci/check-potfiles.sh
potfile_js_check:
extends:
- .fdo.distribution-image@fedora
- .gnome-shell.fedora:34
stage: review
script:
- js78 -m .gitlab-ci/check-potfiles.js
no_template_check:
image: registry.gitlab.gnome.org/gnome/gnome-shell/extension-ci:v2
stage: review
script:
- ./.gitlab-ci/check-template-strings.sh
<<: *only_default
extends:
- .fdo.distribution-image@fedora
- .gnome-shell.fedora:34
stage: review
script:
- ./.gitlab-ci/check-template-strings.sh
build:
image: registry.gitlab.gnome.org/gnome/mutter/master:v4
stage: build
before_script:
- .gitlab-ci/checkout-mutter.sh
- meson mutter mutter/build --prefix=/usr -Dtests=false
- ninja -C mutter/build install
script:
- meson . build -Dbuiltype=debugoptimized -Dman=false --werror
- ninja -C build
- ninja -C build install
<<: *only_default
artifacts:
expire_in: 1 day
paths:
- mutter
- build
stage: build
needs: ["check_commit_log"]
before_script:
- .gitlab-ci/checkout-mutter.sh
- meson mutter mutter/build --prefix=/usr
- meson install -C mutter/build
script:
- meson . build -Dbuildtype=debugoptimized -Dman=false --werror
- meson compile -C build
- meson install -C build
artifacts:
expire_in: 1 day
paths:
- mutter
- build
test:
image: registry.gitlab.gnome.org/gnome/mutter/master:v4
stage: test
variables:
XDG_RUNTIME_DIR: "$CI_PROJECT_DIR/runtime-dir"
NO_AT_BRIDGE: "1"
before_script:
- ninja -C mutter/build install
script:
- dbus-run-session -- xvfb-run meson test -C build --no-rebuild
<<: *only_default
artifacts:
expire_in: 1 day
paths:
- build/meson-logs/testlog.txt
when: on_failure
stage: test
needs: ["build"]
variables:
XDG_RUNTIME_DIR: "$CI_PROJECT_DIR/runtime-dir"
NO_AT_BRIDGE: "1"
before_script:
- meson install -C mutter/build
script:
- dbus-run-session -- xvfb-run meson test -C build --no-rebuild
artifacts:
expire_in: 1 day
paths:
- build/meson-logs/testlog.txt
reports:
junit: build/meson-logs/testlog.junit.xml
when: on_failure
test-pot:
image: registry.gitlab.gnome.org/gnome/mutter/master:v4
stage: test
before_script:
- ninja -C mutter/build install
script:
# Check that pot files are generated correctly:
# https://savannah.gnu.org/bugs/?50920#comment5
- ninja -C build gnome-shell-pot 2>&1 | awk '
BEGIN { start=0; }
start==1 { print $0; }
/gnome-shell-pot/ { start=1; }
' | tee $POT_LOG
- (! grep -q . $POT_LOG)
<<: *only_default
test-coverity:
rules:
- if: '$CI_PIPELINE_SOURCE == "schedule" && $GNOME_SHELL_SCHEDULED_JOB == "coverity"'
when: always
- when: manual
needs: ["build"]
stage: analyze
allow_failure: true
before_script:
- meson install -C mutter/build
script:
- .gitlab-ci/download-coverity-tarball.sh
- CC=clang meson coverity-build -Dman=false
- ./coverity/cov-analysis-linux64-*/bin/cov-build --fs-capture-search js --dir cov-int meson compile -C coverity-build
- tar czf cov-int.tar.gz cov-int
- curl https://scan.coverity.com/builds?project=GNOME+Shell
--form token=$COVERITY_TOKEN --form email=carlosg@gnome.org
--form file=@cov-int.tar.gz --form version="`git describe --tags`"
--form description="GitLab CI build"
cache:
key: coverity-tarball
paths:
- coverity
flatpak:
stage: build
variables:
SUBPROJECT: "subprojects/extensions-app"
# Your manifest path
MANIFEST_PATH: "$SUBPROJECT/build-aux/flatpak/org.gnome.Extensions.json"
RUNTIME_REPO: "https://nightly.gnome.org/gnome-nightly.flatpakrepo"
FLATPAK_MODULE: "gnome-extensions-app"
APP_ID: "org.gnome.Extensions"
extends: .flatpak
<<: *only_default
stage: build
needs: ["check_commit_log"]
variables:
SUBPROJECT: "subprojects/extensions-app"
# Your manifest path
MANIFEST_PATH: "$SUBPROJECT/build-aux/flatpak/org.gnome.Extensions.json"
RUNTIME_REPO: "https://nightly.gnome.org/gnome-nightly.flatpakrepo"
FLATPAK_MODULE: "gnome-extensions-app"
APP_ID: "org.gnome.Extensions.Devel"
extends: .flatpak
nightly:
extends: '.publish_nightly'
variables:
BUNDLES: '$BUNDLE'
dist:
variables:
XDG_RUNTIME_DIR: "$CI_PROJECT_DIR/runtime-dir"
NO_AT_BRIDGE: "1"
stage: deploy
needs: ["build"]
before_script:
- meson install -C mutter/build
- mkdir -m 700 $XDG_RUNTIME_DIR
script:
- dbus-run-session xvfb-run meson dist -C build
rules:
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
changes:
- "**/meson.build"
- meson/*
dist-tarball:
extends: dist
artifacts:
expose_as: 'Get tarball here'
paths:
- build/meson-dist/$CI_PROJECT_NAME-$CI_COMMIT_TAG.tar.xz
rules:
- if: '$CI_COMMIT_TAG'

View File

@ -1,24 +0,0 @@
# Rebuild and push with
#
# cd .gitlab-ci/
# podman build --format docker --no-cache -t registry.gitlab.gnome.org/gnome/gnome-shell/extension-ci:v2 .
# podman push registry.gitlab.gnome.org/gnome/gnome-shell/extension-ci:v2
#
FROM registry.fedoraproject.org/fedora:32
RUN dnf -y update && dnf -y upgrade && \
dnf install -y 'dnf-command(copr)' git && \
# For syntax checks with `find . -name '*.js' -exec js68 -c -s '{}' ';'`
dnf install -y findutils mozjs68-devel && \
# For static analysis with eslint
dnf install -y nodejs && \
npm install -g eslint && \
# Shameless plug for my own tooling; useful for generating zip
dnf copr enable -y fmuellner/gnome-shell-ci && \
dnf install -y gnome-extensions-tool meson && \
dnf clean all

View File

@ -1,31 +0,0 @@
#!/usr/bin/env bash
if [ -z "$CI_MERGE_REQUEST_TARGET_BRANCH_NAME" ]; then
echo Cannot review non-merge request
exit 1
fi
git fetch $CI_MERGE_REQUEST_PROJECT_URL.git $CI_MERGE_REQUEST_TARGET_BRANCH_NAME
branch_point=$(git merge-base HEAD FETCH_HEAD)
commits=$(git log --format='format:%H' $branch_point..$CI_COMMIT_SHA)
if [ -z "$commits" ]; then
echo Commit range empty
exit 1
fi
function commit_message_has_url() {
commit=$1
commit_message=$(git show -s --format='format:%b' $commit)
echo "$commit_message" | grep -qe "\($CI_MERGE_REQUEST_PROJECT_URL/\(-/\)\?\(issues\|merge_requests\)/[0-9]\+\|https://bugzilla.gnome.org/show_bug.cgi?id=[0-9]\+\)"
return $?
}
for commit in $commits; do
if ! commit_message_has_url $commit; then
echo "Missing merge request or issue URL on commit $(echo $commit | cut -c -8)"
exit 1
fi
done

View File

@ -0,0 +1,202 @@
const gettextFuncs = new Set([
'_',
'N_',
'C_',
'NC_',
'dcgettext',
'dgettext',
'dngettext',
'dpgettext',
'gettext',
'ngettext',
'pgettext',
]);
function dirname(file) {
const split = file.split('/');
split.pop();
return split.join('/');
}
const scriptDir = dirname(import.meta.url);
const root = dirname(scriptDir);
const excludedFiles = new Set();
const foundFiles = new Set()
function addExcludes(filename) {
const contents = os.file.readFile(filename);
const lines = contents.split('\n')
.filter(l => l && !l.startsWith('#'));
lines.forEach(line => excludedFiles.add(line));
}
addExcludes(`${root}/po/POTFILES.in`);
addExcludes(`${root}/po/POTFILES.skip`);
function walkAst(node, func) {
func(node);
nodesToWalk(node).forEach(n => walkAst(n, func));
}
function findGettextCalls(node) {
switch(node.type) {
case 'CallExpression':
if (node.callee.type === 'Identifier' &&
gettextFuncs.has(node.callee.name))
throw new Error();
if (node.callee.type === 'MemberExpression' &&
node.callee.object.type === 'Identifier' &&
node.callee.object.name === 'Gettext' &&
node.callee.property.type === 'Identifier' &&
gettextFuncs.has(node.callee.property.name))
throw new Error();
break;
}
return true;
}
function nodesToWalk(node) {
switch(node.type) {
case 'ArrayPattern':
case 'BreakStatement':
case 'CallSiteObject': // i.e. strings passed to template
case 'ContinueStatement':
case 'DebuggerStatement':
case 'EmptyStatement':
case 'Identifier':
case 'Literal':
case 'MetaProperty': // i.e. new.target
case 'Super':
case 'ThisExpression':
return [];
case 'ArrowFunctionExpression':
case 'FunctionDeclaration':
case 'FunctionExpression':
return [...node.defaults, node.body].filter(n => !!n);
case 'AssignmentExpression':
case 'BinaryExpression':
case 'ComprehensionBlock':
case 'LogicalExpression':
return [node.left, node.right];
case 'ArrayExpression':
case 'TemplateLiteral':
return node.elements.filter(n => !!n);
case 'BlockStatement':
case 'Program':
return node.body;
case 'CallExpression':
case 'NewExpression':
case 'TaggedTemplate':
return [node.callee, ...node.arguments];
case 'CatchClause':
return [node.body, node.guard].filter(n => !!n);
case 'ClassExpression':
case 'ClassStatement':
return [...node.body, node.superClass].filter(n => !!n);
case 'ClassMethod':
return [node.name, node.body];
case 'ComprehensionExpression':
case 'GeneratorExpression':
return [node.body, ...node.blocks, node.filter].filter(n => !!n);
case 'ComprehensionIf':
return [node.test];
case 'ComputedName':
return [node.name];
case 'ConditionalExpression':
case 'IfStatement':
return [node.test, node.consequent, node.alternate].filter(n => !!n);
case 'DoWhileStatement':
case 'WhileStatement':
return [node.body, node.test];
case 'ExportDeclaration':
return [node.declaration, node.source].filter(n => !!n);
case 'ImportDeclaration':
return [...node.specifiers, node.source];
case 'LetStatement':
return [...node.head, node.body];
case 'ExpressionStatement':
return [node.expression];
case 'ForInStatement':
case 'ForOfStatement':
return [node.body, node.left, node.right];
case 'ForStatement':
return [node.init, node.test, node.update, node.body].filter(n => !!n);
case 'LabeledStatement':
return [node.body];
case 'MemberExpression':
return [node.object, node.property];
case 'ObjectExpression':
case 'ObjectPattern':
return node.properties;
case 'OptionalExpression':
return [node.expression];
case 'OptionalMemberExpression':
return [node.object, node.property];
case 'Property':
case 'PrototypeMutation':
return [node.value];
case 'ReturnStatement':
case 'ThrowStatement':
case 'UnaryExpression':
case 'UpdateExpression':
case 'YieldExpression':
return node.argument ? [node.argument] : [];
case 'SequenceExpression':
return node.expressions;
case 'SpreadExpression':
return [node.expression];
case 'SwitchCase':
return [node.test, ...node.consequent].filter(n => !!n);
case 'SwitchStatement':
return [node.discriminant, ...node.cases];
case 'TryStatement':
return [node.block, node.handler, node.finalizer].filter(n => !!n);
case 'VariableDeclaration':
return node.declarations;
case 'VariableDeclarator':
return node.init ? [node.init] : [];
case 'WithStatement':
return [node.object, node.body];
default:
print(`Ignoring ${node.type}, you should probably fix this in the script`);
}
}
function walkDir(dir) {
os.file.listDir(dir).forEach(child => {
if (child.startsWith('.'))
return;
const path = os.path.join(dir, child);
const relativePath = path.replace(`${root}/`, '');
if (excludedFiles.has(relativePath))
return;
if (!child.endsWith('.js')) {
try {
walkDir(path);
} catch (e) {
// not a directory
}
return;
}
try {
const script = os.file.readFile(path);
const ast = Reflect.parse(script);
walkAst(ast, findGettextCalls);
} catch (e) {
foundFiles.add(path);
}
});
}
walkDir(root);
if (foundFiles.size === 0)
quit(0);
print('The following files are missing from po/POTFILES.in:')
foundFiles.forEach(f => print(` ${f}`));
quit(1);

View File

@ -1,10 +1,9 @@
#!/usr/bin/env bash
srcdirs="js src subprojects/extensions-tool"
globs=('*.js' '*.c')
srcdirs="src subprojects/extensions-tool"
# find source files that contain gettext keywords
files=$(grep -lR ${globs[@]/#/--include=} '\(gettext\|[^I_)]_\)(' $srcdirs)
files=$(grep -lR --include='*.c' '\(gettext\|[^I_)]_\)(' $srcdirs)
# filter out excluded files
if [ -f po/POTFILES.skip ]; then

View File

@ -1,11 +1,19 @@
#!/usr/bin/bash
fetch() {
local remote=$1
local ref=$2
git fetch --quiet --depth=1 $remote $ref 2>/dev/null
}
mutter_target=
git clone https://gitlab.gnome.org/GNOME/mutter.git
if [ $? -ne 0 ]; then
echo Checkout failed
echo -n Cloning into mutter ...
if git clone --quiet --depth=1 https://gitlab.gnome.org/GNOME/mutter.git; then
echo \ done
else
echo \ failed
exit 1
fi
@ -15,19 +23,33 @@ if [ "$CI_MERGE_REQUEST_TARGET_BRANCH_NAME" ]; then
merge_request_remote=${CI_MERGE_REQUEST_SOURCE_PROJECT_URL//gnome-shell/mutter}
merge_request_branch=$CI_MERGE_REQUEST_SOURCE_BRANCH_NAME
echo Looking for $merge_request_branch on remote ...
if git fetch -q $merge_request_remote $merge_request_branch 2>/dev/null; then
echo -n Looking for $merge_request_branch on remote ...
if fetch $merge_request_remote $merge_request_branch; then
echo \ found
mutter_target=FETCH_HEAD
else
mutter_target=origin/$CI_MERGE_REQUEST_TARGET_BRANCH_NAME
echo Using $mutter_target instead
echo \ not found
echo -n Looking for $CI_MERGE_REQUEST_TARGET_BRANCH_NAME instead ...
if fetch origin $CI_MERGE_REQUEST_TARGET_BRANCH_NAME; then
echo \ found
mutter_target=FETCH_HEAD
else
echo \ not found
fi
fi
fi
if [ -z "$mutter_target" ]; then
mutter_target=$(git branch -r -l origin/$CI_COMMIT_REF_NAME)
mutter_target=${mutter_target:-origin/master}
echo Using $mutter_target instead
echo -n Looking for $CI_COMMIT_REF_NAME on remote ...
if fetch origin $CI_COMMIT_REF_NAME; then
echo \ found
mutter_target=FETCH_HEAD
else
echo \ not found
mutter_target=HEAD
echo Using $mutter_target instead
fi
fi
git checkout -q $mutter_target

View File

@ -0,0 +1,16 @@
patterns:
deny:
- regex: '^$CI_MERGE_REQUEST_PROJECT_URL/(-/)?merge_requests/$CI_MERGE_REQUEST_IID$'
message: Commit message must not contain a link to its own merge request
- regex: '^(st-|St)'
message: Commit message subject should not be prefixed with 'st-' or 'St', use 'st/' instead
where: subject
- regex: '^[^:]+: [a-z]'
message: "Commit message subject should be properly Capitalized. E.g. 'window: Marginalize extradicity'"
where: subject
- regex: '^\S*\.(js|c|h):'
message: Commit message subject prefix should not include .c, .h etc.
where: subject
- regex: '([^.]\.|[:,;])\s*$'
message: Commit message subject should not end with punctuation
where: subject

View File

@ -0,0 +1,38 @@
#!/usr/bin/bash
# We need a coverity token to fetch the tarball
if [ -x $COVERITY_TOKEN ]
then
echo "No coverity token. Run this job from a protected branch."
exit -1
fi
mkdir -p coverity
# Download and check MD5 first
curl https://scan.coverity.com/download/linux64 \
--data "token=$COVERITY_TOKEN&project=GNOME+Shell&md5=1" \
--output /tmp/coverity_tool.md5
diff /tmp/coverity_tool.md5 coverity/coverity_tool.md5 >/dev/null 2>&1
if [ $? -eq 0 -a -d coverity/cov-analysis* ]
then
echo "Coverity tarball is up-to-date"
exit 0
fi
# Download and extract coverity tarball
curl https://scan.coverity.com/download/linux64 \
--data "token=$COVERITY_TOKEN&project=GNOME+Shell" \
--output /tmp/coverity_tool.tgz
rm -rf ./coverity/cov-analysis*
tar zxf /tmp/coverity_tool.tgz -C coverity/
if [ $? -eq 0 ]
then
mv /tmp/coverity_tool.md5 coverity/
fi
rm /tmp/coverity_tool.tgz

View File

@ -0,0 +1,34 @@
#!/bin/bash
set -e
if [[ $# -lt 4 ]]; then
echo Usage: $0 [options] [repo-url] [commit] [subdir]
echo Options:
echo -Dkey=val
exit 1
fi
MESON_OPTIONS=()
while [[ $1 =~ ^-D ]]; do
MESON_OPTIONS+=( "$1" )
shift
done
REPO_URL="$1"
COMMIT="$2"
SUBDIR="$3"
PREPARE="$4"
REPO_DIR="$(basename ${REPO_URL%.git})"
git clone --depth 1 "$REPO_URL" -b "$COMMIT"
pushd "$REPO_DIR"
pushd "$SUBDIR"
sh -c "$PREPARE"
meson --prefix=/usr _build "${MESON_OPTIONS[@]}"
meson install -C _build
popd
popd
rm -rf "$REPO_DIR"

128
.gitlab-ci/run-eslint Executable file
View File

@ -0,0 +1,128 @@
#!/usr/bin/env node
const { ESLint } = require('eslint');
const fs = require('fs');
const path = require('path');
const { spawn } = require('child_process');
function createConfig(config) {
const options = {
cache: true,
cacheLocation: `.eslintcache-${config}`,
};
if (config === 'legacy')
options.overrideConfigFile='lint/eslintrc-legacy.yml';
return new ESLint(options);
}
function git(...args) {
const git = spawn('git', args, { stdio: ['ignore', null, 'ignore'] });
git.stdout.setEncoding('utf8');
return new Promise(resolve => {
let out = '';
git.stdout.on('data', chunk => out += chunk);
git.stdout.on('end', () => resolve(out.trim()));
});
}
function createCommon(report1, report2, ignoreColumn=false) {
return report1.map(result => {
const { filePath, messages } = result;
const match =
report2.find(r => r.filePath === filePath) || { messages: [] };
const filteredMessages = messages.filter(
msg => match.messages.some(
m => m.line === msg.line && (ignoreColumn || m.column === msg.column)));
const [errorCount, warningCount] = filteredMessages.reduce(
([e, w], msg) => {
return [
e + Number(msg.severity === 2),
w + Number(msg.severity === 1)];
}, [0, 0]);
return {
filePath,
messages: filteredMessages,
errorCount,
warningCount,
};
});
}
async function getMergeRequestChanges(remote, branch) {
await git('fetch', remote, branch);
const branchPoint = await git('merge-base', 'HEAD', 'FETCH_HEAD');
const diff = await git('diff', '-U0', `${branchPoint}...HEAD`);
const report = [];
let messages = null;
for (const line of diff.split('\n')) {
if (line.startsWith('+++ b/')) {
const filePath = path.resolve(line.substring(6));
messages = filePath.endsWith('.js') ? [] : null;
if (messages)
report.push({ filePath, messages });
} else if (messages && line.startsWith('@@ ')) {
[, , changes] = line.split(' ');
[start, count] = `${changes},1`.split(',').map(i => parseInt(i));
for (let i = start; i < start + count; i++)
messages.push({ line: i });
}
}
return report;
}
function getOption(...names) {
const optIndex =
process.argv.findIndex(arg => names.includes(arg)) + 1;
if (optIndex === 0)
return undefined;
return process.argv[optIndex];
}
(async function main() {
const outputOption = getOption('--output-file', '-o');
const outputPath = outputOption ? path.resolve(outputOption) : null;
const sourceDir = path.dirname(process.argv[1]);
process.chdir(path.resolve(sourceDir, '..'));
const remote = getOption('--remote') || 'origin';
const branch = getOption('--branch', '-b');
const sources = ['js', 'subprojects/extensions-app/js'];
const regular = createConfig('regular');
const ops = [];
ops.push(regular.lintFiles(sources));
if (branch)
ops.push(getMergeRequestChanges(remote, branch));
else
ops.push(createConfig('legacy').lintFiles(sources));
const results = await Promise.all(ops);
const commonResults = createCommon(...results, branch !== undefined);
const formatter = await regular.loadFormatter(getOption('--format', '-f'));
const resultText = formatter.format(commonResults);
if (outputPath) {
fs.mkdirSync(path.dirname(outputPath), { recursive: true });
fs.writeFileSync(outputPath, resultText);
} else {
console.log(resultText);
}
process.exitCode = commonResults.some(r => r.errorCount > 0) ? 1 : 0;
})().catch((error) => {
process.exitCode = 1;
console.error(error);
});

View File

@ -1,116 +0,0 @@
#!/usr/bin/env bash
OUTPUT_REGULAR=reports/lint-regular-report.txt
OUTPUT_LEGACY=reports/lint-legacy-report.txt
OUTPUT_FINAL=reports/lint-common-report.txt
OUTPUT_MR=reports/lint-mr-report.txt
LINE_CHANGES=changed-lines.txt
is_empty() {
(! grep -q . $1)
}
run_eslint() {
ARGS_LEGACY='--config lint/eslintrc-legacy.yml'
local extra_args=ARGS_$1
local output_var=OUTPUT_$1
local output=${!output_var}
local cache=.eslintcache-${1,,}
# ensure output exists even if eslint doesn't report any errors
mkdir -p $(dirname $output)
touch $output
eslint -f unix --cache --cache-location $cache ${!extra_args} -o $output \
js subprojects/extensions-app/js
}
list_commit_range_additions() {
# Turn raw context-less git-diff into a list of
# filename:lineno pairs of new (+) lines
git diff -U0 "$@" -- js |
awk '
BEGIN { file=""; }
/^+++ b/ { file=substr($0,7); }
/^@@ / {
len = split($3,a,",")
start=a[1]
count=(len > 1) ? a[2] : 1
for (line=start; line<start+count; line++)
printf "%s/%s:%d:\n",ENVIRON["PWD"],file,line;
}'
}
copy_matched_lines() {
local source=$1
local matches=$2
local target=$3
echo -n > $target
for l in $(<$matches); do
grep $l $source >> $target
done
}
create_common() {
# comm requires sorted input;
# we also strip the error message to make the following a "common" error:
# regular:
# file.js:42:23 Indentation of 55, expected 42
# legacy:
# file.js:42:23 Indentation of 55, extected 24
prepare() {
sed 's: .*::' $1 | sort
}
comm -12 <(prepare $OUTPUT_REGULAR) <(prepare $OUTPUT_LEGACY) >$OUTPUT_FINAL.tmp
# Now add back the stripped error messages
copy_matched_lines $OUTPUT_REGULAR $OUTPUT_FINAL.tmp $OUTPUT_FINAL
rm $OUTPUT_FINAL.tmp
}
# Disable MR handling for now. We aren't ready to enforce
# non-legacy style just yet ...
unset CI_MERGE_REQUEST_TARGET_BRANCH_NAME
REMOTE=${1:-$CI_MERGE_REQUEST_PROJECT_URL.git}
BRANCH_NAME=${2:-$CI_MERGE_REQUEST_TARGET_BRANCH_NAME}
if [ "$BRANCH_NAME" ]; then
git fetch $REMOTE $BRANCH_NAME
branch_point=$(git merge-base HEAD FETCH_HEAD)
commit_range=$branch_point...HEAD
list_commit_range_additions $commit_range > $LINE_CHANGES
# Don't bother with running lint when no JS changed
if is_empty $LINE_CHANGES; then
exit 0
fi
fi
echo Generating lint report using regular configuration
run_eslint REGULAR
echo Generating lint report using legacy configuration
run_eslint LEGACY
echo Done.
create_common
if ! is_empty $OUTPUT_FINAL; then
cat $OUTPUT_FINAL
exit 1
fi
# Just show the report and succeed when not testing a MR
if [ -z "$BRANCH_NAME" ]; then
exit 0
fi
copy_matched_lines $OUTPUT_REGULAR $LINE_CHANGES $OUTPUT_MR
cat $OUTPUT_MR
is_empty $OUTPUT_MR

View File

@ -8,7 +8,7 @@ first to ensure that you create a clear and specific issue.
<!--
Provide at least the following information:
* Your OS and version
* Affected GNOME Shell version
* Affected GNOME Shell version (see https://wiki.gnome.org/Schedule for currently supported versions)
* Does this issue appear in XOrg and/or Wayland
-->

1
.jscheckignore Normal file
View File

@ -0,0 +1 @@
js/ui/init.js

View File

@ -131,7 +131,7 @@ whenever possible, that is when not inheriting from GObjects.
};
```
For GObject inheritence, we use the GObject.registerClass() function provided
For GObject inheritance, we use the GObject.registerClass() function provided
by gjs.
```javascript
var MyActor = GObject.registerClass(

505
NEWS
View File

@ -1,3 +1,490 @@
41.1
====
* Fix icon updates while hidden [Marco; !1983]
* Fix erratic scrolling in GTK apps [Christian, Carlos; !1993, #4647]
* Fix GTK color picker support [Florian; !1990]
* Fix sound-file support in notifications [Florian; !1991]
* Fix high-contrast switches [Florian; !2000]
* Only allow one extension prefs dialog at a time [Florian; #4564]
* Fixed crashes [Ray, Sebastian; !2004, !2014]
* Misc. bug fixes and cleanups [Jonas, Florian, Jakub, Carlos; !1985, !1998,
!1996, !1979, !2007, !2010]
Contributors:
Marco Trevisan (Treviño), Carlos Garnacho, Christian Hergert,
Sebastian Keller, Florian Müllner, Jakub Steiner, Ray Strode, Jonas Ådahl
Translators:
Марко Костић [sr], Ngọc Quân Trần [vi], Emin Tufan Çetin [tr],
Yaron Shahrabani [he], Sveinn í Felli [is], Goran Vidović [hr],
Marek Černocký [cs], Selyan Slimane AMIRI [kab], Rūdolfs Mazurs [lv],
eshagh shahidani [fa], Yuri Chornoivan [uk], Matej Urbančič [sl],
Anders Jonsson [sv], Rafael Fontenelle [pt_BR], Kukuh Syafaat [id],
Hugo Carvalho [pt], Aleksandr Melman [ru], Christian Kirbach [de]
41.0
====
Translators:
Goran Vidović [hr], Jordi Mas [ca], Aman Alam [pa], Balázs Úr [hu],
Piotr Drąg [pl], Nathan Follens [nl], Quentin PAGÈS [oc], Jiri Grönroos [fi],
Alexander Shopov [bg], Alan Mortensen [da], Efstathios Iosifidis [el]
41.rc.1
=======
* Make tests optional [Florian; !1975]
* Misc. bug fixes [Florian; !1974]
Contributors:
Florian Müllner
Translators:
Daniel Șerbănescu [ro]
41.rc
=====
* Optimize rendering of fullscreen zoom [Daniel; !1899]
* Fix glitchy launch animations when leaving overview [Daniel; !1440]
* Show low priority notifications only in message list [Florian; #4265]
* Support Soup 3 instead of 2.4 [Florian; !1940, !1966]
* Set log domain for extensions that use console.log() [Evan; !1958]
* Fix wrong separator position in dash [Raghuveer; !1804]
* Fix OSK not registering button presses on X11 [Sebastian; !1955]
* Fix work area getting messed up by hidden panels [Florian; #4569]
* Fix IM candidate popover position [Florian; #4593]
* Restrict callers of private D-Bus APIs [Florian; !1970]
* Support committing preedit string on focus loss [Carlos; !1929]
* Misc. bug fixes and cleanups [Florian, Ivan, Sebastian, José, Robert; !1956,
!1949, !1937, !1961, !1962, !1871, !1964, !1946, !1957, !1959, !1879, !1968]
Contributors:
José Expósito, Carlos Garnacho, Raghuveer Kasaraneni, Sebastian Keller,
Robert Mader, Ivan Molodetskikh, Florian Müllner, Daniel van Vugt, Evan Welsh
Translators:
Yuri Chornoivan [uk], Quentin PAGÈS [oc], Asier Sarasua Garmendia [eu],
Hugo Carvalho [pt], Rafael Fontenelle [pt_BR], Jordi Mas [ca],
Alexey Rubtsov [ru], Danial Behzadi [fa], Kukuh Syafaat [id],
Marek Černocký [cs], Fran Dieguez [gl], Daniel Mustieles [es],
Źmicier Turok [be], Jiri Grönroos [fi], Emin Tufan Çetin [tr],
Baurzhan Muftakhidinov [kk], Bruce Cowan [en_GB], Philipp Kiemle [de],
Matej Urbančič [sl], Dušan Kazik [sk], Charles Monzat [fr],
Luna Jernberg [sv], Aurimas Černius [lt], Boyuan Yang [zh_CN],
Changwoo Ryu [ko]
41.beta
=======
* Unbreak Xwayland apps when not using systemd in user session [Olivier; !1850]
* extension-tool: Always print location on successful creation [Leleat; !1856]
* Fix distributed man pages [Florian; !1859]
* Immediately start app grid drags for non-touch devices [Georges; !1866]
* Avoid unnecessary icon shadow changes [Daniel; !1869]
* Handle screencast failures more gracefully [Florian; !1878]
* Fix glitch in app grid → session transition [Harshad; !1886]
* Use symbolic icons in looking glass toolbar [Chris; !1671]
* Fix IM popup visibility when in fullscreen [Florian; !1900]
* magnifier: Fix view jumps when using caret tracking [Lee; !1823]
* Fix shadow rendering glitches [Daniel; !1897]
* Allow overriding super+number shortcuts in Settings [Florian; #1250]
* Fix vertical scrollbars in RTL locales [Florian; !1910]
* Don't include hidden search results in keynav [Florian; #4470]
* Use anaccelerated deltas in swipe tracker [Alexander; !1763]
* status/network: Do not disable on login screen [Florian; !1874]
* Always take workarea into account when allocating workspaces [Marco; !1892]
* location: Split out geoclue agent from indicator [Ian; !1919]
* Add focus indication for switches [vanadiae; !1920]
* Honor switch-user lockdown settings in unlock screen [Ray; !1833]
* Fix glitch when dragging window preview in overview [Sebastian; #4292]
* Lock down "Show Text" in password entries [Ray; !687]
* Add power mode selection to status menu [Florian; !1907]
* workspace: Handle skip-taskbar changes [Daniel; !1925]
* status/network: Use WWan settings panel for GSM/LTE modems [Mohammed; !1942]
* extensionUtils: Add gettext convenience helpers [Florian; !1941]
* screenShield: Fix suspend inhibitor accounting [Sebastian; !1927, !1952]
* Unify app context menus [Florian; !1948]
* Use consistent terminology in window menu [nitinosiris; !1834]
* Fixed crashes [Gustavo, Florian; !1848, !1885, !1935]
* Misc. bug fixes and cleanups [Jonas Å., Florian, Georges, Daniel, Olivier,
Carlos, Robert, Sebastian, Jakub, Jonas D., Fionn; !1838, !1854, !1860,
!1872, !1876, !1880, !1888, !1890, !1891, !1894, !1902, !1901, !1903,
!1841, !1904, !1786, !1906, !1909, !1908, !1840, !1913, !1917, !1914,
!1857, !1922, !1924, !1931, !1926, !953, !1932, !1939, !1938, !1944,
!1936, !1947, !1945, !1950]
Contributors:
Marco Trevisan (Treviño), Jonas Dreßler, Olivier Fourdan, Carlos Garnacho,
Harshad Gavali, Tjipke van der Heide, Fionn Kelleher, Sebastian Keller, Lee,
Leleat, Robert Mader, Chris Mayo, Alexander Mikhaylenko, Florian Müllner,
Georges Basile Stavracas Neto, nitinosiris, Mohammed Sadiq, Ian Douglas Scott,
Gustavo Noronha Silva, Jakub Steiner, Ray Strode, Daniel van Vugt, vanadiae,
Jonas Ådahl
Translators:
Quentin PAGÈS [oc], Cheng-Chia Tseng [zh_TW], Jordi Mas [ca],
Hugo Carvalho [pt], Julia Dronova [ru], Efstathios Iosifidis [el],
Alexander Shopov [bg], Florentina Mușat [ro], Yuri Chornoivan [uk],
Alexey Rubtsov [ru], Rafael Fontenelle [pt_BR], Yaron Shahrabani [he],
Daniel Mustieles [es], Matej Urbančič [sl], Danial Behzadi [fa],
Kukuh Syafaat [id], Fran Dieguez [gl], Boyuan Yang [zh_CN], Fabio Tomat [fur],
Tjipke van der Heide [fy], Emin Tufan Çetin [tr], Luna Jernberg [sv],
Daniel Șerbănescu [ro]
40.1
====
* Fix keyboard preview for IM that use 'default' layout [Peng; !1756]
* extensions: Fix copying technical details on prefs crash [Jan; !1795, !1796]
* Make window previews as large as possible [Jonas D.; !1670, !1813]
* Fix PgUp/PgDown handling in overview [Florian; !1798]
* Fix scroll view following keyboard focus [Andrew; !1802]
* Fix word suggestions in on-screen keyboard [Jia; !1806]
* Support animated backgrounds set via the wallpaper portal [Alexander; !1816]
* Fix freeze after cancelling (some) system-modal dialogs [Florian; !1819]
* Support double-super when animations are disabled [Florian; !1811]
* gdm: Allow timed login with disabled user list [Ray; !1809]
* status: Report real battery percentage when full [Prajna; !1787]
* Allow tap-drag-release to select variants in OSK [Carlos; !1789]
* Fix password authentication after fingerprint failure [Ray, Benjamin; !1821]
* Fix screen blanking on idle [Florian; !1824]
* Fix oversized system action icons in search [Sebastian; !1777]
* Only show 'Open Windows' in app menus if there are multiple [Leleat; !1827]
* Fix duplicated workspaces in minimap [Sebastian; !1828]
* Fix repeated letters in type-to-find overview search [Sebastian; !1828]
* Improve workspace placeholder in overview minimap [Joonas; !1801]
* screencasts: Improve default gstreamer pipeline [Jonas D.; !1633]
* Leave overview when activating app via shortcut [Nishal; !1839]
* Fix invisible scroll bars in faded views [Florian; !1831]
* Correct arrow navigation in alt-tab switcher in RTL locales [Leleat; !1835]
* Improve touch interaction of app grid actions [Carlos; !1774]
* Fixed crashes [Jonas Å., Sebastian; !1810, !1817]
* Misc. bug fixes and cleanups [Carlos, Yuri, Sebastian, Suryashankar, Zander,
arushsharma24, Florian, Georges, Jonas D., Frederic, Leleat, Jakub,
theRealPadster, Simon, Olivier; !1770, !1781, !1782, !1775, !1769, !1791,
!1764, !1793, !1799, !1805, !1484, !1815, !1820, !1807, !1825, !1822, !1800,
!1818, !1830, !1790, !1812, !1771, !1844, !1845, !1837, !1842]
Contributors:
Jonas Ådahl, arushsharma24, Benjamin Berg, Zander Brown, Jia Chao,
Frederic Crozat, Suryashankar Das, Jonas Dreßler, Olivier Fourdan,
Carlos Garnacho, Joonas Henriksson, Sebastian Keller, Yuri Konotopov,
Nishal Kulkarni, Leleat, Alexander Mikhaylenko, Florian Müllner,
Georges Basile Stavracas Neto, Prajna Sariputra, Simon Schneegans,
Jakub Steiner, Ray Strode, theRealPadster, Jan Tojnar, Peng Wu, Andrew Zaech
Translators:
Timo Jyrinki [fi], Boyuan Yang [zh_CN], Hannie Dumoleyn [nl], Dz Chen [zh_CN],
Ngọc Quân Trần [vi], Hugo Carvalho [pt], Yosef Or Boczko [he],
Yaron Shahrabani [he], Nathan Follens [nl], Cédric Valmary [oc],
Carmen Bianca BAKKER [eo], Emin Tufan Çetin [tr], Dušan Kazik [sk],
Stas Solovey [ru], Pawan Chitrakar [ne], Jordi Mas [ca], Quentin PAGÈS [oc]
40.0
====
Translators:
Zander Brown [en_GB], Dušan Kazik [sk]
40.rc
=====
* Define default app grid arrangement [Allan; !1700]
* Fix shading behind system modal dialogs [Florian; !1712]
* Only show logout-inhibiting apps in end-session dialog [Michael; !1424]
* Fix minimap previews on multi-monitor systems [Florian; !1721]
* Drop strict extension version match for unstable releases [Florian; !1719]
* Fix missing app menu after overview gesture [Florian; !1726]
* Improve app folder appearance [Jakub; !1714]
* Fix window previews becoming undraggable after workspace switch
[Sebastian; !1717]
* Fix dragging icons to a different page in RTL locales [Carlos; !1734]
* Support double super for opening app grid [Florian; !1736]
* Improve workspace handling on secondary monitors [Florian; !1735]
* Improve interaction when dragging between app grid pages [Carlos; !1630]
* Fix launching on requested workspace on wayland [Florian; !1316]
* Make wifi strength indicator consistent with icons in Settings [Remi; !1432]
* Start session in overview [Georges; !1678]
* Tweak window preview layout in overview [Jonas D.; !1702, !1737]
* Improve overview performance [Jonas D.; !1713, !1733, !1743, !1755]
* Fix new workspaces being invisible in minimap [Florian; !1716]
* Fix glitch after dragging window preview from second monitor [Ivan; !1727]
* Do not switch workspaces when scrolling during super-tab [Florian; !1746]
* Make OSK shifting up windows more reliable [Jonas D.; !1728, !1760]
* Fix swipe gesture glitches [Alexander; !1731]
* Fix mis-scaled preview icons in window picker [Sebastian; !1751]
* Fix unintended app grid changes during icon DND in dash [Sebastian; !1767]
* Fix missing X11 fallback icons [Florian; !1761]
* Fixed crashes [Sebastian; !1718]
* Misc. bug fixes and cleanups [Jonas Å., Sebastian, Abderrahim, Florian,
Alexander, Felix, Ivan, Jonas D., Jakub, Daniel; !1710, !1707, !1720, !1722,
!1724, !1732, !1246, !1738, !1740] !1742, !1741, !1745, !1748, !1749, !1765,
!1766, !1757, !1758]
Contributors:
Jonas Ådahl, arushsharma24, Allan Day, Felix Divo, Jonas Dreßler,
Carlos Garnacho, Sebastian Keller, Abderrahim Kitouni, Alexander Mikhaylenko,
Ivan Molodetskikh, Florian Müllner, Georges Basile Stavracas Neto,
Remi Salmon, Jakub Steiner, Michael Terry, Daniel van Vugt
Translators:
Fran Dieguez [gl], Balázs Meskó [hu], Baurzhan Muftakhidinov [kk],
Goran Vidović [hr], Christian Kirbach [de], Марко Костић [sr],
Asier Sarasua Garmendia [eu], Guillaume Bernard [fr], Tim Sabsch [de],
Philipp Kiemle [de], Danial Behzadi [fa], Piotr Drąg [pl],
Rūdolfs Mazurs [lv], Daniel Mustieles [es], Marek Černocký [cs],
Fabio Tomat [fur], Changwoo Ryu [ko], Kjartan Maraas [nb], A S Alam [pa],
Milo Casagrande [it]
40.beta
=======
* Overview redesign
- Move dash to the bottom [Georges, Abderrahim, Jakub; !1559]
- Do not duplicate dash icons in app grid [Florian; !1580]
- Separate favorites from running apps in dash [Florian; !1606, !1610, !1659]
- Change to a horizontal workspace layout [Georges; !1593, !1603]
- Move background to workspaces [Georges, Florian, Jakub; !1599]
- Overhaul window preview style [Florian, Jakub; !1605, !1654, !1657]
- Rework workspace switching animation [Alexander; !1326]
- Show workspace side-by-side [Georges; !1613]
- Allow switching workspaces with super+scroll on wayland [Florian; !1612]
- Allow swiping through more than one workspace at a time [Alexander; !1647]
- Extend active dash area to the screen edge [Florian; !1660]
- Change overall overview layout [Georges, Florian; !1624]
- Refine workspace activation in overview [Georges; !1645]
- Add vertical swipe gesture to shift through overview [Carlos; !1643]
- Add shortcuts for shifting through overview [Florian; !1695]
- Round background corners in overview [Jonas D.; !1651, !1697]
- Hide workspace minimap when using less than two workspaces [Florian; !1696]
- Scale down backgrounds in window picker [Georges; !1691]
- Minor improvements and bug fixes [Florian, Abderrahim, Georges, Sebastian,
Jakub, Pascal, Jonas D.; !1594, !1609, !1608, !1620, !1629, !1625, !1634,
!1640, #3669, !1636, !1655, !1656, !1665, !1667, !1638, !1680, !1682, !1684,
!1681, !1687, !1693, !1694, !1692]
* Fix glitch in app folder icons on smaller displays [Sebastian; !1581]
* Remove arrows from top bar menus [Doan, Florian, Razze; !1583, !1618, !1615]
* Fix stuck grab after failed area screenshots [Sebastian; !1600]
* Prefer image-data hint over app-icon in notifications [Guilherme; !1616]
* Fix drag actor position when animations are turned off [Sebastian; !1627]
* Improve spacing in MPRIS notifications with small text [Sebastian; !1632]
* Add Welcome dialog after major updates [Bastien; !1619]
* Do not save empty commands in run dialog history [Lucas; !1442, !1653]
* Consider device type for fingerprint hint on login screen [Razze; !1572]
* Add tooltip to Extensions app to view unellipsized description [Leleat; !1663]
* Fix stuck polkit dialog when using non-password auth [Florian; !1662]
* Provide screenshot feedback (flash, shutter) before writing file to disk
[Brion, Jonas; !1658]
* Improve Thai layout in on-screen keyboard [Panawat; !1427]
* Improve error handling for fingerprint auth [Marco; !1652]
* Handle a large number of window previews more gracefully [Sebastian; !1685]
* Follow swipe gesture when bringing up on-screen keyboard [Carlos; !1668]
* Disable out-of-date extensions by default (again) [Evan; !1706]
* Fixed crashes [Jonas D., Carlos; !1673, !1672]
* Misc. bug fixes and cleanups [Florian, Sebastian, Razze, Georges, Daniel,
Robert, Jonas D., Jonas Å., Marco, Bastien, TerraAr, Carlos; !1575, !1579,
!1577, !1578, !1585, !1587, !1588, !1590, !1591, !1592, !1595, !1596, !1597,
!1598, !1582, !1589, !1617, !1611, !1637, !1635, !1641, !1646, !1546, !1648,
!1650, !1649, !1644, !1661, !1622, !1075, !1674, !1556, !1686, !1683, !1688,
!1699, !1698, !1701, !1709]
Contributors:
Jonas Ådahl, Jonas Dreßler, Carlos Garnacho, Sebastian Keller,
Abderrahim Kitouni, Leleat, Robert Mader, Alexander Mikhaylenko,
Florian Müllner, Georges Basile Stavracas Neto, Bastien Nocera, Pascal Nowack,
Razze, Guilherme Silva, Jakub Steiner, TerraAr, Marco Trevisan (Treviño),
Brion Vibber, Doan Nam Long Vu, Daniel van Vugt, Evan Welsh,
Lucas Werkmeister, Panawat Wong-kleaw
Translators:
Balázs Úr [hu], Danial Behzadi [fa], Rafael Fontenelle [pt_BR], A S Alam [pa],
Anders Jonsson [sv], Yuri Chornoivan [uk], Marek Černocký [cs],
Hugo Carvalho [pt], Fran Dieguez [gl], Daniel Șerbănescu [ro],
Florentina Mușat [ro], Daniel Mustieles [es], Jordi Mas [ca],
Matej Urbančič [sl], Kukuh Syafaat [id], Bruno Lopes da Silva [pt_BR],
Аляксей [be], Balázs Meskó [hu], Марко Костић [sr], Enrico Nicoletto [pt_BR],
Emin Tufan Çetin [tr], Jiri Grönroos [fi], Aurimas Černius [lt]
40.alpha.1.1
============
* Adapt to settings moving to gsettings-desktop-schemas [Florian; !1573]
* Misc. bug fixes [Georges, Florian; !1571, !1574]
Contributors:
Florian Müllner, Georges Basile Stavracas Neto
Translators:
Марко Костић [sr], Marek Černocký [cs], Fabio Tomat [fur]
40.alpha.1
==========
* Restore app picker fade during swipes [Georges, Florian; !1519, !1569]
* Sort extensions in Looking Glass alphabetically [Florijan; !1516]
* Fix screenshots of unredirected fullscreen windows on X11
[Jonas Å., LuK1337; !1534, !1549]
* Use GPU to render (most) shadows [Georges; !1539]
* Refine avatar styling [Joonas; !1490]
* Fix storing VPN secrets [Sebastian; !1535]
* Don't depend on asciidoc and sassc when building from tarball
[Florian; !1553, !1555]
* Use horizontal pages in app picker [Georges; !1554]
* Avoid costly icon theme lookups unless when needed [Ivan; !1558]
* Properly expose locked state to logind [Florian; !1561]
* Use 3 fingers for system swipe gestures [Georges; !1562]
* Fix glitches in overview transitions [Jonas Å., Ivan; !1545, !1550]
* Improve login screen accessibility [Mike; !1567]
* Overhaul top bar styling [Jonas D.; !1397]
* Allow changing input volume by scrolling over microphone icon [Razze; !1566]
* Port Extensions app and portal to GTK4 [Florian; !1495]
* Fixed crashes [Jonas Å.; !1527]
* Misc. bug fixes and cleanups [Georges, Florian, Tom, Hans, Jonas D., Ivan,
Sebastian, Daniel; !1518, !1521, !1523, !1525, !1520, !1526, !1472, !1339,
!1529, !1531, !1532, !1533, !1528, !1350] !1542, !1537, !1548, !1551, !1557,
!1543, !1560, !1544, !1565]
Contributors:
Jonas Ådahl, Jonas Dreßler, Mike Gerow, Florijan Hamzic, Joonas Henriksson,
Sebastian Keller, Tom Levy, LuK1337, Ivan Molodetskikh, Florian Müllner,
Georges Basile Stavracas Neto, Hans Ulrich Niedermann, Razze, Daniel van Vugt
Translators:
Florentina Mușat [ro], Fabio Tomat [fur], Hugo Carvalho [pt],
Jordi Mas i Hernandez [ca], Philipp Kiemle [de], Fran Dieguez [gl],
Jordi Mas [ca], Kukuh Syafaat [id], Kjartan Maraas [nb],
Daniel Șerbănescu [ro], Matej Urbančič [sl]
40.alpha
========
* Handle @content properties in ease() functions [Andre; !1461]
* Fix screencast indicator on Xorg [Jonas Å.; !1466]
* Expand ellipsized app picker labels on hover [Georges; !1477, !1496]
* Fix inline-replies in chat notifications [Florian; #3226]
* Refine MPRIS notification layout [Harry; !1480]
* Improve do-not-disturb support [Florian; #2873, !1511]
* Fix mobile broadband support [Popax21; #3203]
* Add extension filtering in Extensions app [Florian; #3382]
* Improve app picker spacing on larger resolutions [Georges; !1510]
* Plugged leaks [Ray; !1460, !1459]
* Fixed crashes [Daniel, Florian; !1453, #3258, !1507]
* Misc. bug fixes and cleanups [Florian, Georges, Carlos, Joonas, Jan,
Jonas Å., Robert, Jonas D., Ian, Daniel, Sebastian, Jordan; !1456, !1436,
!1405, !1421, #3252, !1464, !1469, !1465, !1473, !1475, #3307, !1479,
!1482, !1470, !1486, #3335, #3342, #3388, !1497, !1498, !1491, !1501,
!1492, !1489, !1502, !1505, !1504, !1506, !1503, !1483, !1508, !1481,
!1509, !1512, !1417, !1517]
Contributors:
Jonas Dreßler, Carlos Garnacho, Joonas Henriksson, Sebastian Keller,
Robert Mader, Andre Moreira Magalhaes, Daniel García Moreno, Harry Míchal,
Florian Müllner, Georges Basile Stavracas Neto, Jordan Petridis, Popax21,
Ian Douglas Scott, Ray Strode, Jan Tojnar, Olav Vitters, Daniel van Vugt,
Jonas Ådahl
Translators:
Juliano de Souza Camargo [pt], Fabio Tomat [fur], Akarshan Biswas [bn_IN],
Carmen Bianca BAKKER [eo], Daniel Mustieles [es],
Asier Sarasua Garmendia [eu], Ask Hjorth Larsen [da], Yuri Chornoivan [uk],
Anders Jonsson [sv], Kjartan Maraas [nb]
3.38.1
======
* Add screen recordings to recent items [Florian; #3171]
* Tweak peek-password feature [Florian; #3138]
* Fix workspace glitches in overview [Florian; #3208, #3211]
* Improve DND behavior in app picker [Georges; !1447]
* Misc. bug fixes and cleanups [Florian, Daniel, Georges, Bastien, Christopher,
yun341, Carlos; #3169, !1434, !1441, !1444, !379, !1443, #2230, !1448,
!1451, #3209]
Contributors:
Yacine Bouklif, Christopher Davis, Carlos Garnacho, Daniel García Moreno,
Florian Müllner, Georges Basile Stavracas Neto, Bastien Nocera, yun341
Translators:
Juliano de Souza Camargo [pt], Yacine Bouklif [kab], Charles Monzat [fr],
Cheng-Chia Tseng [zh_TW], Yosef Or Boczko [he]
3.38.0
======
* Misc. bug fixes and cleanups [Andy, Florian; #3147, !1438]
Contributors:
Andy Holmes, Florian Müllner
Translators:
Anders Jonsson [sv], Balázs Úr [hu], Dušan Kazik [sk], Alan Mortensen [da],
Tim Sabsch [de], Claude Paroz [fr], Jiri Grönroos [fi], Juliano Camargo [pt],
Milo Casagrande [it], Aron Xu [zh_CN], Rūdolfs Mazurs [lv]
3.37.92
=======
* Fix screen recorder shortcut [Florian; #3097]
* Support cycle-group cycling only over windows in the workspac3 [Mitar; #3116]
* Misc. bug fixes and cleanups [Georges, Daniel, Carlos; !1428, !1423,
!1311, #2968]
Contributors:
Carlos Garnacho, Mitar, Florian Müllner, Georges Basile Stavracas Neto,
Daniel van Vugt
Translators:
Yuri Chornoivan [uk], Zander Brown [en_GB], Rafael Fontenelle [pt_BR],
Nathan Follens [nl], Danial Behzadi [fa], Kukuh Syafaat [id],
Aurimas Černius [lt], Marek Černocký [cs], Fabio Tomat [fur],
Changwoo Ryu [ko], Марко Костић [sr], Daniel Mustieles [es], Dušan Kazik [sk],
Thibault Martin [fr], Jordi Mas [ca]
3.37.91
=======
* Fix potential stack overflow in libcroco [Michael; !1404]
* Fix page removal in app picker [Georges; !1406]
* Fix "old style" VPN authentication [Florian; !1407]
* Fix X11 session login [Benjamin; !1418]
* Fix week number alignment when using font-scaling [Joonas; !1415]
* Fix lock screen on systems without GLSL shader support [Zephaniah; #3071]
* Misc. bug fixes and cleanups [Florian, Jonas, Georges, Andre, Will, Björn;
!1396, !1359, !1408, !1409, !1414, !1413, !1416, #3073]
Contributors:
Jonas Ådahl, Benjamin Berg, Michael Catanzaro, Björn Daase, Joonas Henriksson,
Zephaniah E. Loss-Cutler-Hull, Andre Moreira Magalhaes, Florian Müllner,
Georges Basile Stavracas Neto, Will Thompson
Translators:
Fran Dieguez [gl], Jordi Mas [ca], Daniel Mustieles [es],
Florentina Mușat [ro], Akarshan Biswas [bn_IN], Baurzhan Muftakhidinov [kk],
Piotr Drąg [pl], Rafael Fontenelle [pt_BR], Emin Tufan Çetin [tr],
sicklylife [ja], Danial Behzadi [fa], Jiri Grönroos [fi], Goran Vidović [hr],
Matej Urbančič [sl], Boyuan Yang [zh_CN]
3.37.90
=======
* Fix extension updates when many extensions are installed [Jeremias; !1363]
* Fix missing icons in on-screen keyboard [Emre; #2631, #3007]
* Fix delay when showing calendar events [Sebastian; #2992]
* Allow rearranging items in app picker [Georges; !1284]
* Fix top bar navigation when NumLock is active [Olivier; #550]
* Delay login animation until wallpaper has loaded [Michael; #734996]
* Reset auth prompt on login screen on VT switch before fade in [Ray; #2997]
* Move screencasting into a separate service [Jonas Å.; !1372]
* Replace loaded terms with more descriptive one [Olivier; !1393]
* Add "Boot Options" support to restart dialog [Hans; !199]
* Move "Restart" into a separate menu item/dialog [Florian; #2202]
* Default to not installing updates on low battery [Michael; #2717]
* Misc. bug fixes and cleanups [Florian, Daniel V., Georges, Jonas Å.,
Daniel G., Carlos, Benjamin, Piotr, Andre, Jonas D., Andy; !1357, !1356,
#2969, #2969, !1358, !1371, #3005, !1380, #3022, !1381, !895, !1387, !1386,
!1385, #3037, !1389, !1390, !1391, !1383, !1399, #2983, !1403]
Contributors:
Jonas Ådahl, Benjamin Berg, Michael Catanzaro, Piotr Drąg, Jonas Dreßler,
Olivier Fourdan, Carlos Garnacho, Hans de Goede, Andy Holmes,
Sebastian Keller, Andre Moreira Magalhaes, Daniel García Moreno,
Florian Müllner, Georges Basile Stavracas Neto, Jeremias Ortega, Ray Strode,
Emre Uyguroglu, Daniel van Vugt
Translators:
Tim Sabsch [de], Boyuan Yang [zh_CN], Fabio Tomat [fur],
Efstathios Iosifidis [el], Rafael Fontenelle [pt_BR], Yuri Chornoivan [uk],
Daniel Șerbănescu [ro], Jordi Mas [ca], Daniel Mustieles [es],
Emin Tufan Çetin [tr], Asier Sarasua Garmendia [eu]
3.37.3
======
* Refactor and clean up window picker
@ -230,7 +717,7 @@ Translators:
* Handle extension updates [Florian; !945]
* Animate showing and hiding caps-lock warning [Jonas; !952]
* Support "auto" lengths in CSS [Florian; !971]
* Turn extension-prefs into the offical Extensions app [Florian; #1968]
* Turn extension-prefs into the official Extensions app [Florian; #1968]
* Sandbox the portal helper [Michael; !983]
* Misc. bug fixes and cleanups [Florian, Björn, Jakub, Alexander, Daniel V.,
Jonas, nana-4, Carlos, Sebastian, Daniel G., Georges, Piotr; !918, !917,
@ -519,7 +1006,7 @@ Translators:
======
* Fix keeping actors visible in scrollviews [Marco; #1061]
* Move some chrome above popup windows [Jonas D.; !358]
* Include 'sandboxed-app-id' in winodw introspection info [Florian; #1289]
* Include 'sandboxed-app-id' in window introspection info [Florian; #1289]
* Port to libecal-2.0 [Milan; !501]
* Support TCRYPT in mount password dialog [segfault; !126]
* Misc. bug fixes and cleanups [Florian, Marco, Veerasamy; !517, #745, !499,
@ -1068,7 +1555,7 @@ Translations:
* gdm: Fix "Not listed" focus indication [Florian; #784040]
* Fix missing icons in freedesktop notifications [Florian; #784245]
* gdm: Disable user list when empty [Xiaoguang; #731320]
* gdm: Allow empty reponse to PAM messages [Ray; #784360]
* gdm: Allow empty response to PAM messages [Ray; #784360]
* Fix blocked clicks in shutdown dialog [Florian; #781738]
* Show OSD popup when changing volume via scroll wheel [Florian; #781028]
* Refine list search results [Rares; #749957]
@ -2528,7 +3015,7 @@ Translations:
* Merge the wayland branch [Giovanni, Neil; #707467]
* Make search entry behave better in RTL locales [Matthias, Florian; #705779]
* Allow to change app pages with pageUp/pageDown keys [Carlos; #707979]
* Set approriate a11y states on expandable menu items [Alejandro; #708038]
* Set appropriate a11y states on expandable menu items [Alejandro; #708038]
* Improve page indicator animation [Carlos; #707565]
* Misc bug fixes and cleanups [Florian, Olivier, Jasper, Giovanni, Magdalen,
Adel, Carlos, Rico, Joanmarie; #707308, #707430, #707508, #707557, #707600,
@ -3812,7 +4299,7 @@ Translations:
* Update the calendar code to use ECalClient [Giovanni; #671177]
* Update jhbuild script to use the main moduleset [Owen, Will; #668440]
* StTextureCache: code cleanup, evict unused icons, merge together
simulataneous requests for the same icon [Jasper; #670771, #671656, #672273]
simultaneous requests for the same icon [Jasper; #670771, #671656, #672273]
* Clean up St for recent Clutter changes and fix bugs. StContainer and
StGroup are removed [Jasper, Florian; #670034, #670640, #670904]
* Code cleanup [Adel, Jasper, Rui; #613194, #671086, #671103]
@ -3947,7 +4434,7 @@ Translations:
[Stefano; #664201]
- Delay rearranging windows in the overview as long as the pointer
is over a window [Vit; #645325]
* Add a GConf => DConf migration file for overriden Mutter settings
* Add a GConf => DConf migration file for overridden Mutter settings
[Florian; #667636]
* When a VPN connection is active, show that as the network icon
[Giovanni; #665115]
@ -4194,7 +4681,7 @@ Translations:
- Add fingerprint reader support [Ray; #657823]
- Add a power button offering the choice of Suspend/Restart/Power off
[Ray; #657822]
- Remove the option to view the current keyboad layout [Matthias; #659164]
- Remove the option to view the current keyboard layout [Matthias; #659164]
- Make Control-Alt-Tab work for full keyboard access [Ray; #659177]
* Frequently initiate a full garbage collection; Spidermonkey isn't very good
at tracking the amount of resources we have allocated so this hopefully will
@ -4411,7 +4898,7 @@ Translations:
* Fix selection highlighting for light-on-dark entries [Jasper; #643768]
* Make control-Return in the overview open a new window [Maxim]
* Delay showing the alt-Tab switcher to reduce visual noise when
flipping betweeen windows [Dan; #652346]
flipping between windows [Dan; #652346]
* When we have vertically stacked monitors, put the message tray
on the bottom one [Dan; #636963]
* Fix various problems with keynav and the Activities button
@ -4562,7 +5049,7 @@ Translations:
- Fix missing device descriptions with multiple devices of the
same type [Giovanni]
https://bugzilla.gnome.org/show_bug.cgi?id=646074
- Label ad-hoc neworks with an appropriate icon [Dan]
- Label ad-hoc networks with an appropriate icon [Dan]
https://bugzilla.gnome.org/show_bug.cgi?id=646141
- Fix displaying some devices states as "invalid" [Dan]
https://bugzilla.gnome.org/show_bug.cgi?id=646946

View File

@ -1,5 +1,5 @@
# GNOME Shell
GNOME Shell provides core user interface functions for the GNOME 3 desktop,
GNOME Shell provides core user interface functions for the GNOME desktop,
like switching to windows and launching applications. GNOME Shell takes
advantage of the capabilities of modern graphics hardware and introduces
innovative user interface concepts to provide a visually attractive and
@ -10,6 +10,7 @@ to build GNOME Shell from source and how to get involved with the project,
see the [project wiki][project-wiki].
Bugs should be reported to the GNOME [bug tracking system][bug-tracker].
Please refer to the [*Schedule* wiki page][schedule] to see the supported versions.
## Contributing
@ -19,10 +20,24 @@ Commit messages should follow the [GNOME commit message
guidelines](https://wiki.gnome.org/Git/CommitMessages). We require an URL
to either an issue or a merge request in each commit.
## Default branch
The default development branch is `main`. If you still have a local
checkout under the old name, use:
```sh
git checkout master
git branch -m master main
git fetch
git branch --unset-upstream
git branch -u origin/main
git symbolic-ref refs/remotes/origin/HEAD refs/remotes/origin/main
```
## License
GNOME Shell is distributed under the terms of the GNU General Public License,
version 2 or later. See the [COPYING][license] file for details.
[project-wiki]: https://wiki.gnome.org/Projects/GnomeShell
[bug-tracker]: https://gitlab.gnome.org/GNOME/gnome-shell/issues
[schedule]: https://wiki.gnome.org/Schedule
[license]: COPYING

1
bla bla Normal file
View File

@ -0,0 +1 @@
bla test

View File

@ -13,6 +13,9 @@
/* Define to 1 if you have the `mallinfo' function. */
#mesondefine HAVE_MALLINFO
/* Define to 1 if you have the `mallinfo2' function. */
#mesondefine HAVE_MALLINFO2
/* Define to 1 fi you have the <sys/resource.h> header file. */
#mesondefine HAVE_SYS_RESOURCE_H

View File

@ -0,0 +1,45 @@
<?xml version="1.0" encoding="UTF-8" ?>
<KeyListEntries schema="org.gnome.shell.keybindings"
group="system"
name="Launchers"
wm_name="GNOME Shell"
package="gnome-shell">
<KeyListEntry name="switch-to-application-1"
description="Activate favorite application 1"
hidden="true"/>
<KeyListEntry name="switch-to-application-2"
description="Activate favorite application 2"
hidden="true"/>
<KeyListEntry name="switch-to-application-3"
description="Activate favorite application 3"
hidden="true"/>
<KeyListEntry name="switch-to-application-4"
description="Activate favorite application 4"
hidden="true"/>
<KeyListEntry name="switch-to-application-5"
description="Activate favorite application 5"
hidden="true"/>
<KeyListEntry name="switch-to-application-6"
description="Activate favorite application 6"
hidden="true"/>
<KeyListEntry name="switch-to-application-7"
description="Activate favorite application 7"
hidden="true"/>
<KeyListEntry name="switch-to-application-8"
description="Activate favorite application 8"
hidden="true"/>
<KeyListEntry name="switch-to-application-9"
description="Activate favorite application 9"
hidden="true"/>
</KeyListEntries>

View File

@ -123,7 +123,7 @@ def locale_to_xkb(locale, name):
if xkb:
return xkb
else:
raise KeyError("layout %s explicitely disabled in overrides"
raise KeyError("layout %s explicitly disabled in overrides"
% locale)
xkb_names = sorted(name_to_xkb.keys())
if name in xkb_names:

View File

@ -0,0 +1,76 @@
<!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN"
"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd">
<node>
<!--
net.hadess.PowerProfiles:
@short_description: Power Profiles daemon
The power-profiles-daemon API is meant to be used by parts of the OS or
desktop environment to switch system power profiles based on user choice,
or user intent.
OS components would typically use the "Profiles" property to construct
their UI (2 or 3 profiles available), and monitor the "ActiveProfile"
and the "PerformanceInhibited" properties to update that UI. The UI
would try to set the "ActiveProfile" property if the user selected
a different one.
Note that the reason why the project exists and how it is different from
existing projects is explained <ulink href=" https://gitlab.freedesktop.org/hadess/power-profiles-daemon/-/blob/master/README.md">
in the project's README file</ulink>.
The object path will be "/net/hadess/PowerProfiles".
-->
<interface name="net.hadess.PowerProfiles">
<!--
ActiveProfile:
The type of the currently active profile. It might change automatically
if the "performance" profile was selected but it got inhibited, in which
case the "PerformanceInhibited" property will reflect the reason.
-->
<property name="ActiveProfile" type="s" access="readwrite"/>
<!--
PerformanceInhibited:
This will be set if the performance power profile is unavailable, with
the value being used to identify the reason for unavailability. As new
reasons can be added, it is recommended that front-ends show a generic
reason if they do not recognise the value. Possible values are:
- "lap-detected" (the computer is sitting on the user's lap)
- "high-operating-temperature" (the computer is close to overheating)
- "" (the empty string, if not inhibited)
-->
<property name="PerformanceInhibited" type="s" access="read"/>
<!--
Profiles:
An array of key-pair values representing each profile. The key named
"Driver" (s) identifies the power-profiles-daemon backend code used to
implement the profile.
The key named "Profile" (s) will be one of:
- "power-saver" (battery saving profile)
- "balanced" (the default profile)
- "performance" (a profile that does not care about noise or battery consumption)
Only one of each type of profile will be listed, with the daemon choosing the
more appropriate "driver" for each profile type.
-->
<property name="Profiles" type="aa{sv}" access="read"/>
<!--
Actions:
An array of strings listing each one of the "actions" implemented in
the running daemon. This is used by API users to figure out whether
particular functionality is available in a version of the daemon.
-->
<property name="Actions" type="as" access="read"/>
</interface>
</node>

View File

@ -0,0 +1,78 @@
<!DOCTYPE node PUBLIC
"-//freedesktop//DTD D-BUS Object Introspection 1.0//EN"
"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd">
<node>
<interface name="net.reactivated.Fprint.Device">
<method name="ListEnrolledFingers">
<arg type="s" name="username" direction="in">
</arg>
<arg type="as" name="enrolled_fingers" direction="out">
</arg>
</method>
<method name="DeleteEnrolledFingers">
<arg type="s" name="username" direction="in">
</arg>
</method>
<method name="DeleteEnrolledFingers2">
</method>
<method name="Claim">
<arg type="s" name="username" direction="in">
</arg>
</method>
<method name="Release">
</method>
<method name="VerifyStart">
<arg type="s" name="finger_name" direction="in">
</arg>
</method>
<method name="VerifyStop">
</method>
<signal name="VerifyFingerSelected">
<arg type="s" name="finger_name">
</arg>
</signal>
<signal name="VerifyStatus">
<arg type="s" name="result">
</arg>
<arg type="b" name="done">
</arg>
</signal>
<method name="EnrollStart">
<arg type="s" name="finger_name" direction="in">
</arg>
</method>
<method name="EnrollStop">
</method>
<signal name="EnrollStatus">
<arg type="s" name="result">
</arg>
<arg type="b" name="done">
</arg>
</signal>
<property name="name" type="s" access="read">
</property>
<property name="num-enroll-stages" type="i" access="read">
</property>
<property name="scan-type" type="s" access="read">
</property>
</interface>
</node>

View File

@ -0,0 +1,18 @@
<!DOCTYPE node PUBLIC
"-//freedesktop//DTD D-BUS Object Introspection 1.0//EN"
"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd">
<node>
<interface name="net.reactivated.Fprint.Manager">
<method name="GetDevices">
<arg type="ao" name="devices" direction="out">
</arg>
</method>
<method name="GetDefaultDevice">
<arg type="o" name="device" direction="out">
</arg>
</method>
</interface>
</node>

View File

@ -20,6 +20,12 @@
<method name="ListSessions">
<arg name="sessions" type="a(susso)" direction="out"/>
</method>
<method name="CanRebootToBootLoaderMenu">
<arg type="s" direction="out"/>
</method>
<method name="SetRebootToBootLoaderMenu">
<arg type="t" direction="in"/>
</method>
<signal name="PrepareForSleep">
<arg type="b" direction="out"/>
</signal>

View File

@ -1,26 +0,0 @@
<node>
<interface name="org.gnome.Magnifier.ZoomRegion">
<method name="setMagFactor">
<arg type="d" direction="in"/>
<arg type="d" direction="in"/>
</method>
<method name="getMagFactor">
<arg type="d" direction="out"/>
<arg type="d" direction="out"/>
</method>
<method name="setRoi">
<arg type="ai" direction="in"/>
</method>
<method name="getRoi">
<arg type="ai" direction="out"/>
</method>
<method name="shiftContentsTo">
<arg type="i" direction="in"/>
<arg type="i" direction="in"/>
<arg type="b" direction="out"/>
</method>
<method name="moveResize">
<arg type="ai" direction="in"/>
</method>
</interface>
</node>

View File

@ -1,54 +0,0 @@
<node>
<interface name="org.gnome.Magnifier">
<method name="setActive">
<arg type="b" direction="in"/>
</method>
<method name="isActive">
<arg type="b" direction="out"/>
</method>
<method name="showCursor"/>
<method name="hideCursor"/>
<method name="createZoomRegion">
<arg type="d" direction="in"/>
<arg type="d" direction="in"/>
<arg type="ai" direction="in"/>
<arg type="ai" direction="in"/>
<arg type="o" direction="out"/>
</method>
<method name="addZoomRegion">
<arg type="o" direction="in"/>
<arg type="b" direction="out"/>
</method>
<method name="getZoomRegions">
<arg type="ao" direction="out"/>
</method>
<method name="clearAllZoomRegions"/>
<method name="fullScreenCapable">
<arg type="b" direction="out"/>
</method>
<method name="setCrosswireSize">
<arg type="i" direction="in"/>
</method>
<method name="getCrosswireSize">
<arg type="i" direction="out"/>
</method>
<method name="setCrosswireLength">
<arg type="i" direction="in"/>
</method>
<method name="getCrosswireLength">
<arg type="i" direction="out"/>
</method>
<method name="setCrosswireClip">
<arg type="b" direction="in"/>
</method>
<method name="getCrosswireClip">
<arg type="b" direction="out"/>
</method>
<method name="setCrosswireColor">
<arg type="u" direction="in"/>
</method>
<method name="getCrosswireColor">
<arg type="u" direction="out"/>
</method>
</interface>
</node>

View File

@ -0,0 +1,191 @@
<!DOCTYPE node PUBLIC
'-//freedesktop//DTD D-BUS Object Introspection 1.0//EN'
'http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd'>
<node>
<!--
org.gnome.Mutter.ScreenCast:
@short_description: Screen cast interface
This API is private and not intended to be used outside of the integrated
system that uses libmutter. No compatibility between versions are
promised.
-->
<interface name="org.gnome.Mutter.ScreenCast">
<!--
CreateSession:
@properties: Properties
@session_path: Path to the new session object
* "remote-desktop-session-id" (s): The ID of a remote desktop session.
Remote desktop driven screen casts
are started and stopped by the remote
desktop session.
* "disable-animations" (b): Set to "true" if the screen cast application
would prefer animations to be globally
disabled, while the session is running. Default
is "false". Available since version 3.
-->
<method name="CreateSession">
<arg name="properties" type="a{sv}" direction="in" />
<arg name="session_path" type="o" direction="out" />
</method>
<!--
Version:
@short_description: API version
-->
<property name="Version" type="i" access="read" />
</interface>
<!--
org.gnome.Mutter.ScreenCast.Session:
@short_description: Screen cast session
-->
<interface name="org.gnome.Mutter.ScreenCast.Session">
<!--
Start:
Start the screen cast session
-->
<method name="Start" />
<!--
Stop:
Stop the screen cast session
-->
<method name="Stop" />
<!--
Closed:
The session has closed.
-->
<signal name="Closed" />
<!--
RecordMonitor:
@connector: Connector of the monitor to record
@properties: Properties
@stream_path: Path to the new stream object
Record a single monitor.
Available @properties include:
* "cursor-mode" (u): Cursor mode. Default: 'hidden' (see below)
Available since API version 2.
* "is-recording" (b): Whether this is a screen recording. May be
be used for choosing panel icon.
Default: false. Available since API version 4.
Available cursor mode values:
0: hidden - cursor is not included in the stream
1: embedded - cursor is included in the framebuffer
2: metadata - cursor is included as metadata in the PipeWire stream
-->
<method name="RecordMonitor">
<arg name="connector" type="s" direction="in" />
<arg name="properties" type="a{sv}" direction="in" />
<arg name="stream_path" type="o" direction="out" />
</method>
<!--
RecordWindow:
@properties: Properties used determining what window to select
@stream_path: Path to the new stream object
Supported since API version 2.
Record a single window. The cursor will not be included.
Available @properties include:
* "window-id" (t): Id of the window to record.
* "cursor-mode" (u): Cursor mode. Default: 'hidden' (see RecordMonitor).
* "is-recording" (b): Whether this is a screen recording. May be
be used for choosing panel icon.
Default: false. Available since API version 4.
-->
<method name="RecordWindow">
<arg name="properties" type="a{sv}" direction="in" />
<arg name="stream_path" type="o" direction="out" />
</method>
<!--
RecordArea:
@x: X position of the recorded area
@y: Y position of the recorded area
@width: width of the recorded area
@height: height of the recorded area
@properties: Properties
@stream_path: Path to the new stream object
Record an area of the stage. The coordinates are in stage coordinates.
The size of the stream does not necessarily match the size of the
recorded area, and will depend on DPI scale of the affected monitors.
Available @properties include:
* "cursor-mode" (u): Cursor mode. Default: 'hidden' (see below)
Available since API version 2.
* "is-recording" (b): Whether this is a screen recording. May be
be used for choosing panel icon.
Default: false. Available since API version 4.
Available cursor mode values:
0: hidden - cursor is not included in the stream
1: embedded - cursor is included in the framebuffer
2: metadata - cursor is included as metadata in the PipeWire stream
-->
<method name="RecordArea">
<arg name="x" type="i" direction="in" />
<arg name="y" type="i" direction="in" />
<arg name="width" type="i" direction="in" />
<arg name="height" type="i" direction="in" />
<arg name="properties" type="a{sv}" direction="in" />
<arg name="stream_path" type="o" direction="out" />
</method>
</interface>
<!--
org.gnome.Mutter.ScreenCast.Stream:
@short_description: Screen cast stream
-->
<interface name="org.gnome.Mutter.ScreenCast.Stream">
<!--
PipeWireStreamAdded:
@short_description: Pipewire stream added
A signal emitted when PipeWire stream for the screen cast stream has
been created. The @node_id corresponds to the PipeWire stream node.
-->
<signal name="PipeWireStreamAdded">
<annotation name="org.gtk.GDBus.C.Name" value="pipewire-stream-added"/>
<arg name="node_id" type="u" direction="out" />
</signal>
<!--
Parameters:
@short_description: Optional stream parameters
Available parameters include:
* "position" (ii): Position of the source of the stream in the
compositor coordinate space.
* "size" (ii): Size of the source of the stream in the compositor
coordinate space.
-->
<property name="Parameters" type="a{sv}" access="read" />
</interface>
</node>

View File

@ -3,6 +3,9 @@
<method name="GetAppId">
<arg type="s" direction="out"/>
</method>
<method name="GetFlags">
<arg type="u" direction="out"/>
</method>
<method name="GetReason">
<arg type="s" direction="out"/>
</method>

View File

@ -180,10 +180,10 @@
Enable an extension.
-->
<method name="EnableExtension"> \
<arg type="s" direction="in" name="uuid"/> \
<arg type="b" direction="out" name="success"/> \
</method> \
<method name="EnableExtension">
<arg type="s" direction="in" name="uuid"/>
<arg type="b" direction="out" name="success"/>
</method>
<!--
DisableExtension:
@ -192,10 +192,10 @@
Disable an extension.
-->
<method name="DisableExtension"> \
<arg type="s" direction="in" name="uuid"/> \
<arg type="b" direction="out" name="success"/> \
</method> \
<method name="DisableExtension">
<arg type="s" direction="in" name="uuid"/>
<arg type="b" direction="out" name="success"/>
</method>
<!--
LaunchExtensionPrefs:

View File

@ -70,6 +70,14 @@
-->
<property name="AnimationsEnabled" type="b" access="read"/>
<!--
ScreenSize:
@short_description: The size of the screen
Since: 3
-->
<property name="ScreenSize" type="(ii)" access="read"/>
<property name="version" type="u" access="read"/>
</interface>
</node>

View File

@ -1,7 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<gresources>
<gresource prefix="/org/gnome/shell/dbus-interfaces">
<file preprocess="xml-stripblanks">net.hadess.PowerProfiles.xml</file>
<file preprocess="xml-stripblanks">net.hadess.SensorProxy.xml</file>
<file preprocess="xml-stripblanks">net.reactivated.Fprint.Device.xml</file>
<file preprocess="xml-stripblanks">net.reactivated.Fprint.Manager.xml</file>
<file preprocess="xml-stripblanks">org.freedesktop.Application.xml</file>
<file preprocess="xml-stripblanks">org.freedesktop.bolt1.Device.xml</file>
<file preprocess="xml-stripblanks">org.freedesktop.bolt1.Manager.xml</file>
@ -26,8 +29,7 @@
<file preprocess="xml-stripblanks">org.freedesktop.realmd.Service.xml</file>
<file preprocess="xml-stripblanks">org.freedesktop.UPower.Device.xml</file>
<file preprocess="xml-stripblanks">org.freedesktop.UPower.xml</file>
<file preprocess="xml-stripblanks">org.gnome.Magnifier.xml</file>
<file preprocess="xml-stripblanks">org.gnome.Magnifier.ZoomRegion.xml</file>
<file preprocess="xml-stripblanks">org.gnome.Mutter.ScreenCast.xml</file>
<file preprocess="xml-stripblanks">org.gnome.ScreenSaver.xml</file>
<file preprocess="xml-stripblanks">org.gnome.SessionManager.EndSessionDialog.xml</file>
<file preprocess="xml-stripblanks">org.gnome.SessionManager.Inhibitor.xml</file>

View File

@ -1,4 +0,0 @@
[org.gnome.shell.overrides]
attach-modal-dialogs = /desktop/gnome/shell/windows/attach_modal_dialogs
edge-tiling = /desktop/gnome/shell/windows/edge_tiling
workspaces-only-on-primary = /desktop/gnome/shell/windows/workspaces_only_on_primary

View File

@ -2,14 +2,16 @@
<gresources>
<gresource prefix="/org/gnome/shell/theme">
<file>calendar-today.svg</file>
<file alias="icons/scalable/status/carousel-arrow-next-24-symbolic.svg">carousel-arrow-next-24-symbolic.svg</file>
<file alias="icons/scalable/status/carousel-arrow-back-24-symbolic.svg">carousel-arrow-back-24-symbolic.svg</file>
<file>checkbox-focused.svg</file>
<file>checkbox-off-focused.svg</file>
<file>checkbox-off.svg</file>
<file>checkbox.svg</file>
<file alias="icons/scalable/actions/color-pick.svg">color-pick.svg</file>
<file>dash-placeholder.svg</file>
<file>gnome-shell.css</file>
<file>gnome-shell-high-contrast.css</file>
<file>gnome-shell-start.svg</file>
<file alias="icons/scalable/status/message-indicator-symbolic.svg">message-indicator-symbolic.svg</file>
<file>no-events.svg</file>
<file>no-notifications.svg</file>
@ -20,17 +22,21 @@
<file alias="icons/scalable/actions/pointer-drag-symbolic.svg">pointer-drag-symbolic.svg</file>
<file alias="icons/scalable/actions/pointer-primary-click-symbolic.svg">pointer-primary-click-symbolic.svg</file>
<file alias="icons/scalable/actions/pointer-secondary-click-symbolic.svg">pointer-secondary-click-symbolic.svg</file>
<file alias="icons/scalable/actions/preview-close-symbolic.svg">window-close-24-symbolic.svg</file>
<file alias="icons/scalable/status/keyboard-caps-lock-filled-symbolic.svg">keyboard-caps-lock-filled-symbolic.svg</file>
<file alias="icons/scalable/status/keyboard-enter-symbolic.svg">keyboard-enter-symbolic.svg</file>
<file alias="icons/scalable/status/keyboard-hide-symbolic.svg">keyboard-hide-symbolic.svg</file>
<file alias="icons/scalable/status/keyboard-layout-filled-symbolic.svg">keyboard-layout-filled-symbolic.svg</file>
<file alias="icons/scalable/status/keyboard-shift-filled-symbolic.svg">keyboard-shift-filled-symbolic.svg</file>
<file>process-working.svg</file>
<file alias="icons/scalable/status/screen-privacy-disabled-symbolic.svg">screen-privacy-disabled-symbolic.svg</file>
<file alias="icons/scalable/status/screen-privacy-symbolic.svg">screen-privacy-symbolic.svg</file>
<file>toggle-off.svg</file>
<file>toggle-off-dark.svg</file>
<file>toggle-off-hc.svg</file>
<file>toggle-on.svg</file>
<file>toggle-on-dark.svg</file>
<file>toggle-on-hc.svg</file>
<file>workspace-placeholder.svg</file>
</gresource>
</gresources>

View File

@ -1,10 +0,0 @@
[Unit]
Description=GNOME Shell on Wayland
DefaultDependencies=no
Requisite=gnome-session-initialized.target
PartOf=gnome-session-initialized.target
Before=gnome-session-initialized.target
Requires=gnome-shell-wayland.service
After=gnome-shell-wayland.service

View File

@ -1,4 +1,4 @@
[portal]
DBusName=org.freedesktop.impl.portal.desktop.gnome
DBusName=org.gnome.Shell.Portal
Interfaces=org.freedesktop.impl.portal.Access
UseIn=gnome

View File

@ -41,6 +41,7 @@ foreach service_file : service_files
)
endforeach
theme_deps = []
subdir('dbus-interfaces')
subdir('icons')
@ -72,9 +73,13 @@ configure_file(
install_dir: pkgdatadir
)
keybinding_files = [
'50-gnome-shell-launchers.xml',
'50-gnome-shell-system.xml',
]
install_data('gnome-shell.portal', install_dir: portaldir)
install_data('50-gnome-shell-system.xml', install_dir: keysdir)
install_data(keybinding_files, install_dir: keysdir)
schemaconf = configuration_data()
@ -101,22 +106,21 @@ if have_systemd
unitconf.set('bindir', bindir)
configure_file(
input: 'gnome-shell-x11.service.in',
output: 'gnome-shell-x11.service',
input: 'org.gnome.Shell@x11.service.in',
output: 'org.gnome.Shell@x11.service',
configuration: unitconf,
install_dir: systemduserunitdir
)
configure_file(
input: 'gnome-shell-wayland.service.in',
output: 'gnome-shell-wayland.service',
input: 'org.gnome.Shell@wayland.service.in',
output: 'org.gnome.Shell@wayland.service',
configuration: unitconf,
install_dir: systemduserunitdir
)
units = files('gnome-shell-x11.target',
'gnome-shell-wayland.target',
'gnome-shell-disable-extensions.service')
units = files('org.gnome.Shell.target',
'org.gnome.Shell-disable-extensions.service')
install_data(units, install_dir: systemduserunitdir)
endif
@ -127,5 +131,3 @@ custom_target('compile-schemas',
output: 'gschemas.compiled',
command: [find_program('glib-compile-schemas'), meson.current_build_dir()],
build_by_default: true)
install_data('gnome-shell-overrides.convert', install_dir: convertdir)

View File

@ -1,10 +1,10 @@
[Unit]
Description=GNOME Shell on X11
Description=GNOME Shell
DefaultDependencies=no
Requisite=gnome-session-initialized.target
PartOf=gnome-session-initialized.target
Before=gnome-session-initialized.target
Requires=gnome-shell-x11.service
After=gnome-shell-x11.service
Wants=org.gnome.Shell@wayland.service
Wants=org.gnome.Shell@x11.service

View File

@ -1,7 +1,7 @@
[Unit]
Description=GNOME Shell on Wayland
# On wayland, force a session shutdown
OnFailure=gnome-shell-disable-extensions.service gnome-session-shutdown.target
OnFailure=org.gnome.Shell-disable-extensions.service gnome-session-shutdown.target
OnFailureJobMode=replace-irreversibly
CollectMode=inactive-or-failed
RefuseManualStart=on
@ -13,18 +13,21 @@ Requisite=gnome-session-initialized.target
PartOf=gnome-session-initialized.target
Before=gnome-session-initialized.target
# The units already conflict because they use the same BusName
#Conflicts=gnome-shell-x11.service
[Service]
Slice=session.slice
Type=notify
# NOTE: This can be replaced with ConditionEnvironment=XDG_SESSION_TYPE=%I in
# the [Unit] section with systemd >= 246. Also, the current solution is
# kind of painful as systemd had a bug where it retries the condition.
# Only start if the template instance matches the session type.
ExecCondition=/bin/sh -c 'test "$XDG_SESSION_TYPE" = "%I" || exit 2'
ExecStart=@bindir@/gnome-shell
# unset some environment variables that were set by the shell and won't work now that the shell is gone
ExecStopPost=-systemctl --user unset-environment GNOME_SETUP_DISPLAY WAYLAND_DISPLAY DISPLAY XAUTHORITY
# Exit code 1 means we are probably *not* dealing with an extension failure
SuccessExitStatus=1
# unset some environment variables that were set by the shell and won't work now that the shell is gone
ExecStopPost=-/bin/sh -c 'test "$SERVICE_RESULT" != "exec-condition" && systemctl --user unset-environment GNOME_SETUP_DISPLAY WAYLAND_DISPLAY DISPLAY XAUTHORITY'
# On wayland we cannot restart
Restart=no
# Kill any stubborn child processes after this long

View File

@ -1,7 +1,7 @@
[Unit]
Description=GNOME Shell on X11
# On X11, try to show the GNOME Session Failed screen
OnFailure=gnome-shell-disable-extensions.service gnome-session-failed.target
OnFailure=org.gnome.Shell-disable-extensions.service gnome-session-failed.target
OnFailureJobMode=replace
CollectMode=inactive-or-failed
RefuseManualStart=on
@ -13,18 +13,24 @@ Requisite=gnome-session-initialized.target
PartOf=gnome-session-initialized.target
Before=gnome-session-initialized.target
# The units already conflict because they use the same BusName
#Conflicts=gnome-shell-wayland.service
# Limit startup frequency more than the default
StartLimitIntervalSec=15s
StartLimitBurst=3
[Service]
Slice=session.slice
Type=notify
# NOTE: This can be replaced with ConditionEnvironment=XDG_SESSION_TYPE=%I in
# the [Unit] section with systemd >= 246. Also, the current solution is
# kind of painful as systemd had a bug where it retries the condition.
# Only start if the template instance matches the session type.
ExecCondition=/bin/sh -c 'test "$XDG_SESSION_TYPE" = "%I" || exit 2'
ExecStart=@bindir@/gnome-shell
# Exit code 1 means we are probably *not* dealing with an extension failure
SuccessExitStatus=1
# On X11 we do not need to unset any variables
# On X11 we want to restart on-success (Alt+F2 + r) and on-failure.
Restart=always
# Do not wait before restarting the shell

View File

@ -41,7 +41,7 @@
</description>
</key>
<key name="disable-extension-version-validation" type="b">
<default>true</default>
<default>false</default>
<summary>Disables the validation of extension version compatibility</summary>
<description>
GNOME Shell will only load extensions that claim to support the current
@ -50,20 +50,13 @@
</description>
</key>
<key name="favorite-apps" type="as">
<default>[ 'org.gnome.Epiphany.desktop', 'org.gnome.Geary.desktop', 'org.gnome.Calendar.desktop', 'org.gnome.Music.desktop', 'org.gnome.Photos.desktop', 'org.gnome.Nautilus.desktop', 'org.gnome.Software.desktop' ]</default>
<default>[ 'org.gnome.Epiphany.desktop', 'org.gnome.Calendar.desktop', 'org.gnome.Music.desktop', 'org.gnome.Nautilus.desktop', 'org.gnome.Software.desktop' ]</default>
<summary>List of desktop file IDs for favorite applications</summary>
<description>
The applications corresponding to these identifiers
will be displayed in the favorites area.
</description>
</key>
<key name="app-picker-view" type="u">
<default>0</default>
<summary>App Picker View</summary>
<description>
Index of the currently selected view in the application picker.
</description>
</key>
<key name="command-history" type="as">
<default>[]</default>
<summary>History for command (Alt-F2) dialog</summary>
@ -101,16 +94,42 @@
adapter is ever seen not to have devices associated to it.
</description>
</key>
<key name="introspect" type="b">
<default>false</default>
<summary>Enable introspection API</summary>
<key name="welcome-dialog-last-shown-version" type="s">
<default>''</default>
<summary>The last version the “Welcome to GNOME” dialog was shown for</summary>
<description>
Enables a D-Bus API that allows to introspect the application state of
the shell.
This key determines for which version the “Welcome to GNOME” dialog was
last shown. An empty string represents the oldest possible version, and
a huge number will represent versions that do not exist yet. This huge
number can be used to effectively disable the dialog.
</description>
</key>
<key name="app-picker-layout" type="aa{sv}">
<default>[]</default>
<default><![CDATA[
[{
'org.gnome.Geary.desktop': <{'position': <0>}>,
'org.gnome.Contacts.desktop': <{'position': <1>}>,
'org.gnome.Weather.desktop': <{'position': <2>}>,
'org.gnome.clocks.desktop': <{'position': <3>}>,
'org.gnome.Maps.desktop': <{'position': <4>}>,
'org.gnome.Books.desktop': <{'position': <5>}>,
'org.gnome.Photos.desktop': <{'position': <6>}>,
'org.gnome.Totem.desktop': <{'position': <7>}>,
'org.gnome.Calculator.desktop': <{'position': <8>}>,
'org.gnome.gedit.desktop': <{'position': <9>}>,
'simple-scan.desktop': <{'position': <10>}>,
'gnome-control-center.desktop': <{'position': <11>}>,
'gnome-system-monitor.desktop': <{'position': <12>}>,
'org.gnome.Boxes.desktop': <{'position': <13>}>,
'org.gnome.Terminal.desktop': <{'position': <14>}>,
'Utilities': <{'position': <15>}>,
'org.gnome.Characters.desktop': <{'position': <16>}>,
'yelp.desktop': <{'position': <17>}>,
'org.gnome.Screenshot.desktop': <{'position': <18>}>,
'org.gnome.Cheese.desktop': <{'position': <19>}>,
'org.gnome.font-viewer.desktop': <{'position': <20>}>
}]
]]></default>
<summary>Layout of the app picker</summary>
<description>
Layout of the app picker. Each entry in the array is a page. Pages are
@ -132,6 +151,20 @@
Keybinding to open the application menu.
</description>
</key>
<key name="shift-overview-up" type="as">
<default>["&lt;Super&gt;&lt;Alt&gt;Up"]</default>
<summary>Keybinding to shift between overview states</summary>
<description>
Keybinding to shift between session, window picker and app grid
</description>
</key>
<key name="shift-overview-down" type="as">
<default>["&lt;Super&gt;&lt;Alt&gt;Down"]</default>
<summary>Keybinding to shift between overview states</summary>
<description>
Keybinding to shift between app grid, window picker and session
</description>
</key>
<key name="toggle-application-view" type="as">
<default>["&lt;Super&gt;a"]</default>
<summary>Keybinding to open the “Show Applications” view</summary>
@ -197,6 +230,14 @@
<default>["&lt;Super&gt;9"]</default>
<summary>Switch to application 9</summary>
</key>
<key name="switch-realm" type="as">
<default><![CDATA[['<Super>Tab']]]></default>
<summary>Open Realm Switcher</summary>
</key>
<key name="switch-realm-backward" type="as">
<default><![CDATA[['<Super><Shift>Tab']]]></default>
<summary>Open Realm Switcher Backwards</summary>
</key>
</schema>
<schema id="org.gnome.shell.app-switcher"

View File

@ -176,7 +176,186 @@
"-",
":",
"'",
"@"
"@",
" ๎",
"๏",
"๛",
"๚"
]
]
]
},
{
"level": "shift",
"mode": "latched",
"rows": [
[
[
"+"
],
[
"๑"
],
[
"๒"
],
[
"๓"
],
[
"๔"
],
[
"ู"
],
[
"฿"
],
[
"๕"
],
[
"๖"
],
[
"๗"
],
[
"๘"
],
[
"๙"
]
],
[
[
""
],
[
"\""
],
[
"ฎ"
],
[
"ฑ"
],
[
"ธ"
],
[
"ํ"
],
[
"๊"
],
[
"ณ"
],
[
"ฯ"
],
[
"ญ"
],
[
"ฐ"
],
[
","
]
],
[
[
"ฤ"
],
[
"ฆ"
],
[
"ฏ"
],
[
"โ"
],
[
"ฌ"
],
[
"็"
],
[
"๋"
],
[
"ษ"
],
[
"ศ"
],
[
"ซ"
],
[
"."
],
[
"ฅ"
]
],
[
[
"("
],
[
")"
],
[
"ฉ"
],
[
"ฮ"
],
[
"ฺ"
],
[
"์"
],
[
"?"
],
[
"ฒ"
],
[
"ฬ"
],
[
"ฦ"
]
],
[
[
","
],
[
" "
],
[
".",
"#",
"!",
",",
"?",
"-",
":",
"'",
"@",
" ๎",
"๏",
"๛",
"๚"
]
]
]

View File

@ -0,0 +1,36 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
width="24"
height="24"
viewBox="0 0 24 24.000001"
version="1.1"
id="svg19258">
<defs
id="defs19252" />
<metadata
id="metadata19255">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
id="g834"
transform="rotate(-90,-246.75894,471.75774)"
style="fill:#241f31">
<path
style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#241f31;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate"
d="m 213.0007,724.40348 -10.3711,7.3945 v 0 a 1.5,1.5 0 0 0 -0.6308,1.2187 v 1.5 h 1.5 a 1.5,1.5 0 0 0 0.8711,-0.2793 l 8.6289,-6.1523 8.6289,6.1523 a 1.5,1.5 0 0 0 0.8711,0.2793 h 1.5 v -1.5 a 1.5,1.5 0 0 0 -0.6309,-1.2187 v 0 z"
id="path832" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.3 KiB

View File

@ -0,0 +1,36 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
width="24"
height="24"
viewBox="0 0 24 24.000001"
version="1.1"
id="svg19258">
<defs
id="defs19252" />
<metadata
id="metadata19255">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
id="g872"
transform="matrix(0,-1,-1,0,742.51668,224.9988)"
style="fill:#241f31">
<path
style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#241f31;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate"
d="m 213.0007,724.40348 -10.3711,7.3945 v 0 a 1.5,1.5 0 0 0 -0.6308,1.2187 v 1.5 h 1.5 a 1.5,1.5 0 0 0 0.8711,-0.2793 l 8.6289,-6.1523 8.6289,6.1523 a 1.5,1.5 0 0 0 0.8711,0.2793 h 1.5 v -1.5 a 1.5,1.5 0 0 0 -0.6309,-1.2187 v 0 z"
id="path870" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.3 KiB

View File

@ -11,7 +11,32 @@ stage {
}
.toggle-switch { width: 48px; }
.toggle-switch-us, .toggle-switch-intl {
background-image: url("resource:///org/gnome/shell/theme/toggle-off-hc.svg");
&:checked { background-image: url("resource:///org/gnome/shell/theme/toggle-on-hc.svg"); }
.toggle-switch {
background-image: url("resource:///org/gnome/shell/theme/toggle-off-hc.svg");
&:checked { background-image: url("resource:///org/gnome/shell/theme/toggle-on-hc.svg"); }
}
//force opaque panel
#panel {
&.login-screen,
&.unlock-screen,
&:overview {
background-color: #000;
.panel-corner {
-panel-corner-opacity: 1;
}
}
.panel-button {
color: #fff !important;
}
}
//thumbnail app icons no dropshadow and forced color
.window-picker .icon-dropshadow {
icon-shadow: none;
background-color: $osd_bg_color;
padding: $base_padding * 2;
border-radius: $modal_radius;
}

View File

@ -11,6 +11,6 @@ will then be synchronized periodically before releases.
GNOME Shell Sass is distributed under the terms of the GNU General Public
License, version 2 or later. See the [COPYING][license] file for details.
[shell-subtree]: https://gitlab.gnome.org/GNOME/gnome-shell/tree/master/data/theme/gnome-shell-sass
[shell-subtree]: https://gitlab.gnome.org/GNOME/gnome-shell/tree/HEAD/data/theme/gnome-shell-sass
[sass-repo]: https://gitlab.gnome.org/GNOME/gnome-shell-sass
[license]: COPYING

View File

@ -28,6 +28,7 @@ $osd_borders_color: transparentize(black, 0.3);
$osd_outer_borders_color: transparentize(white, 0.84);
$shadow_color: if($variant == 'light', rgba(0,0,0,0.1), rgba(0,0,0,0.2));
$system_bg_color: desaturate(#241f31,100%); //neutralize the HIG color
//insensitive state derived colors
$insensitive_fg_color: mix($fg_color, $bg_color, 50%);

View File

@ -31,7 +31,7 @@ $base_margin: 4px;
$base_spacing: 6px;
// border radii
$base_border_radius: 5px;
$base_border_radius: 8px;
$modal_radius:$base_border_radius * 2;
@ -76,17 +76,16 @@ stage {
%osd_panel {
color: $osd_fg_color;
background-color: $osd_bg_color;
border: 1px solid $osd_outer_borders_color;
//border: 1px solid $osd_outer_borders_color;
border-radius: $base_border_radius * 2 + 4px;
padding: $base_padding * 2;
}
// Overview panels
// Overview panels
// for the dash and workspace switcher
%overview_panel {
color: $osd_fg_color;
background-color: transparentize($osd_bg_color, 0.2);
border: 1px solid $osd_outer_borders_color;
background-color: transparentize($osd_fg_color, 0.9);
}
// icon tiles
@ -130,8 +129,8 @@ stage {
border-bottom-width: 0;
&:insensitive { @include button(insensitive, $shadow: none); }
&:hover { @include button(hover, $shadow: none); }
&:focus { @include button(focus, $shadow: none); }
&:hover { @include button(hover, $shadow: none); }
&:active { @include button(active, $shadow: none); }
// radius is 2 pixel less to fit in bubble
@ -143,7 +142,7 @@ stage {
border-right-width: 0;
border-radius: 0 0 $modal_radius - 2px 0;
}
&:first-child:last-child {
border-radius: 0 0 $modal_radius - 2px $modal_radius - 2px;
}

View File

@ -46,7 +46,7 @@
border-color: if($fc==$selected_bg_color,
$selected_borders_color,
darken($fc,35%));
box-shadow: inset 0 0 0 1px $fc;
box-shadow: inset 0 0 0 2px $fc;
}
@if $t==hover { }
@if $t==insensitive {
@ -79,7 +79,7 @@
@function draw_button_hilight_color($c) {
//
// calculate the right top hilight color for buttons
// calculate the right top highlight color for buttons
//
// $c: base color;
//
@ -218,7 +218,8 @@
&:drop {
.overview-icon {
background-color: transparentize($selected_bg_color, .15);
border: 2px solid $selected_bg_color; //already 2px transparent so no jumping
background-color: transparentize($selected_bg_color, .8);
}
}

View File

@ -26,6 +26,7 @@ $osd_borders_color: rgba(0,0,0, 0.7);
$osd_outer_borders_color: rgba(255,255,255, 0.1);
$shadow_color: rgba(0,0,0, 0.1);
$system_bg_color: desaturate(#241f31,100%); //neutralize the HIG color
//insensitive state derived colors
$insensitive_fg_color: mix($fg_color, $bg_color, 50%);

View File

@ -37,8 +37,8 @@
@import 'widgets/window-picker';
@import 'widgets/search-entry';
@import 'widgets/search-results';
@import 'widgets/app-grid';
@import 'widgets/dash';
@import 'widgets/app-grid';
@import 'widgets/workspace-thumbnails';
// A11y / misc
@import 'widgets/a11y';
@ -49,3 +49,5 @@
// Lock / login screens
@import 'widgets/login-dialog';
@import 'widgets/screen-shield';
@import 'widgets/realms';

View File

@ -4,10 +4,14 @@ $app_icon_size: 96px;
// app icons
.icon-grid {
row-spacing: $base_spacing * 6;
column-spacing: $base_spacing * 6;
row-spacing: $base_spacing * 2;
column-spacing: $base_spacing * 2;
max-row-spacing: $base_spacing * 12;
max-column-spacing: $base_spacing * 12;
page-padding-top: $base_padding * 4;
page-padding-bottom: $base_padding * 4;
page-padding-left: $base_padding * 2;
page-padding-right: $base_padding * 2;
}
/* App Icons */
@ -30,16 +34,15 @@ $app_grid_fg_color: #fff;
/* App Folders */
.app-well-app.app-folder {
background-color: transparentize($osd_bg_color, 0.8);
background-color: $dash_background_color;
border-radius: $base_border_radius + 4px; // same as %icon_tile
}
// expanded folder
.app-folder-dialog {
.app-folder-dialog { //style like the dash
border-radius: $modal_radius * 1.5;
border: 1px solid $osd_outer_borders_color;
background-color: transparentize(darken($osd_bg_color,10%), 0.05);
padding: 12px;
background-color: $dash_background_color;
padding: 12px 0px 12px 0px;
& .folder-name-container {
padding: 24px 36px 0;
@ -71,14 +74,14 @@ $app_grid_fg_color: #fff;
& .icon-grid {
row-spacing: $base_spacing * 2;
column-spacing: $base_spacing * 5;
page-padding-top: 0;
page-padding-bottom: 0;
page-padding-left: 0;
page-padding-right: 0;
}
& .page-indicators {
margin-bottom: 18px;
.page-indicator {
padding: 15px 12px;
}
}
}
.app-folder-dialog-container {
@ -87,13 +90,6 @@ $app_grid_fg_color: #fff;
height: 620px;
}
.app-folder-icon {
padding: $base_padding;
spacing-rows: $base_spacing;
spacing-columns: $base_spacing;
}
// Running app indicator (also shown in dash)
.app-well-app-running-dot {
height: 5px;
@ -112,14 +108,13 @@ $app_grid_fg_color: #fff;
}
// right-click app menu
.app-menu,
.app-well-menu {
.app-menu {
max-width: 27.25em;
}
// App Grid pagination indicators
.page-indicator {
padding: 15px 20px;
padding: $base_padding $base_padding * 2 0;
.page-indicator-icon {
width: 10px;
@ -129,10 +124,8 @@ $app_grid_fg_color: #fff;
}
}
// Some hacks I don't even know
.all-apps {
// horizontal padding to make sure scrollbars or dash don't overlap content
padding: 0px 88px 10px 88px;
.apps-scroll-view {
padding: 0;
}
// shutdown and other actions in the grid
@ -142,3 +135,33 @@ $app_grid_fg_color: #fff;
border-radius: 99px;
icon-size: $app_icon_size * 0.5;
}
.page-navigation-hint {
width: 300px;
&.dnd {
background: rgba(255, 255, 255, 0.1);
}
&.next:ltr,
&.previous:rtl {
background-gradient-start: rgba(255, 255, 255, 0.05);
background-gradient-end: transparent;
background-gradient-direction: horizontal;
border-radius: 15px 0px 0px 15px;
}
&.previous:ltr,
&.next:rtl {
background-gradient-start: transparent;
background-gradient-end: rgba(255, 255, 255, 0.05);
background-gradient-direction: horizontal;
border-radius: 0px 15px 15px 0px;
}
}
.page-navigation-arrow {
margin: 6px;
width: 24px;
height: 24px;
}

View File

@ -14,5 +14,5 @@
// Dropshadow for large icons
.icon-dropshadow {
icon-shadow: 0 1px 2px rgba(black, 0.4);
icon-shadow: 0 1px 5px rgba(black, 0.8);
}

View File

@ -1,11 +1,11 @@
/* Date/Time Menu */
.clock-display-box {
spacing: $base_spacing / 2;
spacing: 2px;
.clock {
padding-left: $base_padding;
padding-right: $base_padding;
padding-left: $base_padding * 2;
padding-right: $base_padding * 2;
}
}
@ -170,7 +170,6 @@
height: 1.8em;
width: 2.3em;
border-radius: 2px;
padding: 0.5em 0 0;
margin: 6px;
background-color: darken($bg_color, 2%);
color: lighten($fg_color, 5%);
@ -232,7 +231,9 @@
color: $fg_color;
font-feature-settings: "tnum";
@include fontsize($base_font_size);
text-align: right;
&:ltr { text-align: right; }
&:rtl { text-align: left; }
}
// timezone offset label

View File

@ -1,20 +1,18 @@
/* Dash */
$dash_background_color: #3b3b3b;
$dash_placeholder_size: 32px;
$dash_spacing: $base_padding + 4px;
$dash_padding: $base_padding + 4px; // 10px
$dash_spacing: $base_padding / 4;
$dash_bottom_margin: $base_margin * 4;
$dash_border_radius: $modal_radius * 1.5;
#dash {
@extend %overview_panel;
@include fontsize($base_font_size - 2);
padding: ($dash_spacing / 2) 0;
border-radius: 0 $dash_border_radius $dash_border_radius 0;
border-left-width: 0;
&:rtl {
border-radius: $dash_border_radius 0 0 $dash_border_radius;
border-right-width: 0;
}
margin-top: $base_spacing * 3;
padding: 0 $dash_padding;
.placeholder {
// background-image: url("resource:///org/gnome/shell/theme/dash-placeholder.svg");
@ -27,23 +25,38 @@ $dash_border_radius: $modal_radius * 1.5;
width: $dash_placeholder_size;
height: $dash_placeholder_size;
}
.overview-icon {
padding: $dash_padding / 2;
}
}
.dash-background {
background-color: $dash_background_color;
margin-bottom: $dash_bottom_margin;
padding: $dash_padding;
border-radius: $dash_border_radius;
}
// Dash Items
.dash-item-container > StWidget {
padding: ($dash_spacing / 2) $dash_spacing;
.dash-item-container .app-well-app, .show-apps {
padding: $dash_padding $dash_spacing $dash_padding + $dash_bottom_margin;
}
.dash-separator {
width: 1px;
margin: 0 ($dash_spacing + ($dash_padding / 2)) $dash_bottom_margin;
background-color: transparentize($osd_fg_color,0.7);
}
// OSD Tooltip
.dash-label {
background-color: transparentize($osd_bg_color,0.05);
border-radius: $base_border_radius + 2px;
border:none;
box-shadow:0 0 0 1px $osd_outer_borders_color;
color: $osd_fg_color;
padding: $base_padding $base_padding + 2px;
background-color: $osd_bg_color;
border-radius: 99px;
padding: $base_padding $base_padding * 2;
text-align: center;
-x-offset: $base_margin * 2; // distance from the dash edge
-y-offset: $base_margin * 3; // distance from the dash edge
}
// Show apps button
@ -53,9 +66,8 @@ $dash_border_radius: $modal_radius * 1.5;
&:focus,
&:checked {
.overview-icon {
background-color: darken($osd_bg_color,10%);
background-color: transparentize($osd_bg_color,0.5);
color: $fg_color;
}
}
}

View File

@ -38,7 +38,7 @@
font-size: 18pt;
font-weight: 800;
&.leightweight {
&.lightweight {
font-size: 13pt;
font-weight: 800;
}
@ -135,10 +135,6 @@
spacing: 8px;
margin-bottom: 6px;
.polkit-dialog-user-icon {
border-radius: 99px;
background-size: contain;
}
.polkit-dialog-user-root-label { color: $warning_color; }
}
@ -166,3 +162,12 @@
.audio-selection-device-icon {
icon-size: $base_icon_size * 4;
}
/* Welcome dialog */
.welcome-dialog-image {
background-image: url("resource:///org/gnome/shell/theme/gnome-shell-start.svg");
background-size: contain;
/* Reasonable maximum dimensions */
height: 300px;
width: 300px;
}

View File

@ -3,7 +3,7 @@
StEntry {
border-radius: $base_border_radius;
padding: 8px;
border-width: 1px;
border-width: 0;
color: $fg_color;
@include entry(normal);
//&:hover { @include entry(hover);}

View File

@ -5,18 +5,19 @@
max-width: 23em;
}
.login-dialog {
.login-dialog,
.unlock-dialog {
//reset
border: none;
background-color: transparent;
$_gdm_bg: lighten(#2e3436, 19%);
$_gdm_bg: $system_bg_color;
StEntry {
@if $variant=='dark' {
$_gdm_entry_bg: transparentize(lighten(desaturate(#241f31, 20%), 2%), 0.5);
$_gdm_entry_bg: darken($system_bg_color, 3%);
background-color: $_gdm_entry_bg;
color: $osd_fg_color;
color: $fg_color;
}
}
@ -24,9 +25,9 @@
.modal-dialog-button {
padding: 4px 18px;
box-shadow: 0 1px 3px rgba(0,0,0,0.2);
background-color: $_gdm_bg;
border-color: $_gdm_bg;
color: $fg_color;
background-color: darken($system_bg_color, 3%);
border-color: darken($system_bg_color, 3%);
color: $osd_fg_color;
$_hover_c: lighten($_gdm_bg, 5%);
&:hover, &:focus {
@ -43,7 +44,7 @@
@include button(insensitive);
border-color: darken($_gdm_bg, 5%);
background-color: darken($_gdm_bg, 5%);
color: transparentize($fg_color, 0.3);
color: transparentize($osd_fg_color, 0.3);
}
&:default {
@include button(normal, $c:$selected_bg_color, $tc:$selected_fg_color);
@ -76,8 +77,8 @@
border-radius: 99px;
width: $base_icon_size * 2;
height: $base_icon_size * 2;
border-color: transparentize($bg_color,0.7);
background-color: transparentize($bg_color,0.7);
border-color: darken($system_bg_color, 3%);
background-color: darken($system_bg_color, 3%);
StIcon { icon-size: $base_icon_size; }
}
@ -92,7 +93,6 @@
.login-dialog-banner { color: darken($osd_fg_color,10%); }
.login-dialog-button-box { width: 23em; spacing: 5px; }
.login-dialog-message { text-align: center; }
.login-dialog-message-hint { padding-top: 0; padding-bottom: 20px; }
.login-dialog-user-selection-box { padding: 100px 0px; }
.login-dialog-not-listed-label {
padding-left: 2px;
@ -138,11 +138,10 @@
.user-widget.horizontal .user-widget-label {
@include fontsize($base_font_size + 2);
font-weight: bold;
text-align: left;
padding-left: 15px;
&:ltr { padding-left: 14px; }
&:rtl { padding-right: 14px; }
&:ltr { padding-left: 14px; text-align: left; }
&:rtl { padding-right: 14px; text-align: right; }
}
.user-widget.vertical .user-widget-label {
@ -152,6 +151,11 @@
padding-top: 16px;
}
.login-dialog-timed-login-indicator {
height: 2px;
background-color: darken($fg_color,40%);
}
.login-dialog-prompt-layout {
padding-top: 24px;
padding-bottom: 12px;

View File

@ -25,6 +25,20 @@
// NOTE: remove the padding if notification_bubble could remove margin for drop shadow
padding: $base_margin;
spacing: $base_spacing * 2;
.dnd-button {
// We need this because the focus outline isn't inset like for the buttons
// so the dnd button would grow when it gets focus if we didn't change only
// its color when focusing.
border-width: 2px;
border-color: transparent;
border-radius: 99px;
border-style: solid;
&:focus {
border-color: transparentize($selected_bg_color, 0.4);
}
}
}
// message bubbles
@ -71,9 +85,11 @@
> .event-time {
color: transparentize($fg_color, 0.5);
@include fontsize($base_font_size - 2);
text-align: right;
/* HACK: the label should be baseline-aligned with a 1em label, fake this with some bottom padding */
padding-bottom: 0.13em;
&:ltr { text-align: right };
&:rtl { text-align: left };
}
}
@ -97,7 +113,7 @@
/* Media Controls */
.message-media-control {
padding: $base_padding * 2 $base_padding * 4;
padding: $base_padding * 2 1.64em; // $base_padding * 4 = 24px
color: darken($fg_color, 15%);
// uses $hover_bg_color since the media controls are in a notification_bubble

View File

@ -9,6 +9,7 @@
background-size: contain;
color: $osd_fg_color;
border-radius: 99px;
icon-size: $base_icon_size * 4; // 64px
&:hover {
color: lighten($osd_fg_color,30%);
}
@ -16,6 +17,12 @@
& StIcon {
background-color: transparentize($osd_fg_color,0.95);
border-radius: 99px;
padding: $base_padding * 2 ; // 12px
width: $base_icon_size * 2.5; height: $base_icon_size * 2.5; // 40px;
}
&.user-avatar {
border: 2px $osd_fg_color;
}
}
@ -30,15 +37,6 @@
}
}
.user-widget.horizontal .user-icon {
icon-size: $base_icon_size * 4; // 64px
& StIcon {
padding: $base_padding * 2 ; // 12px
width: $base_icon_size * 2.5; height: $base_icon_size * 2.5; // 40px;
}
}
.lightbox { background-color: black; }
.flashspot { background-color: white; }
@ -53,3 +51,9 @@
@include fontsize($base_font_size - 1);
color: $warning_color;
}
/* Workspace animation */
.workspace-animation {
background-color: $system_bg_color;
}

View File

@ -1,4 +1,4 @@
/* Notifications & Mesage Tray */
/* Notifications & Message Tray */
$notification_banner_height: 64px;
$notification_banner_width: 34em;

View File

@ -1,10 +1,13 @@
/* OVERVIEW */
#overview {
spacing: 24px;
background-color: transparent;
.controls-manager, .secondary-monitor-workspaces {
spacing: $base_spacing * 2;
}
#overviewGroup {
background-color: $system_bg_color;
}
.overview-controls {
padding-bottom: 32px;
}
}

View File

@ -3,43 +3,36 @@
$panel_corner_radius: $base_border_radius+1;
$panel_bg_color: #000;
$panel_fg_color: #ccc;
$panel_height: 1.86em;
$panel_fg_color: #ddd;
$panel_height: 2.2em;
$panel_transition_duration: 250ms; // same as the overview transition duration
#panel {
background-color: $panel_bg_color;
font-weight: bold;
height: $panel_height;
font-feature-settings: "tnum";
transition-duration: $panel_transition_duration;
// transparent panel on lock & login screens
&.unlock-screen,
&.login-screen {
&.login-screen,
&:overview {
background-color: transparent;
.panel-corner {
-panel-corner-radius: 0;
-panel-corner-background-color: transparent;
-panel-corner-border-color: transparent;
-panel-corner-opacity: 0;
}
}
// spacing between activities, app menu and such
#panelLeft, #panelCenter {
spacing: $base_spacing;
}
// the rounded outset corners
.panel-corner {
-panel-corner-radius: $panel_corner_radius;
-panel-corner-background-color: $panel_bg_color;
-panel-corner-border-width: 2px;
-panel-corner-border-color: transparent;
&:active, &:overview, &:focus {
-panel-corner-border-color: lighten($selected_bg_color,5%);
}
-panel-corner-opacity: 1;
transition-duration: $panel_transition_duration;
}
// panel menus
@ -48,53 +41,69 @@ $panel_height: 1.86em;
color: $panel_fg_color;
-natural-hpadding: $base_padding * 2;
-minimum-hpadding: $base_padding;
transition-duration: 150ms;
border: 3px solid transparent;
border-radius: 99px;
&:hover {
color: lighten($panel_fg_color, 20%);
&.clock-display {
.clock {
transition-duration: 150ms;
border: 3px solid transparent;
border-radius: 99px;
}
}
&:active, &:overview, &:focus, &:checked {
color: lighten($panel_fg_color, 20%);
&:hover, &:active, &:overview, &:focus, &:checked {
box-shadow: inset 0 0 0 100px rgba(255, 255, 255, 0.20);
// The clock display needs to have the background on .clock because
// we want to exclude the do-not-disturb indicator from the background
&.clock-display {
box-shadow: none;
.clock {
box-shadow: inset 0 0 0 100px rgba(255, 255, 255, 0.20);
}
}
}
// status area icons
.system-status-icon {
icon-size: $base_icon_size;
padding: $base_padding - 1px;
margin: 0 $base_margin;
}
.panel-status-indicators-box .system-status-icon,
.panel-status-menu-box .system-status-icon {
margin: 0;
}
// app menu icon
.app-menu-icon {
margin-left: $base_margin;
margin-right: $base_margin;
-st-icon-style: symbolic;
// dimensions of the icon are hardcoded
}
// lock & login screen styles
.unlock-screen &,
.login-screen & {
color: lighten($fg_color, 10%);
&:focus, &:hover, &:active { color: lighten($fg_color, 10%); }
&#panelActivities {
-natural-hpadding: $base_padding * 3;
}
}
.panel-button {
&:active, &:overview, &:focus, &:checked {
// Trick due to St limitations. It needs a background to draw a box-shadow
background-color: rgba(0, 0, 0, 0.01);
box-shadow: inset 0 -2px 0 0 lighten($selected_bg_color,5%);
}
}
&.unlock-screen,
&.login-screen,
&:overview {
.panel-button {
&:hover, &:active, &:overview, &:focus, &:checked {
box-shadow: inset 0 0 0 100px rgba(255, 255, 255, 0.15);
.panel-button.clock-display {
// Move highlight from .panel-button to .clock
&:active, &:overview, &:focus, &:checked {
box-shadow: none;
&.clock-display {
box-shadow: none;
.clock {
background-color: rgba(0, 0, 0, 0.01);
box-shadow: inset 0 -2px 0 0 lighten($selected_bg_color,5%);
.clock {
box-shadow: inset 0 0 0 100px rgba(255, 255, 255, 0.15);
}
}
}
}
}
@ -119,3 +128,8 @@ $panel_height: 1.86em;
spacing: $base_spacing;
.label-shadow { color: transparent; }
}
#appMenu .panel-status-menu-box {
padding: 0 $base_padding;
spacing: $base_spacing;
}

View File

@ -76,8 +76,10 @@ $popover_arrow_height: 12px;
// container for radio and check boxes
.popup-menu-ornament {
text-align: right;
width: 1.2em;
&:ltr { text-align: right };
&:rtl { text-align: left };
}
// separator

View File

@ -0,0 +1,17 @@
.realm-switch-label {
font-size: 36px;
font-weight: bold;
color: #ffffff;
background-color: rgba(10, 10, 10, 0.7);
border-radius: 5px;
padding: .5em;
}
.realm-frame-label {
font-size: 12pt;
font-weight: bold;
}
.realm-config-icon {
color: #8e8e80;
}

View File

@ -66,7 +66,7 @@
}
#lockDialogGroup {
background-color: lighten(#2e3436, 8%);
background-color: $system_bg_color;
}
#unlockDialogNotifications {

View File

@ -10,17 +10,16 @@ $search_entry_height: 36px;
border-radius: $search_entry_height * 0.5; // half the height
color: transparentize($fg_color,0.3);
background-color: $bg_color;
border-color: $borders_color;
margin-top: $base_spacing * 2;
margin-bottom: $base_spacing;
border-width: 2px;
border-color: transparent;
&:hover {
background-color: $hover_bg_color;
border-color: $hover_borders_color;
color: $hover_fg_color;
}
&:focus {
padding: $base_padding $base_padding+2; // 1px less to account for wider border
border-width: 2px;
border-style: solid;
border-color: $selected_bg_color;
color: $fg_color;
@ -32,4 +31,4 @@ $search_entry_height: 36px;
padding: 0 4px;
color: inherit;
}
}
}

View File

@ -16,7 +16,7 @@ $slider_size: 15px;
-barlevel-overdrive-color: $destructive_color;
-barlevel-overdrive-border-color: if($variant == 'light', darken($destructive_color, 4%), lighten($destructive_color, 2%)); //trough border when red;
-barlevel-overdrive-separator-width:1px;
// slider hander
// slider handler
-slider-handle-radius: $slider_size * 0.5; // half the size of the size
-slider-handle-border-width: 1px;
-slider-handle-border-color: if($variant == 'light', $borders_color, $fg_color);

View File

@ -3,63 +3,50 @@
$window_picker_spacing: $base_spacing; // 6px
$window_picker_padding: $base_padding * 2; // 12px
$window_thumbnail_border_color:transparentize($selected_fg_color, 0.65);
$window_thumbnail_label_color: transparentize($osd_bg_color, 0.4);
$window_close_button_size: 24px;
$window_close_button_size: 30px;
$window_close_button_padding: 3px;
$window_clone_border_size: 6px;
// Window picker
.window-picker {
// Space between window thumbnails
spacing: $window_picker_spacing;
// Padding for container around window thumbnails
padding: $window_picker_padding;
&.external-monitor { padding: $window_picker_padding; }
}
// Borders on window thumbnails
.window-clone-border {
border-width: $window_clone_border_size;
border-style: solid;
border-color: $window_thumbnail_border_color;
border-radius: $base_border_radius + 2;
// For window decorations with round corners we can't match
// the exact shape when the window is scaled. So apply a shadow
// to fix that case
box-shadow: inset 0 0 0 1px transparentize($borders_color, 0.8);
}
// Window titles
.window-caption {
color: $osd_fg_color;
background-color: $osd_bg_color;
border:1px solid $osd_outer_borders_color;
border-radius: $base_border_radius + 1;
border-radius: 99px;
padding: $base_padding $base_padding * 2;
font-weight: bold;
@include fontsize($base_font_size + 1);
}
// Close button
.window-close {
background-color: $selected_bg_color;
color: $selected_fg_color;
border: none;
background-color: $osd_bg_color;
color: $osd_fg_color;
border-radius: $window_close_button_size * 0.5 + $window_close_button_padding * 2;
padding: $window_close_button_padding;
height: $window_close_button_size;
width: $window_close_button_size;
box-shadow: -1px 1px 5px 0px rgba(0,0,0,0.5);
transition-duration: 300ms;
& StIcon { icon-size: 24px; }
&:hover {
background-color: lighten($selected_bg_color, 5%);
background-color: lighten($osd_bg_color, 15%);
}
&:active {
background-color: darken($selected_bg_color, 5%);
color: transparentize($osd_fg_color, 0.2);
background-color: darken($osd_bg_color, 5%);
}
}
.workspace-background {
// keep in sync with BACKGROUND_CORNER_RADIUS_PIXELS in workspace.js
border-radius: 30px;
box-shadow: 0 4px 16px 4px transparentize(darken($osd_bg_color, 30%), 0.7);
}

View File

@ -2,24 +2,20 @@
// thumbnails in overview
.workspace-thumbnails {
@extend %overview_panel;
visible-width: 32px; //amount visible before hover
spacing: $base_spacing;
padding: $base_padding;
border-radius: $modal_radius 0 0 $modal_radius;
border-right-width: 0;
&:rtl {
border-radius: 0 $modal_radius $modal_radius 0;
border-left-width: 0;
.workspace-thumbnail {
@extend %overview_panel;
border-radius: 3px;
}
// drag and drop indicator
.placeholder {
background-image: url("resource:///org/gnome/shell/theme/dash-placeholder.svg");
background-image: url("resource:///org/gnome/shell/theme/workspace-placeholder.svg");
background-size: contain;
height: 24px;
width: 18px;
}
}

View File

@ -0,0 +1,343 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
inkscape:version="1.0.2 (e86c870879, 2021-01-15)"
id="svg8"
version="1.1"
viewBox="0 0 600 400"
height="400"
width="600"
sodipodi:docname="gnome-shell-start.svg">
<defs
id="defs2">
<linearGradient
id="a">
<stop
offset="0"
stop-color="#eef4fc"
id="stop3"
style="stop-color:#b2cdf1;stop-opacity:1" />
<stop
offset="1"
stop-color="#fff"
id="stop5" />
</linearGradient>
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient10562"
id="linearGradient10564"
x1="-1179.9999"
y1="1314.5198"
x2="-940.00006"
y2="1314.5198"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(1.3993149,0,0,1.3993149,1306.25,-919.42736)" />
<linearGradient
inkscape:collect="always"
id="linearGradient10562">
<stop
style="stop-color:#3580e4;stop-opacity:1"
offset="0"
id="stop10558" />
<stop
style="stop-color:#8abfdd;stop-opacity:1"
offset="1"
id="stop10560" />
</linearGradient>
<clipPath
id="e-3"
clipPathUnits="userSpaceOnUse">
<path
d="m 65,177 c -18.502,0 -33.5,14.998 -33.5,33.5 0.008,7.371 4.131,15.807 11.388,23.526 l 12.617,13.171 H 75.02 l 12.137,-13.245 c 6.636,-7.059 11.33,-16.117 11.344,-23.452 0,-18.502 -14.998,-33.5 -33.5,-33.5 z"
style="marker:none"
fill="#ffffff"
stroke-width="2"
id="path34-6" />
</clipPath>
<radialGradient
r="33.5"
fy="48.405998"
fx="79.091003"
cy="48.405998"
cx="79.091003"
gradientTransform="matrix(0.00476,1.62228,-1.43419,0.00422,141.702,-82.047)"
gradientUnits="userSpaceOnUse"
id="f-7"
xlink:href="#b" />
<linearGradient
id="b">
<stop
offset="0"
stop-color="#fff"
id="stop11" />
<stop
offset=".519"
stop-color="#fff"
id="stop13" />
<stop
offset=".734"
stop-color="#cfcfcf"
id="stop15" />
<stop
offset="1"
stop-color="#dcdcdc"
id="stop17" />
</linearGradient>
<radialGradient
r="12"
fy="54.102001"
fx="71.473999"
cy="54.102001"
cx="71.473999"
gradientTransform="matrix(4.50607,0,0,4.76661,-259.306,-59.706)"
gradientUnits="userSpaceOnUse"
id="g-2"
xlink:href="#c" />
<linearGradient
id="c">
<stop
offset="0"
stop-color="#ed686f"
id="stop20" />
<stop
offset=".865"
stop-color="#a51d2d"
id="stop22" />
<stop
offset="1"
stop-color="#e01b24"
id="stop24" />
</linearGradient>
<radialGradient
r="14.583"
fy="49.777"
fx="40.152"
cy="49.777"
cx="40.152"
gradientTransform="matrix(0.87016,4.27869,-2.56693,0.52204,148.394,-163.306)"
gradientUnits="userSpaceOnUse"
id="h-7"
xlink:href="#d" />
<linearGradient
id="d">
<stop
offset="0"
stop-color="#ed686f"
id="stop27" />
<stop
offset=".911"
stop-color="#a51d2d"
id="stop29" />
<stop
offset="1"
stop-color="#e01b24"
id="stop31" />
</linearGradient>
<radialGradient
r="14.583"
fy="49.777"
fx="40.152"
cy="49.777"
cx="40.152"
gradientTransform="matrix(0.87016,4.27869,-2.56693,0.52204,148.394,-163.306)"
gradientUnits="userSpaceOnUse"
id="i-6"
xlink:href="#d" />
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient860"
id="linearGradient22"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(-1.575111,0,0,1.575111,1217.8748,47.173672)"
x1="85"
y1="107.162"
x2="85"
y2="86" />
<linearGradient
id="linearGradient860">
<stop
offset="0"
stop-color="#eef4fc"
id="stop856"
style="stop-color:#c5dcf7;stop-opacity:1" />
<stop
offset="1"
stop-color="#fff"
id="stop858" />
</linearGradient>
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient860"
id="linearGradient24"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(-2.1158457,0,0,2.1158457,1459.4994,-118.92278)"
x1="85"
y1="110.30392"
x2="85"
y2="86.986084" />
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient860"
id="linearGradient23"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(1.5463767,0,0,1.5463767,655.03375,-16.075361)"
x1="85"
y1="107.162"
x2="85"
y2="82.13472" />
</defs>
<sodipodi:namedview
units="px"
borderlayer="true"
inkscape:showpageshadow="false"
showgrid="false"
inkscape:document-rotation="0"
inkscape:current-layer="layer1"
inkscape:document-units="px"
inkscape:cy="75.603256"
inkscape:cx="199.00314"
inkscape:zoom="0.98994949"
inkscape:pageshadow="2"
inkscape:pageopacity="0"
borderopacity="1"
bordercolor="#383838"
pagecolor="#1f1f1f"
id="base"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:window-width="1920"
inkscape:window-height="1011"
inkscape:window-x="0"
inkscape:window-y="0"
inkscape:window-maximized="1"
inkscape:snap-bbox="true"
inkscape:object-paths="true"
inkscape:snap-intersection-paths="true"
inkscape:snap-smooth-nodes="true"
inkscape:snap-midpoints="true">
<inkscape:grid
type="xygrid"
id="grid900" />
</sodipodi:namedview>
<metadata
id="metadata5">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
<cc:license
rdf:resource="http://creativecommons.org/licenses/by-sa/4.0/" />
</cc:Work>
<cc:License
rdf:about="http://creativecommons.org/licenses/by-sa/4.0/">
<cc:permits
rdf:resource="http://creativecommons.org/ns#Reproduction" />
<cc:permits
rdf:resource="http://creativecommons.org/ns#Distribution" />
<cc:requires
rdf:resource="http://creativecommons.org/ns#Notice" />
<cc:requires
rdf:resource="http://creativecommons.org/ns#Attribution" />
<cc:permits
rdf:resource="http://creativecommons.org/ns#DerivativeWorks" />
<cc:requires
rdf:resource="http://creativecommons.org/ns#ShareAlike" />
</cc:License>
</rdf:RDF>
</metadata>
<g
id="layer1"
inkscape:groupmode="layer"
inkscape:label="Layer 1"
transform="translate(-620,9.4371882)">
<g
id="g4043"
transform="translate(-15.793175)">
<circle
style="fill:url(#linearGradient10564);fill-opacity:1;stroke:none;stroke-width:3.66905;stroke-linecap:round;stroke-linejoin:round"
id="path10517"
cx="-177.02397"
cy="920"
r="167.91774"
transform="rotate(-90)" />
<path
d="m 1066.6646,147.98131 c 12.3048,0.0174 23.474,7.19166 28.6008,18.37784 a 23.631877,23.631877 0 0 1 10.7762,-2.62748 c 12.4288,0.0178 22.7209,9.65384 23.5474,22.05492 h 0.08 c 8.6991,0 15.7508,7.05171 15.7508,15.75083 0,8.69911 -7.0522,15.75083 -15.7513,15.75083 h -88.2056 a 18.901933,18.901933 0 0 1 -18.9019,-18.901 18.901933,18.901933 0 0 1 12.6566,-17.81853 33.12417,33.12417 0 0 1 -0.056,-1.08246 c 0,-17.39824 14.1038,-31.50213 31.5025,-31.50213 z"
id="path10"
style="fill:url(#linearGradient22);stroke-width:0.577558" />
<g
id="g245"
transform="matrix(1.5161629,0,0,1.5161629,396.40481,-143.42807)">
<g
id="g126"
transform="matrix(0.75000161,0,0,0.75000161,154.45946,111.99828)">
<g
id="g265">
<g
transform="matrix(3.12129,0,0,2.9344,91.063695,-499.94397)"
clip-path="url(#e-3)"
id="g47-0">
<path
transform="translate(-8,156)"
d="M 73,21 C 54.498,21 39.5,35.998 39.5,54.5 39.508,61.871 43,68.922 46.44,74.879 L 58,98 H 88 L 99.605,74.79 C 103,68.91 106.485,61.835 106.5,54.5 106.5,35.998 91.502,21 73,21 Z"
style="fill:url(#f-7);marker:none"
fill="url(#f)"
id="path39-6" />
<path
d="m 64,177 c 0,0 -18.332,12.132 -18.332,30.989 0,14.571 16.174,46.011 16.174,46.011 H 67 c 0,0 1.333,-31.44 1.333,-46.011 C 68.333,189.132 64,177 64,177 Z"
fill="url(#g)"
id="path41-2"
style="fill:url(#g-2)" />
<path
transform="translate(-8,156)"
d="m 71.983,21.106 c -8.207,0.147 -16.328,3.285 -22.5,8.695 -6.174,5.409 -10.35,13.047 -11.574,21.163 -1.24,8.225 0.567,16.874 4.995,23.915 L 61.902,98 h 6.432 L 55.002,81.27 C 50.702,75.875 46.53,70.2 44.406,63.636 42.283,57.072 42.24,49.836 44.409,43.288 A 32.824,32.824 0 0 1 54.925,28.13 32.824,32.824 0 0 1 71.983,21.105 Z"
fill="url(#h)"
id="path43-6"
style="fill:url(#h-7)" />
<path
transform="matrix(-1,0,0,1,137.16,155.823)"
d="M 73.003,21.303 C 65.294,19.756 57.033,21.149 50.257,25.138 43.481,29.127 38.255,35.675 35.867,43.167 A 32.484,32.484 0 0 0 35.11,59.972 32.484,32.484 0 0 0 42.904,74.879 L 54.11,98 H 67.493 L 54.16,74.356 C 51.292,69.269 48.603,63.95 47.733,58.175 46.863,52.4 47.769,46.404 50.107,41.052 54.28,31.502 62.943,24.03 73.002,21.304 Z"
fill="url(#i)"
id="path45-1"
style="fill:url(#i-6)" />
</g>
<path
style="marker:none"
d="m 271.0607,256.22128 v 19.397 a 9.702,9.702 0 0 0 9.724,9.726 h 26.326 c 5.388,0 8.594,-4.457 9.725,-9.726 v -19.397 z"
fill="#e5a50a"
id="path49-8" />
<path
style="marker:none"
d="m 271.0607,252.06028 v 19.397 a 9.702,9.702 0 0 0 9.724,9.724 h 26.326 c 5.388,0 8.594,-4.455 9.725,-9.724 v -19.397 z"
fill="#e5a50a"
id="path51-7" />
<path
style="marker:none"
d="m 300.1907,252.06028 v 29.121 h 6.92 c 5.388,0 8.594,-4.455 9.725,-9.724 v -19.397 z"
fill="#f3af0b"
id="path53-9" />
</g>
</g>
</g>
<path
style="font-variation-settings:normal;fill:url(#linearGradient24);fill-opacity:1;stroke-width:0.822282"
d="m 1051.0577,24.011554 a 37.111799,37.111799 0 0 0 -36.9465,35.120895 c -13.3251,2.089947 -23.45686,13.564137 -23.45686,27.494149 0,15.421302 12.41476,27.836692 27.83666,27.836692 h 72.3273 c 11.9284,0 21.5316,-9.60251 21.5316,-21.530902 0,-11.928386 -9.6032,-21.532163 -21.5316,-21.532163 h -3.9868 a 37.111799,37.111799 0 0 0 1.4509,-10.27624 37.111799,37.111799 0 0 0 -37.1118,-37.111798 37.111799,37.111799 0 0 0 -0.1123,0 z"
id="path12" />
<path
d="m 803.48555,82.893284 c -12.0805,0.0171 -23.046,7.06046 -28.0791,18.042576 a 23.200767,23.200767 0 0 0 -10.5796,-2.579546 c -12.2021,0.0175 -22.3064,9.477716 -23.1179,21.652566 h -0.079 c -8.5404,0 -15.4634,6.92307 -15.4634,15.46349 0,8.54042 6.9235,15.46349 15.4639,15.46349 h 86.5965 a 18.55711,18.55711 0 0 0 18.5571,-18.55619 18.55711,18.55711 0 0 0 -12.4257,-17.49347 32.519894,32.519894 0 0 0 0.055,-1.06272 c 0,-17.080836 -13.8466,-30.927426 -30.9279,-30.927426 z"
id="path21"
style="fill:url(#linearGradient23);fill-opacity:1;stroke-width:0.999999" />
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 12 KiB

View File

@ -29,6 +29,7 @@ theme_sources = files([
'gnome-shell-sass/widgets/_overview.scss',
'gnome-shell-sass/widgets/_panel.scss',
'gnome-shell-sass/widgets/_popovers.scss',
'gnome-shell-sass/widgets/_realms.scss',
'gnome-shell-sass/widgets/_screen-shield.scss',
'gnome-shell-sass/widgets/_scrollbars.scss',
'gnome-shell-sass/widgets/_search-entry.scss',
@ -42,20 +43,21 @@ theme_sources = files([
'gnome-shell-sass/widgets/_workspace-thumbnails.scss'
])
styles = [
'gnome-shell-high-contrast',
'gnome-shell'
stylesheets = [
'gnome-shell-high-contrast.css',
'gnome-shell.css'
]
theme_deps = []
foreach style: styles
theme_deps += custom_target('style-' + style,
input: '@0@.scss'.format(style),
output: '@0@.css'.format(style),
command: [
sassc, '-a', '@INPUT@', '@OUTPUT@'
],
depend_files: theme_sources)
foreach stylesheet: stylesheets
if not fs.exists(stylesheet)
sassc = find_program('sassc')
theme_deps += custom_target(stylesheet,
input: fs.replace_suffix(stylesheet, '.scss'),
output: stylesheet,
command: [
sassc, '-a', '@INPUT@', '@OUTPUT@'
],
depend_files: theme_sources)
endif
endforeach

View File

@ -0,0 +1,106 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg height="16px" viewBox="0 0 16 16" width="16px" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<filter id="a" height="100%" width="100%" x="0%" y="0%">
<feColorMatrix in="SourceGraphic" type="matrix" values="0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1 0"/>
</filter>
<mask id="b">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.3"/>
</g>
</mask>
<clipPath id="c">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="d">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="e">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="f">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="g">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="h">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="i">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="j">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="k">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="l">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="m">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="n">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="o">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="p">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.3"/>
</g>
</mask>
<clipPath id="q">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="r">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.5"/>
</g>
</mask>
<clipPath id="s">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<g clip-path="url(#c)" mask="url(#b)" transform="matrix(1 0 0 1 -380 -376)">
<path d="m 562.460938 212.058594 h 10.449218 c -1.183594 0.492187 -1.296875 2.460937 0 3 h -10.449218 z m 0 0" fill="#2e3436"/>
</g>
<g clip-path="url(#e)" mask="url(#d)" transform="matrix(1 0 0 1 -380 -376)">
<path d="m 16 632 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#g)" mask="url(#f)" transform="matrix(1 0 0 1 -380 -376)">
<path d="m 17 631 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#i)" mask="url(#h)" transform="matrix(1 0 0 1 -380 -376)">
<path d="m 18 634 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#k)" mask="url(#j)" transform="matrix(1 0 0 1 -380 -376)">
<path d="m 16 634 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#m)" mask="url(#l)" transform="matrix(1 0 0 1 -380 -376)">
<path d="m 17 635 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#o)" mask="url(#n)" transform="matrix(1 0 0 1 -380 -376)">
<path d="m 19 635 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#q)" mask="url(#p)" transform="matrix(1 0 0 1 -380 -376)">
<path d="m 136 660 v 7 h 7 v -7 z m 0 0" fill="#2e3436"/>
</g>
<g clip-path="url(#s)" mask="url(#r)" transform="matrix(1 0 0 1 -380 -376)">
<path d="m 219 642 h 3 v 12 h -3 z m 0 0" fill="#2e3436"/>
</g>
<path d="m 1.53125 0.46875 l -1.0625 1.0625 l 14 14 l 1.0625 -1.0625 l -1.945312 -1.945312 c 0.847656 -0.527344 1.414062 -1.449219 1.414062 -2.523438 v -6 c 0 -1.660156 -1.339844 -3 -3 -3 h -8 c -0.554688 0 -1.070312 0.160156 -1.515625 0.421875 z m 2.53125 2.53125 h 0.199219 l -0.097657 0.097656 z m 2.675781 0 h 0.699219 l -1.6875 1.6875 l -0.351562 -0.351562 z m 2.824219 0 h 1.230469 l -3.367188 3.363281 l -0.613281 -0.613281 z m 2.609375 0.035156 c 0.316406 0.054688 0.578125 0.246094 0.714844 0.523438 l -4.132813 4.132812 l -0.617187 -0.617187 z m -11.171875 1.023438 v 5.941406 c 0 1.660156 1.339844 3 3 3 h 5.941406 l -2 -2 h -1.785156 l 0.894531 -0.894531 l -0.355469 -0.355469 l -1.25 1.25 h -1.238281 l 1.867188 -1.867188 l -0.707031 -0.707031 l -2.160157 2.15625 c -0.121093 -0.164062 -0.207031 -0.359375 -0.207031 -0.582031 v -0.4375 l 1.75 -1.75 l -1.0625 -1.0625 l -0.6875 0.6875 v -0.699219 l 0.339844 -0.339843 z m 12 0.09375 v 5.847656 c 0 0.535156 -0.417969 0.960938 -0.949219 0.988281 l -2.941406 -2.941406 z m -5 9.847656 c -5 0 -5 1 -5 1 c 0 1 1 1 1 1 h 8 c 0.328125 0 0.539062 -0.109375 0.6875 -0.253906 l -1.542969 -1.546875 c -0.730469 -0.113281 -1.71875 -0.199219 -3.144531 -0.199219 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</svg>

After

Width:  |  Height:  |  Size: 5.1 KiB

View File

@ -0,0 +1,109 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg height="16px" viewBox="0 0 16 16" width="16px" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<filter id="a" height="100%" width="100%" x="0%" y="0%">
<feColorMatrix in="SourceGraphic" type="matrix" values="0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1 0"/>
</filter>
<mask id="b">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.3"/>
</g>
</mask>
<clipPath id="c">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="d">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="e">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="f">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="g">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="h">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="i">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="j">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="k">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="l">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="m">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="n">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.05"/>
</g>
</mask>
<clipPath id="o">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="p">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.3"/>
</g>
</mask>
<clipPath id="q">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<mask id="r">
<g filter="url(#a)">
<path d="m 0 0 h 16 v 16 h -16 z" fill-opacity="0.5"/>
</g>
</mask>
<clipPath id="s">
<path d="m 0 0 h 1024 v 800 h -1024 z"/>
</clipPath>
<g clip-path="url(#c)" mask="url(#b)" transform="matrix(1 0 0 1 -360 -376)">
<path d="m 562.460938 212.058594 h 10.449218 c -1.183594 0.492187 -1.296875 2.460937 0 3 h -10.449218 z m 0 0" fill="#2e3436"/>
</g>
<g clip-path="url(#e)" mask="url(#d)" transform="matrix(1 0 0 1 -360 -376)">
<path d="m 16 632 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#g)" mask="url(#f)" transform="matrix(1 0 0 1 -360 -376)">
<path d="m 17 631 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#i)" mask="url(#h)" transform="matrix(1 0 0 1 -360 -376)">
<path d="m 18 634 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#k)" mask="url(#j)" transform="matrix(1 0 0 1 -360 -376)">
<path d="m 16 634 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#m)" mask="url(#l)" transform="matrix(1 0 0 1 -360 -376)">
<path d="m 17 635 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#o)" mask="url(#n)" transform="matrix(1 0 0 1 -360 -376)">
<path d="m 19 635 h 1 v 1 h -1 z m 0 0" fill="#2e3436" fill-rule="evenodd"/>
</g>
<g clip-path="url(#q)" mask="url(#p)" transform="matrix(1 0 0 1 -360 -376)">
<path d="m 136 660 v 7 h 7 v -7 z m 0 0" fill="#2e3436"/>
</g>
<g clip-path="url(#s)" mask="url(#r)" transform="matrix(1 0 0 1 -360 -376)">
<path d="m 219 642 h 3 v 12 h -3 z m 0 0" fill="#2e3436"/>
</g>
<g fill="#2e3436">
<path d="m 4 1 c -1.660156 0 -3 1.339844 -3 3 v 6 c 0 1.660156 1.339844 3 3 3 h 8 c 1.660156 0 3 -1.339844 3 -3 v -6 c 0 -1.660156 -1.339844 -3 -3 -3 z m 0 2 h 0.261719 l -1.261719 1.261719 v -0.261719 c 0 -0.554688 0.445312 -1 1 -1 z m 2.738281 0 h 0.699219 l -4.4375 4.4375 v -0.699219 z m 2.824219 0 h 1.230469 l -7.585938 7.582031 c -0.121093 -0.164062 -0.207031 -0.359375 -0.207031 -0.582031 v -0.4375 z m 2.609375 0.035156 c 0.316406 0.054688 0.578125 0.246094 0.714844 0.523438 l -7.441407 7.441406 h -1.238281 z m 0.828125 1.121094 v 5.84375 c 0 0.554688 -0.445312 1 -1 1 h -5.84375 z m 0 0" fill-rule="evenodd"/>
<path d="m 8 14 c -5 0 -5 1 -5 1 c 0 1 1 1 1 1 h 8 c 1 0 1 -1 1 -1 s 0 -1 -5 -1 z m 0 0"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 4.6 KiB

View File

@ -0,0 +1,31 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
width="24"
height="24"
viewBox="0 0 6.3499999 6.3500002"
version="1.1"
id="svg59656">
<defs
id="defs59650" />
<metadata
id="metadata59653">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<path
style="color:#bebebe;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:'Andale Mono';-inkscape-font-specification:'Andale Mono';text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-anchor:start;display:inline;overflow:visible;visibility:visible;fill:#241f31;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.471289;marker:none;enable-background:new"
id="path10839-9"
d="m 1.5875,1.5875 h 0.2645834 c 0.00274,-3.18e-5 0.0055,-1.217e-4 0.00827,0 0.067456,0.00296 0.1349031,0.03402 0.181901,0.082682 L 3.1758323,2.8029916 4.3160156,1.670182 C 4.3862956,1.609196 4.4341976,1.589352 4.4979166,1.5875 H 4.7625 v 0.264583 c 0,0.075795 -0.00909,0.1456928 -0.066146,0.1984375 L 3.5644391,3.175 4.688086,4.3077474 C 4.737877,4.3575344 4.762498,4.4277227 4.7625,4.4979167 V 4.7625 H 4.4979167 C 4.4277225,4.7624974 4.3575325,4.7378673 4.3077475,4.6880859 L 3.1758323,3.5554004 2.0422526,4.688086 C 1.9924676,4.737878 1.9222747,4.7625 1.8520834,4.7625 H 1.5875 V 4.4979168 c -8e-7,-0.070191 0.024622,-0.1403827 0.074414,-0.1901693 L 2.7954938,3.175 1.6619141,2.0505208 C 1.6061553,1.9990249 1.581703,1.9263651 1.5875,1.8520833 Z" />
</svg>

After

Width:  |  Height:  |  Size: 2.0 KiB

View File

@ -0,0 +1,119 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="27"
height="76"
id="svg11252"
version="1.1"
sodipodi:docname="dash-placeholder-horizontal.svg"
inkscape:version="1.0.2 (e86c870879, 2021-01-15, custom)">
<metadata
id="metadata19">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="640"
inkscape:window-height="480"
id="namedview17"
showgrid="false"
inkscape:pagecheckerboard="true"
inkscape:zoom="12.473684"
inkscape:cx="38"
inkscape:cy="26.327004"
inkscape:current-layer="g99967"
inkscape:document-rotation="0" />
<defs
id="defs11254">
<radialGradient
xlink:href="#linearGradient39563-4-2"
id="radialGradient68155-2-3"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(1,0,0,0.3486842,24.5,341.84211)"
cx="49"
cy="488"
fx="49"
fy="488"
r="38" />
<linearGradient
id="linearGradient39563-4-2">
<stop
style="stop-color:#ffffff;stop-opacity:1;"
offset="0"
id="stop39565-1-4" />
<stop
style="stop-color:#ffffff;stop-opacity:0;"
offset="1"
id="stop39567-7-9" />
</linearGradient>
<radialGradient
xlink:href="#linearGradient39573-6-1"
id="radialGradient68157-0-8"
gradientUnits="userSpaceOnUse"
cx="50.5"
cy="487.5"
fx="50.5"
fy="487.5"
r="10.5"
gradientTransform="matrix(1.2857143,0,0,1.2857143,8.571428,-114.78571)" />
<linearGradient
id="linearGradient39573-6-1">
<stop
style="stop-color:#ffffff;stop-opacity:1;"
offset="0"
id="stop39575-5-6" />
<stop
style="stop-color:#ffffff;stop-opacity:0;"
offset="1"
id="stop39577-1-2" />
</linearGradient>
</defs>
<g
id="layer1"
transform="rotate(90,465.93109,104.43109)">
<g
id="g99967"
style="display:inline"
transform="translate(326,44.862171)">
<rect
style="color:#000000;display:inline;overflow:visible;visibility:visible;opacity:0.49375;fill:url(#radialGradient68155-2-3);fill-opacity:1;stroke:none;stroke-width:1;marker:none;enable-background:accumulate"
id="rect99969"
width="76"
height="2"
x="35.5"
y="511"
rx="0"
ry="0" />
<path
style="color:#000000;display:inline;overflow:visible;visibility:visible;opacity:0.43125;fill:url(#radialGradient68157-0-8);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.28571;marker:none;enable-background:accumulate"
id="path99971"
d="m 87,512.00001 c 0,7.45584 -6.044155,13.5 -13.5,13.5 -7.455844,0 -13.5,-6.04416 -13.5,-13.5 0,-7.45585 6.044156,-13.5 13.5,-13.5 7.455845,0 13.5,6.04415 13.5,13.5 z" />
<path
d="m 78.076923,512.00001 c 0,2.52776 -2.049159,4.57692 -4.576923,4.57692 -2.527766,0 -4.576923,-2.04916 -4.576923,-4.57692 0,-2.52777 2.049157,-4.57692 4.576923,-4.57692 2.527765,0 4.576923,2.04915 4.576923,4.57692 z"
id="path99973"
style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.435897;marker:none;enable-background:accumulate" />
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 4.1 KiB

View File

@ -3,13 +3,8 @@ private_headers = [
'gactionobservable.h',
'gactionobserver.h',
'shell-network-agent.h',
'shell-recorder-src.h'
]
if not enable_recorder
private_headers += 'shell-recorder.h'
endif
exclude_directories = [
'calendar-server',
'hotplug-sniffer',

View File

@ -1,6 +1,6 @@
<?xml version="1.0"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd"
[
<!ENTITY % local.common.attrib "xmlns:xi CDATA #FIXED 'http://www.w3.org/2003/XInclude'">
<!ENTITY version SYSTEM "version.xml">
@ -36,10 +36,6 @@
<xi:include href="xml/shell-tray-icon.xml"/>
<xi:include href="xml/shell-tray-manager.xml"/>
</chapter>
<chapter>
<title>Recorder</title>
<xi:include href="xml/shell-recorder.xml"/>
</chapter>
<chapter>
<title>Integration helpers and utilities</title>
<xi:include href="doc-gen-org.gnome.Shell.SearchProvider.xml"/>

View File

@ -1,6 +1,6 @@
<?xml version="1.0"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd"
[
<!ENTITY % local.common.attrib "xmlns:xi CDATA #FIXED 'http://www.w3.org/2003/XInclude'">
<!ENTITY version SYSTEM "version.xml">

View File

@ -23,7 +23,7 @@ Not only will that give you the very latest version of this rapidly
changing project, it will be much easier than get GNOME Shell and
its dependencies to build from tarballs.</description>
<homepage rdf:resource="https://wiki.gnome.org/Projects/GnomeShell" />
<mailing-list rdf:resource="http://mail.gnome.org/mailman/listinfo/gnome-shell-list" />
<support-forum rdf:resource="https://discourse.gnome.org/tags/shell" />
<download-page rdf:resource="http://download.gnome.org/sources/gnome-shell/" />
<bug-database rdf:resource="https://gitlab.gnome.org/GNOME/gnome-shell/issues/" />
@ -73,4 +73,10 @@ its dependencies to build from tarballs.</description>
<gnome:userid>gbsneto</gnome:userid>
</foaf:Person>
</maintainer>
<maintainer>
<foaf:Person>
<foaf:name>Marge Bot</foaf:name>
<gnome:userid>marge-bot</gnome:userid>
</foaf:Person>
</maintainer>
</Project>

View File

@ -25,6 +25,8 @@ var ServiceImplementation = class {
// subclasses may override this to disable automatic shutdown
this._autoShutdown = true;
this._queueShutdownCheck();
}
// subclasses may override this to own additional names

View File

@ -1,2 +1,7 @@
.expander-frame > * { border-top-width: 0; }
.expander-toolbar { border: 0 solid @borders; border-top-width: 1px; }
.expander { padding: 12px; }
.expander.expanded { border: 0 solid @borders; border-bottom-width: 1px; }
.expander-toolbar {
border: 0 solid @borders;
border-top-width: 1px;
padding: 3px;
}

View File

@ -116,27 +116,37 @@ var ExtensionsService = class extends ServiceImplementation {
if (this._handleError(invocation, error))
return;
if (this._prefsDialog) {
this._handleError(invocation,
new Error('Already showing a prefs dialog'));
return;
}
const [serialized] = res;
const extension = ExtensionUtils.deserializeExtension(serialized);
const window = new ExtensionPrefsDialog(extension);
window.realize();
this._prefsDialog = new ExtensionPrefsDialog(extension);
this._prefsDialog.connect('realize', () => {
let externalWindow = null;
let externalWindow = null;
if (parentWindow)
externalWindow = Shew.ExternalWindow.new_from_handle(parentWindow);
if (parentWindow)
externalWindow = Shew.ExternalWindow.new_from_handle(parentWindow);
if (externalWindow)
externalWindow.set_parent_of(window.window);
if (externalWindow)
externalWindow.set_parent_of(this._prefsDialog.get_surface());
});
if (options.modal)
window.modal = options.modal.get_boolean();
this._prefsDialog.modal = options.modal.get_boolean();
window.connect('destroy', () => this.release());
this._prefsDialog.connect('close-request', () => {
delete this._prefsDialog;
this.release();
return false;
});
this.hold();
window.show();
this._prefsDialog.show();
invocation.return_value(null);
});
@ -156,7 +166,6 @@ var ExtensionPrefsDialog = GObject.registerClass({
GTypeName: 'ExtensionPrefsDialog',
Template: 'resource:///org/gnome/Shell/Extensions/ui/extension-prefs-dialog.ui',
InternalChildren: [
'headerBar',
'stack',
'expander',
'expanderArrow',
@ -165,24 +174,24 @@ var ExtensionPrefsDialog = GObject.registerClass({
],
}, class ExtensionPrefsDialog extends Gtk.Window {
_init(extension) {
super._init();
super._init({
title: extension.metadata.name,
});
this._uuid = extension.uuid;
this._url = extension.metadata.url || '';
this._headerBar.title = extension.metadata.name;
this._actionGroup = new Gio.SimpleActionGroup();
this.insert_action_group('win', this._actionGroup);
this._initActions();
this._addCustomStylesheet();
this._gesture = new Gtk.GestureMultiPress({
widget: this._expander,
this._gesture = new Gtk.GestureClick({
button: 0,
exclusive: true,
});
this._expander.add_controller(this._gesture);
this._gesture.connect('released', (gesture, nPress) => {
if (nPress === 1)
@ -193,7 +202,10 @@ var ExtensionPrefsDialog = GObject.registerClass({
this._expanderArrow.icon_name = this._revealer.reveal_child
? 'pan-down-symbolic'
: 'pan-end-symbolic';
this._syncExpandedStyle();
});
this._revealer.connect('notify::child-revealed',
() => this._syncExpandedStyle());
try {
ExtensionUtils.installImporter(extension);
@ -205,13 +217,21 @@ var ExtensionPrefsDialog = GObject.registerClass({
prefsModule.init(extension.metadata);
const widget = prefsModule.buildPrefsWidget();
this._stack.add(widget);
this._stack.add_named(widget, 'prefs');
this._stack.visible_child = widget;
} catch (e) {
this._setError(e);
logError(e, 'Failed to open preferences');
}
}
_syncExpandedStyle() {
if (this._revealer.reveal_child)
this._expander.add_css_class('expanded');
else if (!this._revealer.child_revealed)
this._expander.remove_css_class('expanded');
}
_setError(exc) {
this._errorView.buffer.text = `${exc}\n\nStack trace:\n`;
// Indent stack trace.
@ -243,8 +263,8 @@ var ExtensionPrefsDialog = GObject.registerClass({
enabled: false,
});
action.connect('activate', () => {
const clipboard = Gtk.Clipboard.get_default(this.get_display());
clipboard.set_text(this._errorMarkdown, -1);
const clipboard = this.get_display().get_clipboard();
clipboard.set(this._errorMarkdown);
});
this._actionGroup.add_action(action);
@ -267,7 +287,7 @@ var ExtensionPrefsDialog = GObject.registerClass({
} catch (e) {
logError(e, 'Failed to add application style');
}
Gtk.StyleContext.add_provider_for_screen(Gdk.Screen.get_default(),
Gtk.StyleContext.add_provider_for_display(Gdk.Display.get_default(),
provider,
Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
}

View File

@ -1,7 +1,7 @@
/* exported main */
imports.gi.versions.Gdk = '3.0';
imports.gi.versions.Gtk = '3.0';
imports.gi.versions.Gdk = '4.0';
imports.gi.versions.Gtk = '4.0';
const { Gtk } = imports.gi;
const pkg = imports.package;
@ -10,7 +10,7 @@ const { DBusService } = imports.dbusService;
const { ExtensionsService } = imports.extensionsService;
function main() {
Gtk.init(null);
Gtk.init();
pkg.initFormat();
const service = new DBusService(

View File

@ -1,38 +1,30 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Generated with glade 3.22.1 -->
<interface>
<requires lib="gtk+" version="3.20"/>
<template class="ExtensionPrefsDialog" parent="GtkWindow">
<property name="default_width">600</property>
<property name="default_height">400</property>
<property name="default-width">600</property>
<property name="default-height">400</property>
<child type="titlebar">
<object class="GtkHeaderBar" id="headerBar">
<property name="visible">True</property>
<property name="show_close_button">True</property>
</object>
<object class="GtkHeaderBar"/>
</child>
<child>
<object class="GtkStack" id="stack">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
<object class="GtkScrolledWindow">
<property name="visible">True</property>
<property name="hscrollbar_policy">never</property>
<property name="propagate_natural_height">True</property>
<property name="hscrollbar-policy">never</property>
<property name="propagate-natural-height">True</property>
<child>
<object class="GtkViewport">
<property name="visible">True</property>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="orientation">vertical</property>
<property name="margin">100</property>
<property name="margin_bottom">60</property>
<property name="margin-start">100</property>
<property name="margin-end">100</property>
<property name="margin-top">100</property>
<property name="margin-bottom">60</property>
<property name="spacing">12</property>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="label" translatable="yes">Somethings gone wrong</property>
<attributes>
<attribute name="scale" value="1.44"/> <!-- x-large -->
@ -44,135 +36,78 @@
</child>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="label" translatable="yes">Were very sorry, but theres been a problem: the settings for this extension cant be displayed. We recommend that you report the issue to the extension authors.</property>
<property name="justify">center</property>
<property name="wrap">True</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
</object>
</child>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="orientation">vertical</property>
<property name="margin_top">12</property>
<object class="GtkFrame">
<property name="margin-top">12</property>
<child>
<object class="GtkFrame" id="expander">
<property name="visible">True</property>
<object class="GtkBox">
<property name="hexpand">True</property>
<property name="shadow_type">in</property>
<property name="orientation">vertical</property>
<child>
<object class="GtkEventBox">
<property name="visible">True</property>
<object class="GtkBox" id="expander">
<property name="spacing">6</property>
<style>
<class name="expander"/>
</style>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="margin">12</property>
<property name="spacing">6</property>
<child>
<object class="GtkImage" id="expanderArrow">
<property name="visible">True</property>
<property name="icon_name">pan-end-symbolic</property>
</object>
</child>
<child>
<object class="GtkLabel">
<property name="visible">True</property>
<property name="label" translatable="yes">Technical Details</property>
</object>
</child>
<object class="GtkImage" id="expanderArrow">
<property name="icon-name">pan-end-symbolic</property>
</object>
</child>
<child>
<object class="GtkLabel">
<property name="label" translatable="yes">Technical Details</property>
</object>
</child>
</object>
</child>
</object>
</child>
<child>
<object class="GtkRevealer" id="revealer">
<property name="visible">True</property>
<child>
<object class="GtkFrame">
<property name="visible">True</property>
<property name="shadow_type">in</property>
<style>
<class name="expander-frame"/>
</style>
<object class="GtkRevealer" id="revealer">
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="orientation">vertical</property>
<child>
<object class="GtkTextView" id="errorView">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="monospace">True</property>
<property name="editable">False</property>
<property name="wrap_mode">word</property>
<property name="left_margin">12</property>
<property name="right_margin">12</property>
<property name="top_margin">12</property>
<property name="bottom_margin">12</property>
<property name="wrap-mode">word</property>
<property name="left-margin">12</property>
<property name="right-margin">12</property>
<property name="top-margin">12</property>
<property name="bottom-margin">12</property>
</object>
</child>
<child>
<object class="GtkToolbar">
<property name="visible">True</property>
<object class="GtkBox">
<style>
<class name="expander-toolbar"/>
</style>
<child>
<object class="GtkToolItem">
<property name="visible">True</property>
<child>
<object class="GtkButton">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="action_name">win.copy-error</property>
<style>
<class name="flat"/>
<class name="image-button"/>
</style>
<child>
<object class="GtkImage">
<property name="visible">True</property>
<property name="icon_name">edit-copy-symbolic</property>
</object>
</child>
</object>
</child>
<object class="GtkButton">
<property name="receives-default">True</property>
<property name="action-name">win.copy-error</property>
<property name="has-frame">False</property>
<property name="icon-name">edit-copy-symbolic</property>
</object>
</child>
<child>
<object class="GtkSeparatorToolItem">
<property name="visible">True</property>
<property name="draw">False</property>
</object>
<packing>
<property name="expand">True</property>
</packing>
</child>
<child>
<object class="GtkToolItem">
<property name="visible">True</property>
<child>
<object class="GtkButton" id="homeButton">
<property name="visible"
bind-source="homeButton"
bind-property="sensitive"
bind-flags="sync-create"/>
<property name="label" translatable="yes">Homepage</property>
<property name="tooltip_text" translatable="yes">Visit extension homepage</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="no_show_all">True</property>
<property name="action_name">win.show-url</property>
<style>
<class name="flat"/>
</style>
</object>
</child>
<object class="GtkButton" id="homeButton">
<property name="visible"
bind-source="homeButton"
bind-property="sensitive"
bind-flags="sync-create"/>
<property name="hexpand">True</property>
<property name="halign">end</property>
<property name="label" translatable="yes">Homepage</property>
<property name="tooltip-text" translatable="yes">Visit extension homepage</property>
<property name="receives-default">True</property>
<property name="has-frame">False</property>
<property name="action-name">win.show-url</property>
</object>
</child>
</object>

View File

@ -6,8 +6,15 @@ launcherconf.set('libdir', libdir)
dbus_services = {
'org.gnome.Shell.Extensions': 'extensions',
'org.gnome.Shell.Notifications': 'notifications',
'org.gnome.ScreenSaver': 'screensaver',
}
if enable_recorder
dbus_services += {
'org.gnome.Shell.Screencast': 'screencast',
}
endif
config_dir = '@0@/..'.format(meson.current_build_dir())
foreach service, dir : dbus_services
@ -20,7 +27,7 @@ foreach service, dir : dbus_services
serviceconf = configuration_data()
serviceconf.set('service', service)
serviceconf.set('gjs', gjs.path())
serviceconf.set('gjs', gjs)
serviceconf.set('pkgdatadir', pkgdatadir)
configure_file(

View File

@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<gresources>
<gresource prefix="/org/gnome/ScreenSaver/js">
<file>main.js</file>
<file>screenSaverService.js</file>
<file>dbusService.js</file>
<file>misc/config.js</file>
<file>misc/fileUtils.js</file>
</gresource>
</gresources>

View File

@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<gresources>
<gresource prefix="/org/gnome/Shell/Screencast/js">
<file>main.js</file>
<file>screencastService.js</file>
<file>dbusService.js</file>
<file>misc/config.js</file>
<file>misc/fileUtils.js</file>
</gresource>
</gresources>

View File

@ -0,0 +1,11 @@
/* exported main */
const { DBusService } = imports.dbusService;
const { ScreencastService } = imports.screencastService;
function main() {
const service = new DBusService(
'org.gnome.Shell.Screencast',
new ScreencastService());
service.run();
}

View File

@ -0,0 +1,471 @@
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
/* exported ScreencastService */
imports.gi.versions.Gtk = '4.0';
const { Gio, GLib, Gst, Gtk } = imports.gi;
const { loadInterfaceXML, loadSubInterfaceXML } = imports.misc.fileUtils;
const { ServiceImplementation } = imports.dbusService;
const ScreencastIface = loadInterfaceXML('org.gnome.Shell.Screencast');
const IntrospectIface = loadInterfaceXML('org.gnome.Shell.Introspect');
const IntrospectProxy = Gio.DBusProxy.makeProxyWrapper(IntrospectIface);
const ScreenCastIface = loadSubInterfaceXML(
'org.gnome.Mutter.ScreenCast', 'org.gnome.Mutter.ScreenCast');
const ScreenCastSessionIface = loadSubInterfaceXML(
'org.gnome.Mutter.ScreenCast.Session', 'org.gnome.Mutter.ScreenCast');
const ScreenCastStreamIface = loadSubInterfaceXML(
'org.gnome.Mutter.ScreenCast.Stream', 'org.gnome.Mutter.ScreenCast');
const ScreenCastProxy = Gio.DBusProxy.makeProxyWrapper(ScreenCastIface);
const ScreenCastSessionProxy = Gio.DBusProxy.makeProxyWrapper(ScreenCastSessionIface);
const ScreenCastStreamProxy = Gio.DBusProxy.makeProxyWrapper(ScreenCastStreamIface);
const DEFAULT_PIPELINE = 'videoconvert chroma-mode=GST_VIDEO_CHROMA_MODE_NONE dither=GST_VIDEO_DITHER_NONE matrix-mode=GST_VIDEO_MATRIX_MODE_OUTPUT_ONLY n-threads=%T ! queue ! vp8enc cpu-used=16 max-quantizer=17 deadline=1 keyframe-mode=disabled threads=%T static-threshold=1000 buffer-size=20000 ! queue ! webmmux';
const DEFAULT_FRAMERATE = 30;
const DEFAULT_DRAW_CURSOR = true;
const PipelineState = {
INIT: 0,
PLAYING: 1,
FLUSHING: 2,
STOPPED: 3,
};
const SessionState = {
INIT: 0,
ACTIVE: 1,
STOPPED: 2,
};
var Recorder = class {
constructor(sessionPath, x, y, width, height, filePath, options,
invocation,
onErrorCallback) {
this._startInvocation = invocation;
this._dbusConnection = invocation.get_connection();
this._onErrorCallback = onErrorCallback;
this._stopInvocation = null;
this._pipelineIsPlaying = false;
this._sessionIsActive = false;
this._x = x;
this._y = y;
this._width = width;
this._height = height;
this._filePath = filePath;
this._pipelineString = DEFAULT_PIPELINE;
this._framerate = DEFAULT_FRAMERATE;
this._drawCursor = DEFAULT_DRAW_CURSOR;
this._applyOptions(options);
this._watchSender(invocation.get_sender());
this._initSession(sessionPath);
}
_applyOptions(options) {
for (const option in options)
options[option] = options[option].deep_unpack();
if (options['pipeline'] !== undefined)
this._pipelineString = options['pipeline'];
if (options['framerate'] !== undefined)
this._framerate = options['framerate'];
if ('draw-cursor' in options)
this._drawCursor = options['draw-cursor'];
}
_addRecentItem() {
const file = Gio.File.new_for_path(this._filePath);
Gtk.RecentManager.get_default().add_item(file.get_uri());
}
_watchSender(sender) {
this._nameWatchId = this._dbusConnection.watch_name(
sender,
Gio.BusNameWatcherFlags.NONE,
null,
this._senderVanished.bind(this));
}
_unwatchSender() {
if (this._nameWatchId !== 0) {
this._dbusConnection.unwatch_name(this._nameWatchId);
this._nameWatchId = 0;
}
}
_senderVanished() {
this._unwatchSender();
this.stopRecording(null);
}
_notifyStopped() {
this._unwatchSender();
if (this._onStartedCallback)
this._onStartedCallback(this, false);
else if (this._onStoppedCallback)
this._onStoppedCallback(this);
else
this._onErrorCallback(this);
}
_onSessionClosed() {
switch (this._pipelineState) {
case PipelineState.STOPPED:
break;
default:
this._pipeline.set_state(Gst.State.NULL);
log(`Unexpected pipeline state: ${this._pipelineState}`);
break;
}
this._notifyStopped();
}
_initSession(sessionPath) {
this._sessionProxy = new ScreenCastSessionProxy(Gio.DBus.session,
'org.gnome.Mutter.ScreenCast',
sessionPath);
this._sessionProxy.connectSignal('Closed', this._onSessionClosed.bind(this));
}
_startPipeline(nodeId) {
if (!this._ensurePipeline(nodeId))
return;
const bus = this._pipeline.get_bus();
bus.add_watch(bus, this._onBusMessage.bind(this));
this._pipeline.set_state(Gst.State.PLAYING);
this._pipelineState = PipelineState.PLAYING;
this._onStartedCallback(this, true);
this._onStartedCallback = null;
}
startRecording(onStartedCallback) {
this._onStartedCallback = onStartedCallback;
const [streamPath] = this._sessionProxy.RecordAreaSync(
this._x, this._y,
this._width, this._height,
{
'is-recording': GLib.Variant.new('b', true),
'cursor-mode': GLib.Variant.new('u', this._drawCursor ? 1 : 0),
});
this._streamProxy = new ScreenCastStreamProxy(Gio.DBus.session,
'org.gnome.ScreenCast.Stream',
streamPath);
this._streamProxy.connectSignal('PipeWireStreamAdded',
(proxy, sender, params) => {
const [nodeId] = params;
this._startPipeline(nodeId);
});
this._sessionProxy.StartSync();
this._sessionState = SessionState.ACTIVE;
}
stopRecording(onStoppedCallback) {
this._pipelineState = PipelineState.FLUSHING;
this._onStoppedCallback = onStoppedCallback;
this._pipeline.send_event(Gst.Event.new_eos());
}
_stopSession() {
this._sessionProxy.StopSync();
this._sessionState = SessionState.STOPPED;
}
_onBusMessage(bus, message, _) {
switch (message.type) {
case Gst.MessageType.EOS:
this._pipeline.set_state(Gst.State.NULL);
this._addRecentItem();
switch (this._pipelineState) {
case PipelineState.FLUSHING:
this._pipelineState = PipelineState.STOPPED;
break;
default:
break;
}
switch (this._sessionState) {
case SessionState.ACTIVE:
this._stopSession();
break;
case SessionState.STOPPED:
this._notifyStopped();
break;
default:
break;
}
break;
default:
break;
}
return true;
}
_substituteThreadCount(pipelineDescr) {
const numProcessors = GLib.get_num_processors();
const numThreads = Math.min(Math.max(1, numProcessors), 64);
return pipelineDescr.replaceAll('%T', numThreads);
}
_ensurePipeline(nodeId) {
const framerate = this._framerate;
let fullPipeline = `
pipewiresrc path=${nodeId}
do-timestamp=true
keepalive-time=1000
resend-last=true !
video/x-raw,max-framerate=${framerate}/1 !
${this._pipelineString} !
filesink location="${this._filePath}"`;
fullPipeline = this._substituteThreadCount(fullPipeline);
try {
this._pipeline = Gst.parse_launch_full(fullPipeline,
null,
Gst.ParseFlags.FATAL_ERRORS);
} catch (e) {
log(`Failed to create pipeline: ${e}`);
this._notifyStopped();
}
return !!this._pipeline;
}
};
var ScreencastService = class extends ServiceImplementation {
constructor() {
super(ScreencastIface, '/org/gnome/Shell/Screencast');
Gst.init(null);
Gtk.init();
this._recorders = new Map();
this._senders = new Map();
this._lockdownSettings = new Gio.Settings({
schema_id: 'org.gnome.desktop.lockdown',
});
this._proxy = new ScreenCastProxy(Gio.DBus.session,
'org.gnome.Mutter.ScreenCast',
'/org/gnome/Mutter/ScreenCast');
this._introspectProxy = new IntrospectProxy(Gio.DBus.session,
'org.gnome.Shell.Introspect',
'/org/gnome/Shell/Introspect');
}
_removeRecorder(sender) {
this._recorders.delete(sender);
if (this._recorders.size === 0)
this.release();
}
_addRecorder(sender, recorder) {
this._recorders.set(sender, recorder);
if (this._recorders.size === 1)
this.hold();
}
_getAbsolutePath(filename) {
if (GLib.path_is_absolute(filename))
return filename;
let videoDir = GLib.get_user_special_dir(GLib.UserDirectory.DIRECTORY_VIDEOS);
if (!GLib.file_test(videoDir, GLib.FileTest.EXISTS))
videoDir = GLib.get_home_dir();
return GLib.build_filenamev([videoDir, filename]);
}
_generateFilePath(template) {
let filename = '';
let escape = false;
[...template].forEach(c => {
if (escape) {
switch (c) {
case '%':
filename += '%';
break;
case 'd': {
const datetime = GLib.DateTime.new_now_local();
const datestr = datetime.format('%0x');
const datestrEscaped = datestr.replace(/\//g, '-');
filename += datestrEscaped;
break;
}
case 't': {
const datetime = GLib.DateTime.new_now_local();
const datestr = datetime.format('%0X');
const datestrEscaped = datestr.replace(/\//g, ':');
filename += datestrEscaped;
break;
}
default:
log(`Warning: Unknown escape ${c}`);
}
escape = false;
} else if (c === '%') {
escape = true;
} else {
filename += c;
}
});
if (escape)
filename += '%';
return this._getAbsolutePath(filename);
}
ScreencastAsync(params, invocation) {
let returnValue = [false, ''];
if (this._lockdownSettings.get_boolean('disable-save-to-disk')) {
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
return;
}
const sender = invocation.get_sender();
if (this._recorders.get(sender)) {
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
return;
}
const [sessionPath] = this._proxy.CreateSessionSync({});
const [fileTemplate, options] = params;
const [screenWidth, screenHeight] = this._introspectProxy.ScreenSize;
const filePath = this._generateFilePath(fileTemplate);
let recorder;
try {
recorder = new Recorder(
sessionPath,
0, 0,
screenWidth, screenHeight,
filePath,
options,
invocation,
_recorder => this._removeRecorder(sender));
} catch (error) {
log(`Failed to create recorder: ${error.message}`);
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
return;
}
this._addRecorder(sender, recorder);
try {
recorder.startRecording(
(_, result) => {
if (result) {
returnValue = [true, filePath];
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
} else {
this._removeRecorder(sender);
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
}
});
} catch (error) {
log(`Failed to start recorder: ${error.message}`);
this._removeRecorder(sender);
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
}
}
ScreencastAreaAsync(params, invocation) {
let returnValue = [false, ''];
if (this._lockdownSettings.get_boolean('disable-save-to-disk')) {
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
return;
}
const sender = invocation.get_sender();
if (this._recorders.get(sender)) {
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
return;
}
const [sessionPath] = this._proxy.CreateSessionSync({});
const [x, y, width, height, fileTemplate, options] = params;
const filePath = this._generateFilePath(fileTemplate);
let recorder;
try {
recorder = new Recorder(
sessionPath,
x, y,
width, height,
filePath,
options,
invocation,
_recorder => this._removeRecorder(sender));
} catch (error) {
log(`Failed to create recorder: ${error.message}`);
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
return;
}
this._addRecorder(sender, recorder);
try {
recorder.startRecording(
(_, result) => {
if (result) {
returnValue = [true, filePath];
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
} else {
this._removeRecorder(sender);
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
}
});
} catch (error) {
log(`Failed to start recorder: ${error.message}`);
this._removeRecorder(sender);
invocation.return_value(GLib.Variant.new('(bs)', returnValue));
}
}
StopScreencastAsync(params, invocation) {
const sender = invocation.get_sender();
const recorder = this._recorders.get(sender);
if (!recorder) {
invocation.return_value(GLib.Variant.new('(b)', [false]));
return;
}
recorder.stopRecording(() => {
this._removeRecorder(sender);
invocation.return_value(GLib.Variant.new('(b)', [true]));
});
}
};

View File

@ -0,0 +1,11 @@
/* exported main */
const { DBusService } = imports.dbusService;
const { ScreenSaverService } = imports.screenSaverService;
function main() {
const service = new DBusService(
'org.gnome.ScreenSaver',
new ScreenSaverService());
service.run();
}

View File

@ -0,0 +1,70 @@
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
/* exported ScreenSaverService */
const { Gio, GLib } = imports.gi;
const { loadInterfaceXML } = imports.misc.fileUtils;
const { ServiceImplementation } = imports.dbusService;
const ScreenSaverIface = loadInterfaceXML('org.gnome.ScreenSaver');
const ScreenSaverProxy = Gio.DBusProxy.makeProxyWrapper(ScreenSaverIface);
var ScreenSaverService = class extends ServiceImplementation {
constructor() {
super(ScreenSaverIface, '/org/gnome/ScreenSaver');
this._autoShutdown = false;
this._proxy = new ScreenSaverProxy(Gio.DBus.session,
'org.gnome.Shell.ScreenShield',
'/org/gnome/ScreenSaver',
(proxy, error) => {
if (error)
log(error.message);
});
this._proxy.connectSignal('ActiveChanged',
(proxy, sender, params) => {
this._dbusImpl.emit_signal('ActiveChanged',
new GLib.Variant('(b)', params));
});
this._proxy.connectSignal('WakeUpScreen',
() => this._dbusImpl.emit_signal('WakeUpScreen', null));
}
LockAsync(params, invocation) {
this._proxy.LockRemote(...params, (res, error) => {
if (this._handleError(invocation, error))
return;
invocation.return_value(null);
});
}
GetActiveAsync(params, invocation) {
this._proxy.GetActiveRemote(...params, (res, error) => {
if (this._handleError(invocation, error))
return;
invocation.return_value(new GLib.Variant('(b)', res));
});
}
SetActiveAsync(params, invocation) {
this._proxy.SetActiveRemote(...params, (res, error) => {
if (this._handleError(invocation, error))
return;
invocation.return_value(null);
});
}
GetActiveTimeAsync(params, invocation) {
this._proxy.GetActiveTimeRemote(...params, (res, error) => {
if (this._handleError(invocation, error))
return;
invocation.return_value(new GLib.Variant('(u)', res));
});
}
};

View File

@ -1,15 +1,17 @@
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
/* exported AuthPrompt */
const { Clutter, GObject, Pango, Shell, St } = imports.gi;
const { Clutter, GLib, GObject, Pango, Shell, St } = imports.gi;
const Animation = imports.ui.animation;
const Batch = imports.gdm.batch;
const GdmUtil = imports.gdm.util;
const Util = imports.misc.util;
const OVirt = imports.gdm.oVirt;
const Vmware = imports.gdm.vmware;
const Params = imports.misc.params;
const ShellEntry = imports.ui.shellEntry;
const UserWidget = imports.ui.userWidget;
const Util = imports.misc.util;
var DEFAULT_BUTTON_WELL_ICON_SIZE = 16;
var DEFAULT_BUTTON_WELL_ANIMATION_DELAY = 1000;
@ -27,11 +29,14 @@ var AuthPromptStatus = {
VERIFYING: 1,
VERIFICATION_FAILED: 2,
VERIFICATION_SUCCEEDED: 3,
VERIFICATION_CANCELLED: 4,
VERIFICATION_IN_PROGRESS: 5,
};
var BeginRequestType = {
PROVIDE_USERNAME: 0,
DONT_PROVIDE_USERNAME: 1,
REUSE_USERNAME: 2,
};
var AuthPrompt = GObject.registerClass({
@ -56,6 +61,7 @@ var AuthPrompt = GObject.registerClass({
this._gdmClient = gdmClient;
this._mode = mode;
this._defaultButtonWellActor = null;
this._cancelledRetries = 0;
let reauthenticationOnly;
if (this._mode == AuthPromptMode.UNLOCK_ONLY)
@ -164,6 +170,13 @@ var AuthPrompt = GObject.registerClass({
this._mainBox.add_child(this._entry);
this._entry.grab_key_focus();
this._timedLoginIndicator = new St.Bin({
style_class: 'login-dialog-timed-login-indicator',
scale_x: 0,
});
this.add_child(this._timedLoginIndicator);
[this._textEntry, this._passwordEntry].forEach(entry => {
entry.clutter_text.connect('text-changed', () => {
if (!this._userVerifier.hasPendingMessages)
@ -192,7 +205,42 @@ var AuthPrompt = GObject.registerClass({
this._defaultButtonWell.add_child(this._spinner);
}
showTimedLoginIndicator(time) {
let hold = new Batch.Hold();
this.hideTimedLoginIndicator();
const startTime = GLib.get_monotonic_time();
this._timedLoginTimeoutId = GLib.timeout_add(GLib.PRIORITY_DEFAULT, 33,
() => {
const currentTime = GLib.get_monotonic_time();
const elapsedTime = (currentTime - startTime) / GLib.USEC_PER_SEC;
this._timedLoginIndicator.scale_x = elapsedTime / time;
if (elapsedTime >= time) {
this._timedLoginTimeoutId = 0;
hold.release();
return GLib.SOURCE_REMOVE;
}
return GLib.SOURCE_CONTINUE;
});
GLib.Source.set_name_by_id(this._timedLoginTimeoutId, '[gnome-shell] this._timedLoginTimeoutId');
return hold;
}
hideTimedLoginIndicator() {
if (this._timedLoginTimeoutId) {
GLib.source_remove(this._timedLoginTimeoutId);
this._timedLoginTimeoutId = 0;
}
this._timedLoginIndicator.scale_x = 0.;
}
_activateNext(shouldSpin) {
this.verificationStatus = AuthPromptStatus.VERIFICATION_IN_PROGRESS;
this.updateSensitivity(false);
if (shouldSpin)
@ -266,20 +314,27 @@ var AuthPrompt = GObject.registerClass({
this.reset();
}
_onShowMessage(userVerifier, message, type) {
this.setMessage(message, type);
_onShowMessage(_userVerifier, serviceName, message, type) {
this.setMessage(serviceName, message, type);
this.emit('prompted');
}
_onVerificationFailed(userVerifier, canRetry) {
this._queryingService = null;
this.clear();
_onVerificationFailed(userVerifier, serviceName, canRetry) {
const wasQueryingService = this._queryingService === serviceName;
if (wasQueryingService) {
this._queryingService = null;
this.clear();
}
this.updateSensitivity(canRetry);
this.setActorInDefaultButtonWell(null);
this.verificationStatus = AuthPromptStatus.VERIFICATION_FAILED;
Util.wiggle(this._entry);
if (!canRetry)
this.verificationStatus = AuthPromptStatus.VERIFICATION_FAILED;
if (wasQueryingService)
Util.wiggle(this._entry);
}
_onVerificationComplete() {
@ -403,7 +458,7 @@ var AuthPrompt = GObject.registerClass({
});
}
setMessage(message, type) {
setMessage(serviceName, message, type) {
if (type == GdmUtil.MessageType.ERROR)
this._message.add_style_class_name('login-dialog-message-warning');
else
@ -421,6 +476,18 @@ var AuthPrompt = GObject.registerClass({
} else {
this._message.opacity = 0;
}
if (type === GdmUtil.MessageType.ERROR &&
this._userVerifier.serviceIsFingerprint(serviceName)) {
// TODO: Use Await for wiggle to be over before unfreezing the user verifier queue
const wiggleParameters = {
duration: 65,
wiggleCount: 3,
};
this._userVerifier.increaseCurrentMessageTimeout(
wiggleParameters.duration * (wiggleParameters.wiggleCount + 2));
Util.wiggle(this._message, wiggleParameters);
}
}
updateSensitivity(sensitive) {
@ -429,8 +496,14 @@ var AuthPrompt = GObject.registerClass({
this._entry.reactive = sensitive;
if (sensitive)
if (sensitive) {
this._entry.grab_key_focus();
} else {
this.grab_key_focus();
if (this._entry === this._passwordEntry)
this._entry.password_visible = false;
}
}
vfunc_hide() {
@ -475,18 +548,26 @@ var AuthPrompt = GObject.registerClass({
if (oldStatus == AuthPromptStatus.VERIFICATION_FAILED)
this.emit('failed');
else if (oldStatus === AuthPromptStatus.VERIFICATION_CANCELLED)
this.emit('cancelled');
let beginRequestType;
if (this._mode == AuthPromptMode.UNLOCK_ONLY) {
// The user is constant at the unlock screen, so it will immediately
// respond to the request with the username
if (oldStatus === AuthPromptStatus.VERIFICATION_CANCELLED)
return;
beginRequestType = BeginRequestType.PROVIDE_USERNAME;
} else if (this._userVerifier.serviceIsForeground(GdmUtil.OVIRT_SERVICE_NAME) ||
} else if (this._userVerifier.serviceIsForeground(OVirt.SERVICE_NAME) ||
this._userVerifier.serviceIsForeground(Vmware.SERVICE_NAME) ||
this._userVerifier.serviceIsForeground(GdmUtil.SMARTCARD_SERVICE_NAME)) {
// We don't need to know the username if the user preempted the login screen
// with a smartcard or with preauthenticated oVirt credentials
beginRequestType = BeginRequestType.DONT_PROVIDE_USERNAME;
} else if (oldStatus === AuthPromptStatus.VERIFICATION_IN_PROGRESS) {
// We're going back to retry with current user
beginRequestType = BeginRequestType.REUSE_USERNAME;
} else {
// In all other cases, we should get the username up front.
beginRequestType = BeginRequestType.PROVIDE_USERNAME;
@ -535,7 +616,14 @@ var AuthPrompt = GObject.registerClass({
if (this.verificationStatus == AuthPromptStatus.VERIFICATION_SUCCEEDED)
return;
if (this.verificationStatus === AuthPromptStatus.VERIFICATION_IN_PROGRESS) {
this._cancelledRetries++;
if (this._cancelledRetries > this._userVerifier.allowedFailures)
this.verificationStatus = AuthPromptStatus.VERIFICATION_FAILED;
} else {
this.verificationStatus = AuthPromptStatus.VERIFICATION_CANCELLED;
}
this.reset();
this.emit('cancelled');
}
});

View File

@ -1,7 +1,7 @@
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
/* exported CredentialManager */
class CredentialManager {
var CredentialManager = class CredentialManager {
constructor(service) {
this._token = null;
this._service = service;
@ -21,4 +21,4 @@ class CredentialManager {
get service() {
return this._service;
}
}
};

View File

@ -1,33 +0,0 @@
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
/* exported FprintManager */
const Gio = imports.gi.Gio;
const FprintManagerIface = `
<node>
<interface name="net.reactivated.Fprint.Manager">
<method name="GetDefaultDevice">
<arg type="o" direction="out" />
</method>
</interface>
</node>`;
const FprintManagerInfo = Gio.DBusInterfaceInfo.new_for_xml(FprintManagerIface);
function FprintManager() {
var self = new Gio.DBusProxy({ g_connection: Gio.DBus.system,
g_interface_name: FprintManagerInfo.name,
g_interface_info: FprintManagerInfo,
g_name: 'net.reactivated.Fprint',
g_object_path: '/net/reactivated/Fprint/Manager',
g_flags: Gio.DBusProxyFlags.DO_NOT_LOAD_PROPERTIES });
try {
self.init(null);
} catch (e) {
log(`Failed to connect to Fprint service: ${e.message}`);
return null;
}
return self;
}

View File

@ -42,7 +42,6 @@ var UserListItem = GObject.registerClass({
_init(user) {
let layout = new St.BoxLayout({
vertical: true,
x_align: Clutter.ActorAlign.START,
});
super._init({
style_class: 'login-dialog-user-list-item',
@ -464,6 +463,7 @@ var LoginDialog = GObject.registerClass({
child: notListedLabel,
reactive: true,
x_align: Clutter.ActorAlign.START,
label_actor: notListedLabel,
});
this._notListedButton.connect('clicked', this._hideUserListAskForUsernameAndBeginVerification.bind(this));
@ -762,6 +762,9 @@ var LoginDialog = GObject.registerClass({
if (this._authPrompt.verificationStatus == AuthPrompt.AuthPromptStatus.NOT_VERIFYING)
this._authPrompt.reset();
if (this._disableUserList && this._timedLoginUserListHold)
this._timedLoginUserListHold.release();
}
}
@ -855,6 +858,7 @@ var LoginDialog = GObject.registerClass({
this._resetGreeterProxy();
this._sessionMenuButton.updateSensitivity(true);
const previousUser = this._user;
this._user = null;
if (this._nextSignalId) {
@ -862,7 +866,11 @@ var LoginDialog = GObject.registerClass({
this._nextSignalId = 0;
}
if (beginRequest == AuthPrompt.BeginRequestType.PROVIDE_USERNAME) {
if (previousUser && beginRequest === AuthPrompt.BeginRequestType.REUSE_USERNAME) {
this._user = previousUser;
this._authPrompt.setUser(this._user);
this._authPrompt.begin({ userName: previousUser.get_user_name() });
} else if (beginRequest === AuthPrompt.BeginRequestType.PROVIDE_USERNAME) {
if (!this._disableUserList)
this._showUserList();
else
@ -953,16 +961,15 @@ var LoginDialog = GObject.registerClass({
if (this.opacity == 255 && this._authPrompt.verificationStatus == AuthPrompt.AuthPromptStatus.NOT_VERIFYING)
return;
if (this._authPrompt.verificationStatus !== AuthPrompt.AuthPromptStatus.NOT_VERIFYING)
this._authPrompt.reset();
this._bindOpacity();
this.ease({
opacity: 255,
duration: _FADE_ANIMATION_TIME,
mode: Clutter.AnimationMode.EASE_OUT_QUAD,
onComplete: () => {
if (this._authPrompt.verificationStatus != AuthPrompt.AuthPromptStatus.NOT_VERIFYING)
this._authPrompt.reset();
this._unbindOpacity();
},
onComplete: () => this._unbindOpacity(),
});
}
@ -1044,54 +1051,72 @@ var LoginDialog = GObject.registerClass({
let loginItem = null;
let animationTime;
let tasks = [() => this._waitForItemForUser(userName),
let tasks = [
() => {
if (this._disableUserList)
return;
() => {
loginItem = this._userList.getItemFromUserName(userName);
this._timedLoginUserListHold = this._waitForItemForUser(userName);
},
// If there is an animation running on the item, reset it.
loginItem.hideTimedLoginIndicator();
},
() => {
this._timedLoginUserListHold = null;
() => {
// If we're just starting out, start on the right item.
if (!this._userManager.is_loaded)
this._userList.jumpToItem(loginItem);
},
if (this._disableUserList)
loginItem = this._authPrompt;
else
loginItem = this._userList.getItemFromUserName(userName);
() => {
// This blocks the timed login animation until a few
// seconds after the user stops interacting with the
// login screen.
// If there is an animation running on the item, reset it.
loginItem.hideTimedLoginIndicator();
},
// We skip this step if the timed login delay is very short.
if (delay > _TIMED_LOGIN_IDLE_THRESHOLD) {
animationTime = delay - _TIMED_LOGIN_IDLE_THRESHOLD;
return this._blockTimedLoginUntilIdle();
} else {
animationTime = delay;
return null;
}
},
() => {
if (this._disableUserList)
return;
() => {
// If idle timeout is done, make sure the timed login indicator is shown
if (delay > _TIMED_LOGIN_IDLE_THRESHOLD &&
this._authPrompt.visible)
this._authPrompt.cancel();
// If we're just starting out, start on the right item.
if (!this._userManager.is_loaded)
this._userList.jumpToItem(loginItem);
},
if (delay > _TIMED_LOGIN_IDLE_THRESHOLD || firstRun) {
this._userList.scrollToItem(loginItem);
loginItem.grab_key_focus();
}
},
() => {
// This blocks the timed login animation until a few
// seconds after the user stops interacting with the
// login screen.
() => loginItem.showTimedLoginIndicator(animationTime),
// We skip this step if the timed login delay is very short.
if (delay > _TIMED_LOGIN_IDLE_THRESHOLD) {
animationTime = delay - _TIMED_LOGIN_IDLE_THRESHOLD;
return this._blockTimedLoginUntilIdle();
} else {
animationTime = delay;
return null;
}
},
() => {
this._timedLoginBatch = null;
this._greeter.call_begin_auto_login_sync(userName, null);
}];
() => {
if (this._disableUserList)
return;
// If idle timeout is done, make sure the timed login indicator is shown
if (delay > _TIMED_LOGIN_IDLE_THRESHOLD &&
this._authPrompt.visible)
this._authPrompt.cancel();
if (delay > _TIMED_LOGIN_IDLE_THRESHOLD || firstRun) {
this._userList.scrollToItem(loginItem);
loginItem.grab_key_focus();
}
},
() => loginItem.showTimedLoginIndicator(animationTime),
() => {
this._timedLoginBatch = null;
this._greeter.call_begin_auto_login_sync(userName, null);
},
];
this._timedLoginBatch = new Batch.ConsecutiveBatch(this, tasks);

View File

@ -6,13 +6,18 @@ const { Clutter, Gdm, Gio, GLib } = imports.gi;
const Signals = imports.signals;
const Batch = imports.gdm.batch;
const Fprint = imports.gdm.fingerprint;
const OVirt = imports.gdm.oVirt;
const Vmware = imports.gdm.vmware;
const Main = imports.ui.main;
const { loadInterfaceXML } = imports.misc.fileUtils;
const Params = imports.misc.params;
const SmartcardManager = imports.misc.smartcardManager;
const FprintManagerIface = loadInterfaceXML('net.reactivated.Fprint.Manager');
const FprintManagerProxy = Gio.DBusProxy.makeProxyWrapper(FprintManagerIface);
const FprintDeviceIface = loadInterfaceXML('net.reactivated.Fprint.Device');
const FprintDeviceProxy = Gio.DBusProxy.makeProxyWrapper(FprintDeviceIface);
Gio._promisify(Gdm.Client.prototype,
'open_reauthentication_channel', 'open_reauthentication_channel_finish');
Gio._promisify(Gdm.Client.prototype,
@ -41,12 +46,20 @@ var DISABLE_USER_LIST_KEY = 'disable-user-list';
// Give user 48ms to read each character of a PAM message
var USER_READ_TIME = 48;
const FINGERPRINT_ERROR_TIMEOUT_WAIT = 15;
var MessageType = {
// Keep messages in order by priority
NONE: 0,
ERROR: 1,
HINT: 1,
INFO: 2,
HINT: 3,
ERROR: 3,
};
const FingerprintReaderType = {
NONE: 0,
PRESS: 1,
SWIPE: 2,
};
function fadeInActor(actor) {
@ -138,7 +151,12 @@ var ShellUserVerifier = class {
this._updateDefaultService.bind(this));
this._updateDefaultService();
this._fprintManager = Fprint.FprintManager();
this._fprintManager = new FprintManagerProxy(Gio.DBus.system,
'net.reactivated.Fprint',
'/net/reactivated/Fprint/Manager',
null,
null,
Gio.DBusProxyFlags.DO_NOT_LOAD_PROPERTIES);
this._smartcardManager = SmartcardManager.getSmartcardManager();
// We check for smartcards right away, since an inserted smartcard
@ -155,10 +173,10 @@ var ShellUserVerifier = class {
this._messageQueue = [];
this._messageQueueTimeoutId = 0;
this.hasPendingMessages = false;
this.reauthenticating = false;
this._failCounter = 0;
this._unavailableServices = new Set();
this._credentialManagers = {};
this._credentialManagers[OVirt.SERVICE_NAME] = OVirt.getOVirtCredentialsManager();
@ -176,6 +194,18 @@ var ShellUserVerifier = class {
}
}
get hasPendingMessages() {
return !!this._messageQueue.length;
}
get allowedFailures() {
return this._settings.get_int(ALLOWED_FAILURES_KEY);
}
get currentMessage() {
return this._messageQueue ? this._messageQueue[0] : null;
}
begin(userName, hold) {
this._cancellable = new Gio.Cancellable();
this._hold = hold;
@ -204,6 +234,7 @@ var ShellUserVerifier = class {
_clearUserVerifier() {
if (this._userVerifier) {
this._disconnectSignals();
this._userVerifier.run_dispose();
this._userVerifier = null;
}
@ -220,7 +251,7 @@ var ShellUserVerifier = class {
}
destroy() {
this.clear();
this.cancel();
this._settings.run_dispose();
this._settings = null;
@ -240,14 +271,19 @@ var ShellUserVerifier = class {
if (!this.hasPendingMessages) {
this._userVerifier.call_answer_query(serviceName, answer, this._cancellable, null);
} else {
const cancellable = this._cancellable;
let signalId = this.connect('no-more-messages', () => {
this.disconnect(signalId);
this._userVerifier.call_answer_query(serviceName, answer, this._cancellable, null);
if (!cancellable.is_cancelled())
this._userVerifier.call_answer_query(serviceName, answer, cancellable, null);
});
}
}
_getIntervalForMessage(message) {
if (!message)
return 0;
// We probably could be smarter here
return message.length * USER_READ_TIME;
}
@ -258,41 +294,72 @@ var ShellUserVerifier = class {
this._messageQueue = [];
this.hasPendingMessages = false;
this.emit('no-more-messages');
}
_queueMessageTimeout() {
if (this._messageQueue.length == 0) {
this.finishMessageQueue();
return;
}
increaseCurrentMessageTimeout(interval) {
if (!this._messageQueueTimeoutId && interval > 0)
this._currentMessageExtraInterval = interval;
}
_serviceHasPendingMessages(serviceName) {
return this._messageQueue.some(m => m.serviceName === serviceName);
}
_filterServiceMessages(serviceName, messageType) {
// This function allows to remove queued messages for the @serviceName
// whose type has lower priority than @messageType, replacing them
// with a null message that will lead to clearing the prompt once done.
if (this._serviceHasPendingMessages(serviceName))
this._queuePriorityMessage(serviceName, null, messageType);
}
_queueMessageTimeout() {
if (this._messageQueueTimeoutId != 0)
return;
let message = this._messageQueue.shift();
const message = this.currentMessage;
this.emit('show-message', message.text, message.type);
delete this._currentMessageExtraInterval;
this.emit('show-message', message.serviceName, message.text, message.type);
this._messageQueueTimeoutId = GLib.timeout_add(GLib.PRIORITY_DEFAULT,
message.interval,
() => {
this._messageQueueTimeoutId = 0;
this._queueMessageTimeout();
return GLib.SOURCE_REMOVE;
});
message.interval + (this._currentMessageExtraInterval | 0), () => {
this._messageQueueTimeoutId = 0;
if (this._messageQueue.length > 1) {
this._messageQueue.shift();
this._queueMessageTimeout();
} else {
this.finishMessageQueue();
}
return GLib.SOURCE_REMOVE;
});
GLib.Source.set_name_by_id(this._messageQueueTimeoutId, '[gnome-shell] this._queueMessageTimeout');
}
_queueMessage(message, messageType) {
_queueMessage(serviceName, message, messageType) {
let interval = this._getIntervalForMessage(message);
this.hasPendingMessages = true;
this._messageQueue.push({ text: message, type: messageType, interval });
this._messageQueue.push({ serviceName, text: message, type: messageType, interval });
this._queueMessageTimeout();
}
_queuePriorityMessage(serviceName, message, messageType) {
const newQueue = this._messageQueue.filter(m => {
if (m.serviceName !== serviceName || m.type >= messageType)
return m.text !== message;
return false;
});
if (!newQueue.includes(this.currentMessage))
this._clearMessageQueue();
this._messageQueue = newQueue;
this._queueMessage(serviceName, message, messageType);
}
_clearMessageQueue() {
this.finishMessageQueue();
@ -300,11 +367,11 @@ var ShellUserVerifier = class {
GLib.source_remove(this._messageQueueTimeoutId);
this._messageQueueTimeoutId = 0;
}
this.emit('show-message', null, MessageType.NONE);
this.emit('show-message', null, null, MessageType.NONE);
}
_checkForFingerprintReader() {
this._haveFingerprintReader = false;
this._fingerprintReaderType = FingerprintReaderType.NONE;
if (!this._settings.get_boolean(FINGERPRINT_AUTHENTICATION_KEY) ||
this._fprintManager == null) {
@ -313,9 +380,17 @@ var ShellUserVerifier = class {
}
this._fprintManager.GetDefaultDeviceRemote(Gio.DBusCallFlags.NONE, this._cancellable,
(device, error) => {
if (!error && device) {
this._haveFingerprintReader = true;
(params, error) => {
if (!error && params) {
const [device] = params;
const fprintDeviceProxy = new FprintDeviceProxy(Gio.DBus.system,
'net.reactivated.Fprint',
device);
const fprintDeviceType = fprintDeviceProxy['scan-type'];
this._fingerprintReaderType = fprintDeviceType === 'swipe'
? FingerprintReaderType.SWIPE
: FingerprintReaderType.PRESS;
this._updateDefaultService();
}
});
@ -348,12 +423,13 @@ var ShellUserVerifier = class {
}
}
_reportInitError(where, error) {
_reportInitError(where, error, serviceName) {
logError(error, where);
this._hold.release();
this._queueMessage(_("Authentication error"), MessageType.ERROR);
this._verificationFailed(false);
this._queueMessage(serviceName, _('Authentication error'), MessageType.ERROR);
this._failCounter++;
this._verificationFailed(serviceName, false);
}
async _openReauthenticationChannel(userName) {
@ -401,13 +477,33 @@ var ShellUserVerifier = class {
}
_connectSignals() {
this._userVerifier.connect('info', this._onInfo.bind(this));
this._userVerifier.connect('problem', this._onProblem.bind(this));
this._userVerifier.connect('info-query', this._onInfoQuery.bind(this));
this._userVerifier.connect('secret-info-query', this._onSecretInfoQuery.bind(this));
this._userVerifier.connect('conversation-stopped', this._onConversationStopped.bind(this));
this._userVerifier.connect('reset', this._onReset.bind(this));
this._userVerifier.connect('verification-complete', this._onVerificationComplete.bind(this));
this._disconnectSignals();
this._signalIds = [];
let id = this._userVerifier.connect('info', this._onInfo.bind(this));
this._signalIds.push(id);
id = this._userVerifier.connect('problem', this._onProblem.bind(this));
this._signalIds.push(id);
id = this._userVerifier.connect('info-query', this._onInfoQuery.bind(this));
this._signalIds.push(id);
id = this._userVerifier.connect('secret-info-query', this._onSecretInfoQuery.bind(this));
this._signalIds.push(id);
id = this._userVerifier.connect('conversation-stopped', this._onConversationStopped.bind(this));
this._signalIds.push(id);
id = this._userVerifier.connect('service-unavailable', this._onServiceUnavailable.bind(this));
this._signalIds.push(id);
id = this._userVerifier.connect('reset', this._onReset.bind(this));
this._signalIds.push(id);
id = this._userVerifier.connect('verification-complete', this._onVerificationComplete.bind(this));
this._signalIds.push(id);
}
_disconnectSignals() {
if (!this._signalIds || !this._userVerifier)
return;
this._signalIds.forEach(s => this._userVerifier.disconnect(s));
this._signalIds = [];
}
_getForegroundService() {
@ -425,12 +521,17 @@ var ShellUserVerifier = class {
return serviceName == this._defaultService;
}
serviceIsFingerprint(serviceName) {
return this._fingerprintReaderType !== FingerprintReaderType.NONE &&
serviceName === FINGERPRINT_SERVICE_NAME;
}
_updateDefaultService() {
if (this._settings.get_boolean(PASSWORD_AUTHENTICATION_KEY))
this._defaultService = PASSWORD_SERVICE_NAME;
else if (this._settings.get_boolean(SMARTCARD_AUTHENTICATION_KEY))
this._defaultService = SMARTCARD_SERVICE_NAME;
else if (this._haveFingerprintReader)
else if (this._fingerprintReaderType !== FingerprintReaderType.NONE)
this._defaultService = FINGERPRINT_SERVICE_NAME;
if (!this._defaultService) {
@ -452,9 +553,15 @@ var ShellUserVerifier = class {
} catch (e) {
if (e.matches(Gio.IOErrorEnum, Gio.IOErrorEnum.CANCELLED))
return;
if (!this.serviceIsForeground(serviceName)) {
logError(e, 'Failed to start %s for %s'.format(serviceName, this._userName));
this._hold.release();
return;
}
this._reportInitError(this._userName
? 'Failed to start verification for user'
: 'Failed to start verification', e);
? 'Failed to start %s verification for user'.format(serviceName)
: 'Failed to start %s verification'.format(serviceName), e,
serviceName);
return;
}
this._hold.release();
@ -463,30 +570,67 @@ var ShellUserVerifier = class {
_beginVerification() {
this._startService(this._getForegroundService());
if (this._userName && this._haveFingerprintReader && !this.serviceIsForeground(FINGERPRINT_SERVICE_NAME))
if (this._userName &&
this._fingerprintReaderType !== FingerprintReaderType.NONE &&
!this.serviceIsForeground(FINGERPRINT_SERVICE_NAME))
this._startService(FINGERPRINT_SERVICE_NAME);
}
_onInfo(client, serviceName, info) {
if (this.serviceIsForeground(serviceName)) {
this._queueMessage(info, MessageType.INFO);
} else if (serviceName == FINGERPRINT_SERVICE_NAME &&
this._haveFingerprintReader) {
this._queueMessage(serviceName, info, MessageType.INFO);
} else if (this.serviceIsFingerprint(serviceName)) {
// We don't show fingerprint messages directly since it's
// not the main auth service. Instead we use the messages
// as a cue to display our own message.
// Translators: this message is shown below the password entry field
// to indicate the user can swipe their finger instead
this._queueMessage(_("(or swipe finger)"), MessageType.HINT);
if (this._fingerprintReaderType === FingerprintReaderType.SWIPE) {
// Translators: this message is shown below the password entry field
// to indicate the user can swipe their finger on the fingerprint reader
this._queueMessage(serviceName, _('(or swipe finger across reader)'),
MessageType.HINT);
} else {
// Translators: this message is shown below the password entry field
// to indicate the user can place their finger on the fingerprint reader instead
this._queueMessage(serviceName, _('(or place finger on reader)'),
MessageType.HINT);
}
}
}
_onProblem(client, serviceName, problem) {
if (!this.serviceIsForeground(serviceName))
const isFingerprint = this.serviceIsFingerprint(serviceName);
if (!this.serviceIsForeground(serviceName) && !isFingerprint)
return;
this._queueMessage(problem, MessageType.ERROR);
this._queuePriorityMessage(serviceName, problem, MessageType.ERROR);
if (isFingerprint) {
// pam_fprintd allows the user to retry multiple (maybe even infinite!
// times before failing the authentication conversation.
// We don't want this behavior to bypass the max-tries setting the user has set,
// so we count the problem messages to know how many times the user has failed.
// Once we hit the max number of failures we allow, it's time to failure the
// conversation from our side. We can't do that right away, however, because
// we may drop pending messages coming from pam_fprintd. In order to make sure
// the user sees everything, we queue the failure up to get handled in the
// near future, after we've finished up the current round of messages.
this._failCounter++;
if (!this._canRetry()) {
if (this._fingerprintFailedId)
GLib.source_remove(this._fingerprintFailedId);
const cancellable = this._cancellable;
this._fingerprintFailedId = GLib.timeout_add(GLib.PRIORITY_DEFAULT,
FINGERPRINT_ERROR_TIMEOUT_WAIT, () => {
this._fingerprintFailedId = 0;
if (!cancellable.is_cancelled())
this._verificationFailed(serviceName, false);
return GLib.SOURCE_REMOVE;
});
}
}
}
_onInfoQuery(client, serviceName, question) {
@ -515,6 +659,7 @@ var ShellUserVerifier = class {
_onReset() {
// Clear previous attempts to authenticate
this._failCounter = 0;
this._unavailableServices.clear();
this._updateDefaultService();
this.emit('reset');
@ -529,44 +674,69 @@ var ShellUserVerifier = class {
this._onReset();
}
_retry() {
this.begin(this._userName, new Batch.Hold());
_retry(serviceName) {
this._hold = new Batch.Hold();
this._connectSignals();
this._startService(serviceName);
}
_verificationFailed(retry) {
_canRetry() {
return this._userName &&
(this._reauthOnly || this._failCounter < this.allowedFailures);
}
_verificationFailed(serviceName, shouldRetry) {
if (serviceName === FINGERPRINT_SERVICE_NAME) {
if (this._fingerprintFailedId)
GLib.source_remove(this._fingerprintFailedId);
}
// For Not Listed / enterprise logins, immediately reset
// the dialog
// Otherwise, when in login mode we allow ALLOWED_FAILURES attempts.
// After that, we go back to the welcome screen.
this._filterServiceMessages(serviceName, MessageType.ERROR);
this._failCounter++;
let canRetry = retry && this._userName &&
(this._reauthOnly ||
this._failCounter < this._settings.get_int(ALLOWED_FAILURES_KEY));
const doneTrying = !shouldRetry || !this._canRetry();
if (doneTrying) {
this._disconnectSignals();
if (canRetry) {
if (!this.hasPendingMessages) {
this._retry();
} else {
let signalId = this.connect('no-more-messages', () => {
this.disconnect(signalId);
if (this._cancellable && !this._cancellable.is_cancelled())
this._retry();
});
}
} else {
// eslint-disable-next-line no-lonely-if
if (!this.hasPendingMessages) {
this._cancelAndReset();
} else {
const cancellable = this._cancellable;
let signalId = this.connect('no-more-messages', () => {
this.disconnect(signalId);
this._cancelAndReset();
if (!cancellable.is_cancelled())
this._cancelAndReset();
});
}
}
this.emit('verification-failed', canRetry);
this.emit('verification-failed', serviceName, !doneTrying);
if (!this.hasPendingMessages) {
this._retry(serviceName);
} else {
const cancellable = this._cancellable;
let signalId = this.connect('no-more-messages', () => {
this.disconnect(signalId);
if (!cancellable.is_cancelled())
this._retry(serviceName);
});
}
}
_onServiceUnavailable(_client, serviceName, errorMessage) {
this._unavailableServices.add(serviceName);
if (!errorMessage)
return;
if (this.serviceIsForeground(serviceName) || this.serviceIsFingerprint(serviceName))
this._queueMessage(serviceName, errorMessage, MessageType.ERROR);
}
_onConversationStopped(client, serviceName) {
@ -578,15 +748,22 @@ var ShellUserVerifier = class {
if (foregroundService) {
this._credentialManagers[foregroundService].token = null;
this._preemptingService = null;
this._verificationFailed(false);
this._verificationFailed(serviceName, false);
return;
}
this._filterServiceMessages(serviceName, MessageType.ERROR);
if (this._unavailableServices.has(serviceName))
return;
// if the password service fails, then cancel everything.
// But if, e.g., fingerprint fails, still give
// password authentication a chance to succeed
if (this.serviceIsForeground(serviceName))
this._verificationFailed(true);
this._failCounter++;
this._verificationFailed(serviceName, true);
}
};
Signals.addSignalMethods(ShellUserVerifier.prototype);

View File

@ -3,7 +3,6 @@
<gresource prefix="/org/gnome/shell">
<file>gdm/authPrompt.js</file>
<file>gdm/batch.js</file>
<file>gdm/fingerprint.js</file>
<file>gdm/loginDialog.js</file>
<file>gdm/oVirt.js</file>
<file>gdm/credentialManager.js</file>
@ -32,6 +31,7 @@
<file>misc/util.js</file>
<file>misc/weather.js</file>
<file>perf/basic.js</file>
<file>perf/core.js</file>
<file>perf/hwtest.js</file>
@ -40,6 +40,7 @@
<file>ui/animation.js</file>
<file>ui/appDisplay.js</file>
<file>ui/appFavorites.js</file>
<file>ui/appMenu.js</file>
<file>ui/audioDeviceSelection.js</file>
<file>ui/backgroundMenu.js</file>
<file>ui/background.js</file>
@ -63,6 +64,7 @@
<file>ui/ibusCandidatePopup.js</file>
<file>ui/iconGrid.js</file>
<file>ui/inhibitShortcutsDialog.js</file>
<file>ui/init.js</file>
<file>ui/kbdA11yDialog.js</file>
<file>ui/keyboard.js</file>
<file>ui/layout.js</file>
@ -70,7 +72,6 @@
<file>ui/locatePointer.js</file>
<file>ui/lookingGlass.js</file>
<file>ui/magnifier.js</file>
<file>ui/magnifierDBus.js</file>
<file>ui/main.js</file>
<file>ui/messageTray.js</file>
<file>ui/messageList.js</file>
@ -92,10 +93,10 @@
<file>ui/ripples.js</file>
<file>ui/runDialog.js</file>
<file>ui/screenShield.js</file>
<file>ui/screencast.js</file>
<file>ui/screenshot.js</file>
<file>ui/scripting.js</file>
<file>ui/search.js</file>
<file>ui/searchController.js</file>
<file>ui/sessionMode.js</file>
<file>ui/shellDBus.js</file>
<file>ui/shellEntry.js</file>
@ -106,12 +107,13 @@
<file>ui/switchMonitor.js</file>
<file>ui/unlockDialog.js</file>
<file>ui/userWidget.js</file>
<file>ui/viewSelector.js</file>
<file>ui/welcomeDialog.js</file>
<file>ui/windowAttentionHandler.js</file>
<file>ui/windowMenu.js</file>
<file>ui/windowManager.js</file>
<file>ui/windowPreview.js</file>
<file>ui/workspace.js</file>
<file>ui/workspaceAnimation.js</file>
<file>ui/workspaceSwitcherPopup.js</file>
<file>ui/workspaceThumbnail.js</file>
<file>ui/workspacesView.js</file>
@ -133,12 +135,19 @@
<file>ui/status/nightLight.js</file>
<file>ui/status/network.js</file>
<file>ui/status/power.js</file>
<file>ui/status/powerProfiles.js</file>
<file>ui/status/rfkill.js</file>
<file>ui/status/volume.js</file>
<file>ui/status/bluetooth.js</file>
<file>ui/status/remoteAccess.js</file>
<file>ui/status/screencast.js</file>
<file>ui/status/system.js</file>
<file>ui/status/thunderbolt.js</file>
<file>ui/realms/realmIndicator.js</file>
<file>ui/realms/realmManager.js</file>
<file>ui/realms/realmSearchProvider.js</file>
<file>ui/realms/realmSwitcher.js</file>
<file>ui/realms/realmWindowFrame.js</file>
<file>ui/realms/realmWindowMenu.js</file>
</gresource>
</gresources>

View File

@ -8,6 +8,8 @@ var PACKAGE_VERSION = '@PACKAGE_VERSION@';
var HAVE_BLUETOOTH = @HAVE_BLUETOOTH@;
/* 1 if networkmanager is available, 0 otherwise */
var HAVE_NETWORKMANAGER = @HAVE_NETWORKMANAGER@;
/* 1 if soup3 support is enabled, 0 otherwise */
var HAVE_SOUP2 = @HAVE_SOUP2@;
/* gettext package */
var GETTEXT_PACKAGE = '@GETTEXT_PACKAGE@';
/* locale dir */

Some files were not shown because too many files have changed in this diff Show More