Commit Graph

7489 Commits

Author SHA1 Message Date
Jonas Dreßler
bf2d012e40 appDisplay: Rename _redisplay() functions unrelated to BaseAppView
The _redisplay() function is usally used for subclasses of BaseAppView
which want to implement their own _redisplay() function, having that
function name in two classes which have nothing to do with BaseAppView
can be quite confusing. Make those names less confusing and call the
functions  _sync() and _rebuildMenu() instead.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011
2020-03-08 00:42:40 +00:00
Jonas Dreßler
711d4ba65c appDisplay: Properly hide overlay scrollbar in folders
Use the scroll-view policy ST_POLICY_EXTERNAL to hide the scrollbar
instead of setting its css properties to hidden, where it can still be
clicked but isn't visible.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011
2020-03-08 00:42:40 +00:00
Jonas Dreßler
4490463513 appDisplay: Remove the top padding from folder app grid
There already is a bottom padding defined for the name container of the
folder, so remove the top padding of the appGrid and make sure we can
show a few more icons inside the folder.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011
2020-03-08 00:42:40 +00:00
Jonas Dreßler
1ec5117715 appDisplay: Take the viewBox into account for the contentBox of folders
The viewBox has a border applied, so when we call adaptToSize using only
the content box of the container, the width of the border is not removed
from the content box and the grid will be allocated less space than what
we told it before using adaptToSize.

Fix that by adjusting the content box for the size of the viewBox, too.
This makes sure the correct amount of columns can be shown inside a
folder, since right now we only show 3 colums even though 4 would fit.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011
2020-03-08 00:42:40 +00:00
Jonas Dreßler
3ddae9d815 slider: Include handle border radius when calculating center offset
Since 38da479ee we correctly ceil the non-integer radius of the slider
handle when calculating the offset for drawing the circle. Since the
handle also has a border with a width of 1px by default, we should also
factor that in when calculating the offset.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/1569
2020-03-06 19:29:06 +00:00
Sebastian Keller
09a1e61c63 location: Update desktop file name for privacy settings
The location settings have been moved to their own panel with a
different desktop file:
https://gitlab.gnome.org/GNOME/gnome-control-center/-/commit/f92f6f5c

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/2316
2020-03-06 19:16:47 +00:00
Marco Trevisan (Treviño)
7345a6f276 main: Get the theme resource name from sessionMode
Along the lines of `styleSheetName`, a session mode may want to provide its
own gresource file, so make this possible via a `themeResourceName` session
mode parameter, defaulted to gnome-shell-theme.gresource

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1063
2020-03-06 19:09:25 +00:00
Florian Müllner
fda938175e shellDBus: Add new OpenExtensionPrefs method
Unlike any other methods in the Extensions API, LaunchExtensionPrefs()
opens what appears to be an application dialog, except that it is
really a separate application that the caller has no control over.

In order to address that, add a new OpenExtensionPrefs() method that
takes additional parameters (modelled after the desktop portal APIs)
that will make it possible to improve the behavior in the future.

The new parameters are ignored for now, but pushing the API out now
will allow us to fill in the functionality post the .0 release.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1074
2020-03-06 19:03:02 +00:00
Florian Müllner
3a39fb5ab8 shellDBus: Add UserExtensionsEnabled property
The 'disable-user-extensions' GSettings key is the last extensions-related
setting that isn't exposed over D-Bus, and therefore requires consumers
to access the GSettings directly.

Expose the setting as UserExtensionsEnabled readwrite property in the
org.gnome.Shell.Extensions interface to allow consumers to manage
extensions purely via D-Bus.

The 'disable-user-extensions' setting is the last extension-related
bit from the org.gnome.shell GSettings schema that is not exposed
via D-Bus.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1074
2020-03-06 19:03:02 +00:00
Carlos Garnacho
1a0ec782b5 ibusManager: Ensure to spawn --xim on non-wayland sessions
This (mistakenly) now only depends on signals triggered on Wayland
sessions. Hardcoding the XIM support on X11 sessions will make input
in some clients work again.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/1690
2020-03-06 18:57:23 +00:00
Olivier Fourdan
a96753f085 windowManager: X11 can work without gsd-xsettings
Currently, a failure to start the Systemd unit `gsd-xsettings.target`
would be considered a failure to start Xwayland.

That means that if `gsd-xsettings.target` fails to start for whatever
reason, no X11 client can be used on Wayland.

However, XSettings is by no mean mandatory for X11 clients and many
legacy X11 clients do not implement XSettings. Those who do always have
a fallback path and therefore can still work without XSettings.

Make a failure to start the Systemd unit `gsd-xsettings.target` non
blocking for Xwayland, and just log a warning message.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1065
2020-03-06 18:50:52 +00:00
Florian Müllner
0dd171a7c8 environment: Fix date conversion
This is a regression from commit 06b690ff21:

GLib.DateTime.new() expects the full four-digit year, so passing
the abbreviated year from Date() will result in a bogus datetime.

Today is *not* Saturday March 2nd, 120 ...

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1061
2020-03-02 13:54:23 +01:00
Florian Müllner
ff2a736193 unlockDialog: Transition switch-user button with prompt
We ended up always showing the switch-user button on the lock screen,
as showing and hiding it with the prompt was too visually distracting.

But now that we have a fancy transition in place, we can easily extend
it to the switch-user button as well.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1029
2020-03-01 01:21:04 +00:00
Florian Müllner
c6cf81f28b unlockDialog: Simplify sensitivity handling
We only call _updateSensitivity() to make elements sensitive, and
nothing ever touches the sensitivity of the switch-user button; so
just call the corresponding authPrompt method directly, which is the
only bit that has an actual effect.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1029
2020-03-01 01:21:04 +00:00
Carlos Garnacho
104d1ae151 windowManager: Fix shutdown signal connection
This signal relied on mutter changes that were withdrawn
and it was unintended to use here. Restore the usage of
good old MetaDisplay::x11-display-closing.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1056
2020-02-29 23:47:46 +01:00
Carlos Garnacho
12e14884ef windowManager: Implement MetaDisplay::init-xserver hook
We do spawn gsd-xsettings, and watch its name before notifying on the
given task, so the mutter bits can proceed with X11 startup.

One notable change is that we only start gsd-xsettings, instead of the
generic gnome-session-x11-services target. We do so as we have to wait
on a dbus name to appear in order to deem the initialization done, and
making it all depend on gsd-xsettings seems tidier.

Less notably, we also use ::shutdown-xserver to shutdown the related
services. Its major benefit is that it'd allow us to ensure the olderly
shutdown of those services, but it's unused at the moment.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/836
2020-02-29 18:58:55 +01:00
Carlos Garnacho
3c4a5a67e2 ibusManager: Use setup X11 display for ibus-x11
(re)spawning ibus to get ibus-x11 will be part atm of Xwayland
initialization process. For it to be set up before the client
it needs using the GNOME_SETUP_DISPLAY.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/836
2020-02-29 18:58:47 +01:00
Daniel van Vugt
bd197789c1 js/ui: Subscribe touchpad gesture handlers to only touchpad events
The touchpad gesture handlers were receiving all events, all the time.
This meant that even mouse movements were getting translated into
JavaScript calls and then discarded by the handlers, which wasted CPU.

Now we subscribe the touchpad gesture handlers to only touchpad events.

