Commit graph

24182 commits

Author SHA1 Message Date
Automeris naranja
6322d8d6f0 printers: Use AdwToast to show status & error messages
Use AdwToast to show when a printer was removed and when
adding a printer fails.

Closes https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/2999
2024-06-03 07:54:13 +00:00
Matthijs Velsink
bc171a6d2d mouse-test: Remove primary indicator delay
Instead, instantly show a primary click was successful. For a double
click, it will remove the primary click success. This makes the testing
feel a little more responsive.

Closes #2991
2024-06-03 07:52:51 +00:00
Automeris naranja
5e00183b6b qr-code-dialog: Minor changes to the "Scan to Connect" label
- Add GtkLabel:wrap, otherwise qr-code-dialog width will grow
if the label is long
- Justify the label to the center so it looks more balanced
when it wraps
2024-06-02 21:29:49 -03:00
Automeris naranja
b1715487d6 qr-code-dialog: Use AdwPreferencesPage and property rows
The "Network Name" and "Password" labels look unbalanced if they
are long. To fix this, use property rows to show the network
information, which also involves porting the GtkScrolledWindow
to AdwPreferencesPage.
2024-06-02 21:29:49 -03:00
Automeris naranja
4ffffd6a5d qr-code-dialog: Add a comment explaining about the QR code being focusable
The rationale didn't get added in [1]. See [2] for more information.

[1] 0aa4e012cd
[2] https://gitlab.gnome.org/GNOME/gtk/-/issues/6749
2024-06-02 21:25:31 -03:00
Automeris naranja
0aa4e012cd qr-code-dialog: Make the dialog contents readable by Orca
- Make the QR code focusable, so the alternative text can be read
by Orca
- Make all labels selectable, but with a workaround to prevent them
showing selected without any user interaction (labels need to be
selectable so they can be read)
2024-06-03 00:07:14 +00:00
Automeris naranja
26c22045dd input-list-box: Remove "No input source selected" placeholder row
This placeholder row will never show because the list box will never be
empty due to the presence of the "Add Input Source" row, which also acts
as a placeholder. Also, the placeholder row broke the list box row
counting even more.

So, remove the "No input source selected" placeholder row, as it's
unnecessary.
2024-06-02 22:54:38 +00:00
Matthijs Velsink
9ff4df5d5e mouse-test: Don't respond to middle clicks
The indicators should only light up for primary or secondary clicks, but
not for a middle click.

To make this clearer too, we can use Gdk constants.

Fixes #3079
2024-06-01 21:28:01 +02:00
Martin
3ac6ae32cf Update Slovenian translation 2024-05-31 13:38:21 +00:00
Matthijs Velsink
6a96efe5f8 privacy,usage: Port to CcNumberRow
This saves a lot of code and translatable strings. Also, this will make
it easier to change the list values in the future, as they will be added
to the list even if a value is set that is not in the list.

By binding to the GSettings keys directly, even more code can be
removed.
2024-05-31 09:47:16 +00:00
Matthijs Velsink
7cbea49005 number-row: Add value type for value in days
This will be useful for the File History & Trash page from Privacy.
2024-05-31 09:47:16 +00:00
Jakub Steiner
be7ef13193 sound: Adjust click effect
- bring click closer to the sound of fdo's bell.

See https://gitlab.gnome.org/GNOME/gsettings-desktop-schemas/-/merge_requests/81
2024-05-31 08:57:23 +00:00
Jamie Gravendeel
02792f3c8e Revert "users: Don't use another style class for the remove avatar button"
This reverts commit 62564c623f.

The custom style class was used to provide different styling than the default destructive style, since the custom style class doesn't affect the opacity of the background.
2024-05-31 08:33:33 +00:00
Automeris naranja
88d74d060f apps: Use ellipsis symbol in the Storage dialog
When the cache or app data size are being calculated, three periods
(...) are shown instead of an ellipsis symbol (…), which is what
HIG recommends:

https://developer.gnome.org/hig/guidelines/typography.html#take-advantage-of-unicode
2024-05-30 21:09:51 +00:00
Felipe Borges
d940df174f network: Reference icon-name that exists in wifi panel desktop file
Similarly to fd65182, rpminspect catched that gnome-wifi-panel.desktop
references an icon name that doesn't exist.

```
Desktop file /usr/share/applications/gnome-wifi-panel.desktop on x86_64 references icon network-wireless but no subpackages contain network-wireless
```

The way the icon lookup works will suffix it with "-symbolic", resulting
in "network-wireless-symbolic", which exists.

While MR !2452 provided settings icons for various panels, it didn't for
the Wifi panel.
2024-05-30 21:05:04 +00:00
Matthijs Velsink
9032a3a86c ci: Fix Coverage once and for all
Apparently, the coverage-html target can't be directly compiled via
meson, but ninja has to be used directly.

So, revert the change from commit 7f541b42 for the coverage job.
2024-05-30 22:47:59 +02:00
Matthijs Velsink
67d94ac78b ci: Fix coverage, don't let it pull build artifacts
Coverage needs to do its own configuration for the coverage report.
Perhaps it can reconfigure the meson directory from the build stage, but
let's just have Coverage do the build as well.

So, don't depend on anything but the container.
2024-05-30 22:15:31 +02:00
Jakub Steiner
19e79cbe1d sound: Update metadata
- sound effects shipped with broken metadata. Clean it up
2024-05-30 15:54:13 +02:00
Matthijs Velsink
f4a0d04e8d background: Switch to using gnome.mkenums_simple
This simplifies the Meson build file, and removes the inline mkenums
template code, which is now inside Meson itself.

Also, we can now use the better prefix `G_DESKTOP_TYPE` instead of
`G_DESKTOP_TYPE_DESKTOP`.
2024-05-30 08:12:01 +00:00
Matthijs Velsink
54003b5f38 system: Switch to using gnome.mkenums_simple
This simplifies the Meson build file, and removes the inline mkenums
template code, which is now inside Meson itself.

Also, we can now use the better prefix `G_DESKTOP_TYPE` instead of
`G_DESKTOP_TYPE_DESKTOP`.
2024-05-30 08:12:01 +00:00
Matthijs Velsink
cf6589d075 common: Switch to using gnome.mkenums_simple
This simplifies the Meson build file, and removes the inline mkenums
template code, which is now inside Meson itself.
2024-05-30 08:12:01 +00:00
Matthijs Velsink
edd89e7772 privacy,screen: Refactor CcNumberRow logic
The logic is a lot simpler with the ability to bind it to GSettings.
2024-05-30 08:05:03 +00:00
Matthijs Velsink
b04fc824fd number-row: Add binding from GSettings to CcNumberRow
The most common use case for CcNumberRow is to bind it to a GSettings
key value.

So, let's add an easy function to perform such a binding. It binds the
"selected" property of the underlying AdwComboRow GSettings value using
mapping functions. If the value does not exist in the CcNumberRow yet,
it will be added to the list of the row and selected.

It makes sure both unsigned and signed values are properly handled, as
CcNumberRow only holds signed values.
2024-05-30 08:05:03 +00:00
Matthijs Velsink
ad385a2b41 number-row: Add option to have no sorting
In the Power panel there will be a use case to not sort the list at all.
Let's add that option via a custom CcNumberSortType enum.
2024-05-30 08:05:03 +00:00
Matthijs Velsink
b7917738c8 number-row: Add value type for hours
For completeness, let's add a value type for hours. Also, we clean up
the magic millisecond conversion values for clarity.
2024-05-30 08:05:03 +00:00
Matthijs Velsink
2699632c6a number-row: Add value-type property for easier use
To make the CcNumberRow easier to use for newcomers as well, let's stop
using GtkExpression directly. Instead, we introduce a `value-type`
property that tells the CcNumberRow how to interpret values and map them
to strings.

With the `custom` value type, a custom GtkExpression is still usable.
2024-05-30 08:05:03 +00:00
Matthijs Velsink
a6466bc504 number-row: Port away from CcNumberList
This is a minimalistic port away from CcNumberList, into CcNumberRow.
Documentation is adjusted as well.
2024-05-30 08:05:03 +00:00
Matthijs Velsink
15086cb088 common: Rename CcNumberList to CcNumberRow
This is just renaming, changes will come in the next commits.
2024-05-30 08:05:03 +00:00
Andy Holmes
a3e73896cc online-accounts: don't show account details when finished
When a new account is successfully added, simply close the dialog,
revealing it to be in the list of accounts, rather than showing
the account details.

closes #3067
2024-05-30 07:41:02 +00:00
Martin
0819e750fe Update Slovenian translation 2024-05-30 07:39:39 +00:00
Matthijs Velsink
50788f7569 ci: Build GTK from source into container
The current GTK 4.15.1 contains an issue for CSS deprecation warnings
that causes criticals, making our tests fail.

This was fixed by gtk!7306, so build from source to have that available.
Again, we do this in the container, to speed up builds but to also have
a stable version in CI for longer.
2024-05-29 21:10:39 +02:00
Matthijs Velsink
c399bde75d ci: Don't build dependencies during build stage
Building dependencies from source (like Libadwaita) can take some time,
so doing it for every build is inneficient.

But more importantly, since commit bc5c9976, the tests depend on the
build output, but don't actually build. So any dependencies for running
the tests must be available globally.

Therefore, build dependencies into the container.

Also, only clone with depth 1, as nothing more is needed.
2024-05-29 20:59:52 +02:00
Automeris naranja
42503c8ced network-wifi: Use header capitalization in the "Security Type" row
As per HIG guidelines:
https://developer.gnome.org/hig/guidelines/writing-style.html#header-capitalization
2024-05-29 14:52:32 +00:00
Automeris naranja
8d9f40b40a network-wifi: Use property rows to show Wi-Fi Hotspot information
Doing, so this will improve consistency as other places in
Settings use property rows [1]. This also ensures that the
network name doesn't get ellipsized if it's long when using
a narrow window width.

[1]
- feb2c8c514
- 5cd300c65a
- d5c66d25a0
2024-05-29 14:52:32 +00:00
Automeris naranja
27aae933cd usage: Replace buttons with AdwButtonRows
https://developer.gnome.org/hig/patterns/containers/boxed-lists.html#adding-buttons
2024-05-29 14:51:49 +00:00
Automeris naranja
44985cf097 apps: Fix search entry being smaller again
Now that the search entry was put in a GtkSearchBar in [1],
the search entry got a bit smaller, breaking a little what
[2] fixed.

To fix this, remove the "maximum-size" and the
"tightening-threshold" from the AdwClamp that contains the
search entry. This will also make the search entry size to
be consistent with the one from cc-keyboard-shortcut-dialog,
which is also a top child of AdwToolbarView.

[1] cd97e4f518
[2] ec01b9d629
2024-05-29 14:48:11 +00:00
Felipe Borges
89bd8b4626 remote-desktop: Don't set credentials when they didn't change
When the entry changes, it triggers the callback dance to store the
values in the backend. Causing `gtk_editable_set_text` to be essentially
called every REMOTE_DESKTOP_STORE_CREDENTIALS_TIMEOUT_S seconds (2
seconds) even when credentials have changed. This call has visual
effects, such as moving the cursor caret and changing the entry
selection state.

Fixes #3077
2024-05-29 12:58:07 +00:00
Jamie Gravendeel
983ed0496a remote-desktop: Move buttons to AdwButtonRow 2024-05-29 08:41:44 +00:00
Automeris naranja
932bbc970f pp-details-dialog: Port to AdwButtonRow
Also:
- Remove "select_from_database_button" and "install_ppd_button"
object IDs, as they are unused by the C code.
- Remove the default-height from the window to avoid showing an
unnecessary scrollbar now that the AdwButtonRows takes more vertical
space
2024-05-28 20:11:28 +00:00
Automeris naranja
d3765f0862 input-list-box: Port "Add Input Source..." to AdwButtonRow
Also, remove the ellipsis, since it isn't necessary when a
button row adds something to a list box.

https://developer.gnome.org/hig/patterns/containers/boxed-lists.html#adding-buttons
2024-05-28 20:00:10 +00:00
Felipe Borges
cb85480a02 search-locations: Move initialization to object _init 2024-05-28 19:54:49 +00:00
Felipe Borges
7177c0e18b search: Rename CcSearchLocationsDialog to CcSearchLocationsPage 2024-05-28 19:54:49 +00:00
Felipe Borges
ce0c071d6b search: Port SearchLocationsDialog into a panel subpage
The goal here is to avoid the dialog and follow a pattern of subpages we
have in other panels.

This dialog is often launched from Nautilus over the
`gnome-control-center search locations` launching argument, making it
even worse as a dialog.
2024-05-28 19:54:49 +00:00
Automeris naranja
c85bd59c56 search-locations-dialog: Port to AdwDialog 2024-05-28 19:54:49 +00:00
Martin
dec6e92542 Update Slovenian translation 2024-05-28 19:52:21 +00:00
Martin
db4b5f9fb9 Update Slovenian translation 2024-05-28 19:50:59 +00:00
Automeris naranja
9b04a0e87c sharing: Use AdwButtonRow in the Media Sharing dialog
https://developer.gnome.org/hig/patterns/containers/boxed-lists.html#adding-buttons
2024-05-28 16:41:32 -03:00
Xiaoguang Wang
0a3ae1b448 users-page: Don't show the system accounts
When handling user-added signal, omit the system accounts.

Fixes https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/3066
2024-05-28 13:51:26 +00:00
Jamie Gravendeel
c09fb7a65f users: Port buttons to AdwButtonRow 2024-05-28 13:48:02 +00:00
Automeris naranja
e51fa8febc ua-mouse-page: Add "Activate Windows on Hover" setting
Design reference:
https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/2962#note_2079399

Closes https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/2962
2024-05-28 13:18:32 +00:00