X-Git-Url: http://average.org/gitweb/?a=blobdiff_plain;f=include%2Fshow.js;h=1a40c569c7ad911bbb4d159e6de28fe7e8f8cd8a;hb=dc476cc5961e6326e9a922f9eb8b1220a6d7ae41;hp=248dee6829f6d755a851ea387c5268e47dddc56e;hpb=283ceff6555c129d7e03f639aa8a3e158dd2e1ac;p=mkgallery.git diff --git a/include/show.js b/include/show.js index 248dee6..1a40c56 100644 --- a/include/show.js +++ b/include/show.js @@ -96,7 +96,7 @@ var Show = new Class({ if (this.currentid > 0) { this.show(this.currentid-1); } else { - alert('show.prev called beyond first element'); + /* alert('show.prev called beyond first element'); */ } }, @@ -113,11 +113,16 @@ var Show = new Class({ this.controls.running(1); }, + toggleplay: function(){ + if (this.isplaying) { this.stop(); } + else { this.play(); } + }, + next: function(){ if (this.currentid < this.vimgs.length-1) { this.show(this.currentid+1); } else { - alert('show.next called beyond last element'); + /* alert('show.next called beyond last element'); */ } }, @@ -139,6 +144,7 @@ var Show = new Class({ this.options.cbStart(); this.isplaying = play; this.controls.running(this.isplaying); + this.updatecoords(); this.show(id); return false; /* to make it usable from href links */ },