mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-14 00:39:57 +09:00
git-svn-id: http://xe-core.googlecode.com/svn/trunk@1562 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
3f7c013fa7
commit
9a5c68a5e9
6 changed files with 123 additions and 21 deletions
|
|
@ -132,33 +132,26 @@ function toggleDisplay(obj, opt) {
|
||||||
* @brief 멀티미디어 출력용 (IE에서 플래쉬/동영상 주변에 점선 생김 방지용)
|
* @brief 멀티미디어 출력용 (IE에서 플래쉬/동영상 주변에 점선 생김 방지용)
|
||||||
**/
|
**/
|
||||||
function displayMultimedia(src, width, height, auto_start) {
|
function displayMultimedia(src, width, height, auto_start) {
|
||||||
var ext = src.split(".");
|
|
||||||
var type = ext[ext.length-1];
|
|
||||||
|
|
||||||
if(auto_start) auto_start = "true";
|
if(auto_start) auto_start = "true";
|
||||||
else auto_start = "false";
|
else auto_start = "false";
|
||||||
|
|
||||||
var clsid = "";
|
var clsid = "";
|
||||||
var codebase = "";
|
var codebase = "";
|
||||||
var html = "";
|
var html = "";
|
||||||
switch(type) {
|
|
||||||
case "flv" :
|
if(/\.swf/i.test(src)) {
|
||||||
html = "<embed src=\"./common/tpl/images/flvplayer.swf?autoStart="+auto_start+"&file="+src+"\" width=\""+width+"\" height=\""+height+"\" type=\"application/x-shockwave-flash\"></embed>";
|
clsid = "clsid:D27CDB6E-AE6D-11cf-96B8-444553540000";
|
||||||
break;
|
codebase = "http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.c-ab#version=6,0,29,0";
|
||||||
case "swf" :
|
html = ""+
|
||||||
clsid = "clsid:D27CDB6E-AE6D-11cf-96B8-444553540000";
|
"<object classid=\""+clsid+"\" codebase=\""+codebase+"\" width=\""+width+"\" hegiht=\""+height+"\" >"+
|
||||||
codebase = "http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.c-ab#version=6,0,29,0";
|
"<param name=\"movie\" value=\""+src+"\" />"+
|
||||||
html = ""+
|
"<param name=\"quality\" value=\"high\" />"+
|
||||||
"<object classid=\""+clsid+"\" codebase=\""+codebase+"\" width=\""+width+"\" hegiht=\""+height+"\" >"+
|
"<embed src=\""+src+"\" autostart=\""+auto_start+"\" width=\""+width+"\" hegiht=\""+height+"\"></embed>"+
|
||||||
"<param name=\"movie\" value=\""+src+"\" />"+
|
"<\/object>";
|
||||||
"<param name=\"quality\" value=\"high\" />"+
|
} else if(/\.flv/i.test(src)) {
|
||||||
"<embed src=\""+src+"\" autostart=\""+auto_start+"\" "+style+"></embed>"+
|
html = "<embed src=\"./common/tpl/images/flvplayer.swf?autoStart="+auto_start+"&file="+src+"\" width=\""+width+"\" height=\""+height+"\" type=\"application/x-shockwave-flash\"></embed>";
|
||||||
"<\/object>";
|
} else {
|
||||||
break;
|
html = "<embed src=\""+src+"\" autostart=\""+auto_start+"\" width=\""+width+"\" hegiht=\""+height+"\"></embed>";
|
||||||
default :
|
|
||||||
html = ""+
|
|
||||||
"<embed src=\""+src+"\" autostart=\""+auto_start+"\" width=\""+width+"\" hegiht=\""+height+"\"></embed>";
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
document.writeln(html);
|
document.writeln(html);
|
||||||
|
|
|
||||||
46
plugins/styx_clock/conf/info.xml
Normal file
46
plugins/styx_clock/conf/info.xml
Normal file
|
|
@ -0,0 +1,46 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<plugin version="0.1">
|
||||||
|
<title xml:lang="ko">플래시 시계</title>
|
||||||
|
<author email_address="styx@bystyx.com" link="http://www.bystyx.com" date="2007. 2. 28">
|
||||||
|
<name xml:lang="ko">스틱스 </name>
|
||||||
|
<description xml:lang="ko">플래쉬로 된 시계를 출력합니다.</description>
|
||||||
|
</author>
|
||||||
|
<extra_vars>
|
||||||
|
<var id="best">
|
||||||
|
<name xml:lang="ko">제목</name>
|
||||||
|
<type>text</type>
|
||||||
|
<description xml:lang="ko">시계내의 제목을 바꿀 수 있습니다. (공백으로 하면 나타나지 않습니다)</description>
|
||||||
|
</var>
|
||||||
|
<var id="width">
|
||||||
|
<name xml:lang="ko">가로길이</name>
|
||||||
|
<type>text</type>
|
||||||
|
<description xml:lang="ko">가로길이를 지정하실 수 있습니다. (기본 200)</description>
|
||||||
|
</var>
|
||||||
|
<var id="theme">
|
||||||
|
<name xml:lang="ko">테마</name>
|
||||||
|
<type>select</type>
|
||||||
|
<description xml:lang="ko">흰색/검은색 배경색에 따라 조절하시면 됩니다.</description>
|
||||||
|
<options>
|
||||||
|
<name xml:lang="ko">흰색 배경</name>
|
||||||
|
<value>white</value>
|
||||||
|
</options>
|
||||||
|
<options>
|
||||||
|
<name xml:lang="ko">검은색 배경</name>
|
||||||
|
<value>black</value>
|
||||||
|
</options>
|
||||||
|
</var>
|
||||||
|
<var id="day">
|
||||||
|
<name xml:lang="ko">일자 표시</name>
|
||||||
|
<type>select</type>
|
||||||
|
<description xml:lang="ko">시계내에 일자를 표시하는 기능을 끄거나 캬실 수 있습니다.</description>
|
||||||
|
<options>
|
||||||
|
<name xml:lang="ko">나타냄</name>
|
||||||
|
<value></value>
|
||||||
|
</options>
|
||||||
|
<options>
|
||||||
|
<name xml:lang="ko">숨김</name>
|
||||||
|
<value>false</value>
|
||||||
|
</options>
|
||||||
|
</var>
|
||||||
|
</extra_vars>
|
||||||
|
</plugin>
|
||||||
3
plugins/styx_clock/skins/default/clock.html
Normal file
3
plugins/styx_clock/skins/default/clock.html
Normal file
|
|
@ -0,0 +1,3 @@
|
||||||
|
<script type="text/javascript">
|
||||||
|
displayMultimedia("{$plugin_info->src}", {$plugin_info->width}, {$plugin_info->width});
|
||||||
|
</script>
|
||||||
BIN
plugins/styx_clock/skins/default/clock.swf
Normal file
BIN
plugins/styx_clock/skins/default/clock.swf
Normal file
Binary file not shown.
13
plugins/styx_clock/skins/default/skin.xml
Normal file
13
plugins/styx_clock/skins/default/skin.xml
Normal file
|
|
@ -0,0 +1,13 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<skin>
|
||||||
|
<title xml:lang="ko">플래시 시계 기본 컬러셋</title>
|
||||||
|
<maker email_address="styx@bystyx.com" link="http://www.bystyx.com" date="2007. 2. 28">
|
||||||
|
<name xml:lang="ko">styx</name>
|
||||||
|
<description xml:lang="ko">플래시 시계를 출력합니다.</description>
|
||||||
|
</maker>
|
||||||
|
<colorset>
|
||||||
|
<color name="normal">
|
||||||
|
<title xml:lang="ko">기본</title>
|
||||||
|
</color>
|
||||||
|
</colorset>
|
||||||
|
</skin>
|
||||||
47
plugins/styx_clock/styx_clock.class.php
Normal file
47
plugins/styx_clock/styx_clock.class.php
Normal file
|
|
@ -0,0 +1,47 @@
|
||||||
|
<?php
|
||||||
|
/**
|
||||||
|
* @class styx_clock
|
||||||
|
* @author styx (styx@bystyx.com)
|
||||||
|
* @brief 플래시 시계 출력
|
||||||
|
* @version 0.1
|
||||||
|
**/
|
||||||
|
|
||||||
|
class styx_clock extends PluginHandler {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @brief 플러그인의 실행 부분
|
||||||
|
*
|
||||||
|
* ./plugins/플러그인/conf/info.xml 에 선언한 extra_vars를 args로 받는다
|
||||||
|
* 결과를 만든후 print가 아니라 return 해주어야 한다
|
||||||
|
**/
|
||||||
|
function proc($args) {
|
||||||
|
// 템플릿의 스킨 경로를 지정 (skin, colorset에 따른 값을 설정)
|
||||||
|
$tpl_path = sprintf('%sskins/%s', $this->plugin_path, $args->skin);
|
||||||
|
Context::set('colorset', $args->colorset);
|
||||||
|
|
||||||
|
// 템플릿 파일을 지정
|
||||||
|
$tpl_file = 'clock';
|
||||||
|
|
||||||
|
// 플러그인 자체적으로 설정한 변수들을 체크
|
||||||
|
$best = $args->best;
|
||||||
|
|
||||||
|
$theme = $args->theme;
|
||||||
|
if($theme != "white") $theme = "black";
|
||||||
|
|
||||||
|
$day = $args->day;
|
||||||
|
if($day != "false") $day = "true";
|
||||||
|
|
||||||
|
$width = $args->width;
|
||||||
|
if(!$width) $width = 200;
|
||||||
|
$plugin_info->width = $width;
|
||||||
|
|
||||||
|
$plugin_info->src = sprintf("%s/clock.swf?best=%s&theme=%s&day=%s", $tpl_path, $best, $theme, $day);
|
||||||
|
|
||||||
|
Context::set('plugin_info', $plugin_info);
|
||||||
|
|
||||||
|
// 템플릿 컴파일
|
||||||
|
$oTemplate = &TemplateHandler::getInstance();
|
||||||
|
return $oTemplate->compile($tpl_path, $tpl_file);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
Loading…
Add table
Add a link
Reference in a new issue