Commit graph

654 commits

Author SHA1 Message Date
Georges Basile Stavracas Neto
4ac4f4a04e network: Make the history dialog use a headerbar
In order to start moving towards the new redesigned Network
panel [1], it is necessary to make the dialogs use a headerbar.

Currently, however, they don't, making the dialog sinconsistent
with the rest of the panels, and the GNOME desktop as a whole.

Fix that by setting the headerbar to the History dialog, and
adjusting the elements so hat they match the "Known Wi-Fi Networks"
dialog in the mockup [1].

[1] https://github.com/gnome-design-team/gnome-mockups/blob/master/system-settings/network/aday2/network-wires.png

https://bugzilla.gnome.org/show_bug.cgi?id=779841
2017-05-22 12:40:13 -03:00
Jonathan Kang
9cc065bb04 network: Update the hotspot dialog
Update the hotspot dialog according to the new redesigned Network
panel[1].

[1] https://github.com/gnome-design-team/gnome-mockups/blob/master/system-settings/network/aday2/network-wires.png

https://bugzilla.gnome.org/show_bug.cgi?id=779841
2017-05-22 12:28:32 -03:00
Georges Basile Stavracas Neto
fe2a21e696 network: Make connection editor dialog use a headerbar
In order to start moving towards the new redesigned connection
editor [1], it is necessary to make the dialog use a headerbar.

Currently, however, it doesn't, making the connection editor
dialog inconsistent with the rest of the panels, and the GNOME
desktop as a whole.

Fix that by exporting the buttons as action buttons, and setting
the use-header-bar property to TRUE.

[1] https://github.com/gnome-design-team/gnome-mockups/blob/master/system-settings/network/aday2/network-wires.png

https://bugzilla.gnome.org/show_bug.cgi?id=779841
2017-05-21 10:41:43 -03:00
Rui Matos
585b1fdd9c network: Remove remaining traces of firewalld zones support
These were overlooked in commit
b36924567e.
2017-05-18 18:57:26 +02:00
Benjamin Berg
2c95c6a5d0 network: Include the connection title in the sort string
The list of networks is sorted by connection type. If a user has e.g. a
lot of VPN connections, then the unsorted list is hard to browse.
To fix this, include the title of the connection in the sort order and
ensure the list is kept sorted when a title is changed.

Reported-by: Oliver Haessler <oliver@redhat.com>

https://bugzilla.gnome.org/show_bug.cgi?id=778685
2017-05-17 15:14:10 +02:00
Benjamin Berg
f70ac1d863 network: Re-render connection title whenever it changes
The title of network connections may change if the user edits it or if
it was changed programatically by another program. This worked fine, but
the UI was not updated. This patch ensures the network list in the UI is
updated.

Reported-by: Oliver Haessler <oliver@redhat.com>

https://bugzilla.gnome.org/show_bug.cgi?id=778685
2017-05-17 11:24:39 +02:00
Benjamin Berg
93fc508061 network: Remove unused "title" column from devices liststore
The title column is not used as the title is fetched from the net object
on the fly when it is needed.

https://bugzilla.gnome.org/show_bug.cgi?id=778685
2017-05-17 11:24:39 +02:00
Bastien Nocera
4ee2055027 network: Better debug when creating a hotspot 2017-05-05 19:05:45 +02:00
Bastien Nocera
87928a5d6f network: Add hotspot setup debug 2017-04-29 14:11:22 +02:00
Bastien Nocera
937a518889 network: Fix return value type
We're supposed to return a pointer to GBytes, not a boolean.
2017-04-27 19:44:05 +02:00
Jonathan Kang
bb8ca23701 network: Fix mobile broadband switch state
The switch was only reflecting the value of the WWAN killswitch instead
of both the WWAN killswitch and the state of the connection itself.

https://bugzilla.gnome.org/show_bug.cgi?id=690361
2017-04-13 15:51:51 +02:00
Bastien Nocera
b36924567e network: Remove support for firewalld zones
Firewalld is a Fedora-only daemon, and it doesn't integrate all that
well with Fedora Workstation, the version of Fedora that uses GNOME, so
remove the support.

In Fedora Workstation, firewalld only ever supports one zone, as the
other ones are badly defined, and not translatable or translated.
2017-04-13 10:23:39 +02:00
Bastien Nocera
6ab5552d59 network: Update wireless-security UI from network-manager-applet 2017-03-13 18:56:57 +01:00
Bastien Nocera
0470c040b1 network: Update wireless-security from network-manager-applet 2017-03-13 18:56:57 +01:00
Bastien Nocera
b4ac30b51e network: Simplify object destruction 2017-03-10 19:17:24 +01:00
Bastien Nocera
c7800dd22f network: Fix initial state of Wi-Fi device
This ensures that:
- the AP list shown on startup when the Hotspot is disabled on
  startup, or when disabling it at run-time
- the hotspot page is shown on startup when the Hotspot is enabled,
  or when it gets enabled at runtime

