http://pastebin.com/uWvGBM6X
I've made it detect whether a book is open so the menus should work. (So no need to disable when you aren't using it)
I went back to the key detection method as it works better and it much cleaner.
While playing around with the Kindle I also found something cool.
I remember hearing about some people being annoyed with the progress bar at the bottom of the screen so I made something that will blank it out when in a book (you wont get more book space unfortunately)
http://pastebin.com/0mksGGBu
It basically just prints whitespace over the progress bar and it will detect whether you are in a book or not so you shouldn't have to disable it.
You can use the "eips" to print text/image onto the screen:
eips X-Pos Y-Pos "blah"
X-Pos goes from 0-49 and Y-Pos 0-39
My open book detection is not very nice as it takes 0.05s, if anyone knows any better ways, please share