Changeset 227
- Timestamp:
- 06/08/07 19:34:41 (1 year ago)
- Files:
-
- trunk/api/process/commongallery.php (modified) (1 diff)
- trunk/api/process/luxbumimage.php (modified) (1 diff)
- trunk/api/ui/link.php (modified) (1 diff)
- trunk/api/ui/public/SlideShow.php (modified) (2 diffs)
- trunk/index.php (modified) (1 diff)
- trunk/templates/common/javascript/slideshow.js (modified) (1 diff)
- trunk/templates/public/luxbum/gallery.html (modified) (1 diff)
- trunk/templates/public/luxbum/slideshow.html (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/api/process/commongallery.php
r216 r227 195 195 */ 196 196 public function getLinkSlideshow() { 197 return link::slideshow($this->dir );197 return link::slideshow($this->dir, $this->f()->getFile()); 198 198 } 199 199 trunk/api/process/luxbumimage.php
r201 r227 263 263 return link::full($this->dir, $this->file); 264 264 } 265 266 /** 267 * @return string the link url to consult the gallery as a slideshow 268 */ 269 public function getLinkSlideshow() { 270 return link::slideshow($this->dir, $this->file); 271 } 265 272 } 266 273 trunk/api/ui/link.php
r216 r227 67 67 68 68 // Le lien pour les pages de slideshow 69 function slideshow($dir, $ start='') {69 function slideshow($dir, $file) { 70 70 $dir = link::encode($dir); 71 if($start == '') { 72 return link::prefix().'slide-show/'.$dir; 73 } 74 else { 75 return link::prefix().'slide-show/'.$dir.$start; 76 } 71 $file = link::encode($file); 72 return link::prefix().'slide-show/'.$dir.$file; 77 73 } 78 74 trunk/api/ui/public/SlideShow.php
r222 r227 27 27 $this->checkFile($dir, $defaultImage); 28 28 $this->checkPrivate($dir); 29 30 $GLOBALS['LB']['dir'] = $dir; 31 $GLOBALS['LB']['title'] = ' - '.NOM_GALERIE; 32 29 33 30 $gallery = new luxBumGallery($dir, TYPE_IMAGE_FILE); 34 31 $imgIndex = $gallery->getImageIndex($defaultImage); … … 37 34 38 35 $context = new Pluf_Template_Context(array('gallery' => $gallery, 36 'first' => $imgIndex, 39 37 'cfg' => $GLOBALS['_PX_config'])); 40 38 trunk/index.php
r216 r227 98 98 99 99 // Image gallery slideshow 100 $dispatcher->registerController('ui_public_SlideShow', 'action', '#^/slide\-show/(.*)$#i'); 101 $dispatcher->registerController('ui_public_SlideShow', 'action', '#^/slide\-show/(.*)/([0-9]+)$#i'); 100 $dispatcher->registerController('ui_public_SlideShow', 'action', '#^/slide\-show/(.*)/(.*)$#i'); 102 101 103 102 trunk/templates/common/javascript/slideshow.js
r226 r227 18 18 // Startup script 19 19 window.onload = function () { 20 current_fg_index = first; 21 current_bg_index = first + 1;alert(current_fg_index+ ' ' + current_bg_index); 20 22 idshowcontroltimeout = window.setTimeout(slide_hideControl, 4000); 21 23 trunk/templates/public/luxbum/gallery.html
r215 r227 111 111 ({$cFile.commentCount})</a> 112 112 {/if} 113 114 {if $cFile->isImage() && $cfg['show_slideshow']} 115 + <a href="javascript:void(0);" onclick="window.open('{$cFile.linkSlideshow}', '{i18n 'Slideshow'}', 'width=670,height=530');">{i18n 'Slideshow'}</a> 116 {/if} 113 117 </td> 114 118 trunk/templates/public/luxbum/slideshow.html
r226 r227 27 27 var smoothtrans = {$cfg['slideshow_fading']}; // Set this to false to prevent any fading effect 28 28 var slide_speed = {$cfg['slideshow_time']}; 29 var first = {$first}; 29 30 --> 30 31 </script>