Prequisite: https://gitlab.gnome.org/GNOME/mutter/merge_requests/1000

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/283

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/925
2020-02-29 13:39:17 +00:00
Jonas Dreßler
da05c85f3c windowManager: Show window resizing clone on "size-changed"
When a window is being resized by the compositor, with Wayland the
compositor first asks the window to change its size and emits the
"size-change" signal, and then emits the "size-changed" signal after
the window acknowledges the new size. To show a fancy resize animation,
gnome-shell creates a "screenshot" of the resizing window on the
"size-change" signal, and later animates that "screenshot" to the new
window size on the "size-changed" signal.

Now if a client is not responding to our requests asking it to change
its size, we get a "size-change" signal and start showing the
window-clone, but never a "size-changed" signal, animating and hiding
the clone again. This causes a so called "ghost window" that is shown
above everything else and never disappears again.

To fix that, start showing the window clone once we get the
"size-changed" signal instead of the "size-change" signal. This makes
sure the window actually updates its size and the clone is going to be
hidden again.

Fixes https://gitlab.gnome.org/GNOME/mutter/issues/1078

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1055
2020-02-28 18:08:24 +00:00
Florian Müllner
06b690ff21 environment: reduce calls to g_time_zone_new_local()
Creating a new GTimeZone for the local timezone can be quite expensive if
done repeatedly. It requires an open(), mmap(), and parsing of
/etc/localtime.

This patch was provided by Florian, and I've tested it as far back as
3.28.4 to ensure that we are really reducing the number of open() calls
on the compositor thread.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1051

Signed-off-by: Christian Hergert <chergert@redhat.com>
2020-02-27 13:48:26 -08:00
Jonas Dreßler
51b7eb7a2b altTab: Don't fade out thumbnails on destroy
The thumbnails actor `this._thumbnails` has already been destroyed when
calling `_destroyThumbnails()` from the `destroy` signal handler because
it is a child actor of the AppSwitcherPopup. So stop destroying the
thumbnails separately (fading them out inside a destroy handler wouldn't
make sense anyway).

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167
2020-02-26 22:46:51 +00:00
Jonas Dreßler
023859ee4b switcherPopup: Use correct scroll-direction property
The correct property for the scroll-direction with scrolling events is
`direction`, no `scroll_direction`. This fixes scrolling in the alt-tab
popup, which broke with the actorization changes.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167
2020-02-26 22:46:51 +00:00
Jonas Dreßler
09acd0a3db switcherPopup: Always return true when the popup finished early
When the switcherPopup was initiated successfully, we return true,
otherwise the WindowManager will try to destroy it. Since an early
release of the keystroke will also switch to another application and
close the switcher just fine, we should return true to indicate success
here.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167
2020-02-26 22:46:51 +00:00
Jonas Dreßler
bf213af362 switcherPopup: Lookup index of items when hovering or clicking
Right now the index that gets selected on click and motion events is set
when connecting the event inside the addItem function. If items are
added or removed (for example when an application is closed by pressing
"q"), this index isn't valid anymore and has to be updated.

To fix this, use the items themselves instead of the index as arguments
for the event handlers and lookup the index of the item inside the event
handler.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167
2020-02-26 22:46:51 +00:00
Jonas Dreßler
bfb0bc7a29 switcherPopup: Implement functions to add and remove accessible states
Set the accessible states of the switcherList items by calling a
function instead of manipulating class-internal variables from outside
the class, which is considered bad practice.

The check whether the item at `_selectedIndex` exists can also be
removed since we always select a new index after an item was removed
(i.e. an app was closed) and destroy the alt-tab switcher right away if
no more items exist (see `SwitcherPopup._itemRemovedHandler`).

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167
2020-02-26 22:46:51 +00:00
Jonas Dreßler
c00f1d040b switcherPopup: Select correct item after removal of item
If an item was removed, make sure the selected item is still selected or
select the last one if the selected item was removed.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167
2020-02-26 22:46:51 +00:00
Jonas Dreßler
ba7cfff90c switcherPopup: Disable hover on scrolling events
Just like with keyboard events, disable hover on scrolling events. Mouse
movements should not mess up the selection while scrolling.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167
2020-02-26 22:46:51 +00:00
Jonas Dreßler
548c41d164 switcherPopup: Swap Math.max and Math.min in _scrollToLeft
Limit the minimum and maximum value to scroll to inside the box to 0 and
the upper limit, for some reason this was done right in _scrollToRight,
but not in _scrollToLeft.

This fixes the behavior of scrolling to the left: Before, scrolling one
item to the left moved the view to the first element of the list (this
can make the selected element invisible in large lists). Instead, scroll
one item to the left, just like scrolling to the right works.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167
2020-02-26 22:46:51 +00:00
Jonas Dreßler
172d21cf50 switcherPopup: Use local variable for index in scrolling functions
Make sure the index that's being scrolled to doesn't change while the
scrolling animation is running by using an argument instead of the
this._highlighed class scope variable.

This fixes wrongly shown arrows when selecting new elements faster than
the scrolling animation takes for one index. The check run to disable
the arrow might be checking against a newer index than the one at the
start of the animation which results in the arrow not getting hidden
even if no more scrolling is possible.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167
2020-02-26 22:46:51 +00:00
Jonas Dreßler
5c8f3a65f7 switcherPopup: Use this._highlighted to check for reentrancy
Since this._highlighted is always set to the currently highlighted
index, there's no need to save the index to a separate variable. This
obviously depends on getting the new item highlighted as a result of the
item-entered event.

This fixes bugs in situations where the highlighted element changes
after an event that is not calling _onItemEnter, for example after
scrolling or pressing a key. In those cases the _currentItemEntered
variable wouldn't be updated and the old item couldn't be entered
anymore without entering another one before.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167
2020-02-26 22:46:51 +00:00
Florian Müllner
19fc7c4d31 loginDialog: Do not expand "Not listed" button
Visually the button is just an interactive label, so having the
interactive area extend to the empty space next to the label
is surprising.

Instead, left-align the whole button rather than just the label
inside, so the clickable area corresponds to the visible one.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1046
2020-02-26 19:46:50 +00:00
Florian Müllner
d66f5ab3c6 mpris: Disallow media section on login screen
The 'gdm' user is not going to run a media player, so there is no
point in allowing the corresponding section on the login screen.

All other sections are already disabled, so this is the only reason why
we end up with the message list instead of only showing the calendar.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2241
2020-02-26 17:45:33 +00:00
Daniel van Vugt
c773c8c162 Revert "js/ui: Use Clutter.OffscreenRedirect.ON_IDLE"
This reverts commit c0c027c608. Because for
some reason animating external opacity and position is still incurring
internal repaints, which disables offscreening and makes fading of
overlapping actors look wrong. `ON_IDLE` should be fixed in mutter before
it is used (in boxpointer at least) again.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/2270
2020-02-26 11:54:54 +08:00
Jonas Dreßler
b3999e4078 overview: Hide the overview on session mode hasOverview changes
If the sessionMode does not allow to show the overview, we should also
hide an already visible overview.

