pocketbook-coolreader
pocketbook-coolreader copied to clipboard
revamp .cr3hist storage
http://www.mobileread.com/forums/showthread.php?p=3241743#post3241743
pkb
CR stores reading position and highlights in the .cr3hist file. It is ok when there is only
one instance of CR (its intended use). I assume when you switch the book you run another
instances of the CR. Every instance saves reading position and highlits at exit and
overwrites what was saved by another instance i.e. only last one's data will be preserved.
To fix this someone will have to implement another storage mechanism allowing record level
access to the data like db or some interprocess communication so that only one instance
would write the data.
You also could experiment with events. I think, if we saveHistory() at EVT_BACKGROUND and loadHistory() at EVT_FOREGROUND (or whatever event that comes when we switch back to CR) we will not be losing history anymore.
I confirm this bug. It's very frustrating that when you read several books in one session, the position of all but one is not remembered.