From 6678af3a25583550fbc2a99510db1b6be983c6fc Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 7 Dec 2009 10:25:25 -0700 Subject: [PATCH] ... --- src/calibre/debug.py | 2 +- src/calibre/devices/nook/driver.py | 1 + src/calibre/gui2/device.py | 5 +++-- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/calibre/debug.py b/src/calibre/debug.py index 9c0151a748..799a67f31b 100644 --- a/src/calibre/debug.py +++ b/src/calibre/debug.py @@ -98,7 +98,7 @@ def debug_device_driver(): errors = {} success = False for dev in connected_devices: - print 'Device possibly connected:', dev + print 'Device possibly connected:', dev.__class__.name print 'Trying to open device...', try: dev.open() diff --git a/src/calibre/devices/nook/driver.py b/src/calibre/devices/nook/driver.py index 8557af75b8..b9bf8443fb 100644 --- a/src/calibre/devices/nook/driver.py +++ b/src/calibre/devices/nook/driver.py @@ -13,6 +13,7 @@ from calibre.devices.usbms.driver import USBMS class NOOK(USBMS): name = 'Nook Device Interface' + gui_name = _('The Nook') description = _('Communicate with the Nook eBook reader.') author = 'John Schember' supported_platforms = ['windows', 'linux', 'osx'] diff --git a/src/calibre/gui2/device.py b/src/calibre/gui2/device.py index 267fff2aad..115f3d8800 100644 --- a/src/calibre/gui2/device.py +++ b/src/calibre/gui2/device.py @@ -784,8 +784,9 @@ class DeviceGUI(object): if _auto_ids != []: for id in _auto_ids: if specific_format == None: - formats = [f.lower() for f in self.library_view.model().db.formats(id, index_is_id=True).split(',')] - formats = formats if formats != None else [] + formats = self.library_view.model().db.formats(id, index_is_id=True) + formats = formats.split(',') if formats is not None else [] + formats = [f.lower().strip() for f in formats] if list(set(formats).intersection(available_input_formats())) != [] and list(set(self.device_manager.device_class.settings().format_map).intersection(available_output_formats())) != []: auto.append(id) else: