2011-05-24 11:28:35 +00:00
|
|
|
<?php defined("SYSPATH") or die("No direct script access.") ?>
|
|
|
|
<? /* Placeholder for infromation in mosaic view. */ ?>
|
2011-05-30 06:26:32 +00:00
|
|
|
<script type="text/javascript">
|
|
|
|
$(function() {
|
2012-01-10 14:07:23 +00:00
|
|
|
slideshowTimeout = <?=module::get_var("th_pear4gallery3", "slideshow_time", "5000")?>;
|
|
|
|
mosaicEffect = "<?
|
|
|
|
$mosaic_effect = module::get_var("th_pear4gallery3", "mosaic_effect", "blind");
|
|
|
|
if ($mosaic_effect == "none") print "";
|
|
|
|
else print $mosaic_effect;
|
|
|
|
?>";
|
|
|
|
sidebarInit('<?=module::get_var("th_pear4gallery3", "sidebar_view")?>');
|
|
|
|
bodyLoad( "<?=module::get_var("th_pear4gallery3", "mainmenu_view")?>",
|
2011-05-30 06:26:32 +00:00
|
|
|
"<?=module::get_var("th_pear4gallery3", "background")?>");
|
|
|
|
});
|
|
|
|
</script>
|
2012-01-10 14:07:23 +00:00
|
|
|
<table id="mosaicTable" style="width: 100%; margin: -2px -2px 0px 0px; overflow: hidden">
|
2011-05-24 11:28:35 +00:00
|
|
|
<tr>
|
|
|
|
<td class="left" style=" width: 65%; vertical-align: middle; padding: 0px;">
|
2012-01-10 14:07:23 +00:00
|
|
|
<div id="gsImageView" class="gbBlock gcBorder1" style="padding: 0px !important; text-align: center;">
|
|
|
|
<div style="padding: 0px; width: 0px; margin-top: 0px; opacity: 0.999999; display: none;" id="mosaicDetail">
|
|
|
|
<div id="photo"> <img id="mosaicImg" src="" alt="Main image"/> </div>
|
|
|
|
<div class="gsContentDetail" style="width: 100%;">
|
2011-05-24 11:28:35 +00:00
|
|
|
<div class="gbBlock gcBorder1" id="imageTitle"> </div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2012-01-10 14:07:23 +00:00
|
|
|
</div>
|
2011-05-24 11:28:35 +00:00
|
|
|
</td>
|
|
|
|
<td class="right" style="margin: 0px; padding: 0px; width: 35%; vertical-align: top;">
|
|
|
|
<div class="gallery-album" id="mosaicGridContainer" style="display: block;">
|
2012-01-10 14:07:23 +00:00
|
|
|
<script type="text/javascript">
|
|
|
|
var slideshowImages = new Array();
|
|
|
|
</script>
|
2011-05-24 11:28:35 +00:00
|
|
|
<? if (count($children)): ?>
|
|
|
|
<? foreach ($children as $i => $child): ?>
|
|
|
|
<? $item_class = "g-photo"; ?>
|
|
|
|
<? if ($child->is_album()): ?>
|
2011-05-25 13:12:03 +00:00
|
|
|
<? $item_class = "g-album\" onclick=\"window.location='".$child->url()."/'+getAlbumHash(skimimg);"; ?>
|
2011-05-24 11:28:35 +00:00
|
|
|
<? endif ?>
|
|
|
|
<? $img_class = "g-thumbnail"; ?>
|
|
|
|
<? if ($child->is_photo()): ?>
|
|
|
|
<? $img_class = "g-thumbnail p-photo"; ?>
|
|
|
|
<? endif ?>
|
2011-11-08 10:24:21 +00:00
|
|
|
<? if ($child->is_movie()): ?>
|
|
|
|
<a href="<?= $child->url() ?>">
|
|
|
|
<? endif ?>
|
2011-05-26 06:13:42 +00:00
|
|
|
<div id="g-thumb-id-<?= $child->id ?>" class="g-item gallery-thumb <?= $item_class ?>" title="<?= $child->description?>">
|
2011-05-24 11:28:35 +00:00
|
|
|
<?= $theme->thumb_top($child) ?>
|
2011-11-08 10:24:21 +00:00
|
|
|
<? if ($child->is_album() || $child->is_movie()): ?>
|
|
|
|
<div class="gallery-thumb-round"></div>
|
2011-05-24 11:28:35 +00:00
|
|
|
<? endif ?>
|
2012-01-11 13:16:07 +00:00
|
|
|
<?= $theme->context_menu($child, "#g-item-id-{$child->id} .g-thumbnail") ?>
|
2011-05-24 11:28:35 +00:00
|
|
|
<? if ($child->has_thumb()): ?>
|
|
|
|
<?= $child->thumb_img(array("class" => $img_class, "id" => "thumb_$child->id", "style" => "width: 200px; height 200px;")) ?>
|
2012-01-10 14:07:23 +00:00
|
|
|
<? else: ?>
|
|
|
|
<span style="display: block; width: 200px; height: 200px;"></span>
|
|
|
|
<? endif ?>
|
2011-11-08 10:24:21 +00:00
|
|
|
<? if ($child->is_movie()): ?>
|
|
|
|
<span class="p-video"></span>
|
|
|
|
<? endif ?>
|
2012-01-10 14:07:23 +00:00
|
|
|
<?// Begin skimming
|
2011-05-24 11:28:35 +00:00
|
|
|
if($child->is_album()):
|
|
|
|
$granchildren = $child->viewable()->children();
|
|
|
|
$offset = 0;
|
2011-11-08 10:24:21 +00:00
|
|
|
$step = round(200/min(count($granchildren),50));
|
2011-05-24 11:28:35 +00:00
|
|
|
foreach ($granchildren as $i => $granchild):?>
|
2011-11-10 14:38:26 +00:00
|
|
|
<? if(++$i > 50) break; ?>
|
2011-05-27 09:16:41 +00:00
|
|
|
<? if ($granchild->has_thumb()): ?>
|
2011-05-24 11:28:35 +00:00
|
|
|
<?= $granchild->thumb_img(array("style" => "display: none;")) ?>
|
2011-11-10 14:38:26 +00:00
|
|
|
<div class="skimm_div" style="height: 200px; width: <?=$step?>px; left: <?=$offset?>px; top: 0px;" onmouseover="$('#thumb_<?=$child->id?>').attr('src', '<?=$granchild->thumb_url()?>');skimimg=<?=$i-1?>;" id="area_<?=$granchild->id?>"></div>
|
2011-05-24 11:28:35 +00:00
|
|
|
<? endif ?>
|
|
|
|
<? $offset+=$step;
|
2012-01-10 14:07:23 +00:00
|
|
|
endforeach;
|
|
|
|
endif;
|
2011-05-24 11:28:35 +00:00
|
|
|
// End skimming // ?>
|
2011-11-08 10:24:21 +00:00
|
|
|
<p class="giTitle <? if(!$child->is_album()) print 'center';?>"><?= html::purify(text::limit_chars($child->title, 20)) ?> </p>
|
2011-05-25 13:53:28 +00:00
|
|
|
<? if($child->is_album()): ?><div class="giInfo"><?= count($granchildren)?> photos</div><? endif ?>
|
|
|
|
</div>
|
2011-11-08 10:24:21 +00:00
|
|
|
<? if ($child->is_movie()): ?>
|
|
|
|
</a>
|
|
|
|
<? endif ?>
|
2011-05-25 13:53:28 +00:00
|
|
|
<?/* <?= $theme->thumb_bottom($child) ?>
|
2011-05-24 11:28:35 +00:00
|
|
|
<?= $theme->context_menu($child, "#g-item-id-{$child->id} .g-thumbnail") ?>
|
|
|
|
<h2><span class="<?= $item_class ?>"></span>
|
|
|
|
<a href="<?= $child->url() ?>"><?= html::purify($child->title) ?></a></h2>
|
|
|
|
<div class="g-metadata">
|
|
|
|
<ol><?= $theme->thumb_info($child) ?></ol>
|
|
|
|
</div>
|
2011-05-25 13:53:28 +00:00
|
|
|
</div>*/?>
|
2011-05-24 11:28:35 +00:00
|
|
|
<? endforeach ?>
|
2012-01-12 15:25:18 +00:00
|
|
|
<script type="text/javascript">
|
2011-05-24 11:28:35 +00:00
|
|
|
<? foreach ($children as $i => $child): ?>
|
|
|
|
<? if(!($child->is_album() || $child->is_movie())): ?>
|
2011-11-08 10:24:21 +00:00
|
|
|
slideshowImages.push(['<?= $child->resize_url() ?>', '<?= url::site("exif/show/$child->id") ?>', '<?= $child->width ?>','<?= $child->height ?>', '<?= htmlentities($child->title, ENT_QUOTES) ?>', '<?= $child->file_url() ?>', '<?= $child->url() ?>']);
|
2011-05-24 11:28:35 +00:00
|
|
|
<? endif ?>
|
|
|
|
<? endforeach ?>
|
|
|
|
</script>
|
|
|
|
<? else: ?>
|
|
|
|
<? if ($user->admin || access::can("add", $item)): ?>
|
|
|
|
<? $addurl = url::site("uploader/index/$item->id") ?>
|
|
|
|
<li><?= t("There aren't any photos here yet! <a %attrs>Add some</a>.",
|
|
|
|
array("attrs" => html::mark_clean("href=\"$addurl\" class=\"g-dialog-link\""))) ?></li>
|
|
|
|
<? else: ?>
|
|
|
|
<li><?= t("There aren't any photos here yet!") ?></li>
|
|
|
|
<? endif; ?>
|
|
|
|
<? endif; ?>
|
|
|
|
</div>
|
2012-01-10 14:07:23 +00:00
|
|
|
<? if (module::get_var("th_pear4gallery3", "sidebar_view") != ''): ?>
|
|
|
|
</td><td>
|
2012-01-11 13:16:07 +00:00
|
|
|
<div id="sidebarContainer" style="overflow-y: auto;">
|
2012-01-10 14:07:23 +00:00
|
|
|
<div id="sidebarBorder" style="background-color: darkGrey; width: 5px; height: 100%; position: absolute;"></div>
|
|
|
|
<div id="sidebar" class="sidebar" style="width: 220px; position: aboslute; padding-left: 5px;">
|
|
|
|
<? if ($theme->page_subtype != "login"): ?>
|
|
|
|
<?= new View("sidebar.html") ?>
|
|
|
|
<? endif ?>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<? endif ?>
|
2011-06-15 06:09:05 +00:00
|
|
|
</td></tr></table>
|
2012-01-10 14:07:23 +00:00
|
|
|
<div id="pearFlowPadd" class="imageflow" style="display: none;"></div>
|
|
|
|
<div id="pearImageFlow" class="imageflow" style="display: none;"> </div>
|
2011-05-24 11:28:35 +00:00
|
|
|
<?= $theme->album_bottom() ?>
|
|
|
|
|
|
|
|
<?= $theme->paginator() ?>
|