This fixes a bug where, if the lockscreen was shown while the overview
was visible, the Ctrl+Alt+Tab popup would allow navigating inside the
overview because the overview actor is still mapped.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1043
2020-02-25 20:10:22 +01:00
Philippe Troin
d0a587d42f panel: Only consider St.Widgets for corner buttons
We cannot syncronize styles with plain Clutter.Actors, so don't return
them when looking for corner buttons.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1047
2020-02-25 18:32:30 +00:00
Florian Müllner
2bb8e1be9b environment: Handle reversed transition with 0 duration
If a transition is reversed, the final property values will be the
same as before the transition. However this currently only works
correctly when we actually use a transition; to fix this with a
duration of 0, simply skip the set() call when the transition is
reversed.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1042
2020-02-25 18:08:47 +00:00
Jonas Dreßler
4c4d23ed83 dateMenu: Sync initial state of the message indicator
While the unread messages indicator is updated when starting a new
session because we call _onSourceAdded() on existing sources, we should
also update the do-not-disturb setting which might still be enabled.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1037
2020-02-25 16:47:29 +01:00
Jonas Dreßler
7173ec1df7 dateMenu: Remove an unnecessary change for RTL layouts
Calculating 1 - 0.5 is rather useless if the value was 0.5 before...

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1037
2020-02-25 16:47:24 +01:00
Jonas Dreßler
bc465ab006 theme: Hide panel underline under the do not disturb icon
Hide the focused/active indicator of the panel underneath the
do-not-disturb icon.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1037
2020-02-25 16:47:17 +01:00
Florian Müllner
d62391c8f1 unlockDialog: Set accessible name of icon-only buttons
We turned both the auth prompt's cancel button and the switch user
button into icon buttons now, which means they are completely cryptic
when using a screen reader.

Just use the previously used labels as accessible names, which has the
nice side effect of lowering the impact of the string freeze break.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2210
2020-02-24 12:29:44 +00:00
Florian Müllner
ab24ee7a7e authPrompt: Don't focus hidden cancelButton
The button is hidden on the lock screen, so it shouldn't be allowed to
activate it, be it via click or keyboard. The latter is still possible
by keynaving to the button and hitting space/enter. Fix that by making
the button unfocusable when we make it unreactive.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2210
2020-02-24 12:29:44 +00:00
Florian Müllner
c52fd9373c unlockDialog: Turn mainBox into an St.Widget
This is the container that contains the elements that are interesting
for keynav, so it must be aware of focus-chain and -navigation.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2210
2020-02-24 12:29:44 +00:00
Florian Müllner
1249655d0a unlockDialog: Don't make dialog focusable
There is little point in focusing the dialog itself, we want keynav
to navigate inside instead and navigate between focusable children.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2210
2020-02-24 12:29:44 +00:00
Jonas Dreßler
3848513cf4 magnifier: Use inhibit-unfocus API to keep wayland focus while hidden
Since commit mutter/a2a8f0cda we force the focus surface of the
meta-wayland-pointer to NULL while the pointer is hidden. This
introduced an issue with the magnifier, where we use
`set_pointer_visible` to hide the real cursor and show our own cursor at
the correct position: Because the meta-wayland-pointer is still used to
communicate with Wayland clients, the UI of the windows will not respond
to mouse movement anymore as soon as the real cursor is hidden.

To fix this, use the newly added clutter_seat_inhibit_unfocus() API to
temporarily disable unsetting the focus-surface while the magnifier is
hiding the system cursor.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/993
2020-02-24 10:31:08 +00:00
Jonas Dreßler
725c72e020 magnifier: Use own showSystemCursor() instead of set_pointer_visible()
We already have our own function to show the system cursor, use it!

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/993
2020-02-24 10:31:08 +00:00
Florian Müllner
3633e1feca shellEntry: Restore natural-height-set instead of forcing it
If we are transitioning the label from 0 to its natural height, we
must set natural-height-set again after querying the preferred height,
otherwise Clutter would skip the transition.

However when transitioning in the opposite direction, setting the
property to true can go horribly wrong:
If the actor hasn't been allocated before, it will store a fixed
natural height of 0. But as there is no fixed min-height, we can
end up with min-height > natural-height, which is a fatal error.

(This isn't an issue when *actually* setting a fixed height, as
that will set both natural and minimum height)

So instead of always setting natural-height-set to true, restore
its previous value to fix the issue.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2255
2020-02-22 16:58:01 +00:00
Florian Müllner
4759197200 util: Don't wiggle when animations are disabled
repeatCount and autoReverse don't play well with animations disabled:
They cause password entries to wiggle themselves off-screen (by ending
up with some off-scale translation-x value).

While we should handle this more gracefully in the transition helpers,
it also makes sense to handle the case directly in wiggle(): As it
uses a chain of three transitions, we would still end up with a crude
one-frame-per-transition wiggle "animation".

Instead, do no animation at all as you would expect when animations are
disabled.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2236
2020-02-22 16:38:43 +00:00
Jonas Dreßler
255627bd69 layout: Show and hide keyboard using translation_y
ClutterActors anchor-y property is deprecated, which means we get a
warning when animating it, so use the translation property instead to
show or hide the osk.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1039
2020-02-21 12:59:21 +00:00
Florian Müllner
0afac36713 unlockDialog: Use "normal" background
Now that we apply a strong blur effect to the background, it doesn't
make too much sense to use a separate lock-screen background: It will
be mostly unrecognizable anyway.

The alternative would be to turn off the blur effect if a different
background is used (or have a hidden setting for that), but that would
then imply that we must keep the contents readable without blur.

Let's avoid that rabbit hole and just re-use the regular background.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1001
2020-02-21 12:34:37 +00:00
Daniel van Vugt
c0c027c608 js/ui: Use Clutter.OffscreenRedirect.ON_IDLE
To bypass offscreening in cases where continuous animation is happening.
Offscreening is slower in such cases so this reduces the render time of
animations within offscreenable actors.

On an i7-7700 this reduces the render time of boxpointers for example by
25-30%.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1025
2020-02-21 12:19:15 +00:00
Jonas Ådahl
32fa060a62 closeDialog: Make dialog inactive while fading out
Otherwise the user might click Kill, which would crash if the fade-out
was triggered because a Wayland window was closed.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1032
2020-02-21 08:11:57 +00:00
Daniel van Vugt
38da479ee8 slider: Calculate handle position in whole pixel units
`-slider-handle-radius` is a floating point value and even in the default
theme it's not a whole number. Regardless of the fractional part that's
still going to occupy a whole extra pixel with antialiasing. So make room
for it. Otherwise it looks clipped, which it is by the Cairo context of
its `StDrawingArea`.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/1569
2020-02-21 11:29:09 +08:00
Florian Müllner
ee6635282c status/keyboard: Check for monkey-patched property before using it
This avoid another "reference to undefined property" warning.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1035
2020-02-20 19:08:47 +00:00
Florian Müllner
ff39b3274b authPrompt: Initialize property in _init()
This avoid a "reference to undefined property" warning when using
it in a comparison.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1035
2020-02-20 19:08:47 +00:00
Carlos Garnacho
57669bca1b keyboard: Specify symbolic icons to use in default keys
The style classes are not removed yet, might make sense to do that
if they don't bring anything wrt theming.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2214
2020-02-20 11:34:07 +00:00
Carlos Garnacho
5171bdd45f keyboard: Add support for setting OSK keys with icons
Unused at the moment, but add the plumbing so that default key
definitions may specify symbolic icons that will be shown instead
of the text.

This is intended to replace the use of CSS and background-image
to handle those buttons with an icon.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2214
2020-02-20 11:34:07 +00:00
Jonas Ådahl
9ab0071aa5 introspect: Add AnimationsEnabled property
While the gsetting is available for all who needs it, the Shell might
override it given various hueristics. Expose the decision made by the
Shell via a new property.

Intended to be used by gsd-xsettings as well as xdg-desktop-portal-gtk.

