mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-08-30 23:00:21 -04:00
When adding quick start guide also add its cover
This commit is contained in:
parent
86530031b1
commit
1a212506e2
Binary file not shown.
@ -278,11 +278,8 @@ class Main(MainWindow, MainWindowMixin, DeviceMixin, EmailMixin, # {{{
|
||||
self.library_view.model().count_changed_signal.connect(
|
||||
self.iactions['Choose Library'].count_changed)
|
||||
if not gprefs.get('quick_start_guide_added', False):
|
||||
from calibre.ebooks.metadata import MetaInformation
|
||||
mi = MetaInformation(_('Calibre Quick Start Guide'), ['John Schember'])
|
||||
mi.author_sort = 'Schember, John'
|
||||
mi.comments = "A guide to get you up and running with calibre"
|
||||
mi.publisher = 'calibre'
|
||||
from calibre.ebooks.metadata.meta import get_metadata
|
||||
mi = get_metadata(open(P('quick_start.epub'), 'rb'), 'epub')
|
||||
self.library_view.model().add_books([P('quick_start.epub')], ['epub'],
|
||||
[mi])
|
||||
gprefs['quick_start_guide_added'] = True
|
||||
|
Loading…
x
Reference in New Issue
Block a user