10-01-2019, 04:28 AM | #1 |
null operator (he/him)
Posts: 20,590
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
File Type Plugins and Add Format tools
Can a File Type plugin execute when a format file is added to an existing book, I know GetFileName doesn't (nor should it - IMO) and I don't have (or want) the deDRM plugin which is the only other File Type plugin i know of.
TIA BR |
10-01-2019, 04:31 AM | #2 |
creator of calibre
Posts: 43,870
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
IIRC they execute whenever a book file is added to the database whether that is part of a new book or a new format for an existing book.
|
Advert | |
|
10-01-2019, 05:23 AM | #3 |
null operator (he/him)
Posts: 20,590
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
I just cut & pasted a solid image zip into a existing book and it became a CBZ - which suggests your right.
GetFileName does not do its normal 'thing' when I cut & paste a format into an existing book, only when I add a format to create a new book. It must detect its creating a new book. I'm sure TdM will drop by and explain. BR |
10-01-2019, 06:16 AM | #4 |
Grand Sorcerer
Posts: 6,235
Karma: 11768331
Join Date: Jun 2009
Location: Madrid, Spain
Device: Kobo Clara/Aura One/Forma,XiaoMI 5, iPad, Huawei MediaPad, YotaPhone 2
|
I'll try to check this evening (more probably tomorrow), but I think that, when you add a format to the book, the event that GetFileName is getting doesn't have the info (or it is adding something different). I think I checked it when I was creating it and it wasn´t possible to recover the name.
|
10-01-2019, 07:01 AM | #5 | |
null operator (he/him)
Posts: 20,590
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
Quote:
Please understand I am not suggesting GFN should do anything when a format is added to an existing book even if it could except if the File Name custom column was empty - maybe ;-) I'm asking on behalf someone thinking of writing a plugin for their video collection. BR |
|
Advert | |
|
10-01-2019, 08:13 AM | #6 |
Grand Sorcerer
Posts: 6,235
Karma: 11768331
Join Date: Jun 2009
Location: Madrid, Spain
Device: Kobo Clara/Aura One/Forma,XiaoMI 5, iPad, Huawei MediaPad, YotaPhone 2
|
I've already thought about that myself I'll check but I think that, adding the format, the plugin was not called (and there was a remark from Kovid about that)
|
10-04-2019, 07:35 AM | #7 |
Grand Sorcerer
Posts: 6,235
Karma: 11768331
Join Date: Jun 2009
Location: Madrid, Spain
Device: Kobo Clara/Aura One/Forma,XiaoMI 5, iPad, Huawei MediaPad, YotaPhone 2
|
Sorry, I has been trying to look for information. The plugin only implements the postadd method, so it works only when a new record is created, but it doesn't implement the postimport method. At this moment, I don't remember why, I should make some tests but I'm not sure if it's going to work.
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[File Type Plugin] Automatically Add Covers to .djvu Files on Import | hazel.noelle | Plugins | 4 | 01-07-2023 07:33 AM |
Kindle tips and essential plugins/tools | syrianrue | Amazon Kindle | 1 | 07-20-2018 07:41 PM |
Automatic Adding Add file type to ignore list | toomuchreading | Calibre | 5 | 01-14-2015 06:44 PM |
Feature Request:Add two different files with the same file format as one book | hola!claude | Library Management | 4 | 11-16-2014 04:00 AM |
Add new format in Edit Meta deletes file contents in Calibre | tpkacer | Introduce Yourself | 7 | 11-22-2010 12:43 PM |