From: Eugene Crosser Date: Mon, 1 Sep 2008 11:15:00 +0000 (+0000) Subject: fix image centering issue X-Git-Tag: 2.00~28 X-Git-Url: http://www.average.org/gitweb/?p=mkgallery.git;a=commitdiff_plain;h=9e2f170c6e4ffb4f6ba758387c5689142615ecbd fix image centering issue --- diff --git a/include/gallery.css b/include/gallery.css index e06e65a..fa3ad84 100644 --- a/include/gallery.css +++ b/include/gallery.css @@ -5,7 +5,7 @@ http://www.average.org/mkgallery/ */ -img { +.slideimage img { clear:both; border-style: inset; border-color: gray; @@ -13,6 +13,13 @@ img { margin: 0.2ex; } +.slideshowContainer img { + clear:both; + border-style: none; + margin: 0px; + padding: 0px; +} + table.slide { float: left; width: 210px; diff --git a/include/gallery.js b/include/gallery.js index e4eeef3..d5ff775 100644 --- a/include/gallery.js +++ b/include/gallery.js @@ -120,4 +120,11 @@ function init_gallery() { } /* Initialization */ -window.addEvent('domready',init_gallery) +window.addEvent('domready',init_gallery); + +/* This is how I would like it done for explorer: +window.addEvent('readystatechange',function(parm){ + alert('readystatechange, parm='+parm); + init_gallery(); +}); +/* but it does not seem to work */ diff --git a/include/show.js b/include/show.js index 248dee6..5245232 100644 --- a/include/show.js +++ b/include/show.js @@ -139,6 +139,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 */ }, diff --git a/include/showwin.js b/include/showwin.js index 9656826..00f91ce 100644 --- a/include/showwin.js +++ b/include/showwin.js @@ -9,7 +9,7 @@ */ /* - Hidable "fullscreen" Window for Slideshow + Hideable "fullscreen" Window for Slideshow */ var showWindow = new Class({ @@ -20,6 +20,7 @@ var showWindow = new Class({ container: document.body, tohide: '', onClick: $empty, + onKeypress: $empty, } }, @@ -43,10 +44,10 @@ var showWindow = new Class({ display: 'none' }).addEvent('click', function(){ this.options.onClick() + }.bind(this)).addEvent('keypress', function(){ + this.options.onKeypress() }.bind(this)).injectInside(this.options.container); - this.position(); - window.addEvent('resize', this.position.bind(this)); window.addEvent('scroll', this.position.bind(this)); }, @@ -93,6 +94,7 @@ var showWindow = new Class({ 'overflow-x': 'hidden', 'overflow-y': 'hidden', }); + this.position(); this.container.setStyle('display', 'block'); }, diff --git a/mkgallery.pl b/mkgallery.pl index 6b3febe..a486e1b 100755 --- a/mkgallery.pl +++ b/mkgallery.pl @@ -595,7 +595,9 @@ sub endindex { my $self = shift; my $IND = $self->{-IND}; - print $IND end_center,end_div,end_html,"\n"; + print $IND end_center,end_div, + # "\n",'',"\n", + end_html,"\n"; close($IND) if ($IND); undef $self->{-IND};