This also add a version property to the API, so that semi external
services (xdg-desktop-portal-gtk) can detect what API is expected to be
present.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/757
2020-02-20 11:14:55 +00:00
Jonas Ådahl
cf39b2db87 introspect: Rename variable
It was too generic, and would conflict with a StSettings variable.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/757
2020-02-20 11:14:55 +00:00
Jonas Ådahl
8a1c0f3a42 main: Inhibit animations when there is a remote desktop session
If a remote desktop session asks for animations to be disabled, inhibit
animations while the session is active.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/757
2020-02-20 11:14:55 +00:00
Jonas Ådahl
4b42879a2c main: Inhibit animations if X server advertises VNC-EXTENSION
This was previously done by gsd-xsettings to disable animations when
running in Xvnc.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/757
2020-02-20 11:14:55 +00:00
Jonas Ådahl
394121f77d main: Inhibit animations when software rendered
This was previously decided by gsd-xsettings.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/757
2020-02-20 11:14:55 +00:00
Jonas Ådahl
059fb5c7cb introspect: Add helper to check method call permission
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/757
2020-02-20 11:14:55 +00:00
Florian Müllner
affbec73ef extensionPrefs: Fix more fallout from un-templating strings
The version field in extension metadata is a number, so we cannot
just use it as a string.

('creator' should be fine, but change it as well for the symmetry)

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1031
2020-02-19 19:29:21 +01:00
Daniel van Vugt
e781e1fdba iconGrid: Create icon clones in a separate loop
For reasons not yet fully understood, `Main.uiGroup.add_actor` takes around
10 milliseconds to complete.

