network-manager-applet r754 - in trunk: . po src src/connection-editor src/utils
- From: dcbw svn gnome org
- To: svn-commits-list gnome org
- Subject: network-manager-applet r754 - in trunk: . po src src/connection-editor src/utils
- Date: Tue, 10 Jun 2008 17:04:48 +0000 (UTC)
Author: dcbw
Date: Tue Jun 10 17:04:47 2008
New Revision: 754
URL: http://svn.gnome.org/viewvc/network-manager-applet?rev=754&view=rev
Log:
2008-06-10 Dan Williams <dcbw redhat com>
Fix up for symbol renames for ethernet and wifi devices in libnm-glib
Added:
trunk/src/applet-device-wifi.c
- copied, changed from r752, /trunk/src/applet-device-wireless.c
trunk/src/applet-device-wifi.h
- copied, changed from r751, /trunk/src/applet-device-wireless.h
Removed:
trunk/src/applet-device-wireless.c
trunk/src/applet-device-wireless.h
Modified:
trunk/ChangeLog
trunk/po/POTFILES.in
trunk/src/Makefile.am
trunk/src/ap-menu-item.h
trunk/src/applet-device-wired.c
trunk/src/applet-dialogs.c
trunk/src/applet.c
trunk/src/applet.h
trunk/src/connection-editor/page-wireless-security.c
trunk/src/utils/utils.c
trunk/src/wireless-dialog.c
Modified: trunk/po/POTFILES.in
==============================================================================
--- trunk/po/POTFILES.in (original)
+++ trunk/po/POTFILES.in Tue Jun 10 17:04:47 2008
@@ -5,7 +5,7 @@
src/applet-device-cdma.c
src/applet-device-gsm.c
src/applet-device-wired.c
-src/applet-device-wireless.c
+src/applet-device-wifi.c
src/applet-dialogs.c
src/applet.c
src/applet.glade
Modified: trunk/src/Makefile.am
==============================================================================
--- trunk/src/Makefile.am (original)
+++ trunk/src/Makefile.am Tue Jun 10 17:04:47 2008
@@ -40,8 +40,8 @@
applet-dialogs.c \
applet-device-wired.h \
applet-device-wired.c \
- applet-device-wireless.h \
- applet-device-wireless.c \
+ applet-device-wifi.h \
+ applet-device-wifi.c \
ap-menu-item.h \
ap-menu-item.c \
applet-device-gsm.h \
Modified: trunk/src/ap-menu-item.h
==============================================================================
--- trunk/src/ap-menu-item.h (original)
+++ trunk/src/ap-menu-item.h Tue Jun 10 17:04:47 2008
@@ -30,8 +30,6 @@
#include "applet.h"
#include "nm-access-point.h"
-#include <nm-device-802-11-wireless.h>
-
#define NM_TYPE_NETWORK_MENU_ITEM (nm_network_menu_item_get_type ())
#define NM_NETWORK_MENU_ITEM(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), NM_TYPE_NETWORK_MENU_ITEM, NMNetworkMenuItem))
#define NM_NETWORK_MENU_ITEM_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), NM_TYPE_NETWORK_MENU_ITEM, NMNetworkMenuItemClass))
Copied: trunk/src/applet-device-wifi.c (from r752, /trunk/src/applet-device-wireless.c)
==============================================================================
--- /trunk/src/applet-device-wireless.c (original)
+++ trunk/src/applet-device-wifi.c Tue Jun 10 17:04:47 2008
@@ -40,12 +40,12 @@
#include <nm-access-point.h>
#include <nm-setting-connection.h>
#include <nm-setting-wireless.h>
-#include <nm-device-802-11-wireless.h>
+#include <nm-device-wifi.h>
#include <nm-setting-8021x.h>
#include <nm-utils.h>
#include "applet.h"
-#include "applet-device-wireless.h"
+#include "applet-device-wifi.h"
#include "ap-menu-item.h"
#include "utils.h"
#include "gnome-keyring-md5.h"
@@ -124,7 +124,7 @@
typedef struct {
NMApplet *applet;
- NMDevice80211Wireless *device;
+ NMDeviceWifi *device;
NMAccessPoint *ap;
NMConnection *connection;
} WirelessMenuItemInfo;
@@ -240,7 +240,7 @@
/* WPA2 PSK first */
if ( (rsn_flags & NM_802_11_AP_SEC_KEY_MGMT_PSK)
- && (dev_caps & NM_802_11_DEVICE_CAP_RSN)) {
+ && (dev_caps & NM_WIFI_DEVICE_CAP_RSN)) {
sec->key_mgmt = g_strdup ("wpa-psk");
sec->proto = g_slist_append (sec->proto, g_strdup ("rsn"));
sec->pairwise = add_ciphers_from_flags (rsn_flags, TRUE);
@@ -250,7 +250,7 @@
/* WPA PSK */
if ( (wpa_flags & NM_802_11_AP_SEC_KEY_MGMT_PSK)
- && (dev_caps & NM_802_11_DEVICE_CAP_WPA)) {
+ && (dev_caps & NM_WIFI_DEVICE_CAP_WPA)) {
sec->key_mgmt = g_strdup ("wpa-psk");
sec->proto = g_slist_append (sec->proto, g_strdup ("wpa"));
sec->pairwise = add_ciphers_from_flags (wpa_flags, TRUE);
@@ -260,7 +260,7 @@
/* WPA2 Enterprise */
if ( (rsn_flags & NM_802_11_AP_SEC_KEY_MGMT_802_1X)
- && (dev_caps & NM_802_11_DEVICE_CAP_RSN)) {
+ && (dev_caps & NM_WIFI_DEVICE_CAP_RSN)) {
sec->key_mgmt = g_strdup ("wpa-eap");
sec->proto = g_slist_append (sec->proto, g_strdup ("rsn"));
sec->pairwise = add_ciphers_from_flags (rsn_flags, TRUE);
@@ -274,7 +274,7 @@
/* WPA Enterprise */
if ( (wpa_flags & NM_802_11_AP_SEC_KEY_MGMT_802_1X)
- && (dev_caps & NM_802_11_DEVICE_CAP_WPA)) {
+ && (dev_caps & NM_WIFI_DEVICE_CAP_WPA)) {
sec->key_mgmt = g_strdup ("wpa-eap");
sec->proto = g_slist_append (sec->proto, g_strdup ("wpa"));
sec->pairwise = add_ciphers_from_flags (wpa_flags, TRUE);
@@ -330,7 +330,7 @@
else
g_assert_not_reached ();
- dev_caps = nm_device_802_11_wireless_get_capabilities (NM_DEVICE_802_11_WIRELESS (device));
+ dev_caps = nm_device_wifi_get_capabilities (NM_DEVICE_WIFI (device));
s_wireless_sec = get_security_for_ap (info->ap, dev_caps, &supported, &s_8021x);
if (!supported) {
g_object_unref (s_wireless);
@@ -413,7 +413,7 @@
}
static GSList *
-filter_connections_for_access_point (GSList *connections, NMDevice80211Wireless *device, NMAccessPoint *ap)
+filter_connections_for_access_point (GSList *connections, NMDeviceWifi *device, NMAccessPoint *ap)
{
GSList *ap_connections = NULL;
GSList *iter;
@@ -428,7 +428,7 @@
}
static NMNetworkMenuItem *
-add_new_ap_item (NMDevice80211Wireless *device,
+add_new_ap_item (NMDeviceWifi *device,
NMAccessPoint *ap,
struct dup_data *dup_data,
NMAccessPoint *active_ap,
@@ -521,7 +521,7 @@
}
static void
-add_one_ap_menu_item (NMDevice80211Wireless *device,
+add_one_ap_menu_item (NMDeviceWifi *device,
NMAccessPoint *ap,
GSList *connections,
NMAccessPoint *active_ap,
@@ -634,7 +634,7 @@
GtkWidget *menu,
NMApplet *applet)
{
- NMDevice80211Wireless *wdev;
+ NMDeviceWifi *wdev;
char *text;
GtkWidget *item;
const GPtrArray *aps;
@@ -644,8 +644,8 @@
GtkWidget *label;
char *bold_text;
- wdev = NM_DEVICE_802_11_WIRELESS (device);
- aps = nm_device_802_11_wireless_get_access_points (wdev);
+ wdev = NM_DEVICE_WIFI (device);
+ aps = nm_device_wifi_get_access_points (wdev);
all = applet_get_all_connections (applet);
connections = utils_filter_connections_for_device (device, all);
@@ -697,7 +697,7 @@
goto out;
}
- active_ap = nm_device_802_11_wireless_get_active_access_point (wdev);
+ active_ap = nm_device_wifi_get_active_access_point (wdev);
/* Add all networks in our network list to the menu */
for (i = 0; aps && (i < aps->len); i++)
@@ -760,7 +760,7 @@
}
static void
-notify_active_ap_changed_cb (NMDevice80211Wireless *device,
+notify_active_ap_changed_cb (NMDeviceWifi *device,
GParamSpec *pspec,
NMApplet *applet)
{
@@ -773,7 +773,7 @@
if (nm_device_get_state (NM_DEVICE (device)) != NM_DEVICE_STATE_ACTIVATED)
return;
- ap = nm_device_802_11_wireless_get_active_access_point (device);
+ ap = nm_device_wifi_get_active_access_point (device);
if (!ap)
return;
@@ -905,7 +905,7 @@
struct ap_notification_data
{
NMApplet *applet;
- NMDevice80211Wireless *device;
+ NMDeviceWifi *device;
guint id;
gulong last_notification_time;
};
@@ -920,7 +920,7 @@
{
struct ap_notification_data *data = datap;
NMApplet *applet = data->applet;
- NMDevice80211Wireless *device = data->device;
+ NMDeviceWifi *device = data->device;
int i;
const GPtrArray *aps;
GSList *all_connections;
@@ -944,7 +944,7 @@
g_slist_free (all_connections);
all_connections = NULL;
- aps = nm_device_802_11_wireless_get_access_points (device);
+ aps = nm_device_wifi_get_access_points (device);
for (i = 0; aps && (i < aps->len); i++) {
NMAccessPoint *ap = aps->pdata[i];
GSList *ap_connections = filter_connections_for_access_point (connections, device, ap);
@@ -1006,7 +1006,7 @@
}
static void
-access_point_added_cb (NMDevice80211Wireless *device,
+access_point_added_cb (NMDeviceWifi *device,
NMAccessPoint *ap,
gpointer user_data)
{
@@ -1031,13 +1031,13 @@
static void
wireless_device_added (NMDevice *device, NMApplet *applet)
{
- NMDevice80211Wireless *wdev = NM_DEVICE_802_11_WIRELESS (device);
+ NMDeviceWifi *wdev = NM_DEVICE_WIFI (device);
const GPtrArray *aps;
int i;
struct ap_notification_data *data;
g_signal_connect (wdev,
- "notify::" NM_DEVICE_802_11_WIRELESS_ACTIVE_ACCESS_POINT,
+ "notify::" NM_DEVICE_WIFI_ACTIVE_ACCESS_POINT,
G_CALLBACK (notify_active_ap_changed_cb),
applet);
@@ -1062,7 +1062,7 @@
queue_avail_access_point_notification (device);
/* Hash all APs this device knows about */
- aps = nm_device_802_11_wireless_get_access_points (wdev);
+ aps = nm_device_wifi_get_access_points (wdev);
for (i = 0; aps && (i < aps->len); i++)
add_hash_to_ap (g_ptr_array_index (aps, i));
}
@@ -1088,7 +1088,7 @@
state == NM_DEVICE_STATE_IP_CONFIG ||
state == NM_DEVICE_STATE_NEED_AUTH ||
state == NM_DEVICE_STATE_ACTIVATED) {
- ap = nm_device_802_11_wireless_get_active_access_point (NM_DEVICE_802_11_WIRELESS (device));
+ ap = nm_device_wifi_get_active_access_point (NM_DEVICE_WIFI (device));
}
if (!ap || (ap != applet->current_ap)) {
@@ -1554,8 +1554,7 @@
GtkWidget *dialog;
g_assert (specific_object);
- ap = nm_device_802_11_wireless_get_access_point_by_path (NM_DEVICE_802_11_WIRELESS (device),
- specific_object);
+ ap = nm_device_wifi_get_access_point_by_path (NM_DEVICE_WIFI (device), specific_object);
dialog = nma_wireless_dialog_new (applet, connection, device, ap);
if (!dialog) {
@@ -1581,7 +1580,7 @@
}
NMADeviceClass *
-applet_device_wireless_get_class (NMApplet *applet)
+applet_device_wifi_get_class (NMApplet *applet)
{
NMADeviceClass *dclass;
Copied: trunk/src/applet-device-wifi.h (from r751, /trunk/src/applet-device-wireless.h)
==============================================================================
--- /trunk/src/applet-device-wireless.h (original)
+++ trunk/src/applet-device-wifi.h Tue Jun 10 17:04:47 2008
@@ -19,16 +19,16 @@
* (C) Copyright 2008 Red Hat, Inc.
*/
-#ifndef __APPLET_DEVICE_WIRELESS_H__
-#define __APPLET_DEVICE_WIRELESS_H__
+#ifndef __APPLET_DEVICE_WIFI_H__
+#define __APPLET_DEVICE_WIFI_H__
#include <gtk/gtkwidget.h>
#include "applet.h"
-NMADeviceClass *applet_device_wireless_get_class (NMApplet *applet);
+NMADeviceClass *applet_device_wifi_get_class (NMApplet *applet);
void nma_menu_add_other_network_item (GtkWidget *menu, NMApplet *applet);
void nma_menu_add_create_network_item (GtkWidget *menu, NMApplet *applet);
-#endif /* __APPLET_DEVICE_WIRELESS_H__ */
+#endif /* __APPLET_DEVICE_WIFI_H__ */
Modified: trunk/src/applet-device-wired.c
==============================================================================
--- trunk/src/applet-device-wired.c (original)
+++ trunk/src/applet-device-wired.c Tue Jun 10 17:04:47 2008
@@ -35,7 +35,7 @@
#include <nm-setting-wired.h>
#include <nm-setting-8021x.h>
#include <nm-setting-pppoe.h>
-#include <nm-device-802-3-ethernet.h>
+#include <nm-device-ethernet.h>
#include "applet.h"
#include "applet-device-wired.h"
@@ -204,7 +204,7 @@
* we know it doesn't have a link.
*/
if (nm_device_get_capabilities (device) & NM_DEVICE_CAP_CARRIER_DETECT)
- carrier = nm_device_802_3_ethernet_get_carrier (NM_DEVICE_802_3_ETHERNET (device));
+ carrier = nm_device_ethernet_get_carrier (NM_DEVICE_ETHERNET (device));
label = gtk_bin_get_child (GTK_BIN (item));
bold_text = g_markup_printf_escaped ("<span weight=\"bold\">%s</span>",
Modified: trunk/src/applet-dialogs.c
==============================================================================
--- trunk/src/applet-dialogs.c (original)
+++ trunk/src/applet-dialogs.c Tue Jun 10 17:04:47 2008
@@ -24,8 +24,8 @@
#include <sys/socket.h>
#include <arpa/inet.h>
-#include <nm-device-802-3-ethernet.h>
-#include <nm-device-802-11-wireless.h>
+#include <nm-device-ethernet.h>
+#include <nm-device-wifi.h>
#include <nm-gsm-device.h>
#include <nm-cdma-device.h>
@@ -245,9 +245,9 @@
/* Interface */
iface = nm_device_get_iface (device);
- if (NM_IS_DEVICE_802_3_ETHERNET (device))
+ if (NM_IS_DEVICE_ETHERNET (device))
str = g_strdup_printf (_("Ethernet (%s)"), iface);
- else if (NM_IS_DEVICE_802_11_WIRELESS (device))
+ else if (NM_IS_DEVICE_WIFI (device))
str = g_strdup_printf (_("802.11 WiFi (%s)"), iface);
else if (NM_IS_GSM_DEVICE (device))
str = g_strdup_printf (_("GSM (%s)"), iface);
@@ -267,10 +267,10 @@
/* Hardware address */
str = NULL;
- if (NM_IS_DEVICE_802_3_ETHERNET (device))
- str = g_strdup (nm_device_802_3_ethernet_get_hw_address (NM_DEVICE_802_3_ETHERNET (device)));
- else if (NM_IS_DEVICE_802_11_WIRELESS (device))
- str = g_strdup (nm_device_802_11_wireless_get_hw_address (NM_DEVICE_802_11_WIRELESS (device)));
+ if (NM_IS_DEVICE_ETHERNET (device))
+ str = g_strdup (nm_device_ethernet_get_hw_address (NM_DEVICE_ETHERNET (device)));
+ else if (NM_IS_DEVICE_WIFI (device))
+ str = g_strdup (nm_device_wifi_get_hw_address (NM_DEVICE_WIFI (device)));
gtk_table_attach_defaults (table,
create_info_label (_("Hardware Address:")),
@@ -292,12 +292,12 @@
/* Speed */
speed = 0;
- if (NM_IS_DEVICE_802_3_ETHERNET (device)) {
+ if (NM_IS_DEVICE_ETHERNET (device)) {
/* Wired speed in Mb/s */
- speed = nm_device_802_3_ethernet_get_speed (NM_DEVICE_802_3_ETHERNET (device));
- } else if (NM_IS_DEVICE_802_11_WIRELESS (device)) {
+ speed = nm_device_ethernet_get_speed (NM_DEVICE_ETHERNET (device));
+ } else if (NM_IS_DEVICE_WIFI (device)) {
/* Wireless speed in Kb/s */
- speed = nm_device_802_11_wireless_get_bitrate (NM_DEVICE_802_11_WIRELESS (device));
+ speed = nm_device_wifi_get_bitrate (NM_DEVICE_WIFI (device));
speed /= 1000;
}
Modified: trunk/src/applet.c
==============================================================================
--- trunk/src/applet.c (original)
+++ trunk/src/applet.c Tue Jun 10 17:04:47 2008
@@ -40,8 +40,8 @@
#include <sys/socket.h>
#include <NetworkManagerVPN.h>
-#include <nm-device-802-3-ethernet.h>
-#include <nm-device-802-11-wireless.h>
+#include <nm-device-ethernet.h>
+#include <nm-device-wifi.h>
#include <nm-gsm-device.h>
#include <nm-cdma-device.h>
#include <nm-utils.h>
@@ -61,7 +61,7 @@
#include "applet.h"
#include "applet-device-wired.h"
-#include "applet-device-wireless.h"
+#include "applet-device-wifi.h"
#include "applet-device-gsm.h"
#include "applet-device-cdma.h"
#include "applet-dialogs.h"
@@ -105,20 +105,20 @@
continue;
}
- if (NM_IS_DEVICE_802_11_WIRELESS (best_dev)) {
- if (NM_IS_DEVICE_802_3_ETHERNET (candidate)) {
+ if (NM_IS_DEVICE_WIFI (best_dev)) {
+ if (NM_IS_DEVICE_ETHERNET (candidate)) {
best_dev = candidate_dev;
best = candidate;
}
} else if (NM_IS_CDMA_DEVICE (best_dev)) {
- if ( NM_IS_DEVICE_802_3_ETHERNET (candidate)
- || NM_IS_DEVICE_802_11_WIRELESS (candidate)) {
+ if ( NM_IS_DEVICE_ETHERNET (candidate)
+ || NM_IS_DEVICE_WIFI (candidate)) {
best_dev = candidate_dev;
best = candidate;
}
} else if (NM_IS_GSM_DEVICE (best_dev)) {
- if ( NM_IS_DEVICE_802_3_ETHERNET (candidate)
- || NM_IS_DEVICE_802_11_WIRELESS (candidate)
+ if ( NM_IS_DEVICE_ETHERNET (candidate)
+ || NM_IS_DEVICE_WIFI (candidate)
|| NM_IS_CDMA_DEVICE (candidate)) {
best_dev = candidate_dev;
best = candidate;
@@ -309,10 +309,10 @@
g_return_val_if_fail (device != NULL, NULL);
g_return_val_if_fail (applet != NULL, NULL);
- if (NM_IS_DEVICE_802_3_ETHERNET (device))
+ if (NM_IS_DEVICE_ETHERNET (device))
return applet->wired_class;
- else if (NM_IS_DEVICE_802_11_WIRELESS (device))
- return applet->wireless_class;
+ else if (NM_IS_DEVICE_WIFI (device))
+ return applet->wifi_class;
else if (NM_IS_GSM_DEVICE (device))
return applet->gsm_class;
else if (NM_IS_CDMA_DEVICE (device))
@@ -854,19 +854,19 @@
return strcmp (aa_desc, bb_desc);
}
- if (aa_type == NM_TYPE_DEVICE_802_3_ETHERNET && bb_type == NM_TYPE_DEVICE_802_11_WIRELESS)
+ if (aa_type == NM_TYPE_DEVICE_ETHERNET && bb_type == NM_TYPE_DEVICE_WIFI)
return -1;
- if (aa_type == NM_TYPE_DEVICE_802_3_ETHERNET && bb_type == NM_TYPE_GSM_DEVICE)
+ if (aa_type == NM_TYPE_DEVICE_ETHERNET && bb_type == NM_TYPE_GSM_DEVICE)
return -1;
- if (aa_type == NM_TYPE_DEVICE_802_3_ETHERNET && bb_type == NM_TYPE_CDMA_DEVICE)
+ if (aa_type == NM_TYPE_DEVICE_ETHERNET && bb_type == NM_TYPE_CDMA_DEVICE)
return -1;
if (aa_type == NM_TYPE_GSM_DEVICE && bb_type == NM_TYPE_CDMA_DEVICE)
return -1;
- if (aa_type == NM_TYPE_GSM_DEVICE && bb_type == NM_TYPE_DEVICE_802_11_WIRELESS)
+ if (aa_type == NM_TYPE_GSM_DEVICE && bb_type == NM_TYPE_DEVICE_WIFI)
return -1;
- if (aa_type == NM_TYPE_CDMA_DEVICE && bb_type == NM_TYPE_DEVICE_802_11_WIRELESS)
+ if (aa_type == NM_TYPE_CDMA_DEVICE && bb_type == NM_TYPE_DEVICE_WIFI)
return -1;
return 1;
@@ -959,12 +959,12 @@
if (!(nm_device_get_capabilities (device) & NM_DEVICE_CAP_NM_SUPPORTED))
continue;
- if (NM_IS_DEVICE_802_11_WIRELESS (device)) {
+ if (NM_IS_DEVICE_WIFI (device)) {
if ( nm_client_wireless_get_enabled (applet->nm_client)
&& (nm_device_get_state (device) >= NM_DEVICE_STATE_DISCONNECTED)) {
n_wireless_devices++;
}
- } else if (NM_IS_DEVICE_802_3_ETHERNET (device))
+ } else if (NM_IS_DEVICE_ETHERNET (device))
n_wired_devices++;
else if (NM_IS_CDMA_DEVICE (device))
n_cdma_devices++;
@@ -988,9 +988,9 @@
if (!(nm_device_get_capabilities (device) & NM_DEVICE_CAP_NM_SUPPORTED))
continue;
- if (NM_IS_DEVICE_802_11_WIRELESS (device))
+ if (NM_IS_DEVICE_WIFI (device))
n_devices = n_wireless_devices;
- else if (NM_IS_DEVICE_802_3_ETHERNET (device))
+ else if (NM_IS_DEVICE_ETHERNET (device))
n_devices = n_wired_devices;
else if (NM_IS_CDMA_DEVICE (device))
n_devices = n_cdma_devices;
@@ -1267,7 +1267,7 @@
devices = nm_client_get_devices (applet->nm_client);
for (i = 0; devices && (i < devices->len); i++) {
- if (NM_IS_DEVICE_802_11_WIRELESS (g_ptr_array_index (devices, i))) {
+ if (NM_IS_DEVICE_WIFI (g_ptr_array_index (devices, i))) {
have_wireless = TRUE;
break;
}
@@ -2238,8 +2238,8 @@
applet->wired_class = applet_device_wired_get_class (applet);
g_assert (applet->wired_class);
- applet->wireless_class = applet_device_wireless_get_class (applet);
- g_assert (applet->wireless_class);
+ applet->wifi_class = applet_device_wifi_get_class (applet);
+ g_assert (applet->wifi_class);
applet->gsm_class = applet_device_gsm_get_class (applet);
g_assert (applet->gsm_class);
@@ -2268,7 +2268,7 @@
g_source_remove (applet->update_timestamps_id);
g_slice_free (NMADeviceClass, applet->wired_class);
- g_slice_free (NMADeviceClass, applet->wireless_class);
+ g_slice_free (NMADeviceClass, applet->wifi_class);
g_slice_free (NMADeviceClass, applet->gsm_class);
if (applet->update_icon_id)
Modified: trunk/src/applet.h
==============================================================================
--- trunk/src/applet.h (original)
+++ trunk/src/applet.h Tue Jun 10 17:04:47 2008
@@ -92,7 +92,7 @@
/* Device classes */
NMADeviceClass *wired_class;
- NMADeviceClass *wireless_class;
+ NMADeviceClass *wifi_class;
NMADeviceClass *gsm_class;
NMADeviceClass *cdma_class;
Modified: trunk/src/connection-editor/page-wireless-security.c
==============================================================================
--- trunk/src/connection-editor/page-wireless-security.c (original)
+++ trunk/src/connection-editor/page-wireless-security.c Tue Jun 10 17:04:47 2008
@@ -219,12 +219,12 @@
combo = GTK_COMBO_BOX (glade_xml_get_widget (parent->xml, "wireless_security_combo"));
- dev_caps = NM_802_11_DEVICE_CAP_CIPHER_WEP40
- | NM_802_11_DEVICE_CAP_CIPHER_WEP104
- | NM_802_11_DEVICE_CAP_CIPHER_TKIP
- | NM_802_11_DEVICE_CAP_CIPHER_CCMP
- | NM_802_11_DEVICE_CAP_WPA
- | NM_802_11_DEVICE_CAP_RSN;
+ dev_caps = NM_WIFI_DEVICE_CAP_CIPHER_WEP40
+ | NM_WIFI_DEVICE_CAP_CIPHER_WEP104
+ | NM_WIFI_DEVICE_CAP_CIPHER_TKIP
+ | NM_WIFI_DEVICE_CAP_CIPHER_CCMP
+ | NM_WIFI_DEVICE_CAP_WPA
+ | NM_WIFI_DEVICE_CAP_RSN;
if (s_wireless->mode && !strcmp (s_wireless->mode, "adhoc"))
is_adhoc = TRUE;
Modified: trunk/src/utils/utils.c
==============================================================================
--- trunk/src/utils/utils.c (original)
+++ trunk/src/utils/utils.c Tue Jun 10 17:04:47 2008
@@ -25,8 +25,8 @@
#include <netinet/ether.h>
#include <glib.h>
-#include <nm-device-802-3-ethernet.h>
-#include <nm-device-802-11-wireless.h>
+#include <nm-device-ethernet.h>
+#include <nm-device-wifi.h>
#include <nm-gsm-device.h>
#include <nm-cdma-device.h>
#include <nm-access-point.h>
@@ -495,7 +495,7 @@
NMDevice *device,
gpointer specific_object)
{
- NMDevice8023Ethernet *ethdev = NM_DEVICE_802_3_ETHERNET (device);
+ NMDeviceEthernet *ethdev = NM_DEVICE_ETHERNET (device);
NMSettingWired *s_wired;
const char *str_mac;
struct ether_addr *bin_mac;
@@ -516,7 +516,7 @@
if (!s_wired->mac_address)
return TRUE;
- str_mac = nm_device_802_3_ethernet_get_hw_address (ethdev);
+ str_mac = nm_device_ethernet_get_hw_address (ethdev);
g_return_val_if_fail (str_mac != NULL, FALSE);
bin_mac = ether_aton (str_mac);
@@ -535,7 +535,7 @@
NMDevice *device,
gpointer specific_object)
{
- NMDevice80211Wireless *wdev = NM_DEVICE_802_11_WIRELESS (device);
+ NMDeviceWifi *wdev = NM_DEVICE_WIFI (device);
NMSettingWireless *s_wireless;
NMSettingWirelessSecurity *s_wireless_sec;
guint32 wcaps;
@@ -552,7 +552,7 @@
const char *str_mac;
struct ether_addr *bin_mac;
- str_mac = nm_device_802_11_wireless_get_hw_address (wdev);
+ str_mac = nm_device_wifi_get_hw_address (wdev);
g_return_val_if_fail (str_mac != NULL, FALSE);
bin_mac = ether_aton (str_mac);
@@ -587,29 +587,29 @@
return TRUE;
/* Match security with device capabilities */
- wcaps = nm_device_802_11_wireless_get_capabilities (wdev);
+ wcaps = nm_device_wifi_get_capabilities (wdev);
/* At this point, the device better have basic WPA support. */
- if ( !(wcaps & NM_802_11_DEVICE_CAP_WPA)
- || !(wcaps & NM_802_11_DEVICE_CAP_CIPHER_TKIP))
+ if ( !(wcaps & NM_WIFI_DEVICE_CAP_WPA)
+ || !(wcaps & NM_WIFI_DEVICE_CAP_CIPHER_TKIP))
return FALSE;
/* Check for only RSN */
if ( (g_slist_length (s_wireless_sec->proto) == 1)
&& !strcmp (s_wireless_sec->proto->data, "rsn")
- && !(wcaps & NM_802_11_DEVICE_CAP_RSN))
+ && !(wcaps & NM_WIFI_DEVICE_CAP_RSN))
return FALSE;
/* Check for only pairwise CCMP */
if ( (g_slist_length (s_wireless_sec->pairwise) == 1)
&& !strcmp (s_wireless_sec->pairwise->data, "ccmp")
- && !(wcaps & NM_802_11_DEVICE_CAP_CIPHER_CCMP))
+ && !(wcaps & NM_WIFI_DEVICE_CAP_CIPHER_CCMP))
return FALSE;
/* Check for only group CCMP */
if ( (g_slist_length (s_wireless_sec->group) == 1)
&& !strcmp (s_wireless_sec->group->data, "ccmp")
- && !(wcaps & NM_802_11_DEVICE_CAP_CIPHER_CCMP))
+ && !(wcaps & NM_WIFI_DEVICE_CAP_CIPHER_CCMP))
return FALSE;
return TRUE;
@@ -663,9 +663,9 @@
g_return_val_if_fail (s_con != NULL, FALSE);
g_return_val_if_fail (s_con->type != NULL, FALSE);
- if (NM_IS_DEVICE_802_3_ETHERNET (device))
+ if (NM_IS_DEVICE_ETHERNET (device))
return connection_valid_for_wired (connection, s_con, device, specific_object);
- else if (NM_IS_DEVICE_802_11_WIRELESS (device))
+ else if (NM_IS_DEVICE_WIFI (device))
return connection_valid_for_wireless (connection, s_con, device, specific_object);
else if (NM_IS_GSM_DEVICE (device))
return connection_valid_for_gsm (connection, s_con, device, specific_object);
Modified: trunk/src/wireless-dialog.c
==============================================================================
--- trunk/src/wireless-dialog.c (original)
+++ trunk/src/wireless-dialog.c Tue Jun 10 17:04:47 2008
@@ -33,7 +33,7 @@
#include <nm-client.h>
#include <nm-utils.h>
-#include <nm-device-802-11-wireless.h>
+#include <nm-device-wifi.h>
#include <nm-setting-connection.h>
#include <nm-setting-wireless.h>
#include <nm-setting-ip4-config.h>
@@ -444,7 +444,7 @@
if (s_wireless->mac_address) {
const char *hw_addr;
- hw_addr = nm_device_802_11_wireless_get_hw_address (NM_DEVICE_802_11_WIRELESS (priv->device));
+ hw_addr = nm_device_wifi_get_hw_address (NM_DEVICE_WIFI (priv->device));
if (hw_addr) {
struct ether_addr *ether;
@@ -552,7 +552,7 @@
if (!(nm_device_get_capabilities (device) & NM_DEVICE_CAP_NM_SUPPORTED))
return FALSE;
- if (!NM_IS_DEVICE_802_11_WIRELESS (device))
+ if (!NM_IS_DEVICE_WIFI (device))
return FALSE;
if (nm_device_get_state (device) < NM_DEVICE_STATE_DISCONNECTED)
@@ -701,7 +701,7 @@
* If a connection is given, that connection's options should be selected
* by default.
*/
- dev_caps = nm_device_802_11_wireless_get_capabilities (NM_DEVICE_802_11_WIRELESS (priv->device));
+ dev_caps = nm_device_wifi_get_capabilities (NM_DEVICE_WIFI (priv->device));
if (priv->ap != NULL) {
ap_flags = nm_access_point_get_flags (priv->ap);
ap_wpa = nm_access_point_get_wpa_flags (priv->ap);
@@ -739,7 +739,7 @@
* even though technically it's possible to have this configuration.
*/
if ( nm_utils_security_valid (NMU_SEC_STATIC_WEP, dev_caps, !!priv->ap, is_adhoc, ap_flags, ap_wpa, ap_rsn)
- && ((!ap_wpa && !ap_rsn) || !(dev_caps & (NM_802_11_DEVICE_CAP_WPA | NM_802_11_DEVICE_CAP_RSN)))) {
+ && ((!ap_wpa && !ap_rsn) || !(dev_caps & (NM_WIFI_DEVICE_CAP_WPA | NM_WIFI_DEVICE_CAP_RSN)))) {
WirelessSecurityWEPKey *ws_wep;
WEPKeyType default_wep_type = WEP_KEY_TYPE_PASSPHRASE;
@@ -778,7 +778,7 @@
* even though technically it's possible to have this configuration.
*/
if ( nm_utils_security_valid (NMU_SEC_LEAP, dev_caps, !!priv->ap, is_adhoc, ap_flags, ap_wpa, ap_rsn)
- && ((!ap_wpa && !ap_rsn) || !(dev_caps & (NM_802_11_DEVICE_CAP_WPA | NM_802_11_DEVICE_CAP_RSN)))) {
+ && ((!ap_wpa && !ap_rsn) || !(dev_caps & (NM_WIFI_DEVICE_CAP_WPA | NM_WIFI_DEVICE_CAP_RSN)))) {
WirelessSecurityLEAP *ws_leap;
ws_leap = ws_leap_new (priv->glade_file, priv->connection, connection_id);
@@ -1041,7 +1041,7 @@
/* Ensure device validity */
dev_caps = nm_device_get_capabilities (device);
g_return_val_if_fail (dev_caps & NM_DEVICE_CAP_NM_SUPPORTED, NULL);
- g_return_val_if_fail (NM_IS_DEVICE_802_11_WIRELESS (device), NULL);
+ g_return_val_if_fail (NM_IS_DEVICE_WIFI (device), NULL);
self = NMA_WIRELESS_DIALOG (g_object_new (NMA_TYPE_WIRELESS_DIALOG, NULL));
if (!self)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]