https://bugzilla.gnome.org/show_bug.cgi?id=705546
2017-03-10 19:17:19 +01:00
Bastien Nocera
7fbb1435a9 network: Remove use of temporary variable 2017-03-10 19:17:17 +01:00
Bastien Nocera
fe6e71198c network: Add checks for cancelled calls 2017-03-10 19:17:13 +01:00
Bastien Nocera
700e5e544c network: Save new SSID to disk before enabling the hotspot
Commit e824868 was supposed to do this, but needed to write the changes
out to disk before activating the hotspot.

https://bugzilla.gnome.org/show_bug.cgi?id=705546
2017-03-10 19:17:12 +01:00
Bastien Nocera
277ac7de02 network: Move hotspot connection search into a helper function
https://bugzilla.gnome.org/show_bug.cgi?id=705546
2017-03-10 19:17:08 +01:00
Michael Catanzaro
03ebd431b5 network: Fix missing page title on wired panel
The NetDeviceEthernet's title is not set until after the UI is created,
so we have to listen for changes to the title.

https://bugzilla.gnome.org/show_bug.cgi?id=776369
2017-01-04 08:49:45 -06:00
Andreas Henriksson
bb4b83360b network: drop unneeded null-check for ip4 address
The pointer has already been dereferenced. Might have made more sense
to check if it's the empty string and treat that as error, but
nm_utils_ipaddr_valid also returns error on empty string so lets just
rely on the utility function doing the right thing here.

https://bugzilla.gnome.org/show_bug.cgi?id=708500
2016-11-11 17:55:04 +01:00
Andreas Henriksson
898d0aa4e9 network: allow empty ip4 default gateway
Null-checking the text_gateway makes no sense as it has already been
dereferenced earlier. Instead check if it's the empty string and
treat that as not-an-error. Also prevent the empty string from
being set in default_gateway.

https://bugzilla.gnome.org/show_bug.cgi?id=708500
2016-11-11 17:55:04 +01:00
Piotr Drąg
eabc878192 network: use Unicode in translatable strings
See https://developer.gnome.org/hig/stable/typography.html

https://bugzilla.gnome.org/show_bug.cgi?id=772199
2016-10-03 15:20:47 +02:00
Piotr Drąg
d791e5b334 Disambiguate "Reset" string with context 2016-09-27 17:36:19 +02:00
Bastien Nocera
7dfc6a6c23 network: Fix application of the default gateway
Now that we ensured that only the first address has a gateway entry,
read it and apply it.

See https://bugzilla.gnome.org/show_bug.cgi?id=765969

https://bugzilla.gnome.org/show_bug.cgi?id=771515
2016-09-20 10:30:27 +02:00
Bastien Nocera
d28ffc9902 network: Fix gateway entry visibility
From https://bugzilla.gnome.org/show_bug.cgi?id=765969 as explained by
Dan Winship:
"
libnm-util/libnm-glib had a buggy data model, which nm-connection-editor
(and then gnome-control-center) copied, in which each manually-configured
IP address has an associated gateway address. In reality, NM always just
took the first non-empty gateway value from the address array, and
completely ignored any other gateway values.
libnm represents this more accurately, by having a single gateway
value which is separate from the address array. Ideally, the editors should
show it this way as well (eg, like nmtui does). Failing that, it would
be nice to at least make it so that only the first row in the address
table can have a non-empty gateway value.
"

We went for the second option, only showing a gateway entry for the
first address in the list.

This isn't related to route-specific gateway addresses.

https://bugzilla.gnome.org/show_bug.cgi?id=765969
2016-09-20 10:30:27 +02:00
Bastien Nocera
ab2b13cacd network: Fix compilation warnings
Those come from the fixes made in commits 981c354 and 7f601cf.

https://bugzilla.gnome.org/show_bug.cgi?id=771538
2016-09-20 10:30:27 +02:00
Bastien Nocera
da7be92093 network: Fix warning when opening IPv4 connection editor
https://bugzilla.gnome.org/show_bug.cgi?id=771515
2016-09-20 10:30:27 +02:00
Bastien Nocera
981c354ebb network: Fix crash entering IPv4 routes
The wrong destructor was used for a GPtrArray of NMIPRoute.

See https://bugzilla.gnome.org/show_bug.cgi?id=771251
See https://bugzilla.gnome.org/show_bug.cgi?id=771432
2016-09-14 17:18:32 +02:00
Bastien Nocera
7f601cfed4 network: Fix crash entering IPv4 Gateway
The wrong destructor was used for a GPtrArray of NMIPAddress.

https://bugzilla.gnome.org/show_bug.cgi?id=771432
2016-09-14 17:18:32 +02:00
Bastien Nocera
ca47ff295a network: Fix crash when changing IPv4 DNS
The dns_servers GStrv was not NULL-terminated because we forgot to
append a NULL item to the GPtrArray that we used to construct it.

https://bugzilla.gnome.org/show_bug.cgi?id=771251
2016-09-13 11:45:20 +02:00
Bastien Nocera
e824868976 network: Re-set the SSID when enabling the Hotspot
Instead of expecting the hostname to stay the same.