Because of this, each `actor.opacity = 0` has a good chance of falling
on a different frame. And when it does, `_opacityChangedId` also lands
on multiple different frames each incurring a separate relayout cycle.
It is this excessive number of relayouts that causes stuttering in the
icon grid animation (#2065). But it is the slowness of `uiGroup.add_actor`
that causes the number to be excessive when it should be one.

By creating the clones and adding them to `uiGroup` early, we then enable
the existing loop starting the animation to complete within a single frame.
And by completing within a single frame all the opacity changes land within
the same frame interval, thus incurring only a single relayout instead of
many.

This issue went unnoticed until 004a5e1042 (!704), after which the slow
emissions of `notify::opacity` became a more visible performance problem.

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

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1002
2020-02-19 15:39:21 +00:00
Florian Müllner
6e7344b837 dateMenu: Use BindConstraint for indicator pad
Now that Clutter.BindConstraint modifies the size request in addition to
the allocation, we can use it instead of the custom IndicatorPad widget.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1026
2020-02-19 12:44:28 +00:00
Georges Basile Stavracas Neto
b8f8e1710b appDisplay: Remove unnecessary bind constraint
Now that the bind constraint changes the preferred size of
the actor, a major flaw in the AppDisplay code was exposed:
the folder dialog depends on the preferred size of a parent,
and the parent depends on the preferred size of the folder
dialog.

While we know this is not actually true, we shouldn't rely
on broken behavior to achieve this result. What's interesting
is that the bind constraint used by the folder dialog is a
relic of the development phase; we now control the position
and size of the dialog with a combination of CSS, and alignment.

Remove the unnecessary bind constraint.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1027
2020-02-19 09:20:05 -03:00
Jonas Dreßler
8b0a67fe64 dateMenu: Hide overlay scrollbar in the notification popup
Since the design of the notification popup changed with the theme
refactor and there are now boxes around the world-clock and weather
sections, the overlay scrollbar that is shown above them looks rather
bad. So simply hide that scrollbar, we still have the vfade effect to
indicate the container is scrollable and we also depend on that in the
new popup app-folders.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1013
2020-02-19 11:47:04 +00:00
Jonas Dreßler
26a49168ba lookingGlass: Also handle null objects in objectToString
Whoops, while ff4623454 fixed the handling of `undefined` objects,
`null` objects obviously still don't have a toString() method. So also
handle those and return 'null' in case the object is null.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1024
2020-02-19 11:56:36 +01:00
Florian Müllner
ff4623454f lookingGlass: Handle undefined in objectToString()
Fallout from commit 9d941f8202: Template strings handle undefined
values just fine, the replacement does not. Fix that.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1020
2020-02-19 11:17:17 +01:00
Jonas Dreßler
cf5204760d workspace: Ensure style of window-chrome titles before requesting width
Make sure the stylesheet properties of the window-chrome title are
updated before requesting the preferred width of the title to prevent
size changes of the title after we animated the width.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/58
2020-02-19 10:09:20 +00:00
Jonas Dreßler
2a3875775d userWidget: Always set actor size inside update()
We also want to ensure the Avatar StBin is sized correctly when an icon
child is used, so always set the actor size inside the `update()`
function.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1018
2020-02-18 22:10:00 +00:00
Jonas Dreßler
38b38732d3 userWidget: Simplify icon size setting a bit
Remove the default icon size of -1 and always set the container StBin to
a real size. This fixes an error where the "width" and "height"
properties get set to -2 (which is -1 * scaleFactor) in the `_init`
function.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1018
2020-02-18 22:10:00 +00:00
Florian Müllner
24c8f5bb70 authPrompt: Fix cancel button visibility
Grrr, this slipped in in 5cad5c20e9, and we don't have a compiler
to catch those kinds of bugs :-(

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2228
2020-02-18 21:34:16 +00:00
Jonas Dreßler
45bc8ae292 keyboard: Plug a leak of KeyboardControllers
To make sure the GC really disposes the KeyboardController object we
need to remove all references to the object, which means we have to
disconnect signals the object connects to, too.

This also fixes a bug where keys remain pressed forever and thus also
break that key on real keyboards. It happens if the OSK gets destroyed
during an OSK-key is being held so the StButton of the key is not
released. That means the key remains pressed in the
MetaVirtualInputDevice that we are now leaking because
KeyboardController isn't garbage collected.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1015
2020-02-18 14:48:39 +00:00
Florian Müllner
9d941f8202 js: Don't use templates in files with translations
xgettext gained some support for template strings, and no longer
fails when encountering '/' somewhere between backticks.

Unfortunately its support is still buggy as hell, and it is now
silently dropping translatable strings, yay. I hate making the
code worse, but until xgettext really gets its shit together,
the only viable way forward seems to be to not use template
strings in any files listed in POTFILES.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1014
2020-02-17 23:20:40 +01:00
Jonas Dreßler
80a869e768 dialogs: Use a smaller font-size if the title width exceeds the space
Since quite a few strings of dialogs provided by external programs are
not updated yet and the string freeze is already in effect, make sure we
don't break those dialogs by stripping aways large parts of the
headline.

To do that, detect if the title label is larger than the available width
and if it is, switch to a smaller font-size of 13pt. This makes sure we
still show about the same number of characters in the headline as we did
in previous releases.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1012
2020-02-17 21:42:05 +00:00
Florian Müllner
6f12864776 screenShield: Always deactivate when interrupting idle before lock
With the old screen shield, we were simply hiding the lightboxes to show
the shield when the user became active after activating the shield but
before locking the screen (that is, when using a lock-delay).

However now that the shield is gone, we end up showing the unlock dialog
even though we are not actually locked.

We probably don't want to add back a shield-like mode (that is, a way to
raise the unlock dialog without authentication when we aren't locked),
so just deactivate the whole shield when the user becomes active again
before the lock kicks in.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2213
2020-02-17 11:13:34 +00:00
Florian Müllner
5934dc16d3 screenShield: Reset correct translation
When showing the lock dialog without animation, we currently reset the
translation of the wrong actor, leaving the unlock dialog off-screen.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2213
2020-02-17 11:13:34 +00:00
Jonas Dreßler
bcc652632d authPrompt: Use the same hint text as the polkitDialog for the password
Be consistent and show the hint for the password entry that we already
show in the polkitDialog in the auth dialog.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/977
2020-02-17 11:03:07 +00:00
Jonas Dreßler
95ebbb9360 Update hint texts of all entries
The design team discussed the ellipses at the end of the hint text of
our entries and, even though they are present in most mockups, it turned
out they don't like them, so remove them.

It also turned out they don't like the prefixes like "Enter" before it,
so remove those, too.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/977
2020-02-17 11:03:07 +00:00
Jonas Dreßler
775c3345eb networkAgent: Update dialog entry descriptions for new design
With the new dialog design the descriptions of entries are now
implemented as hint-text of the StEntry. That means the colon at the end
of the descriptions no longer makes sense and should be removed.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/977
2020-02-17 11:03:07 +00:00
Florian Müllner
9c7098816e popupMenu: Remove excess padding from separators
Currently separators get all the padding from regular menu items,
which is excessive for non-interactive elements.

Shuffle style classes around a bit to allow overriding the normal
padding for separators.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1004
2020-02-15 00:16:45 +00:00
Florian Müllner
8834088f3b unlock: Don't show prompt on shifty key presses
Shift, caps-lock and friends change the capitalization of following
key presses. It is unexpected for those keys to have side-effects,
so don't switch to the prompt when they are pressed.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2215
2020-02-14 21:57:03 +01:00
Florian Müllner
0d766dcf70 authPrompt: Use placeholder label to avoid layout changes
We don't want to show a caps-lock warning when showing a non-password
entry, but we also don't want the layout to jump when changing the
label's visibility.

Achieve that by inserting an empty placeholder label that we can
show whenever the caps-lock warning is hidden.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2215
2020-02-14 21:57:03 +01:00
Florian Müllner
41da4b0681 Revert "authPrompt: Don't hide the caps lock warning label"
Using the opacity to control the label's visibility doesn't work
correctly, as CapsLockWarning itself changes the opacity when
the caps-lock state changes.

This reverts commit 9f5f6aa9b2.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2215
2020-02-14 21:57:03 +01:00
Georges Basile Stavracas Neto
5cad5c20e9 authPrompt: Hide cancel button on unlock screen
As per the latest design review, hide the cancel button
on the unlock dialog.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1006
2020-02-14 20:49:57 +00:00
Georges Basile Stavracas Neto
133b623204 unlockDialog: Iconize the switch user button
Make it look exactly the same as the login screen's session
selection button.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1006
2020-02-14 20:49:57 +00:00
Georges Basile Stavracas Neto
d44a4a6a62 unlockDialog: Move switch user to the main dialog
Right now, it's still a label displayed following the same
layout algorithm of the cog button in the login screen. It'll
become a button later in the patchset.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1006
2020-02-14 20:49:57 +00:00
Georges Basile Stavracas Neto
06565542e7 Revert "unlockDialog: Remove 'Login as another user' Label"
This reverts commit c6a79fafc. The back button doesn't really work
as a replacement for going back to the login screen.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1006
2020-02-14 20:49:57 +00:00
Florian Müllner
41b4c51341 unlockDialog: Don't explicitly show prompt
The promptBox is initially fully opaque, so showing it before the
transition can result in a brief flash before fading in.

Just remove the show() call and let the transition handle the
visibility.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2212
2020-02-14 14:56:25 +01:00
Georges Basile Stavracas Neto
7e27a2db3d authPrompt: Keep password entry on reset
Usually, logging in or unlocking the session is made asynchronously,
and AuthPrompt properly manages which entry is currently visible.
External code don't rely on any specific entry to be set, since it
is AuthPrompt's responsibility to select the correct one to be shown.

However, there's one specific case where AuthPrompt must preserve
the password entry: on reset. The reset code preserved whatever
entry was currently displayed, but after fe69dacaf1, it always
changes to the username entry.

Make sure to show the password entry on reset.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/999
2020-02-13 18:11:16 -03:00
Georges Basile Stavracas Neto
523eec521c unlockDialog: Only create GDM client once
We don't need to create a new one every time we create an
auth prompt.

Create only one GDM client.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/999
2020-02-13 18:11:09 -03:00
Georges Basile Stavracas Neto
77890c6000 loginDialog: Hide session menu button when showing the user list
In the past, the session menu button was part of the auth prompt widgetry,
so we didn't have to manually hide it when showing the user list. However,
now it is part of the login screen itself.

Hide the session menu button when the user list is shown.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/999
2020-02-13 18:11:05 -03:00
Florian Müllner
ccc64e2621 unlockDialog: Only show count for multiple notifications
In the common case where we only have a single unread notification
from a particular app, the count doesn't add useful information.
Reduce clutter a bit by only showing the notification count if we
have at least two.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/997
2020-02-13 20:55:33 +01:00
Florian Müllner
e57768e2e8 unlockDialog: Show unlock hint on inactivity
Inactivity on the unlock screen can be an indication that the user
doesn't know how to get to the auth prompt. Fade in a small hint
that points them in the right direction.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/972
2020-02-13 15:01:25 +00:00
Florian Müllner
d43401cc74 unlockDialog: Support clock/prompt switching via scrolling
SwipeTracker "only" handles touch gestures and smooth scrolling.
Scrolling still makes sense for regular mice as well though, so
add handling for that as well.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/972
2020-02-13 15:01:25 +00:00
Florian Müllner
9e5071849c unlockDialog: Add swipe gesture
Clicking or typing to reveal the auth prompt are good options for
mouse/keyboard workflows, but awkward on touch devices. Now that
we have SwipeTracker, adding corresponding gestures support is
easy, so do just that.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/972
2020-02-13 15:01:25 +00:00
Florian Müllner
55bfc4d820 unlockDialog: Use adjustment to control the transition
Tying the transition parameters to a single progress value represented
by an adjustment will enable us to implement stick-to-content swipe
gestures.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/972
2020-02-13 15:01:25 +00:00
Florian Müllner
6577a295da unlockDialog: Tweak transition animation
The current transition between clock and auth prompt uses a simple
crossfade.

"What kind of spatial model is that?!"
                                  T.B.

Root the transition a bit more by adding translation and scale to
the animation.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/972
2020-02-13 15:01:25 +00:00
Georges Basile Stavracas Neto
9f5f6aa9b2 authPrompt: Don't hide the caps lock warning label
Hiding the Caps lock warning label changes the layout of
Auth Prompt. This is specially noticeable when logging in
with unlisted users, where we change the visibility of this
label after typing a username, and the whole user widget
moves a bit.

Change the Cap lock label's opacity instead of hiding it.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
261d6d35f5 userWidget: Add empty label when user is null
Currently, when a null user is passed, we don't add any
username label. That makes the layout of user and no-user
cases inconsistent.

Add a ghost label with no opacity to mimic the username
label.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
0f34cbb658 authPrompt: Only spin on password entries
Spinning while typing the password is a bit off-putting, and
inconsistent with how regular authentication behaves.

Only spin the spinner after typing the password.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
077a1d2309 authPrompt: Refactor 'next' signal
Currently, AuthPrompt is connecting to its own 'next' signal
signal to react to any of the entries being activated, and do
some actions like starting the spinner and answering the PAM
question.

Refactor this code into another method, and don't connect to
our own signal.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
66835c6e15 authPrompt: Remove colons from questions
Unfortunately, the question that is displayed comes directly
from PAM. It usually is just "Password:", which comes from
pam-unix, but other questions can be set, usually with the
colons, since they are crafted with a CLI workflow in mind.

Manually drop the colons from questions asked by PAM. This
is also done by the PolKit agent, which shows how the stack
is fragile, but it's what we have for now.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
99e81b32f4 authPrompt: Keep buttonWell and cancel button sizes in sync
So that the entry is horizontally centralized at all times.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
fe69dacaf1 loginDialog: Use text entry for username
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
6daeb048af authPrompt: Connect signals to both text and password entries
This is a regression from the transition to password entry. Both
entries need to be connected to the relevant signals, otherwise
username-based login won't ever work.

Connect both the text and the password entries.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
db4dfd8fa5 authPrompt: Trivial style cleanup
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
0b150a17c5 loginDialog: Replace colon by ellipsis on username question
So it plays better as a hint text.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
43a45c091d authPrompt: Use entry to show question texts
Currently, there is a dedicated label above the entry to
display the question text. According to the new mockups
for the lock screen, this label doesn't exist; instead,
the question is set inside the entry itself, as a hint
text.

Set the questions as hint texts of the entry, and remove
the now unused label.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
cc5adcbeef loginDialog: Center align Caps Lock and authentication messages
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Georges Basile Stavracas Neto
848cc1bb19 loginDialog: Set null user when asking for username
When going through the username + password login flow, set
the username to 'null' to update the user avatar.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Umang Jain
654093dc40 userWidget: Adapt if user is not mentioned for username login
If username-based login flow is followed, we need a default avatar
for the userWidget. Hence, check if the user passed to userWidget
is (null) which implies a username-based login flow.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Umang Jain
aebea82474 loginDialog: Move and relayout sessionMenuButton to bottom right
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Umang Jain
a6b29d6501 loginDialog: Apply CSS to sessionMenuButton according to mockups
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Umang Jain
c6a79fafc9 unlockDialog: Remove 'Login as another user' Label
According to the new mockups, logging in as another user
should be handled by the (<) button present on the lock-screen.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Umang Jain
7fc4fe9a97 authPrompt: Iconize the cancel button
Replace the "Cancel" label in the cancel button
by an arrow icon, and adjust the theme to make
it circular.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Umang Jain
ee0a36e6a3 authPrompt: Move cancel button, entry and spinner to a single row
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Umang Jain
a5972d2882 authPrompt: Remove Next button and its references
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Umang Jain
2fdc627257 userWidget: Allow vertical orientation for user avatars
Allow vertical orientation for the userWidget so that the user-avatar
can be centered and user's name can be placed below it. The plan
for 3.36 is to use this vertical userWidget layout for both lock
and login screen.

The userWidget is also used while creating the user-selection list
at the login, hence we still need to keep the horizontal layout
for userWidget in place.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/922
2020-02-12 19:29:48 +00:00
Jonas Dreßler
e1be4ba434 unlockDialog: Multiply blur sigma value with the scale factor
Since the blur sigma decides how many pixels get factored in when
blurring and setting a scale factor increases the background texture by
that factor, the sigma value should also be multiplied by the scale
factor.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/991
2020-02-12 11:11:03 -03:00
Jonas Dreßler
f351cfa2f7 blur-effect: Use sigma value instead of blur radius
Almost all implementations, including CSS [1] of gaussian blurs use the
sigma/standard deviation value as the input parameter, even if they call
that value "radius". Since using sigma is more correct mathematically
and avoids confusion for people used to other blur implementations, use
that parameter here, too.

[1] https://www.w3.org/TR/filter-effects-1/#funcdef-filter-blur

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/991
2020-02-12 11:10:38 -03:00
Georges Basile Stavracas Neto
dee738e24f background: Remove noise texture
Use the plain background color.

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

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
84c7890917 screenShield: Remove lock screen group from Crtl-Alt-Tab manager
There is nothing else to be focused in the lock screen itself -- the
top bar is already handled elsewhere, and the dialog manages itself
now.

Remove the lock screen group from the Ctrl-Alt-Tab manager.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
fd484099ae screenShield: Cleanup _ensureUnlockDialog
Just like on ScreenShield.activate(), we can just ensure the
unlock screen on ScreenShield.showDialog().

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
727c84251d screenShield: Rework key focus management
Instead of always grabbing key focus for the screen lock
group, do that for the unlock dialog itself.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
37e55df298 unlockDialog: Create auth prompt on demand
AuthPrompt is the set of actors that contain the user avatar,
the username, and the password entry. With the removal of the
screen shield, the unlock dialog (be it UnlockDialog or the
LoginDialog) is always created, and in the case of UnlockDialog,
so is the auth prompt.

This is problematic, though, since for passwordless accounts,
the simple act of creating AuthPrompt authenticates the user,
and lifts the lock screen.

Create the AuthPrompt on demand in UnlockDialog.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
2644f62318 unlockDialog: Add .critical CSS class to critical notifications
As per the latest lock screen mockups, critical notifications must have
a more prominent, solid color.

Add a .critical style class to critical notification bubbles, and make
them darker.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
893bde0ca1 theme: Adjust style of lock screen notifications
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
bd0bf3d3d0 unlockDialog: Line notification labels horizontally
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
05c918dc1a unlockDialog: Use just the counter to format notifications
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
3651cb2047 unlockDialog: Show clock when canceling or failing auth
There is still a problem of focus not going to the entry after the
first cancel, but it seems to work fine otherwise.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
b9c7631a55 unlockDialog: Toggle between clock and auth prompt
Toggle between them when (1) tapping anythere on the screen, and
(2) pressing any key.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
b59c9c6946 unlockDialog: Move auth prompt and clock to a ShellStack
We will toggle between each other in the next commit, so add
both to a ShellStack.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
f02313c1c6 screenShield: Remove key press event handler
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
6493789bc9 unlockDialog: Introduce UnlockDialogLayout
This is the layout manager responsible for ensuring
that the clock is always at the third of the screen
height, and the notifications can push it to above.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
c20451c2e7 sessionMode: Remove lock-screen mode
Now that the screen shield is gone (at least, as it used to
be), the corresponding session mode is not necessary anymore
as well.

Remove the 'lock-screen' session mode, and the corresponding
CSS.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
16dcb1ac15 screenShield: Move lock shield below dialog
Pretty much what the commit title says.

This gives the lock shield actor another role: instead of
being the interactive screen shield, make it the invisible
actor that prevents interacting with windows while the
unlock dialog is sliding down.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
c1ee656c35 screenShield: Only animate the unlock dialog
Remove the slide-up-down animation from the lock shield.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
cd09144069 screenShield: Rename _liftShield to _activateDialog
Lifting the shield is now what happens *after* successfully logging
in, not before. Now, what we do is activate the dialog before logging
in.

Rename the method to reflect that.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
7851069d9c screenShield: Activate dialog when necessary
Activating a dialog is slightly different from opening it; the
former is about showing the user authentication widgetry, while
the latter is about creating it and pre-allocating the necessary
resources.

Activate the screen shield dialog when necessary.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
e42700a308 screenShield: Lift the unlock dialog
Instead of scaling it, lift the unlock dialog when unlocking,
and vice-versa.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
febc0690c1 screenShield: Remove scrolling
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
308b4f81b5 screenShield: Cleanup unused method arguments
The 'velocity' argument is not used anymore, since the only
caller passing a different value than 0 was the drag motion
callback.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
66a3ad42da screenShield: Remove the drag action from the shield
This is start of the end of the screen shield; start by
removing the dragging action from it.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
1b84a3ecb2 unlockDialog: Don't destroy on cancel
Otherwise there will be no way to recover it in the future. Also
remove an else condition that assumed the dialog would destroy
itself on cancel.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
78fd9d9e4f screenShield: Always show session's unlock dialog
Instead of destroying the dialog when the screen shield is
visible, and creating it when lifting the shield, always show
the session's unlock dialog.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
baa5bfcf49 screenShield: Remove _lockScreenContents and family
It is not used anymore, and together with it, we don't need the
_ensureLockScreen() / _clearLockScreen() pair anymore too.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:52 +00:00
Georges Basile Stavracas Neto
5d88729fc1 unlockDialog: Blur background
Add a 200px blur with a 55% brightness to the unlock dialog
background.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:51 +00:00
Georges Basile Stavracas Neto
15b59414d6 screenShield: Move background to Unlock Dialog
In addition to that, remove the ClutterBoxLayout that is set as
the layout manager of the Unlock Dialog, and apply the primary
monitor constraint to the child St.BoxLayout instead.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:51 +00:00
Georges Basile Stavracas Neto
2b39d6e95a screenShield: Remove unused 'onPrimary' argument
The 'onPrimary' argument was being passed to dialog.open(). Turns out,
neither UnlockDialog nor LoginDialog use this parameter.

Remove the unnecessary 'onPrimary' parameter, and cleanup the related
code.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:51 +00:00
Georges Basile Stavracas Neto
73eaf0df9f screenShield: Move notifications to Unlock Dialog
Also adjust the CSS style classes names to match the new owner.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:51 +00:00
Georges Basile Stavracas Neto
54e2d3ceb7 unlockDialog, loginDialog: Add a 'wake-up-screen' signal
The signal is currently present in the notifications box, but next
commits will move the notifications box to the unlock dialog.

Add a 'wake-up-screen' signal to the dialogs.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:51 +00:00
Georges Basile Stavracas Neto
d3cfb5801b unlockDialog: Adjust date format
As per design feedback at FOSDEM, adjust the time format to
not have a comma, nor padding.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:51 +00:00
Georges Basile Stavracas Neto
143cda628e screenShield: Move clock to Unlock Dialog
Move the Screen Shield clock to Unlock Dialog. Also adjust
the CSS style classes names to match the new owner.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:51 +00:00
Georges Basile Stavracas Neto
e90940ae10 screenShield: Remove arrows
They are not present anywhere in the new mockups.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/872
2020-02-10 22:30:51 +00:00
Carlos Garnacho
34207cc457 keyboard: Only enable automatically if ClutterSeat::touch-mode is enabled
This defers the policy on backends about whether it makes sense to show
the OSK.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/872
2020-02-10 22:07:19 +00:00
Carlos Garnacho
e16def0c43 magnifier: Make magnification factor changes animatable
So we can seamlessly change between them through eg. keybindings.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/984
2020-02-07 18:18:25 +01:00
Carlos Garnacho
83d083f189 magnifier: Implement pointer motion tracking differently
The use of the core idle monitor means that focus change events
are also delayed by keyboard interaction. Since the magnifier is
already in the business of pointer tracking, it's easy enough to
fire the pointer rest timeout from here, so focus changes are
accumulated and delayed.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/984
2020-02-07 18:18:25 +01:00
Carlos Garnacho
b1ea4f6c35 magnifier: Animate focus/caret position changes
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/984
2020-02-07 18:18:25 +01:00
Carlos Garnacho
60c540e93a magnifier: Add support for animating "scroll" on focus changes
This is nice in that it provides a hint of the relative position of
the new focus area, as opposed to a sudden jump.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/984
2020-02-07 18:18:25 +01:00
Carlos Garnacho
f3b56e0eb1 magnifier: Transform a11y events' coordinates by scale factor
We get those events in logical coordinates, which we have to transform
into actual pixels.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/984
2020-02-07 18:18:25 +01:00
Carlos Garnacho
c8d02be14a magnifier: Ignore repeated a11y events
We may get several a11y events setting the caret on the same
coordinates it previously was. Make focus tracking ignore those,
as we're jumping to the same coordinates again during eg. mouse
operation.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/984
2020-02-07 18:18:25 +01:00
Carlos Garnacho
42b50051ac magnifier: Sanity check coordinates in scrollContentsTo
We may receive a11y events with bogus coordinates (eg. x/y = minint),
so ensure the coordinates are sane before scrolling there.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/984
2020-02-07 18:18:25 +01:00
Carlos Garnacho
bda18888c0 magnifier: Clip all crosshair lines at even distances
If the crosshair is clipped so it doesn't cover the pointer cursor,
the clip rectangle is skewed towards the bottom/right. This was
made so to accomodate the default pointer, but the unevenness stays
on other pointer cursors, and it makes the crosshair look odd on
short crosshair length.

Make all lines clip to an even distance from the center instead.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/984
2020-02-07 18:18:25 +01:00
Carlos Garnacho
c150fe95b9 magnifier: Apply color inversion to crosshairs/pointer
It is somewhat unexpected that crosshair color and pointer cursor colors
remain the same across changes in color inversion settings, and may lead
to contrast issues. Apply the effect on the common container, so it
applies to these all.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/984
2020-02-07 18:18:25 +01:00
Carlos Garnacho
8b4b9d396b magnifier: Apply scale factor to crosshair length
On hidpi displays the length is double as advertised, make it match
the advertised length.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/984
2020-02-07 18:18:25 +01:00
Daniel van Vugt
8929c89d1f workspace: Animate window clones using translation properties
Instead of position x/y properties. This reduces CPU-intensive relayouts
in JavaScript (`vfunc_allocate` etc).

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/1271
since the other fix required already landed in 4c4846e9.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/936
2020-02-07 14:43:56 +00:00
Daniel van Vugt
881eab7669 dnd: Make DND translation-property-aware
Previously DND only worked properly for actors with zero translation.
But it only requires a small tweak to `this._dragOffsetX/Y` to support
non-zero translation values.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/936
2020-02-07 14:43:56 +00:00
Daniel van Vugt
b5651e38c7 iconGrid: Avoid animating the same icon twice
If the icon proper has opacity of zero then that's probably because a
clone of it is animating. So avoid animating the source actor too.

And if there's any other reason for the opacity being zero, still don't
animate it because we can't see it :)

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/2167
2020-02-07 11:31:20 +00:00
Daniel van Vugt
33ae220ad2 appDisplay: Call super.vfunc_unmap last
So as to guarantee the unmapped state sticks and doesn't get toggled
back to mapped before we return.

Being in a mapped state when `FolderIcon.vfunc_unmap()` returned was
causing an assertion failure in `clutter_actor_set_mapped` and crashed
the shell.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/2170
2020-02-07 11:23:25 +00:00
Florian Müllner
9d7a319721 extensionPrefs: Remove stray > in .ui file
This slipped through as GtkBuilder still accepts it, but let's
not rely on that and fix our XML.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2180
2020-02-06 20:05:32 +01:00
Piotr Drąg
b7df1133b8 extensionPrefs: Make the Log Out button a proper verb
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/981
2020-02-06 18:56:00 +00:00
Alexander Mikhaylenko
dfb8737007 appDisplay: Disable swipe tracker during swarm animation
Eensures it resets when an animation starts.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2177
2020-02-06 17:36:05 +00:00
Alexander Mikhaylenko
a06a418ac1 swipeTracker: Reset scroll gesture state on disabling
Ensure that scrolling works correctly next time it's enabled.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2177
2020-02-06 17:36:05 +00:00
Michael Catanzaro
35063c9e7c portalHelper: Enable WebKit sandbox if available
The portal helper is rather sensitive because potentially-hostile Wi-Fi
networks can decide to launch it whenever they want (by blocking the
user's connection to the nmcheck domain) and load whatever web content
they want into it. So having this unsandboxed is really extraordinarily
risky. Previously it was a risk we had to accept, because WebKit did not
have a web process sandbox, but now it does. So let's bubblewrap all the
things!

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/983
2020-02-06 18:28:40 +01:00
Carlos Garnacho
5c570460cf magnifier: Use core idletime monitor
As it's getting the idletime monitor for the seat pointer, boils
down to about the same thing. We are moving away from per-device
idletime monitors though.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/978
2020-02-05 16:17:30 +00:00
Florian Müllner
7b33e240ed extensionPrefs: Fix typo
https://gitlab.gnome.org/GNOME/gnome-shell/issues/2176
2020-02-04 18:51:57 +01:00
Florian Müllner
a205f4e249 status/system: Fix session submenu visibility
Commit 147a743d8d moved the suspend and power-off actions into
the submenu that contains the log-out and switch-user actions,
but did not update the submenu visibility logic to account for
the additional actions.

As a result, the submenu is hidden when log-out and switch-user
are unavailable (like on the login screen), even if suspend and
power-off are enabled.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2169
2020-02-04 14:40:44 +00:00
Florian Müllner
9e00e8a0fb extensionPrefs: Schedule updates check on activate
While gnome-shell will now check for extension updates, the checks
are performed infrequently. Opening the Extensions app implies that
the user's current focus is on extensions, so it is an appropriate
time to schedule another updates check.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:33:14 +01:00
Florian Müllner
529829a561 extensionSystem: Periodically check for extension updates
Now that we can download, apply and display extension updates, it is time
to actually check for updates. Schedule an update check right on startup,
then every 24 hours.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:33:14 +01:00
Florian Müllner
ed84541050 extensionSystem: Show notification when updates are available
Now that the extensions app has the ability to handle updates, we
can use it as source of updates notifications.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:33:14 +01:00
Florian Müllner
075f4a5efc extensionPrefs: Support extension updates
Now that we have support for extension updates in the shell, we
need some place to display the updates to the user.

As we are establishing the Extensions app as the primary way for
managing extensions, it's a natural place for that functionality.

Show which extensions have updates available, and offer a log out
button (so gnome-shell can apply the updates when logging back in).

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:33:12 +01:00
Florian Müllner
f1bd94a367 extensionPrefs: Split user and system extensions
Until now, it didn't matter whether an extension was installed in the
user's home or system-wide. However with support for uninstallation,
there is now a significant different, as that action is only available
for user extensions.

Account for that by separating extensions by type, so that users don't
have to second-guess which extensions can be fully-managed and which
appear as part of the system.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:13:44 +01:00
Florian Müllner
db69ad876a extensionPrefs: Support uninstalling user extensions
This is functionality currently provided by GNOME Software, and
which the new Extensions app should (and easily can) provide.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:11:21 +01:00
Florian Müllner
c6f297e4e5 extensionPrefs: Include more extension details in expander
The newly added expander gives us a place where we can display
more details without cluttering the interface.

Take advantage of that by including the extension website, version
and author.

(Author is in the mockups, but will not actually be shown until
the extensions website is changed to include it in its metadata;
however best to have UI and string in place for the freezes)

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:11:21 +01:00
Florian Müllner
1067642300 extensionPrefs: Move description into a expander
The description can be useful information, but also increases the
visual complexity of the extensions list. Move it into a hidden
details area that can be expanded, which unclutters the interface
while keeping the information readily available.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:11:21 +01:00
Florian Müllner
059524b007 extensionPrefs: Use actions for row controls
Actions are another mean to separate state and interactions from
the UI. Start using them for the existing controls before adding
more in follow-up commits.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:11:21 +01:00
Florian Müllner
1d72f28a1c extensionPrefs: Use template for rows
Rows are already complex enough to justify a template, and we are
about to add more.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:11:21 +01:00
Florian Müllner
5b92e3a9a8 extensionPrefs: Use a single line for description
The current fixed two-line label requires a custom widget, which
make moving to a widget template harder.

As the description will soon move elsewhere anyway, just go back
to a single line with a standard label for now.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:11:21 +01:00
Florian Müllner
8795668c41 extensionPrefs: Rename to Extensions
... and make the application user-visible.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:03:19 +01:00
Florian Müllner
872c84a1c3 extensionPrefs: Add standard app elements
In order to turn the extensions-prefs tool into a proper GNOME app, it
should follow basic app patterns, so add a primary menu and about dialog.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:03:19 +01:00
Florian Müllner
b47879d0a7 extensionPrefs: Add info popover to headerbar
Extensions can have a major impact on stability and performance. Now that
the tool will become the main way for users to manage their extensions, it
is an appropriate place to warn the user of that risk.

Add a small info popover to the headerbar to display that warning, together
with the previously removed hint of where to go for finding new extensions.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:03:19 +01:00
Florian Müllner
679fc20765 extensionPrefs: Add application icon
We are about to make the tool a user-visible application, so we
need an icon. Add one (plus its symbolic variant).

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:03:19 +01:00
Florian Müllner
db85e7084c extensionPrefs: Scroll with key focus
Currently when the extensions list is scrolled, it is possible to
keynav out of view, as the scrolling doesn't follow the key focus.

Hook up the adjustment to fix that.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:03:19 +01:00
Florian Müllner
1afd2c6ad2 extensionPrefs: Don't fill view
Extension rows contain both name/description and controls to
open preferences and enable/disable the extension. Those
elements become disassociated when the row expands too much
horizontally, so instead of filling the entire view, switch
to the embedded list style[0].

[0] https://developer.gnome.org/hig/stable/lists.html.en

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:03:19 +01:00
Florian Müllner
a74a9f6443 extensionPrefs: Use template for ExtensionsWindow
As the window will become more complex, it makes sense to let GtkBuilder
construct the UI and focus on the actual implementation.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:03:19 +01:00
Florian Müllner
f49e20bbae extensionPrefs: Split out window class
Currently the main window is a plain Gtk.ApplicationWindow that is
built and managed from within the application.

As the application becomes more complex, it makes sense to decouple
the two and handle the window from a separate ExtensionsWindow class.

Not least this is a prerequisite of using a widget template for the
window.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:03:19 +01:00
Florian Müllner
9916989272 extensionPrefs: Simplify empty placeholder
GNOME Software will remove its extension support, so we should stop
referencing it in addition to extensions.gnome.org.

In fact, the placeholder is not the best place to hint at where new
extensions can be found, as the user will never see it in case the
distribution includes pre-installed extensions.

So remove the hint altogether, we will add it back in a more prominent
place later.

With the whole placeholder now being much lighter, we can stop dimming
the remaining elements.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/1968
2020-02-03 19:03:19 +01:00
Jonas Dreßler
45c5f21f6c dialogs: Hide caps lock warning if password entry is hidden
If all password entries in dialogs are hidden, there is either an entry
that has visible characters or no entry at all. That means we don't have
to show the caps lock warning at all, so hide it.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/942
2020-02-01 08:08:33 +01:00