Changeset 16048


Ignore:
Timestamp:
Jun 26, 2012, 10:33:51 AM (12 years ago)
Author:
plg
Message:

first step to make Luciano compatible with Piwigo 2.4

Location:
extensions/luciano
Files:
3 deleted
5 edited

Legend:

Unmodified
Added
Removed
  • extensions/luciano/js/script.js

    r12533 r16048  
    1 window.addEvent('domready', function() {
    2         galleryThumbs = $$('.thumbnailCategories li');
    3         galleryThumbs.each(function(el){
    4                 el.linkUrl = el.getElement('a').href;
    5                 el.addEvents({
    6                         'mouseenter'    : function(){addOver(el)},
    7                         'mouseleave'    : function(){removeOver(el)},
    8                         'click'                 : function(){goToUrl(el)}
    9                 });
    10         });
    11        
    12         catThumbs = $$('.thumbnails li');
    13         catThumbs.each(function(el){
    14                 el.addEvents({
    15                         'mouseenter'    : function(){addOver(el)},
    16                         'mouseleave'    : function(){removeOver(el)}
    17                 });
    18         });
    19        
    20         var mySelect = new elSelect( {container : 'order', onClicked: function(){new URI(this.hiddenInput.value).go();}} );
    21   var themeSelect = new elSelect( {container : 'themeSelect'} );
    22   var languageSelect = new elSelect( {container : 'languageSelect'} );
    23        
    24         var photoPrev = $('linkPrev');
    25        
    26         if(photoPrev)
    27         {
    28                 photoPrev.image = photoPrev.getElement('img');
    29                 photoPrev.image.setStyle('opacity', 0);
    30                 photoPrev.setStyle('display', 'block');
    31                 photoPrev.addEvents({
    32                         'mouseenter': function(){ showElement(photoPrev.image) },
    33                         'mouseleave': function(){ hideElement(photoPrev.image)}
    34                 });
    35         }
    36        
    37         var photoNext = $('linkNext');
    38         if(photoNext)
    39         {
    40                 photoNext.image = photoNext.getElement('img');
    41                 photoNext.image.setStyle('opacity', 0);
    42                 photoNext.setStyle('display', 'block');
    43                 photoNext.addEvents({
    44                         'mouseenter': function(){ showElement(photoNext.image) },
    45                         'mouseleave': function(){ hideElement(photoNext.image)}
    46                 });
    47         }
    48 });
    49 
    50 function addOver(el){
    51         if(!el.hasClass('hover')) el.addClass('hover');
    52 }
    53 
    54 function removeOver(el){
    55         if(el.hasClass('hover')) el.removeClass('hover');
    56 }
    57 
    58 function goToUrl(el){
    59         new URI(el.linkUrl).go();
    60 }
    61 
    62 function showElement(el)
    63 {
    64         el.morph({'opacity': 1});
    65 }
    66 
    67 function hideElement(el)
    68 {
    69         el.morph({'opacity': 0});
    70 }
    71 
    72 function toggleElement(el)
    73 {
    74         if(el.getStyle('opacity') == 0) showElement(el); else hideElement(el);
    75 }
    76 
    77 var gRatingOptions, gRatingButtons, gUserRating;
    78 
    791function makeNiceRatingForm(options)
    802{
     
    205127        return false;
    206128}
    207 
    208 
    209 /**
    210 * @file elSelect.js
    211 * @downloaded from http://www.cult-f.net/2007/12/14/elselect/
    212 * @hacked by Luciano Amodio www.lucianoamodio.it
    213 * @author Sergey Korzhov aka elPas0
    214 * @site  http://www.cult-f.net
    215 * @date December 14, 2007
    216 *
    217 */
    218 var elSelect = new Class({
    219         options: {
    220                 container: false,
    221                 baseClass : 'elSelect',
    222                 onClicked: $lambda(false)
    223         },
    224         source : false,
    225         selected : false,
    226         _select : false,
    227         current : false,
    228         selectedOption : false,
    229         dropDown : false,
    230         optionsContainer : false,
    231         hiddenInput : false,
    232         /*
    233         pass the options,
    234         create html and inject into container
    235         */
    236         initialize: function(options){
    237                 this.setOptions(options)
    238                
    239                 if ( !$(this.options.container) ) return
    240                
    241                 this.selected = false
    242                 this.source = $(this.options.container).getElement('select')
    243                 this.buildFrameWork()
    244                
    245                 $(this.source).getElements('option').each( this.addOption, this )
    246                 $(this.options.container).set('html', '')
    247                 this._select.injectInside($(this.options.container))
    248                
    249                 this.bindEvents()
    250                
    251         },
    252        
    253         buildFrameWork : function() {
    254                 this._select = new Element('div').addClass( this.options.baseClass )
    255                 this.current = new Element('div').addClass('selected').injectInside($(this._select))
    256                 this.selectedOption = new Element('div').addClass('selectedOption').injectInside($(this.current))
    257                 this.dropDown = new Element('div').addClass('dropDown').injectInside($(this.current))
    258                 new Element('div').addClass('clear').injectInside($(this._select))
    259                 this.optionsContainer = new Element('div').addClass('optionsContainer').injectInside($(this._select))
    260                 var t = new Element('div').addClass('optionsContainerTop').injectInside($(this.optionsContainer))
    261                 var o = new Element('div').injectInside($(t))
    262                 var p = new Element('div').injectInside($(o))
    263                 var t = new Element('div').addClass('optionsContainerBottom').injectInside($(this.optionsContainer))
    264                 var o = new Element('div').injectInside($(t))
    265                 var p = new Element('div').injectInside($(o))
    266 
    267                 this.hiddenInput = new Element('input', {
    268                         'type'  : 'hidden',
    269                         'name'  : this.source.get('name')                               
    270                 }).inject($(this.options.container), 'before');
    271                
    272         },
    273        
    274         bindEvents : function() {
    275                 document.addEvent('click', function() {
    276                                 if ( this.optionsContainer.getStyle('display') == 'block')
    277                                         this.onDropDown()
    278                         }.bind(this));
    279                        
    280                 $(this.options.container).addEvent( 'click', function(e) { new Event(e).stop(); } )             
    281                 this.current.addEvent('click', this.onDropDown.bindWithEvent(this) )
    282                
    283         },
    284        
    285         //add single option to select
    286         addOption: function( option ){
    287         var o = new Element('div').addClass('option').setProperty('value',option.value)
    288                 if ( option.disabled ) { o.addClass('disabled') } else {
    289                         o.addEvents( {
    290                                 'click': this.onOptionClick.bindWithEvent(this),
    291                                 'mouseout': this.onOptionMouseout.bindWithEvent(this),
    292                                 'mouseover': this.onOptionMouseover.bindWithEvent(this)
    293                         })
    294                 }
    295                
    296                 if ( $defined(option.getProperty('class')) && $chk(option.getProperty('class')) )
    297                         o.addClass(option.getProperty('class'))
    298 
    299        
    300                 if ( option.selected ) {
    301                         if ( this.selected) this.selected.removeClass('selected');
    302                         this.selected = o
    303                         o.addClass('selected')
    304                         this.selectedOption.set('text', option.text);
    305                         this.hiddenInput.setProperty('value',option.value);
    306                 }
    307                 o.set('text', option.text);     
    308                 o.injectBefore($(this.optionsContainer).getLast());
    309         },
    310        
    311         onDropDown : function( e ) {
    312                        
    313                         if ( this.optionsContainer.getStyle('display') == 'block') {
    314                                 this.optionsContainer.setStyle('display','none')
    315                         } else {
    316                                 this.optionsContainer.setStyle('display','block')
    317                                 this.selected.addClass('selected')
    318                                 //needed to fix min-width in ie6
    319                                 var width =  this.optionsContainer.getStyle('width').toInt() > this._select.getStyle('width').toInt() ?
    320                                                                                                                         this.optionsContainer.getStyle('width')
    321                                                                                                                         :
    322                                                                                                                         this._select.getStyle('width')
    323                                                                                                                        
    324                                 this.optionsContainer.setStyle('width', width)
    325                                 this.optionsContainer.getFirst().setStyle('width', width)
    326                                 this.optionsContainer.getLast().setStyle('width', width)
    327                         }                                               
    328         },
    329         onOptionClick : function(e) {
    330                 var event = new Event(e)
    331                 if ( this.selected != event.target ) {
    332                         this.selected.removeClass('selected')
    333                         event.target.addClass('selected')
    334                         this.selected = event.target
    335                         this.selectedOption.set('text', this.selected.get('text'));
    336                         this.hiddenInput.setProperty('value',this.selected.getProperty('value'));
    337                         this.fireEvent('clicked');
    338                 }
    339                 this.onDropDown()
    340         },
    341         onOptionMouseover : function(e){
    342                 var event = new Event(e)
    343                 this.selected.removeClass('selected')
    344                 event.target.addClass('selected')
    345         },
    346         onOptionMouseout : function(e){
    347                 var event = new Event(e)
    348                 event.target.removeClass('selected')
    349         }
    350        
    351 });
    352 elSelect.implement(new Events);
    353 elSelect.implement(new Options);
  • extensions/luciano/local_head.tpl

    r9974 r16048  
    1414{/if}
    1515
     16{*
    1617{combine_script id="mootools.core" path="themes/luciano/js/mootools-1.2.4-core.js"}
    1718{combine_script id="mootools.more" require="mootools.core" path="themes/luciano/js/mootools-1.2.4.4-more.js"}
    18 {combine_script id="luciano.script" require="mootools.more" path="themes/luciano/js/script.js"}
     19*}
     20{combine_script id="luciano.script" path="themes/luciano/js/script.js"}
    1921
    2022{footer_script}
  • extensions/luciano/template/picture.tpl

    r12534 r16048  
    2222  </ul>
    2323</div>
     24
     25{footer_script require='jquery'}{literal}
     26jQuery("#linkPrev img, #linkNext img").css("opacity", 0);
     27
     28jQuery("#linkPrev").mouseenter(function() {
     29  jQuery("#linkPrev img").css("opacity", 1);
     30});
     31jQuery("#linkPrev").mouseleave(function() {
     32  jQuery("#linkPrev img").css("opacity", 0);
     33});
     34
     35jQuery("#linkNext").mouseenter(function() {
     36  jQuery("#linkNext img").css("opacity", 1);
     37});
     38jQuery("#linkNext").mouseleave(function() {
     39  jQuery("#linkNext img").css("opacity", 0);
     40});
     41{/literal}{/footer_script}
    2442
    2543<div id="theImage">
     
    84102{rdelim});
    85103{/footer_script}
    86 
    87104      </div>
    88105    </form>
  • extensions/luciano/theme.css

    r12532 r16048  
    2828label                           { color:#999; }
    2929textarea                { border: 1px solid #666; }
    30 textarea:focus,
    31 input:focus     { border: 1px solid #666; }
     30textarea:focus
     31input:focus, #menubar input:focus       { border: 1px solid #666; }
    3232select                  { background-color: #222; color: #666; }
    33 input                           { border: 1px solid #444; background-color: #222; color: #666; }
    34 input[type="submit"]                            { background-color: #666; color: #222; }
    35 input[type="submit"]:hover      { background-color: #222; color: #666; cursor: hand; }
     33input, #menubar input { border: 1px solid #444; background-color: #222; color: #666; }
     34input[type="submit"], #menubar input[type="submit"] { background-color: #666; color: #222; }
     35input[type="submit"]:hover, #menubar input[type="submit"]:hover { background-color: #222; color: #666; cursor: hand; }
    3636input[type="checkbox"]                  { color: #000; border: 0 none; vertical-align: middle; }
    3737input[type="radio"]                                     { background-color: transparent; border:0 none; color: #000; }
     
    5454p                                               { margin: 10px;}
    5555a, a:visited    { color: #ddd; text-decoration: none; }
    56 a:hover                         { color: #fff }
     56a:hover                         { color: #fff; text-decoration:none; border:none; }
    5757h2 a                                    { margin-left: 3px; }
    5858
    59 #the_page                                                                       { position: relative; width: 1024px; margin: 0 auto; text-align: center }
     59#the_page                                                                       { /* position: relative; */ width: 1024px; margin: 0 auto; text-align: center }
     60#thePicturePage #the_page {position:relative;}
    6061#theHeader,.content                     { text-align: left }
    6162
    6263#theHeader                                                      { padding-top: 20px; margin-bottom: 20px; }
    63 #theHeader h1                                           { color: #fff; font-size: 1.4em }
     64#theHeader h1                                           { color: #fff; font-size: 1.4em; text-align:left;}
    6465#theHeader h1,
    6566#theHeader h1 a,
     
    8990
    9091.content {
     92/*
    9193  float: right;
     94*/
    9295  width: 750px;
    9396  margin-bottom: 10px;
    9497  padding-bottom: 10px;
    95   position: relative;
     98  /* position: relative; */
    9699  background: transparent url(skin/750darkBottom.png) bottom left;
    97100}
     
    114117
    115118
    116 #menubar                { float: left; width: 264px; margin-bottom: 20px; text-align: left; color: #888; }
     119#menubar { float: left; width: 264px; margin: 0 0 20px 0; text-align: left; color: #888; }
    117120#menubar dl     { width: 264px; background: transparent url(skin/264grey3.png); margin-bottom: 10px; }
    118 #menubar dt     { margin-left: 10px; padding-top: 10px; margin-bottom: 10px; font-size: 1.2em; font-weight: 700 }
     121#menubar dt     { margin-left: 10px; padding-top: 10px; margin-bottom: 10px; font-size: 1.2em; font-weight: 700; text-align:left; }
    119122
    120123#menubar dd                                             { width: 264px; background: transparent url(skin/264grey3.png) bottom left; }
     
    125128#menubar dt a,
    126129#menubar dt a:visited           { color: #f70; }
    127 #menubar dt a:hover                     { color: #eee; }
    128 
    129 #menubar dd ul,
    130 #menubar form { padding: 0 5px 10px 30px; }
     130#menubar dt a:hover                     { color: #eee;}
     131
     132#menubar ul { list-style: none outside none;}
     133#menubar dd ul { padding: 0 5px 10px 30px; }
     134#menubar form { padding: 0 5px 5px 5px; margin-top:-20px;}
     135#menubar #quicksearch {margin-top:-10px}
    131136
    132137#menubar #menuTagCloud                  { padding: 0 10px 10px 15px; }
     
    143148/* ELEMENTS */
    144149
    145 .titrePage                                              { padding: 10px 0 5px 10px; height: 30px; }
     150.content .titrePage                                             { padding: 10px 0 5px 10px; height: 30px; }
    146151.titrePage h1                                   { float: left; }
    147 .additional_info                        { clear: both; padding: 10px; text-indent: 50px; color: #333; text-align:justify;}
    148 .thumbnailCategories    { margin-left: 10px; clear:both; }
     152.content .additional_info {padding: 10px; text-indent: 20px; color: #666; text-align:justify;font-size:100%; }
     153.thumbnailCategories    { margin-left: 10px; }
    149154
    150155.thumbnailCategories li                         { background: transparent url(skin/catBg.png) 0 0; width: 355px; height: 170px; float: left; margin-right: 15px; margin-top: 10px }
     
    161166.thumbnails li.hover                    { background: transparent url(skin/thumbBg.png) 0 -170px; }
    162167.thumbnails li .wrap2           { width:170px; height:172px; display:table-cell; vertical-align:middle;}
    163 .thumbnails li img                              { margin: 10px; border: 1px solid #222; border-left: 1px solid #444; border-bottom: 1px solid #444;}
     168.thumbnails li img                              { border: 1px solid #222; border-left: 1px solid #444; border-bottom: 1px solid #444;}
    164169.thumbnails li.hover img        { border: 1px solid #111; border-left: 1px solid #222; border-bottom: 1px solid #222; }
    165170
     
    173178#playSlideshow a                { color: #666; }
    174179
    175 .navigationBar                                          { clear: both; color:#444; text-align: right; padding: 10px 30px }
    176 .navigationBar span,
    177 .navigationBar a                                        { border: 1px solid; padding: 0px 5px; }
    178 .navigationBar a,
    179 .navigationBar a:visited        { color: #999}
    180 .navigationBar a:hover          { color: #eee}
    181 
    182 .navigationBarSimple                                                    { color:#666; text-align: center; }
     180.content .navigationBar                                                 { clear: both; color:#444; text-align: right; padding: 10px 30px }
     181.content .navigationBar span,
     182.content .navigationBar a                                       { border: 1px solid; padding: 0px 5px; }
     183.content .navigationBar a,
     184.content .navigationBar a:visited       { color: #999}
     185.content .navigationBar a:hover         { color: #eee}
     186
     187.navigationBarSimple                                                    { color:#666; text-align: center; position:relative;}
    183188.navigationBarSimple span,
    184189.navigationBarSimple a                                          { height: 150px; width: 20px; border: 0; padding: 0; text-indent: -3000px; }
    185 .navigationBarSimple .prew                              { position: absolute; top: 235px; left: 0px; background: transparent url(icon/prew.png) no-repeat scroll; }
    186 .navigationBarSimple .next                              { position: absolute; top: 235px; right: 0px; background: transparent url(icon/next.png) no-repeat scroll;  }
     190.navigationBarSimple .prew                              { position: absolute; top: -350px; left: 0px; background: transparent url(icon/prew.png) no-repeat scroll; }
     191.navigationBarSimple .next                              { position: absolute; top: -350px; right: 0px; background: transparent url(icon/next.png) no-repeat scroll;  }
    187192.navigationBarSimple a.prew:hover { background: transparent url(icon/prew.png) 0 -150px no-repeat scroll; }
    188193.navigationBarSimple a.next:hover { background: transparent url(icon/next.png) 0 -150px no-repeat scroll; }
     
    264269#slidshowToolBar        { position: absolute; top: 60px; margin-left: 400px; height: 33px;  }
    265270
    266 #imageHeaderBar .imageNumber { width: 70px; font-size: 3em; font-style: italic; color: #222; position: absolute; top: 80px; left: 20px; }
     271#imageHeaderBar .imageNumber { width: 70px; font-size: 3em; font-style: italic; color: #222; position: absolute; top: 20px; right:0; }
    267272#imageHeaderBar .browsePath     { float: left; }
    268273.randomButtons  { float: right; }
     
    355360.icon_1         { background: url(elSelect/icon_1.gif) no-repeat 4px 50%; padding-left: 20px !important; }
    356361.icon_2         { background: url(elSelect/icon_2.gif) no-repeat 4px 50%; padding-left: 20px !important; }
     362
     363/* LanguageSwitch */
     364/*
     365#languageSwitchLink .pwg-button-text {display:none;}
     366
     367#languageSwitchLink .pwg-icon {
     368  display: inline-block;
     369  height: 26px;
     370  overflow: hidden;
     371  text-indent: -9999px;
     372  vertical-align: bottom;
     373  width: 26px;
     374}
     375*/
     376
     377/* icons */
     378.pwg-icon { background-image: url(../default/s26/outline_808080.png);}
     379A:hover .pwg-icon { background-image: url(../default/s26/outline_ffffff.png);}
     380
     381.contentWithMenu {
     382  margin-left: 275px;
     383}
     384
     385.switchBox {
     386  border: 1px solid #000000;
     387  background-color: #555;
     388  color:#aaa;
     389  font-size:14px;
     390}
     391
     392.switchBoxTitle {
     393  border-bottom: 1px solid #444444;
     394}
  • extensions/luciano/themeconf.inc.php

    r6019 r16048  
    1313  'icon_dir'               => 'themes/luciano/icon',
    1414  'local_head'             => 'local_head.tpl',
    15   'load_parent_css'        => false,
     15  'load_parent_css'        => true, // false,
    1616  'load_parent_local_head' => false,
    1717);
Note: See TracChangeset for help on using the changeset viewer.