View Single Post
Old 12-28-2009, 05:03 AM   #1
Car105
Junior Member
Car105 began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Dec 2009
Device: Sony PRS-505
Pages to end of chapter. Any javascript function?

Hi,

I would like to have in the status line the number of pages to the end of chapter, but I cannot find a javascript function to get this information.

Do any of you know how can it be done?

Where can I find the functions that can be used within the pageChanged fucntios as countPages of getPage?

Code:
<function id="pageChanged">
	if (this.isShown()) {
		this.setVariable("BOOK_SIZE", this.getScale());
		this.setVariable("BOOK_HALF_PAGE", this.getHalfPage());
		var c = this.countPages();
		var i = this.getPage() + 1;
                ...
I will add to the status bar the percent of book read, pages per minute, pages to finish chapter and estimated time to finish chapter.

I have already started modifying the main.xml and applicationStart.xml files, and now I master the procedure after bricking my reader several times.

As soon as it is ready I will submit to Jeff in case he wants to add it to the PRSCustomizer.

/Carlos
Car105 is offline   Reply With Quote