https://bugzilla.gnome.org/show_bug.cgi?id=705546
2016-08-30 17:17:27 +02:00
Bastien Nocera
2a6706fe4c network: Avoid setting a GError if already set
If the wireless security is invalid, don't try to set the GError if the
ad-hoc mode is invalid as well.

https://bugzilla.gnome.org/show_bug.cgi?id=769230
2016-08-30 17:15:33 +02:00
Bastien Nocera
b0329f8ef6 network: Return better error when 8021x security is invalid
Rather than the generic "Invalid 802.1x security".

https://bugzilla.gnome.org/show_bug.cgi?id=769230
2016-08-30 17:15:33 +02:00
Bastien Nocera
73a8d38946 network: Remove unused ->validate class implementations
The implementation of ->validate in the parent class will return TRUE if
there's no implementation in the child class, so no need to implement
those.

https://bugzilla.gnome.org/show_bug.cgi?id=769230
2016-08-30 17:15:33 +02:00
Bastien Nocera
a90dc605d6 network: Fix IPv6 settings not being applicable when method changes
When changing the method from Manual to Automatic, we need to clear the
gateway setting, otherwise the settings verification will fail:
ipv6.gateway: gateway cannot be set if there are no addresses configured

Another fallout of the libnm 1.2 port

https://bugzilla.gnome.org/show_bug.cgi?id=769230
2016-08-30 17:15:33 +02:00
Bastien Nocera
94e2be8ff6 network: Fix warning if IPv6 gateway is empty
GtkEntry doesn't like NULL text.

https://bugzilla.gnome.org/show_bug.cgi?id=769230
2016-08-30 17:15:33 +02:00
Bastien Nocera
dc14602e55 network: Fix saving of IPv6 gateway
https://bugzilla.gnome.org/show_bug.cgi?id=769230
2016-08-30 17:15:33 +02:00
Bastien Nocera
cdb6a6c682 network: Fix warning when enabling hotspot
GLib-GObject-WARNING **: g_object_set_valist: object class 'NMSettingWireless' has no property named 'security'

https://bugzilla.gnome.org/show_bug.cgi?id=769230
2016-08-30 17:15:33 +02:00
Bastien Nocera
c6f1b3a2be network: Simplify complete_connection_for_type()
Now that there's only one type to be added (VPNs).

https://bugzilla.gnome.org/show_bug.cgi?id=767614
2016-06-24 17:26:10 +02:00
Bastien Nocera
d0fcd5843c network: Remove the first page of the "Add Connection" wizard
We still offered to add Bond, Team, Bridge and VLAN connections even
though we don't support them any more. Remove the first page as we only
offer to add VPN connections.

https://bugzilla.gnome.org/show_bug.cgi?id=767614
2016-06-24 17:26:10 +02:00
Bastien Nocera
7adfaf1ed9 network: Fix VPN UI not showing up
The VPN editor API changed as well.

https://bugzilla.gnome.org/show_bug.cgi?id=767614
2016-06-24 17:26:10 +02:00
Bastien Nocera
2a7b19202b network: Fix crash creating a VPN
The listing of VPN plugins was done using the nm-glib API instead of the
new libnm 1.2 one.

https://bugzilla.gnome.org/show_bug.cgi?id=767614
2016-06-24 17:26:10 +02:00
Georges Basile Stavracas Neto
2777fd583d panels: use the new categories
Following the previous patch, this patch adds the new alternative
categories to the panels' Desktop files. These alternative categories
are only relevant for the alternative Shell, and do not break the
current Shell in any way.

https://bugzilla.gnome.org/show_bug.cgi?id=767301
2016-06-14 12:16:43 -03:00
Bastien Nocera
44c16fc6ff network: Use the correct type for the "ssid" property
Set the Hotspot SSID property correctly for libnm 1.2.
2016-06-10 17:21:40 +02:00
Bastien Nocera
e66941753b network: Fix hotspot silently failing with long hostname
By truncating the SSID to 32 bytes.

network-cc-panel-WARNING **: Failed to add new connection: (32) 802-11-wireless.ssid: SSID length is out of range <1-32> bytes

See https://bugzilla.redhat.com/show_bug.cgi?id=1309331
2016-06-10 17:10:35 +02:00
Bastien Nocera
8f359fbe5e network: Remember "Ignore CA certificate"
The CA certificate, when not needed, is saved somewhere in the same
GSettings schema used by nm-connection-editor.
2016-06-07 18:50:38 +02:00
Bastien Nocera
9d4800b5b2 network: Fix warning when BSSID is empty
libnm-CRITICAL **: _nm_utils_hwaddr_to_dbus: assertion 'len > 0 && len
<= NM_UTILS_HWADDR_LEN_MAX' failed
2016-06-07 18:50:38 +02:00
Bastien Nocera
8386631dcd network: Update wireless-security from network-manager-applet
To replace the WIP code that landed earlier.
2016-06-07 18:50:38 +02:00