From 6b7badf5696b246f09ae7f7d661b527f134e9004 Mon Sep 17 00:00:00 2001 From: Sean Robinson Date: Sun, 30 Mar 2014 08:52:37 -0700 Subject: [PATCH] Add add_profile method Signed-off-by: Sean Robinson --- wifiradar/gui/g2/__init__.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/wifiradar/gui/g2/__init__.py b/wifiradar/gui/g2/__init__.py index 643f3e8..012ead2 100644 --- a/wifiradar/gui/g2/__init__.py +++ b/wifiradar/gui/g2/__init__.py @@ -474,6 +474,21 @@ class RadarWindow: # get cooked strings from config file self.config.raw = False + def add_profile(self, profile): + """ Add :data:`profile` to the list of APs shown to the user. + """ + if profile['roaming']: + profile['bssid'] = ' Multiple APs' + + wep = None + if profile['encrypted']: + wep = gtk.STOCK_DIALOG_AUTHENTICATION + + self.pstore.append([profile['essid'], profile['bssid'], + self.known_profile_icon, profile['known'], profile['available'], + wep, self.signal_none_pb, profile['mode'], profile['protocol'], + profile['channel']]) + def create_new_profile(self, widget, profile, data=None): """ Respond to a request to create a new AP profile -- 2.11.4.GIT