Running job on library change
For my Kobo Utilities plugin, I am adding an option to run a job when the device is connected. This will fetch the reading status of the books from the device and populate some custom columns. I have this working, but I realised it also needs to be run after changing to a new library.
Looking through the code of other plugins, the only thing I could find was library_changed. At first look, this seemed to be what I wanted. But, it gets called before the ondevice status has been updated for the new library. I am using this to decide which books need to have the reading status retrieved from the device.
Have I missed something? Is there another signal or call a bit later that I can use? Or, can I get the list I need from within the job? The last time I looked at this, I couldn't, but that was before the new database engine.
|