[network-manager-applet] applet, libnm-gtk: ensure AP mode connections are treated as Hotspot too
- From: Dan Williams <dcbw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-applet] applet, libnm-gtk: ensure AP mode connections are treated as Hotspot too
- Date: Thu, 31 Jan 2013 17:16:39 +0000 (UTC)
commit acd6270f0ea11b9674061565b75e1ade10a53de2
Author: JÃrÃmy Lal <kapouer melix org>
Date: Thu Jan 31 11:15:13 2013 -0600
applet,libnm-gtk: ensure AP mode connections are treated as Hotspot too
For example, in the wifi dialog connection list and when building the
list of default options.
src/applet-device-wifi.c | 2 +-
src/libnm-gtk/nm-wifi-dialog.c | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/src/applet-device-wifi.c b/src/applet-device-wifi.c
index bd02592..fa3d618 100644
--- a/src/applet-device-wifi.c
+++ b/src/applet-device-wifi.c
@@ -1469,7 +1469,7 @@ wifi_dialog_response_cb (GtkDialog *foo,
s_wifi = nm_connection_get_setting_wireless (connection);
if (s_wifi)
mode = nm_setting_wireless_get_mode (s_wifi);
- if (g_strcmp0 (mode, "adhoc") == 0) {
+ if (g_strcmp0 (mode, "adhoc") == 0 || g_strcmp0 (mode, "ap") == 0) {
s_con = nm_connection_get_setting (connection, NM_TYPE_SETTING_CONNECTION);
if (!s_con) {
s_con = nm_setting_connection_new ();
diff --git a/src/libnm-gtk/nm-wifi-dialog.c b/src/libnm-gtk/nm-wifi-dialog.c
index c389455..8a98957 100644
--- a/src/libnm-gtk/nm-wifi-dialog.c
+++ b/src/libnm-gtk/nm-wifi-dialog.c
@@ -474,7 +474,7 @@ connection_combo_init (NMAWifiDialog *self, NMConnection *connection)
/* Ignore non-Ad-Hoc connections too */
mode = nm_setting_wireless_get_mode (s_wireless);
- if (!mode || strcmp (mode, "adhoc"))
+ if (!mode || (strcmp (mode, "adhoc") && strcmp (mode, "ap")))
continue;
}
@@ -853,7 +853,7 @@ security_combo_init (NMAWifiDialog *self, gboolean secrets_only)
s_wireless = nm_connection_get_setting_wireless (priv->connection);
mode = nm_setting_wireless_get_mode (s_wireless);
- if (mode && !strcmp (mode, "adhoc"))
+ if (mode && (!strcmp (mode, "adhoc") || !strcmp (mode, "ap")))
is_adhoc = TRUE;
wsec = nm_connection_get_setting_wireless_security (priv->connection);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]