Ignore:
Timestamp:
Jul 15, 2012, 7:44:26 PM (12 years ago)
Author:
gbo
Message:

2.4F improve frame management first size and JS resize

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/LLGBO2/include/manage_picture_content.php

    r16145 r16754  
    22$prev = $template->get_template_vars('previous');
    33$next  = $template->get_template_vars('next');
    4 $current  = $template->get_template_vars('current');
     4$current = $template->get_template_vars('current');
    55$themeconf = $template->get_template_vars('themeconf');
     6$slideshow = $template->get_template_vars('U_SLIDESHOW');
    67//print_r($next);
    78$swtimg =   '||<img src=';     
     
    1415        $template->append('llgbo', array('tooltipCSS'  => $sweetcss), true);
    1516        }       
    16        
     17If (($conf['LLGBO_SETTINGS'] [0] == 'true') and (!isset($slideshow))  ) //Frame
     18        {       
     19        $template->set_prefilter('default_content', 'LLGBO_prefilter_Content_Frame');
     20
    1721//----------------------------------------------------   
    18 /*              HTML  frame                          */
    19 //----------------------------------------------------   
    20 If (($conf['LLGBO_SETTINGS'] [0] == 'true') ) //Frame
    21         {       
    22         $template->set_prefilter('default_content', 'LLGBO_prefilter_Frame');
    23         // selected picture Size                       
    24         $deriv_type = pwg_get_session_var('picture_deriv', IMG_LARGE);
    25         $PictSizeWH  =  $element_info['derivatives'][$deriv_type]->get_size(); 
    26         $frame_width  = $PictSizeWH[0];
    27                 $frame_height = $PictSizeWH[1];
    28                 $lastbrdpx = 0;
    29                 $frame_begin ='';
     22/*       HTML End  frame   on Picture_content       */
     23//----------------------------------------------------         
    3024                $frame_end='';
    3125                for ($x = 1   ;$x < 32  ; $x =$x +2)
    3226                {       if ((isset($conf['LLGBO_FRAME'][$x+1])) and  ($conf['LLGBO_FRAME'][$x+1] > 0))  // boder value > 0     
    33                           { $bordpx= $conf['LLGBO_FRAME'][$x+1];
    34                                 $frame_width = $frame_width + ( 2* $lastbrdpx);                         
    35                                 $frame_height = $frame_height + ( 2* $lastbrdpx);
    36                             $bordcolor = $conf['LLGBO_FRAME'][$x];
    37                             $frame_begin = '<div   id ="llgboframe'.$x.'" style="border:'.$bordpx.'px solid '.$bordcolor.';width:'.$frame_width.'px; height:'.$frame_height.'px;">'."\n".$frame_begin;
    38                                 $frame_end = $frame_end .'</div>';     
    39                                 $lastbrdpx = $bordpx;}
     27                          {     $frame_end = $frame_end .'</div>';      }
    4028                }
    4129        $csstheme = 'default';
    4230        $themeconf = $template->get_template_vars('themeconf');
    43                 $frame_width = $frame_width + ( 2* $lastbrdpx);                         
    44                 $frame_height = $frame_height + ( 2* $lastbrdpx);
    45                 $frame_size = 'style="border:0 ;width:'.$frame_width.'px; height:'.$frame_height.'px;"';
    46                 $themestyle = $themeconf['parent'];
     31        //  dedicated Css by parent theme       
     32                $themestyle = 'default';
     33                if (isset ($themeconf['parent']))
     34                { $themestyle = $themeconf['parent'];}
    4735                If ($themestyle == 'default')
    4836                   { $themestyle = $themeconf['id'];}
    49                 // print_r($themestyle);
    5037                 $template->append('llgbo', array(
    51                          'FRAME_SIZE' => $frame_size,
    52                          'FRAME_BEGIN' => $frame_begin,
    5338                          'FRAME_END' => $frame_end,
    5439                          'GBOCSS' => LLGBO_PATH."css/llgbo_content_".$themestyle.".css" ), true);
    5540
    56                          
    57         If (($conf['LLGBO_SETTINGS'] [5]  == 'true' )  /* title on frame */
    58         and ($conf['LLGBO_SETTINGS'] [0]  == 'true' ) )// frame
    59                  {  $template->append('llgbo', array(
    60                                  'TITLE_FRAME_COLOR' => $conf['LLGBO_FRAME'][0],
    61                                  'TITLE_FRAME' => $current['name'] ), true);
    62                         $template->assign('SHOW_PICTURE_NAME_ON_TITLE' , false);
    63        
    64                         }
    6541} // end frame
     42
    6643?>
Note: See TracChangeset for help on using the changeset viewer.