projects
/
bookreader.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b1ce59b
)
Set background colour of beginning/end facing page to transparent
author
Michael Ang
<mang@archive.org>
Fri, 21 May 2010 00:43:16 +0000
(
00:43
+0000)
committer
Michael Ang
<mang@archive.org>
Fri, 21 May 2010 00:43:16 +0000
(
00:43
+0000)
BookReader/BookReader.js
patch
|
blob
|
history
diff --git
a/BookReader/BookReader.js
b/BookReader/BookReader.js
index
7f23ef4
..
176b56c
100644
(file)
--- a/
BookReader/BookReader.js
+++ b/
BookReader/BookReader.js
@@
-2309,6
+2309,12
@@
BookReader.prototype.prefetchImg = function(index) {
//console.log('prefetching ' + index);
var img = document.createElement("img");
img.className = 'BRpageimage';
+ if (index < 0 || index > (this.numLeafs - 1) ) {
+ // Facing page at beginning or end, or beyond
+ $(img).css({
+ 'background-color': 'transparent'
+ });
+ }
img.src = pageURI;
img.uri = pageURI; // browser may rewrite src so we stash raw URI here
this.prefetchedImgs[index] = img;