mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix #1731024 [New BN Nook Glowlight 3 not recognized](https://bugs.launchpad.net/calibre/+bug/1731024)
This commit is contained in:
parent
11b12b9c2f
commit
69afa80715
@ -12,7 +12,8 @@ import os
|
|||||||
|
|
||||||
import cStringIO
|
import cStringIO
|
||||||
|
|
||||||
from calibre import fsync
|
from calibre import fsync, prints
|
||||||
|
from calibre.constants import DEBUG
|
||||||
from calibre.devices.usbms.driver import USBMS
|
from calibre.devices.usbms.driver import USBMS
|
||||||
|
|
||||||
|
|
||||||
@ -104,6 +105,15 @@ class NOOK_COLOR(NOOK):
|
|||||||
def upload_cover(self, path, filename, metadata, filepath):
|
def upload_cover(self, path, filename, metadata, filepath):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
def post_open_callback(self):
|
||||||
|
product_id = self.device_being_opened[1]
|
||||||
|
if DEBUG:
|
||||||
|
prints('Opened NOOK with product id:', product_id)
|
||||||
|
if product_id == 0xb:
|
||||||
|
if DEBUG:
|
||||||
|
prints('Setting Nook upload directory to NOOK')
|
||||||
|
self.EBOOK_DIR_MAIN = 'NOOK'
|
||||||
|
|
||||||
def get_carda_ebook_dir(self, for_upload=False):
|
def get_carda_ebook_dir(self, for_upload=False):
|
||||||
if for_upload:
|
if for_upload:
|
||||||
return self.EBOOK_DIR_MAIN
|
return self.EBOOK_DIR_MAIN
|
||||||
|
Loading…
x
Reference in New Issue
Block a user