source: extensions/stripped-galleria/themeconf.inc.php @ 18907

Last change on this file since 18907 was 17962, checked in by Zaphod, 12 years ago

version 1.4.2

File size: 1.5 KB
Line 
1<?php
2/*
3Theme Name: stripped-galleria
4Version: Auto
5Description: stripped-galleria theme
6Theme URI: http://piwigo.org/ext/extension_view.php?eid=585
7Author: Julien Capitaine (Zaphod on Piwigo forums)
8Author URI: http://www.audreyetjulien.fr/galerie
9*/
10       
11$themeconf = array(
12  'parent' => 'stripped',
13  'load_parent_css' => true,
14  'load_parent_local_head' => true,
15  'name' => 'stripped-galleria',
16  'theme_dir' => 'stripped-galleria',
17  'icon_dir' => 'themes/stripped/icon',
18  'admin_icon_dir' => 'themes/default/icon/admin',
19  'mime_icon_dir' => 'themes/default/icon/mimetypes/',
20  'local_head' => 'local_head.tpl',
21);
22
23global $conf, $stripped, $strippedgalleria;
24
25// temporary workaround
26$conf['template_combine_files'] = false;
27
28// Need upgrade?
29if (!isset($conf['stripped-galleria']))
30  include(PHPWG_THEMES_PATH.'stripped-galleria/admin/upgrade.inc.php');
31
32$stripped['maxThumb']=999;
33$stripped = array_merge( unserialize( $conf['stripped'] ), (array)$stripped );
34$strippedgalleria = unserialize( $conf['stripped-galleria'] );
35if (!isset($strippedgalleria['lightbox'])) $strippedgalleria['lightbox']='none';
36
37// Access to HD and link to original
38
39add_event_handler('loc_end_index_thumbnails', 'add_thumbnails_hd_url', 50, 2);
40function add_thumbnails_hd_url($tpl_vars, $pictures)
41{
42        global $user;
43        foreach($tpl_vars as &$x)
44        {
45                if ($user['enabled_high']) $x['HD_ACCESS'] = true;
46                else $x['HD_ACCESS'] = false;
47        }
48        unset($x);
49        return $tpl_vars;
50}
51?>
Note: See TracBrowser for help on using the repository browser.