From f10768f8b0673270e63f47943632d955959beca9 Mon Sep 17 00:00:00 2001 From: cuu Date: Mon, 17 Dec 2018 16:32:10 +0800 Subject: [PATCH] bluetooth GenNetworkList skip mac address --- Menu/GameShell/10_Settings/Bluetooth/__init__.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Menu/GameShell/10_Settings/Bluetooth/__init__.py b/Menu/GameShell/10_Settings/Bluetooth/__init__.py index 2f183c9..0de9b71 100644 --- a/Menu/GameShell/10_Settings/Bluetooth/__init__.py +++ b/Menu/GameShell/10_Settings/Bluetooth/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- - +import re import pygame #import math import commands @@ -568,6 +568,10 @@ class BluetoothPage(Page): if "Name" in self._Devices[v]: if len(self._Devices[v]["Name"]) < 2: continue + if re.match("[0-9a-f]{2}([-:]?)[0-9a-f]{2}(\\1[0-9a-f]{2}){4}$", self._Devices[v]["Name"].lower()): + continue + else: + continue ni = NetItem() ni._Parent = self