microphone/pyaudio_.py
def get_devices(self, device_type='all'):
        num_devices = self._pyaudio.get_device_count()
        self._logger.debug('Found %d PyAudio devices', num_devices)
        for i in range(num_devices):
            info = self._pyaudio.get_device_info_by_index(i)
            name = info['name']
            if name in self.devices:
                continue
            else:
                self.devices[name] = PyAudioDevice(self, info)

        return self.devices
        """
        if device_type == plugin.audioengine.DEVICE_TYPE_ALL:
            return devs
        else:
            return [device for device in devs if device_type in device.types]
        """
def get_devices(self, device_type='all'):
        num_devices = self._pyaudio.get_device_count()
        self._logger.debug('Found %d PyAudio devices', num_devices)
        for i in range(num_devices):
            info = self._pyaudio.get_device_info_by_index(i)
            name = info['name']
            if name in self.devices:
                continue
            else:
                self.devices[name] = PyAudioDevice(self, info)

        return self.devices
        """
        if device_type == plugin.audioengine.DEVICE_TYPE_ALL:
            return devs
        else:
            return [device for device in devs if device_type in device.types]
        """
def get_devices ( self , device_type = 'all' ) : num_devices = self . _pyaudio . get_device_count ( ) self . _logger . debug ( 'Found %d PyAudio devices' , num_devices ) for i in range ( num_devices ) : info = self . _pyaudio . get_device_info_by_index ( i ) name = info [ 'name' ] if name in self . devices : continue else : self . devices [ name ] = PyAudioDevice ( self , info ) return self . devices
if device_type == plugin.audioengine.DEVICE_TYPE_ALL:
            return devs
        else:
            return [device for device in devs if device_type in device.types]
if device_type == plugin . audioengine . DEVICE_TYPE_ALL : return devs else : return [ device for device in devs if device_type in device . types ]