mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-23 13:19:56 +09:00
git-svn-id: http://xe-core.googlecode.com/svn/trunk@617 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
085eac5258
commit
052f5bd2b3
9 changed files with 38 additions and 23 deletions
|
|
@ -43,10 +43,22 @@
|
|||
function transHTML($xml_obj) {
|
||||
$width = $xml_obj->attrs->width;
|
||||
$height = $xml_obj->attrs->height;
|
||||
$make_thumbnail = $xml_obj->attrs->make_thumbnail;
|
||||
$body = $xml_obj->body;
|
||||
$image_list = explode("\n",$body);
|
||||
|
||||
$output = sprintf('<div style="width:%s;height:%s">%s</div>', $width, $height, $body);
|
||||
return $output;
|
||||
Context::set("slide_show_width", $width);
|
||||
Context::set("slide_show_height", $height);
|
||||
Context::set("slide_show_images", $image_list);
|
||||
Context::set("slide_show_srl", rand(111111,999999));
|
||||
|
||||
$tpl_path = $this->component_path.'tpl';
|
||||
$tpl_file = 'slide_show.html';
|
||||
|
||||
Context::set("tpl_path", $tpl_path);
|
||||
require_once("./classes/template/TemplateHandler.class.php");
|
||||
$oTemplate = new TemplateHandler();
|
||||
return $oTemplate->compile($tpl_path, $tpl_file);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,23 +1,22 @@
|
|||
<!--%import("slide_show.js")-->
|
||||
<!--%import("slide_show.css")-->
|
||||
<script type='text/javascript'>
|
||||
var _tmp_srl = {$srl};
|
||||
var _tmp_srl = {$slide_show_srl};
|
||||
z_gallery_opacity[_tmp_srl] = 0.3;
|
||||
z_gallery_highlight_speed[_tmp_srl] = 50; // ms
|
||||
z_gallery_highlight_opacity[_tmp_srl] = 0.1;
|
||||
|
||||
{foreach from=$file_list item=obj}
|
||||
{if $obj->thumbnail_url}
|
||||
z_add_gallery(_tmp_srl,'{$obj->thumbnail_url}','{$obj->download_url}');
|
||||
{/if}
|
||||
{/foreach}
|
||||
<!--@foreach($slide_show_images as $image)-->
|
||||
z_add_gallery(_tmp_srl,'{$image}','{$image}');
|
||||
<!--@end-->
|
||||
</script>
|
||||
|
||||
<div style="border:1px solid #DDDDDD;">
|
||||
<div id='zone_gallery_{$srl}' style='width:auto;background-Color:#FFFFFF;padding:10px 10px 10px 10px;text-align:center;'>
|
||||
<div style="border:1px solid #DDDDDD;width:{$slide_show_width}px;">
|
||||
<div id='zone_gallery_{$slide_show_srl}' style='width:{$slide_show_width}px;background-Color:#FFFFFF;padding:10px 10px 10px 10px;text-align:center;'>
|
||||
<span style="color:#000000;font-size:8pt;">loading...</span>
|
||||
</div>
|
||||
|
||||
<div id='zone_thumbnail_{$srl}' style='width:auto;background-Color:#FFFFFF;padding:10px 10px 10px 10px;text-align:center;'></div>
|
||||
<div id='zone_thumbnail_{$slide_show_srl}' style='width:{$slide_show_width}px;background-Color:#FFFFFF;padding:10px 10px 10px 10px;text-align:center;'></div>
|
||||
</div>
|
||||
|
||||
<script type='text/javascript'>
|
||||
|
|
|
|||
|
|
@ -71,6 +71,8 @@ function z_start_gallery() {
|
|||
_obj_thumbnail[srl][idx].srl = srl;
|
||||
_obj_thumbnail[srl][idx].idx = idx;
|
||||
_obj_thumbnail[srl][idx].style.cursor = 'pointer';
|
||||
_obj_thumbnail[srl][idx].style.width = '60px';
|
||||
_obj_thumbnail[srl][idx].style.height= '60px';
|
||||
if(idx == _gallery_idx[srl]) {
|
||||
_obj_thumbnail[srl][idx].style.opacity = 1;
|
||||
_obj_thumbnail[srl][idx].style.filter = "alpha(opacity=100)";
|
||||
|
|
@ -114,8 +116,8 @@ function z_show_gallery(srl, idx) {
|
|||
obj_gallery.style.cursor = 'pointer';
|
||||
|
||||
obj_gallery.start_opacity = 0;
|
||||
obj_gallery.style.width = obj['gallery'].width;
|
||||
obj_gallery.style.height = obj['gallery'].height;
|
||||
obj_gallery.style.width = obj['gallery'].width+"px";
|
||||
obj_gallery.style.height = obj['gallery'].height+"px";
|
||||
obj_gallery.style.opacity = 0;
|
||||
obj_gallery.style.filter = "alpha(opacity=0)";
|
||||
obj_gallery.start_opacity = 1;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue