Commit graph

1290 commits

Author SHA1 Message Date
Automeris naranja
58b0d7392a net-proxy-page: Add mnemonic to the "Configuration URL" entry 2024-01-23 11:09:19 +00:00
Automeris naranja
547b4542be network-ethernet: Tweak network options button tooltip
- Change "Options" to "Network Options" to
provide more context

- Remove the a11y label, which is redundant,
because this button already have a tooltip (the
screen reader also reads tooltips)
2024-01-23 10:55:23 +00:00
Automeris naranja
7fd77c339d wifi-connection-row: Tweak tooltips
- Rename "Show QR Code" to "Share Network",
since the latter is is the proper name of
this action

- Change "Options" to "Network Options" to
provide more context

- Add tooltip to the forget network button

- Removes a11y labels from buttons that already
have tooltips, since the former is redundant
due to the fact that the screen reader reads
tooltips
2024-01-23 10:55:23 +00:00
Automeris naranja
d12a7713d5 qr-code-dialog: Port to AdwWindow/AdwToolbarView
See https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/2624
2024-01-18 11:58:34 +00:00
velsinki
b76d6d0d00 ethernet: Add thousands separator to speed
Increases readability for speeds >= 1000 Mb/s.

Fixes #2804
2024-01-08 12:52:59 +00:00
velsinki
0b3c670ed4 wifi: Avoid critical warning for hotspot dialog
The CcWifiHotspotDialog is derived from GtkDialog, which is floating.
The floating reference is destroyed on closing the main window, before
the NetDeviceWifi is disposed. This causes a critical warning when the
NetDeviceWifi dispose does run, since it tries to destroy a now
non-existent window.

Fix this by sinking the floating reference, and unreffing it in the
NetDeviceWifi dispose function.

Fixes #2823
2024-01-08 09:38:55 +00:00
Bart Gravendeel
cacc2b5bef Remove use-underline property from all CCListRows 2024-01-04 10:11:35 +00:00
velsinki
99b42130b0 wifi: Fix crash when switching to other panel after forget network
Similar to the previous crashes, if you switch panels after forgetting a
network while the toast is still alive, Settings crashes. This is
because the AdwToastOverlay is not properly disposed because the Saved
Networks dialog is also not destroyed.

However, destroying the saved networks dialog still leaves a crash,
because the overlay disposal first unreferences its child, but we still
need that for the dismissal of the waiting toasts. Therefore, we keep an
extra reference to the saved networks list.

To prevent further crashing, we cannot set "list" to NULL, because there
may be multiple async calls. Also, we have to keep a reference to self
in the async call, otherwise it does not work when you remove many
networks and then switch panels.

As an added bonus, we can now use the saved networks list inside the UI
refresh function.
2023-12-19 09:33:26 +00:00
velsinki
794d8f5135 wifi: Move Saved Network mostly to .ui and clean up
It is cleaner to define the dialog in a .ui file. Moreover, since we are
initializing the main Visible Networks list in the code, we can
initialize the Saved Networks list in the same location, in the same
style.
2023-12-19 09:33:26 +00:00
velsinki
74279db43f wifi: Clean up net-device-wifi
There is a lot of unused code for the saved networks dialog. We can
remove all of that.

We furthermore format the code a litte better.
2023-12-19 09:33:26 +00:00
velsinki
91771c4c31 wifi: Avoid casting of Adw and GTK types
This reduces some of the casting noise in the code.
2023-12-19 09:33:26 +00:00
velsinki
218adbd306 wifi: Fix crash on reopen of Saved Networks after forget
When a network is forgotten from the Saved Networks dialog and the
dialog is closed, the toast remains active. However, when you then
quickly reopen the dialog, a new CcWifiConnectionList gets made, which
causes a crash when the toast expires or is dismissed, as the row for
the toast has now become invalid.

Fix this by only setting up the CcWifiConnectionList for saved networks
once.
2023-12-19 09:33:26 +00:00
velsinki
7a4869017e wifi: Fix "forget multiple networks" crash
When forgetting more than one network from the Saved Networks dialog,
there are multiple overlapping toasts. When the first toast expires or
is dismissed, the underlying CcWifiConnectionList is already thawed,
meaning previous rows get cleaned up and new ones generated. When the
next toast then expires or is dismissed, this results in a crash, as the
row belonging to that toast is now invalid.

Fix this by freezing the connection list earlier.

Fixes #2793
2023-12-19 09:33:26 +00:00
velsinki
1e8ce56887 ce-vpn-page: Fix layout of Identity page
b291e98c introduced a scrolled window, but forgot to update the C code
to use the new box instead. Now we use it correctly again.

Fixes #2795
2023-12-15 10:49:22 +00:00
velsinki
0427e160bd network: Hexpand connection editor routes labels
Commit ef644deb made the routes labels for the IPv4 and IPv6 center
properly. However, when stretching the dialog, this centering is lost
because the labels do not horizontally expand.

So let's make all of them horizontally expand.
2023-11-30 09:41:49 +00:00
Maximiliano Sandoval R.
200cac0970 connection-editor: Remove default size
In the previous commits we added scrolled windows on all pages, these
scrolled windows propagate their natural size and hence the dialog will
try to present itself with that size.

By having all pages inside of a scrolled window we can now use the
connection editor on mobile devices.

Fixes: https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/2764
2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R.
b291e98c00 ce-vpn-page: Add a scrolled window
We wrap the contents of the page in a scrolled window.
2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R.
f37e284ae4 ce-ip6-page: Remove comments 2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R.
e85f094184 ce-ip6-page: Propagate natural size of content
We remove hscrollbar-policy=never. This can only work if the view is
adaptive. This has to be restored once the page is adaptive.
2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R.
4fade06a02 ce-ip4-page: Propagate natural size of content
We remove hscrollbar-policy=never. This can only work if the view is
adaptive. This has to be restored once the page is adaptive.
2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R.
3b3ca34a57 ce-wireguard: Propagate natural size of content
We remove hscrollbar-policy=never. This can only work if the view is
adaptive. This has to be restored once the page is adaptive.
2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R
15844ddefe ce-page-details: Port to AdwBin
We add a scrolled window.
2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R.
f374c62b81 ce-page-ethernet: Port to AdwBin
We add a scrolled window.
2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R.
665288a47c ce-page-wifi: Port to AdwBin
We add a scrolled window.
2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R.
4f8789c466 ce-page-security: Port to AdwBin
We add a scrolled window.
2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R.
15694399dd ce-8021x-security-page: Port to AdwBin
We add a scrolled window.
2023-11-29 17:35:16 +00:00
Maximiliano Sandoval R.
9f86405bdd connection-editor: Add suggested action to button 2023-11-29 17:35:16 +00:00
Jonathan Kang
f0d04a180f network-connection-editor: Close the editor when nm-connection-editor exits
Previously, when editing a connection that doesn't have native editor
support, nm-connection-editor is spawned to do the work. But after
closing nm-connection-editor, an empty editor dialog still exists.

Fix that in this commit.
2023-11-29 10:28:18 +00:00
Automeris naranja
d975dd335c network: Add tooltip to some buttons 2023-11-29 10:12:30 +00:00
Ismael
9ed28e9c27 network: Share WPA3 (SAE) networks with QR Code 2023-11-27 12:15:20 +01:00
Automeris naranja
52a5afcc28 ce-page-details: Add ellipsis to labels of forget_button
"Use an ellipsis (…) at the end of a label if
further input or confirmation is required from
the user before the action can be carried out".

https://developer.gnome.org/hig/guidelines/writing-style.html
2023-11-27 10:36:00 +00:00
Automeris naranja
1093f2993f connection-editor: Set .pill style to forget_button 2023-11-27 10:36:00 +00:00
Marcos Miller
5e27373700 network: Show top buttons on unsupported network daemon page
When entering the network panel without the network daemon,
the window decoration buttons do not appear because the whole panel
content was overwritten by an AdwStatusPage.

Now only the content of the AdwToolbarView is changed, preserving
the AdwHeaderBar and buttons.

Fixes https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/2695
2023-11-24 10:49:08 +01:00
Ondřej Pohořelský
8f3eee7ee1 wifi: hide QR code icon when connection not successful
Don't show QR code icon when there is no info about connection being
valid and successful. Also hide it when we are connecting and when WiFi
has no password.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-control-center/-/merge_requests/2030>
2023-11-23 05:10:07 +00:00
Florian Müllner
38cac20497 network: Handle BT device connections ourselves
Bluetooth connections are among those that we still delegate to
nm-connection-editor. Luckily they are fairly simple connections
without any options on their own, so the built-in connection editor
can handle them just fine.

https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/1157

Part-of: <https://gitlab.gnome.org/GNOME/gnome-control-center/-/merge_requests/2044>
2023-11-21 13:38:32 +00:00
Felipe Borges
fd4b45c84e wifi: Close "Saved Wi-Fi Networks" dialog when last item is removed
Otherwise we are left with an empty dialog again.

Fixes #2715
2023-11-13 10:58:50 +00:00
Felipe Borges
7e7cb4a2de wifi: Don't show "Saved Wi-Fi Networks" row when there's nothing to show
Fixes #2715
2023-11-13 10:58:50 +00:00
Ondřej Pohořelský
7f104fb9c8 network: remove wpa-none from key_mgmt
Network Manager dropped `wpa-none` value from `key_mgmt` a while ago[0]
There is no need to test for this option anymore.

[0]c97e0ce30b
2023-11-13 10:02:31 +00:00
Automeris naranja
e01f49d11e net-proxy-page: Add use-underline property to the Network Proxy row
Otherwise the mnemonic won't work.
2023-11-13 09:52:29 +00:00
Lukáš Tyrychtr
c6a6a6b859 network: Ensure we pick-up the latest numeric values for Wireguard settings
The SpinBox value returned by get_value and friends gets definitely
updated only when the control loses focus. That is unfortunately too late
for the validation machinery, so force the updates at the right time.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-control-center/-/merge_requests/1983>
2023-11-07 09:10:38 +00:00
Automeris naranja
01f5bd318a net-proxy-page: Add missing mnemonics
Add mnemonics to the following rows
- Network Proxy
- Configuration

...and to the following buttons:
- Cancel
- Save

Partially fixes https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/2541
2023-11-05 17:39:31 -03:00
Automeris naranja
da158ef042 network: Add mnemonic to the "Proxy" row
Partially fixes https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/2541
2023-11-05 17:39:31 -03:00
Ondřej Pohořelský
de23defe3c network: Wireguard hide Last used and Automatic connection
Part-of: <https://gitlab.gnome.org/GNOME/gnome-control-center/-/merge_requests/1996>
2023-11-05 08:59:11 +00:00
Ondřej Pohořelský
51b82c0719 network: vpn hide metered connection settings
NetworkManager does not support metered connection settings in the
context of VPN. This commit hides the setting on VPN details pages.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-control-center/-/merge_requests/1996>
2023-11-05 08:59:11 +00:00
Ondřej Pohořelský
72246bceb1 network: hide Last used when creating new connection
Part-of: <https://gitlab.gnome.org/GNOME/gnome-control-center/-/merge_requests/1996>
2023-11-05 08:59:11 +00:00
Ondřej Pohořelský
88ce1f97b3 network: show details page when creating new connection
Resolves #2536

When creating new vpn/wired connection, the user doesn't have a choice
to change `Make available to other users` option. This commit adds it.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-control-center/-/merge_requests/1996>
2023-11-05 08:59:11 +00:00
Automeris naranja
0b17fff10b network-wifi: Fix wrong a11y label of the "Connect to Hidden Network" row
This a11y label of this row is "Show Saved Networks", which is wrong.
2023-11-05 08:26:59 +00:00
Felipe Borges
e95645187d wifi: Close "Saved Wi-Fi Networks" dialog on Escape key 2023-11-02 11:22:18 +01:00
Felipe Borges
8172f638e0 network: Show "Undo" toast when forgetting network in "Saved Wi-Fi Networks"
Fixes #2670
2023-11-02 11:22:18 +01:00
Automeris naranja
85d802c356 wifi-connection-row: Add a11y label to the forget network button 2023-11-02 11:22:18 +01:00