Changeset 199
- Timestamp:
- 06/14/08 18:41:46 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
plugins/lightbox/js/modal.js
r198 r199 6 6 7 7 $.modal = function(data,params) { 8 this.params = $.extend({ 8 this.params = $.extend(this.params,params); 9 return this.build(data); 10 }; 11 $.modal.version = '1.0'; 12 13 $.modal.prototype = { 14 params: { 9 15 width: null, 10 16 height: null, … … 15 21 close_img: 'close.png', 16 22 close_txt: 'close' 17 },params); 18 19 return this.build(data); 20 }; 21 $.modal.version = '1.0'; 22 23 $.modal.prototype = { 23 }, 24 24 ctrl: { 25 25 box: $(), … … 186 186 (function($) { 187 187 $.fn.modalImages = function(params) { 188 params = $.extend({ 188 params = $.extend(this.params,params); 189 var links = new Array(); 190 this.each(function() { 191 if ($(this).attr('href') == '' || $(this).attr('href') == undefined || $(this).attr('href') == '#') { 192 return false; 193 } 194 var index = links.length; 195 links.push($(this)); 196 $(this).click(function() { 197 new $.modalImages(index,links,params); 198 return false; 199 }); 200 return true; 201 }); 202 203 return this; 204 }; 205 206 $.modalImages = function(index,links,params) { 207 this.links = links; 208 this.modal = new $.modal(null,params); 209 this.showImage(index); 210 }; 211 212 $.modalImages.prototype = { 213 params: { 189 214 prev_txt: 'previous', 190 215 next_txt: 'next', … … 192 217 next_img: 'next.png', 193 218 blank_img: 'blank.gif' 194 },params); 195 var links = new Array(); 196 this.each(function() { 197 if ($(this).attr('href') == '' || $(this).attr('href') == undefined || $(this).attr('href') == '#') { 198 return false; 199 } 200 var index = links.length; 201 links.push($(this)); 202 $(this).click(function() { 203 new $.modalImages(index,links,params); 204 return false; 205 }); 206 return true; 207 }); 208 209 return this; 210 }; 211 212 $.modalImages = function(index,links,params) { 213 this.links = links; 214 this.modal = new $.modal(null,params); 215 this.showImage(index); 216 }; 217 218 $.modalImages.prototype = { 219 }, 219 220 showImage: function(index) { 220 221 var This = this;
Note: See TracChangeset
for help on using the changeset viewer.