mirror of
				https://github.com/kovidgoyal/calibre.git
				synced 2025-10-31 02:27:01 -04:00 
			
		
		
		
	Fix #812750 (Literati (aka Azbooka) does not detect SD Card)
This commit is contained in:
		
							parent
							
								
									a389b310c6
								
							
						
					
					
						commit
						1b136b6fec
					
				| @ -131,7 +131,7 @@ class AZBOOKA(ALEX): | ||||
|     description = _('Communicate with the Azbooka') | ||||
| 
 | ||||
|     VENDOR_NAME      = 'LINUX' | ||||
|     WINDOWS_MAIN_MEM = 'FILE-STOR_GADGET' | ||||
|     WINDOWS_MAIN_MEM = WINDOWS_CARD_A_MEM = 'FILE-STOR_GADGET' | ||||
| 
 | ||||
|     MAIN_MEMORY_VOLUME_LABEL  = 'Azbooka Internal Memory' | ||||
| 
 | ||||
|  | ||||
| @ -574,6 +574,13 @@ class Tag(object): # {{{ | ||||
| 
 | ||||
| class IndexEntry(object): # {{{ | ||||
| 
 | ||||
|     ''' | ||||
|     The index is made up of entries, each of which is represented by an | ||||
|     instance of this class. Index entries typically point to offsets int eh | ||||
|     HTML, specify HTML sizes and point to text strings in the CNCX that are | ||||
|     used in the navigation UI. | ||||
|     ''' | ||||
| 
 | ||||
|     TYPES = { | ||||
|             # Present in book type files | ||||
|             0x0f : 'chapter', | ||||
| @ -619,6 +626,11 @@ class IndexEntry(object): # {{{ | ||||
| 
 | ||||
| class IndexRecord(object): # {{{ | ||||
| 
 | ||||
|     ''' | ||||
|     Represents all indexing information in the MOBI, apart from indexing info | ||||
|     in the trailing data of the text records. | ||||
|     ''' | ||||
| 
 | ||||
|     def __init__(self, record, index_header, cncx): | ||||
|         self.record = record | ||||
|         raw = self.record.raw | ||||
| @ -684,6 +696,12 @@ class IndexRecord(object): # {{{ | ||||
| 
 | ||||
| class CNCX(object) : # {{{ | ||||
| 
 | ||||
|     ''' | ||||
|     Parses the records that contain the compiled NCX (all strings from the | ||||
|     NCX). Presents a simple offset : string mapping interface to access the | ||||
|     data. | ||||
|     ''' | ||||
| 
 | ||||
|     def __init__(self, records, codec): | ||||
|         self.records = OrderedDict() | ||||
|         pos = 0 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user