]> www.average.org Git - mkgallery.git/commitdiff
to stop leaking showwin's internals, make a trivial getter
authorEugene Crosser <crosser@average.org>
Tue, 2 Sep 2008 09:18:30 +0000 (09:18 +0000)
committerEugene Crosser <crosser@average.org>
Tue, 2 Sep 2008 09:18:30 +0000 (09:18 +0000)
include/show.js
include/showwin.js

index 806d3c12604c11fe18a5d833a6d06b29b8e73c18..b9ee1a08d8ef154c1ff26971db1acb92f7744968 100644 (file)
@@ -75,9 +75,9 @@ var Show = new Class({
                        set('class', 'mainformat').
                        setProperty('alt', 'Current Image').
                        setStyle('opacity', 0).
                        set('class', 'mainformat').
                        setProperty('alt', 'Current Image').
                        setStyle('opacity', 0).
-                       injectInside(this.container.container);
+                       injectInside(this.container.domelement());
                this.ondisplay = this.prevdisplay.clone().
                this.ondisplay = this.prevdisplay.clone().
-                       injectInside(this.container.container);
+                       injectInside(this.container.domelement());
                this.loadingdiv = new Element('div').
                addClass('loading').setStyles({
                        position: 'absolute',
                this.loadingdiv = new Element('div').
                addClass('loading').setStyles({
                        position: 'absolute',
@@ -87,7 +87,7 @@ var Show = new Class({
                        display: 'none',
                        width: this.coords.width,
                        height: this.coords.height,
                        display: 'none',
                        width: this.coords.width,
                        height: this.coords.height,
-               }).injectInside(this.container.container);
+               }).injectInside(this.container.domelement());
 
                window.addEvent('resize', this.resizer.bind(this))
        },
 
                window.addEvent('resize', this.resizer.bind(this))
        },
@@ -251,7 +251,7 @@ var Show = new Class({
                });
                this.prevdisplay.dispose();
                this.prevdisplay = this.ondisplay.clone().
                });
                this.prevdisplay.dispose();
                this.prevdisplay = this.ondisplay.clone().
-               setStyle('zIndex', 2).injectInside(this.container.container);
+               setStyle('zIndex', 2).injectInside(this.container.domelement());
                newimg.replaces(this.ondisplay);
                this.ondisplay = newimg;
                this.effect();
                newimg.replaces(this.ondisplay);
                this.ondisplay = newimg;
                this.effect();
index 7e4435745d83c9f567f57cb3cf9b948bd72e920b..10978772e8a19407191325ea6f581ea7387e2958 100644 (file)
@@ -101,7 +101,11 @@ var showWindow = new Class({
                }
                document.body.setStyles(this.bodystyles);
                this.container.setStyle('display', 'none');
                }
                document.body.setStyles(this.bodystyles);
                this.container.setStyle('display', 'none');
-       }
+       },
+
+       domelement: function(){
+               return this.container;
+       },
 })
 showWindow.implement(new Options);
 
 })
 showWindow.implement(new Options);