We currently load the last-panel every time gnome-control-center
is launched, we do it from the CcWindow contructor method.
But we shouldn't do it when we are explicitly opening a different
panel by eg. using commandline parameter (gnome-control-center keyboard)
or from a DBus method, because otherwise we slow things down by
unnecesarily start launching last-panel just to be cancelled
moments later when the code starts processing the other panel.
We fix it by moving the code that loads last-panel to an idle
handler, so by the time it gets executed the other panel has
already started loading, and we can check for that with the
cc_panel_list_get_current_panel() function we add in this patch.
With this patch, I can feel that panels opened from a
gnome-shell search are presented faster.
Fixes issue #2569
Improve keyboard navigation with Up/Down arrow keys between
Search entry and the search results list.
Pressing Arrow Down in search entry will now move focus
to search list, and when pressing Arrow Up on the first
list result will move back focus to Search entry.
Meson extracts them by itself and add them as dependencies for the target.
It means one less location to keep track of files, and a lot less boilerplate
around the meson files
When pressing ENTER (i.e. activating) a search with no
results ("No results found") the first Wifi panel was
being activating, that's wrong because cc_panel_list_activate()
should activate the first visible panel, but there are
no visible panels at the moment (No results found page is shown)
The problem was the visibility check in cc_panel_list_activate()
was incomplete and so it wrongly thought panels were app visible.
Part of #2119 (comments 4th and 5th)
Avoid activating a panel when doing an empty search
i.e. clicking ENTER without having entered
any text in the search entry.
We should do nothing in this case, we fixed it by
detecting for this case when an activation happens
when there's still no search results view in place.
Closes#2119
When activating a panel from Search or from commandline
let's scroll the sidebar so the row for that panel is
revealed and vertically centered on the list.
Closes#2098
Don't activate first row panel (i.e. 'Wifi') when:
- Canceling search view (pressing ESC or deleting all query text).
- Activating a search result from search view.
Closes#2472
If the previously shown panel had a custom sidebar, we were not
switching back to the main list if the currently shown panel
doesn't have one.
This will result in the sidebar having empty content.
Fix it by always switching to main sidebar view if no custom
sidebar widget is set.
Closes#2261Closes#2292
This is part of an initiative to use "app" instead of "applications",
see: https://gitlab.gnome.org/Teams/Design/initiatives/-/issues/123
Redo of !1539 that was closed by a ghosting user.
Replaces "application" with "app" in user facing strings in these
panels:
- applications
- camera, location, microphone
- default-apps
- multitasking
- notifications
- removable-media
- search
- usage
- user-accounts
Fixes: #2208.
If the previously shown panel had a custom sidebar, we were not switching
back to the main list if the currently shown panel doesn't have one.
This will result in the sidebar having empty content.
Fix it by always switching to main sidebar view if no custom sidebar widget
is set.
Fixes#2261
GtkStyleContext will be deprecated in gtk 4.10.
https://docs.gtk.org/gtk4/class.StyleContext.html
This preserves code blocks where additional GtkStyleContext operations
were used, such as gtk_style_context_save/restore.
The `X-GNOME-Bugzilla-*` entries were for use by bug-buddy, a GNOME 2
technology that's been gone for over a decade. These entries are
obsolete and can be removed from all desktop files.
The `X-GNOME-Settings-Panel` entry is also obsolete as far as I can
tell and only these panels had it in their desktop file: notifications,
sharing, sound and user-accounts. These entries can also be removed.
After removing the `X-GNOME-Bugzilla-*` entries, the desktop files have
no more variables in them. The meson `configure_file` step is therefor
pointless—there are no variables to configure. As such the
`*.desktop.in.in` files are renamed to `*.desktop.in` to reflect this
and `meson.build` files are modified to remove `configure_file` step.
The error should not be touched after passing it to
`g_task_return_error()` as noted by its documentation:
Note that since the task takes ownership of @error, and since the
task may be completed before returning from g_task_return_error(),
you cannot assume that @error is still valid after calling this.
However, previously, the code did try to free error since the
`local_error` was defined with `g_autoptr(GError)`.
This was designed some time ago [1] but never actually implemented, so:
- Change the screen lock section to "screen"
- Move the screen section up, so it's next to the other types of
hardware
- Added a Screen lock section in there
[1] https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/909#note_737827
The Firmware Security panel exposes the host security levels
and details. The information is generated by fwupd. The panel
also exposes hardware configuration changes to pinpoint the
configuration changing time.
Currently this panel shows:
- HSI and secure boot status
- Details of HSI and secure boot
- Configuration changelog
- Digested security level
- Extended protection
We need to cancel internal operations before starting to create a new
panel, otherwise panels might be creating the same object for the cache
in parallel and this is not supported by the object cache.
The alternative to this would be to handle this inside the object
store to allow parallel creation of the same key.
Fixes: #1685