When the GridSearchBase actor is destroyed we should remove the
ongoing later that might try to access to invalid resources.
To do this, add an _onDestroy() callback function to SearchResultsBase
and override it in GridSearchBase.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/700
Easing calls on show/hide functions have some parameters in common whether the
radial effect is enabled or not.
So instead of doing repeated calls with similar parameters, initialize common
values in params objects.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/700
If the resource scale or the scale factor changes while the animation
is playing, we need to stop the animation and start it again once the
texture is loaded, as the idle might try to access an invalidated
animation child otherwise.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/700
Commit 21e14bd46f fixed this for the
brightness slider, but we have the same problem for volume too. When the
volume is muted - for example in Settings or via a media key, we update
the slider to '0' to indicate this visually. But we also actually invoke
the slider's callback to *set* the volume to zero. That means that the
previous level is overwritten so it can't be restored when unmuting.
The fix is the same - when we update the slider internally ourselves,
don't call the signal handler.
https://gitlab.gnome.org/GNOME/gnome-shell/issues/1557
We now do 2 things along Xwayland startup/shutdown:
- Start or stop the gnome-session-x11-services target, that will
pull all X11 related services that the session might depend on.
- As we start ibus-daemon manually, trigger a restart in order to
toggle the XIM daemon on and off along with Xwayland presence.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/680
We may need to restart it with different arguments, so make it
possible to do that. Also, avoid to just restart it on _clear(),
this is now most likely through our --replace call than it is
through ibus-daemon eg. dying, avoids some noise in logs as
there is already an ongoing ibus-daemon.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/680
An Endless OS system was found in the wild with a malformed
.local/share/gnome-shell/notifications which causes _loadNotifications()
to raise an exception. This exception was not previously handled and
bubbles all the way out to gnome_shell_plugin_start(), whereupon the
shell exit(1)s. The user could no longer log into their computer.
Handle exceptions from _loadNotifications(), log them, and attempt to
continue. Ensure that this._isLoading is set to 'false' even on error,
so that future calls to _saveNotifications() can overwrite the (corrupt)
state file.
https://gitlab.gnome.org/GNOME/gnome-shell/issues/1552
The updatesPermission is currently initialized synchronously, which
blocks the Mainloop for quite some time and therefore slows down startup
of the shell, let's do it asynchronously instead.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/689
Since we now put a short timeout in before the start of the actual pie
timer we don't start the timer as often as we used to. This allows us to
create a new PieTimer object each time a timeout is started and
therefore play a finish animation independently of other (new) timeouts.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/688
If the circle is complete and the pie timeout finished, we don't need
the lines to the center point indicating the ends of the pie anymore.
We just draw a clean circle instead, which allows for a zoom-out and
fade animation of the circle when we're done.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/688
If the pie timeout has finished successfully there's no need to cancel
the pie animation, instead we can just wait for that animation to finish
and show some visual feedback like a zoom-out animation to indicate the
click afterwards.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/688
Fade the pie timer in using a duration of 1/4 of the timeout and a
EASE_IN_QUAD animation. This significantly reduces flickering of the pie
timer while moving the cursor and makes the timer less distracting.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/688
gjs no longer has an implicit dependency on GTK 3.0, so without
requesting an explicit version, we will get the highest available.
Our code isn't GTK-4 ready, so request 3.0 explicitly.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/686
Before the move to Clutters implicit animations with 0846238f6 and
bf497ed64, we used Tweener to do a fake-animation of the opacity and
Tweeners `onUpdate` signal to queue a repaint of the PieTimer everytime
Tweener tries to update the animation.
Now, with Clutters implicit animations, there is no `onUpdate` signal
anymore and also `notify::opacity` no longer gets emitted since the
value doesn't actually change. This lead to the PieTimer no longer being
repainted, which broke the animation.
Fix this by implementing the current angle of the pie using a custom
GObject property `angle` and animating this property using the new
`actor.ease_property` method.
Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/1533
When cancelling the animations of the icon grid, right now we simply
destroy all the clones without resetting the opacity and making the
actor reactive again. So if the spring animation to show the grid is
cancelled by pressing a key to start a search, the icon clones would be
destroyed, but the icon-opacity would still be set to 0. Now if the
Escape key is pressed, viewSelector will show the last active page (ie.
the iconGrid) without a custom animation and only fade in the page, and
because the icons still have an opacity of 0, they will be invisible.
Fix this by always restoring the opacity and reactive property of the
original actors if the animation is cancelled instead of only destroying
the clones.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/678
Since we set the proxy value when the slider changes and set the slider
value on proxy property changes, we run into a cycle.
Before commit 3d3dca4aa this was addressed by not notifying on all slider
changes, but only in reaction to direct user action. Given that since the
splitting out of the BarLevel class those events are handled in a subclass,
that approach is at least unconvential and fairly fragile.
Instead, make the brightness indicator ignore any changes to the slider it
initiated itself.
https://gitlab.gnome.org/GNOME/gnome-shell/issues/1500
With 8b368d010 we fixed a bug where the onComplete callback was always
called no matter whether the transition was interrupted before or not.
This exposed another bug: viewSelector depends on this behaviour when
fading out pages: After fading out a page, we call `this._animateIn` to
show the new page. Now if the fade-out animation gets interrupted, with
the correct behaviour of onComplete we end up not showing a new page and
the viewSelector remains empty instead. One case where this happens is
when pressing a key to start a search during the overview-animation.
Obviously we also want to show the new page in case the fade-out
animation was interrupted, so use the onStopped callback instead of the
onComplete callback here.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/674
An actor ease callback could destroy the actor, in such case we should do not
touch the actor anymore.
So, before calling the callback, reset restore the easing state and don't
perform any further action with it.
Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/1507
When a drag is cancelled and the source actor
is visible, the drag actor is animated back to
the source position. The scale that the drag
actor will become is calculated as:
scale = this._dragActor.width / sourceScaledWidth
However, this is wrong; what we wanted to do
is the opposite:
scale = sourceScaledWidth / this._dragActor.width
Fix the scale calculation to match the math
above.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/671
Create a new folder when dropping an icon over another
icon. Try and find a good folder name by looking into
the categories of the applications.
Delete the folder when removing the last icon.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/671
Because the Dash icons are not drop targets themselves,
add a tiny DashIcon class, which is an AppDisplay.AppIcon
subclass, and disable all DND drop code from it.
Show a folder preview when dragging an app icon over another
app icon.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/671
As per design direction, scale and fade the app icon
when starting dragging it, and show it again if the
drop is accepted. Clutter takes care of animating the
rest of icon positions through implicit animations.
Scale and fade the dragged icon while it's being dragged.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/671
Since the `notify::allocation` signal will obviously get emitted while
the actor is inside an allocation cycle and we might end up doing
changes to its allocation inside `updateSearch` by hiding or showing the
actor (which queues a relayout), we get a warning from Clutter.
Fix this by delaying the call to the parent method until the next
redraw, which should happen a few moments after the current relayout.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/672
Since commit 1a27ff6130 we use the
allocation width of the GridSearchResults actor to calculate the max
number of results that can be shown for this search provider.
On the first run of the search, when no previous (cached) allocation is
available for the actor of GridSearchResults, the allocation width used
in `_getMaxDisplayedResults` will be 0, which in turn will make
`updateSearch` filter out all results returned by the search provider.
Now if this search provider is the only search provider that's enabled,
after calling `updateSearch`, the `SearchResults` class will call
`_updateSearchProgress` to check if any results are visible, assume
nothing was found and therefore hide the scrollView. This in turn causes
the GridSearchResults actor to not get a new allocation, which prevents
our code to fixup the max number of results on `notify::allocation` from
working: The number will continue to be 0 and we'll never show any
results.
To fix this regression, return -1 in `_getMaxDisplayedResults` if the
allocation width is 0 to inform `updateSearch` that we can't calculate
the maximum number yet and interpret a return value of -1 as "show all
results" in `updateSearch`. The same problem would probably also appear
if the allocation width is anything between 0 and the width of the
iconGrid with one icon in it, although this might as well be a valid
width in case a very small screen is used or with very large icons. So
let's only check for a width of 0 and hope the GridSearchResults actor
won't get weird temporary allocations in that range.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/672
Just as we animate the apps launch using the zoom out animation if the
'new-window' action provided by the app is launched, we should also show
this animation if the 'activate-discrete-gpu' action provided by the app
via its AppInfo is launched.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/673
For the "New Window" entry we add to the AppIcons popup menu we should
always animate the app icon if the menu entry is activated as it was
intended by commit 62786c09a8.
For the "Launch using Dedicated Graphics Card" entry we can also always
show the animation if the entry is activated since the entry should only
be visible if the app is stopped.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/673
Clocks has exactly the same issue as Weather: Its integration currently
relies on accessing its settings directly, which isn't possible when
the app is sandboxed.
Fix this the same way we did for Weather, by adding our own setting
and syncing it with the app via a custom D-Bus interface.
https://gitlab.gnome.org/GNOME/gnome-shell/issues/1158
We add our own "New Window" menu entry if the app doesn't already
provide a 'new-window' action. For this menu entry, we show the zoom out
animation on the app icon when the user clicks the entry.
To be consistent in case the app already provides its own 'new-window'
action via its AppInfo, also show the zoom out animation when this
action is activated.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/662