updated destroy method
This commit is contained in:
parent
75814daed6
commit
c0ddf82df8
1 changed files with 8 additions and 2 deletions
|
@ -5,6 +5,7 @@
|
|||
|
||||
Fo sho:
|
||||
- README with build instructions
|
||||
- only trigger navigate event on page change (not resize, etc.)
|
||||
- fix manga mode
|
||||
- trigger preload if requesting valid but not loaded images (can happen if network was interupted)
|
||||
- loading and generally hackiness of pointer is buggy, fix.
|
||||
|
@ -791,14 +792,19 @@ function ComicBook(id, srcs, opts) {
|
|||
|
||||
ComicBook.prototype.destroy = function () {
|
||||
|
||||
$("#cb-loading-overlay, #cb-status, #cb-color, .cb-control, .cb-toolbar, #cb-width-shiv").remove();
|
||||
$.each(book.controls, function (name, $control) {
|
||||
$control.remove();
|
||||
});
|
||||
|
||||
canvas.width = 0;
|
||||
canvas.height = 0;
|
||||
|
||||
window.removeEventListener("keydown", self.navigation, false);
|
||||
window.removeEventListener("hashchange", checkHash, false);
|
||||
|
||||
setHash('');
|
||||
|
||||
$(this).trigger("destroy");
|
||||
// $(this).trigger("destroy");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue