[Xfce4-commits] <www:xfce-4.10> Some 4.10 website updates.

Nick Schermer noreply at xfce.org
Sun Apr 8 12:42:02 CEST 2012


Updating branch refs/heads/xfce-4.10
         to b18331d2568e9b31f403e2807227ea3d390dede9 (commit)
       from d4d242f95343ce32136845a9b2f646120a44008c (commit)

commit b18331d2568e9b31f403e2807227ea3d390dede9
Author: Nick Schermer <nick at xfce.org>
Date:   Sun Apr 8 12:39:27 2012 +0200

    Some 4.10 website updates.

 images/frontpage/intro-1-small.jpg       |  Bin 30386 -> 0 bytes
 images/frontpage/intro-1.png             |  Bin 128342 -> 0 bytes
 images/frontpage/intro-2-small.jpg       |  Bin 28380 -> 0 bytes
 images/frontpage/intro-2.png             |  Bin 93292 -> 0 bytes
 images/frontpage/intro-3-small.jpg       |  Bin 26430 -> 0 bytes
 images/frontpage/intro-3.png             |  Bin 92169 -> 0 bytes
 images/frontpage/intro-4-small.jpg       |  Bin 37563 -> 0 bytes
 images/frontpage/intro-4.png             |  Bin 98666 -> 0 bytes
 images/frontpage/slider-apps.jpg         |  Bin 0 -> 84026 bytes
 images/frontpage/slider-desktop.jpg      |  Bin 0 -> 75731 bytes
 images/frontpage/slider-panel.jpg        |  Bin 0 -> 83130 bytes
 images/frontpage/slider-settings.jpg     |  Bin 0 -> 71845 bytes
 images/frontpage/slider-thunar.jpg       |  Bin 0 -> 74993 bytes
 images/frontpage/slider-xfwm4.jpg        |  Bin 0 -> 87827 bytes
 images/frontpage/src/slider-apps.png     |  Bin 0 -> 213034 bytes
 images/frontpage/src/slider-desktop.png  |  Bin 0 -> 243863 bytes
 images/frontpage/src/slider-panel.png    |  Bin 0 -> 203631 bytes
 images/frontpage/src/slider-settings.png |  Bin 0 -> 163125 bytes
 images/frontpage/src/slider-thunar.png   |  Bin 0 -> 209036 bytes
 images/frontpage/src/slider-xfwm4.png    |  Bin 0 -> 152125 bytes
 module.xml                               |   28 ---------
 pages/frontpage.php                      |   92 ++++++++++++++++-------------
 pages/header.php                         |   10 +---
 pages/versions.php                       |    6 +-
 style/base.css                           |    2 +-
 style/bundle.php                         |    2 +-
 style/frontpage.css                      |   70 ++++++++++++++++++++++
 style/home.css                           |   71 -----------------------
 style/tiny.packed.js                     |   31 ----------
 style/tinyslider.js                      |   48 +++++++++++++++
 30 files changed, 176 insertions(+), 184 deletions(-)

diff --git a/images/frontpage/intro-1-small.jpg b/images/frontpage/intro-1-small.jpg
deleted file mode 100644
index 7a958b3..0000000
Binary files a/images/frontpage/intro-1-small.jpg and /dev/null differ
diff --git a/images/frontpage/intro-1.png b/images/frontpage/intro-1.png
deleted file mode 100644
index f2bea68..0000000
Binary files a/images/frontpage/intro-1.png and /dev/null differ
diff --git a/images/frontpage/intro-2-small.jpg b/images/frontpage/intro-2-small.jpg
deleted file mode 100644
index 30b4f15..0000000
Binary files a/images/frontpage/intro-2-small.jpg and /dev/null differ
diff --git a/images/frontpage/intro-2.png b/images/frontpage/intro-2.png
deleted file mode 100644
index e8dacca..0000000
Binary files a/images/frontpage/intro-2.png and /dev/null differ
diff --git a/images/frontpage/intro-3-small.jpg b/images/frontpage/intro-3-small.jpg
deleted file mode 100644
index 03cb0b0..0000000
Binary files a/images/frontpage/intro-3-small.jpg and /dev/null differ
diff --git a/images/frontpage/intro-3.png b/images/frontpage/intro-3.png
deleted file mode 100644
index cb30fa0..0000000
Binary files a/images/frontpage/intro-3.png and /dev/null differ
diff --git a/images/frontpage/intro-4-small.jpg b/images/frontpage/intro-4-small.jpg
deleted file mode 100644
index a434899..0000000
Binary files a/images/frontpage/intro-4-small.jpg and /dev/null differ
diff --git a/images/frontpage/intro-4.png b/images/frontpage/intro-4.png
deleted file mode 100644
index 6dc8e88..0000000
Binary files a/images/frontpage/intro-4.png and /dev/null differ
diff --git a/images/frontpage/slider-apps.jpg b/images/frontpage/slider-apps.jpg
new file mode 100644
index 0000000..72b6d0a
Binary files /dev/null and b/images/frontpage/slider-apps.jpg differ
diff --git a/images/frontpage/slider-desktop.jpg b/images/frontpage/slider-desktop.jpg
new file mode 100644
index 0000000..1bbf76a
Binary files /dev/null and b/images/frontpage/slider-desktop.jpg differ
diff --git a/images/frontpage/slider-panel.jpg b/images/frontpage/slider-panel.jpg
new file mode 100644
index 0000000..ad2e31d
Binary files /dev/null and b/images/frontpage/slider-panel.jpg differ
diff --git a/images/frontpage/slider-settings.jpg b/images/frontpage/slider-settings.jpg
new file mode 100644
index 0000000..41086b8
Binary files /dev/null and b/images/frontpage/slider-settings.jpg differ
diff --git a/images/frontpage/slider-thunar.jpg b/images/frontpage/slider-thunar.jpg
new file mode 100644
index 0000000..4c88337
Binary files /dev/null and b/images/frontpage/slider-thunar.jpg differ
diff --git a/images/frontpage/slider-xfwm4.jpg b/images/frontpage/slider-xfwm4.jpg
new file mode 100644
index 0000000..1ec38ce
Binary files /dev/null and b/images/frontpage/slider-xfwm4.jpg differ
diff --git a/images/frontpage/src/slider-apps.png b/images/frontpage/src/slider-apps.png
new file mode 100644
index 0000000..01eb723
Binary files /dev/null and b/images/frontpage/src/slider-apps.png differ
diff --git a/images/frontpage/src/slider-desktop.png b/images/frontpage/src/slider-desktop.png
new file mode 100644
index 0000000..23405b3
Binary files /dev/null and b/images/frontpage/src/slider-desktop.png differ
diff --git a/images/frontpage/src/slider-panel.png b/images/frontpage/src/slider-panel.png
new file mode 100644
index 0000000..f5942b5
Binary files /dev/null and b/images/frontpage/src/slider-panel.png differ
diff --git a/images/frontpage/src/slider-settings.png b/images/frontpage/src/slider-settings.png
new file mode 100644
index 0000000..5b2555c
Binary files /dev/null and b/images/frontpage/src/slider-settings.png differ
diff --git a/images/frontpage/src/slider-thunar.png b/images/frontpage/src/slider-thunar.png
new file mode 100644
index 0000000..78b0575
Binary files /dev/null and b/images/frontpage/src/slider-thunar.png differ
diff --git a/images/frontpage/src/slider-xfwm4.png b/images/frontpage/src/slider-xfwm4.png
new file mode 100644
index 0000000..6c345c8
Binary files /dev/null and b/images/frontpage/src/slider-xfwm4.png differ
diff --git a/module.xml b/module.xml
deleted file mode 100644
index 0afc8da..0000000
--- a/module.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<Project xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
-         xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
-         xmlns:foaf="http://xmlns.com/foaf/0.1/"
-         xmlns:gnome="http://api.gnome.org/doap-extensions#"
-         xmlns="http://usefulinc.com/ns/doap#">
-
-  <name xml:lang="en">Xfce.org</name>
-  <shortdesc xml:lang="en">The Xfce website</shortdesc>
-  <homepage rdf:resource="http://www.xfce.org/"/>
-  <mailing-list rdf:resource="http://foo-projects.org/mailman/listinfo/xfce/"/>
-
-  <maintainer>
-    <foaf:Person>
-      <foaf:name>Jérôme Guelfucci</foaf:name>
-      <foaf:mbox>mailto:jeromeg at xfce.org</foaf:mbox>
-      <gnome:userid>jeromeg</gnome:userid>
-    </foaf:Person>
-  </maintainer>
-
-  <developer>
-    <foaf:Person>
-      <foaf:name>Nick Schermer</foaf:name>
-      <foaf:mbox>mailto:nick at xfce.org</foaf:mbox>
-      <gnome:userid>nick</gnome:userid>
-    </foaf:Person>
-  </developer>
-</Project>
diff --git a/pages/frontpage.php b/pages/frontpage.php
index 78a6e83..b00232b 100644
--- a/pages/frontpage.php
+++ b/pages/frontpage.php
@@ -5,54 +5,64 @@ include ('pages/versions.php');
 
 $head['description'] = 'Xfce Desktop Environment';
 $head['keywords'] = 'desktop environment, window manager, desktop, speed, lightweight, gtk+, open source, xforms common environment';
-$head['stylesheet'] = array ('/style/home.css');
 $head['feed'] = 'http://www.xfce.org/feed?lang='.$lang;
+$head['javascript'] = '/style/tinyslider.js';
 ?>
 
-<div id="intro">
-
-<div id="intro-wrap">
-<div id="intro-logo"><h1 class="hidden">Xfce Desktop Environment 4.8</h1></div>
-
-<p>
-  <?php E_('Xfce is a lightweight desktop environment for UNIX-like operating systems. It aims to be fast and low on system resources, while still being visually appealing and user friendly.') ?>
-</p>
-
-<ul>
-  <li><a href="/download"><?php printf (R_('Download the latest %s release'), $stable_version) ?></a></li>
-  <li><a href="/download/changelogs/4.8.0"><?php printf (R_('Release notes for %s'), $stable_version) ?></a></li>
-  <li><a href="/about/tour"><?php E_('Visual tour of Xfce 4.8') ?></a></li>
-  <li><a href="/about/screenshots"><?php E_('Screenshots') ?></a></li>
-</ul>
-
-</div>
-<div id="slideshow">
-  <ul id="no-show-slides">
-    <li><img src="http://cdn.xfce.org/frontpage/intro-1-small.jpg" id="intro1" alt="" width="450" height="300" /></li>
-    <li><img src="http://cdn.xfce.org/frontpage/intro-2-small.jpg" id="intro2" alt="" width="450" height="300" /></li>
-    <li><img src="http://cdn.xfce.org/frontpage/intro-3-small.jpg" id="intro3" alt="" width="450" height="300" /></li>
-    <li><img src="http://cdn.xfce.org/frontpage/intro-4-small.jpg" id="intro4" alt="" width="450" height="300" /></li>
-  </ul>
-
-  <script type="text/javascript">
-    // <![CDATA[
-      document.getElementById('no-show-slides').id = 'slides';
-    // ]]>
-  </script>
-
-  <noscript>
-    <ul id="slides">
-      <?php  $i = rand(1,4) ?>
-      <li><img src=<?php echo("\"images/frontpage/intro-" . $i . "-small.jpg\" id=\"intro" . $i . "-noscript\" alt=\"\"") ?> /></li>
+<div id="slides">
+  <div id="slider">
+    <ul>
+      <li>
+        <img src="/images/frontpage/slider-desktop.jpg" width="800" height="400" alt="Xfce Desktop" />
+        <p><?php E_('Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit amet ipsum mauris. Maecenas congue ligula ac quam viverra nec consectetur ante hendrerit. Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue.') ?></p>
+      </li>
+      <li>
+        <img src="/images/frontpage/slider-thunar.jpg" width="800" height="400" alt="File Manager" />
+        <p><?php E_('Thunar is the file manager for the Xfce Desktop Environment. It has been designed from the ground up to be fast and easy-to-use. Its user interface is clean and intuitive, and does not include any confusing or useless options by default.') ?></p>
+      </li>
+      <li>
+        <img src="/images/frontpage/slider-settings.jpg" width="800" height="400" alt="Settings" />
+        <p><?php E_('The Xfce Desktop Environement provides all the required settings to configure your hardware, desktop appearance and other desktop-critical settings allowing you to easily manage your system.') ?></p>
+      </li>
+      <li>
+        <img src="/images/frontpage/slider-xfwm4.jpg" width="800" height="400" alt="Window Manager" />
+        <p><?php E_('The Xfce Window Manager is the core of the desktop. It can be adjusted in a lot of ways to make window management quick and predictable. It also features around 100 border styles giving it the look you want!') ?></p>
+      </li>
+      <li>
+        <img src="/images/frontpage/slider-panel.jpg" width="800" height="400" alt="Panel" />
+        <p><?php E_('The Xfce Panel can be customized in numerous ways so it provides all the items you need right where you need it. It has three different display modes, transparency and a dozen different plugins.') ?></p>
+      </li>
+      <li>
+        <img src="/images/frontpage/slider-apps.jpg" width="800" height="400" alt="Applications" />
+        <p><?php E_('Beside the core desktop functionality, a number of other applications are developed in the Xfce repositories, like an image viewer, the Midori web browser, task manager, notes plugin and calendar.') ?></p>
+      </li>
     </ul>
-  </noscript>
-</div>
-<div class="clearboth"></div>
+  </div>
+  <ul id="pagination">
+    <li onclick="slideshow.pos(0)"></li>
+    <li onclick="slideshow.pos(1)"></li>
+    <li onclick="slideshow.pos(2)"></li>
+    <li onclick="slideshow.pos(3)"></li>
+    <li onclick="slideshow.pos(4)"></li>
+    <li onclick="slideshow.pos(5)"></li>
+  </ul>
+  <div class="clearboth"></div>
 </div>
 
-<script type="text/javascript" src="/style/tiny.packed.js"></script>
+<script type="text/javascript">
+var slideshow=new TINY.slider.slide('slideshow',{
+  id:'slider',
+  auto:10,
+  vertical:false,
+  navid:'pagination',
+  activeclass:'current',
+  position:0,
+  rewind:false,
+  elastic:false
+});
+</script>
 
-<h2>Latest News</h2>
+<h2><?php E_('Latest News') ?></h2>
 <?php
   $count = 3;
   foreach ($news as $item)
diff --git a/pages/header.php b/pages/header.php
index 35b6c7d..a3d061d 100644
--- a/pages/header.php
+++ b/pages/header.php
@@ -14,20 +14,14 @@ else
 	<link rel="shortcut icon" href="/style/favicon.png" type="image/png" />
 	<link rel="stylesheet" media="screen" href="/style/bundle.php" type="text/css" />
 <?php
-        /*
-        add filename to the array in bundle.php instead
-        if (isset ($head['stylesheet']) && is_array ($head['stylesheet']))
-                foreach ($head['stylesheet'] as $sheet)
-                        echo "\t<link rel=\"stylesheet\" media=\"screen\" href=\"$sheet\" type=\"text/css\" />\n";
-        */
         if (isset ($head['description']))
                 echo "\t<meta name=\"description\" content=\"".$head['description']."\" />\n";
-
         if (isset ($head['keywords']))
                 echo "\t<meta name=\"keywords\" content=\"".$head['keywords']."\" />\n";
-
         if (isset ($head['feed']))
                 echo "\t<link rel=\"alternate\" type=\"application/rss+xml\" title=\"RSS 2.0\" href=\"".$head['feed']."\" />\n";
+        if (isset ($head['javascript']))
+                echo "\t<script type=\"text/javascript\" src=\"".$head['javascript']."\"></script>\n";
 ?>
 </head>
 
diff --git a/pages/versions.php b/pages/versions.php
index 06f9004..d750b88 100644
--- a/pages/versions.php
+++ b/pages/versions.php
@@ -5,11 +5,11 @@
    **/
 
   /* latest stable release version */
-  $stable_version = '4.8';
-  $stable_date = '2011-01-16';
+  $stable_version = '4.10';
+  $stable_date = '2012-04-28';
 
   /* latest development version */
   $preview_version = '4.10pre1';
   $preview_date = '2012-04-01';
-  $preview_visible = true /* set to true if preview is *newer* then stable */
+  $preview_visible = faqlse /* set to true if preview is *newer* then stable */
 ?>
diff --git a/style/base.css b/style/base.css
index 693d43c..3119f41 100644
--- a/style/base.css
+++ b/style/base.css
@@ -11,7 +11,7 @@ body {
 	margin: auto;
 	text-align: left;
 	margin-bottom: 3em;
-
+	padding: 10px;
 	min-width: 850px;
 	max-width: 1000px;
 }
diff --git a/style/bundle.php b/style/bundle.php
index 18fc937..c53f04f 100644
--- a/style/bundle.php
+++ b/style/bundle.php
@@ -39,7 +39,7 @@ $buf = '';
 $mtime = 0;
 
 /* load contents */
-$files = array ('header.css', 'base.css', 'home.css', 'news.css', 'projects.css');
+$files = array ('header.css', 'base.css', 'frontpage.css', 'news.css', 'projects.css');
 foreach ($files as $file)
   {
     $buf .= file_get_contents ($file);
diff --git a/style/frontpage.css b/style/frontpage.css
new file mode 100644
index 0000000..b59e716
--- /dev/null
+++ b/style/frontpage.css
@@ -0,0 +1,70 @@
+.file_frontpage {
+	margin-right: 0;
+}
+
+#slides {
+	width: 800px;
+	margin: auto;
+	height: 400px;
+	position: relative;
+	
+	box-shadow: 0 0 3px rgba(0, 0, 0, .5);
+	-webkit-box-shadow: 0 0 3px rgba(0, 0, 0, .5);
+	-moz-box-shadow: 0 0 3px rgba(0, 0, 0, .5);
+}
+#slider {
+	float: left; 
+	position: relative; 
+	overflow: auto; 
+	width: 800px; 
+	height: 400px;
+	background: #000;
+	cursor: default;
+	overflow: hidden;
+}
+#slider ul {
+	position: absolute; 
+	list-style: none; 
+	top: 0; 
+	left: 0;
+	margin: 0;
+	padding: 0;
+}
+#slider li {
+	float: left; 
+	width: 800px; 
+	height: 400px;
+}
+#slider li p {
+	padding:6px;
+	margin:6px;
+	position:absolute;
+	bottom:0;
+	width:450px;
+	background:#333;
+	color:#fff;
+	border: 0;
+	border-radius: 6px;
+}
+#slider li p {
+	background:rgba(0, 0, 0, 0.8)
+}
+#pagination {
+	position:absolute;
+	top:8px;
+	right:0;
+	list-style:none; 
+	margin:0;
+	padding:0;
+}
+#pagination li {
+	float:left; 
+	cursor:pointer; 
+	height:8px; 
+	width:8px; 
+	margin:0 8px 0 0; 
+	border:2px solid #fff;
+}
+#pagination li:hover, #pagination li.current  {
+	background:#fff;
+}
diff --git a/style/home.css b/style/home.css
deleted file mode 100644
index debb648..0000000
--- a/style/home.css
+++ /dev/null
@@ -1,71 +0,0 @@
-
-.file_frontpage {
-	margin-right: 0;
-}
-
-#intro {
-	background: #eee;
-	border: 1px solid #ccc;
-	margin: 2em auto;
-	padding: 10px;
-	-webkit-border-radius: 20px;
-	moz-border-radius: 20px;
-	border-radius: 20px;
-	width: 850px;
-}
-
-#intro-wrap {
-	float: right;
-	width: 380px;
-	margin: 10px;
-	background: #eee;
-}
-
-#intro-logo {
-	background: url('img/logointro.png') no-repeat;
-	width: 380px;
-	height: 65px;
-}
-
-#slideshow {
-	height: 300px;
-	margin-right: 400px;
-	width: 450px;
-}
-
-#slides {
-	list-style:none;
-	margin: 0;
-	padding: 0;
-}
-
-#no-show-slides {
-	display: none;
-}
-
-#slides img {
-	cursor: pointer;
-}
-
-#tinybox {
-	position: absolute;
-	display: none;
-	padding: 0;
-	border: 10px solid #eee;
-	z-index: 2000;
-}
-
-#tinymask {
-	position: absolute;
-	display: none;
-	top: 0;
-	left: 0;
-	height:100%;
-	width: 100%;
-	background: #000;
-	z-index: 1500;
-}
-
-#tinycontent {
-	background: #fff;
-}
diff --git a/style/tiny.packed.js b/style/tiny.packed.js
deleted file mode 100644
index 0780eaa..0000000
--- a/style/tiny.packed.js
+++ /dev/null
@@ -1,31 +0,0 @@
-/* scripts from http://www.leigeber.com/ */
-var TINY={};
-
-/* tinyfader */
-function T$(i){return document.getElementById(i)}function T$$(e,p){return p.getElementsByTagName(e)}TINY.fader=function(){function fade(n,p){this.n=n;this.init(p)}fade.prototype.init=function(p){var s=T$(p.id),u=this.u=T$$('li',s),l=u.length,i=this.l=this.c=this.z=0;if(p.navid&&p.activeclass){this.g=T$$('li',T$(p.navid));this.s=p.activeclass}s.style.overflow='hidden';this.a=p.auto||0;this.p=p.resume||0;for(i;i<l;i++){if(u[i].parentNode==s){u[i].style.position='absolute';this.l++;u[i].o=p.visible?100:0;u[i].style.opacity=u[i].o/100;u[i].style.filter='alpha(opacity='+u[i].o+')'}}this.pos(p.position||0,this.a?1:0,p.visible)},fade.prototype.auto=function(){this.u.ai=setInterval(new Function(this.n+'.move(1,1)'),this.a*1000)},fade.prototype.move=function(d,a){var n=this.c+d,i=d==1?n==this.l?0:n:n<0?this.l-1:n;this.pos(i,a)},fade.prototype.pos=function(i,a,v){var p=this.u[i];this.z++;p.style.zIndex=this.z;clearInterval(p.si);clearInterval(this.u.ai);this.u.ai=0;this.c=i;if(p.o>=10
 0&&!v){p.o=0;p.style.opacity=0;p.style.filter='alpha(opacity=0)'}if(this.g){for(var x=0;x<this.l;x++){this.g[x].className=x==i?this.s:''}}p.si=setInterval(new Function(this.n+'.fade('+i+','+a+')'),20)},fade.prototype.fade=function(i,a){var p=this.u[i];if(p.o>=100){clearInterval(p.si);if((a||(this.a&&this.p))&&!this.u.ai){this.auto()}}else{p.o+=5;p.style.opacity=p.o/100;p.style.filter='alpha(opacity='+p.o+')'}};return{fade:fade}}();
-
-/* tinybox */
-function T$(i){return document.getElementById(i)}TINY.box=function(){var p,m,b,fn,ic,iu,iw,ih,ia,f=0;return{show:function(c,u,w,h,a,t){if(!f){p=document.createElement('div');p.id='tinybox';m=document.createElement('div');m.id='tinymask';b=document.createElement('div');b.id='tinycontent';document.body.appendChild(m);document.body.appendChild(p);p.appendChild(b);m.onclick=TINY.box.hide;window.onresize=TINY.box.resize;f=1}if(!a&&!u){p.style.width=w?w+'px':'auto';p.style.height=h?h+'px':'auto';p.style.backgroundImage='none';b.innerHTML=c}else{b.style.display='none';p.style.width=p.style.height='100px'}this.mask();ic=c;iu=u;iw=w;ih=h;ia=a;this.alpha(m,1,80,3);if(t){setTimeout(function(){TINY.box.hide()},1000*t)}},fill:function(c,u,w,h,a){if(u){p.style.backgroundImage='';var x=window.XMLHttpRequest?new XMLHttpRequest():new ActiveXObject('Microsoft.XMLHTTP');x.onreadystatechange=function(){if(x.readyState==4&&x.status==200){TINY.box.psh(x.responseText,w,h,a)}};x.open('GET',c,1);x.s
 end(null)}else{this.psh(c,w,h,a)}},psh:function(c,w,h,a){if(a){if(!w||!h){var x=p.style.width,y=p.style.height;b.innerHTML=c;p.style.width=w?w+'px':'';p.style.height=h?h+'px':'';b.style.display='';w=parseInt(b.offsetWidth);h=parseInt(b.offsetHeight);b.style.display='none';p.style.width=x;p.style.height=y}else{b.innerHTML=c}this.size(p,w,h)}else{p.style.backgroundImage='none'}},hide:function(){TINY.box.alpha(p,-1,0,3)},resize:function(){TINY.box.pos();TINY.box.mask()},mask:function(){m.style.height=TINY.page.total(1)+'px';m.style.width='';m.style.width=TINY.page.total(0)+'px'},pos:function(){var t=(TINY.page.height()/2)-(p.offsetHeight/2);t=t<10?10:t;p.style.top=(t+TINY.page.top())+'px';p.style.left=(TINY.page.width()/2)-(p.offsetWidth/2)+'px'},alpha:function(e,d,a){clearInterval(e.ai);if(d==1){e.style.opacity=0;e.style.filter='alpha(opacity=0)';e.style.display='block';this.pos()}e.ai=setInterval(function(){TINY.box.ta(e,a,d)},20)},ta:function(e,a,d){var o=Math.round(e.style.
 opacity*100);if(o==a){clearInterval(e.ai);if(d==-1){e.style.display='none';e==p?TINY.box.alpha(m,-1,0,2):b.innerHTML=p.style.backgroundImage=''}else{e==m?this.alpha(p,1,100):TINY.box.fill(ic,iu,iw,ih,ia)}}else{var n=Math.ceil((o+((a-o)*.5)));n=n==1?0:n;e.style.opacity=n/100;e.style.filter='alpha(opacity='+n+')'}},size:function(e,w,h){e=typeof e=='object'?e:T$(e);clearInterval(e.si);var ow=e.offsetWidth,oh=e.offsetHeight,wo=ow-parseInt(e.style.width),ho=oh-parseInt(e.style.height);var wd=ow-wo>w?0:1,hd=(oh-ho>h)?0:1;e.si=setInterval(function(){TINY.box.ts(e,w,wo,wd,h,ho,hd)},20)},ts:function(e,w,wo,wd,h,ho,hd){var ow=e.offsetWidth-wo,oh=e.offsetHeight-ho;if(ow==w&&oh==h){clearInterval(e.si);p.style.backgroundImage='none';b.style.display='block'}else{if(ow!=w){var n=ow+((w-ow)*.5);e.style.width=wd?Math.ceil(n)+'px':Math.floor(n)+'px'}if(oh!=h){var n=oh+((h-oh)*.5);e.style.height=hd?Math.ceil(n)+'px':Math.floor(n)+'px'}this.pos()}}}}();TINY.page=function(){return{top:function()
 {return document.documentElement.scrollTop||document.body.scrollTop},width:function(){return self.innerWidth||document.documentElement.clientWidth||document.body.clientWidth},height:function(){return self.innerHeight||document.documentElement.clientHeight||document.body.clientHeight},total:function(d){var b=document.body,e=document.documentElement;return d?Math.max(Math.max(b.scrollHeight,e.scrollHeight),Math.max(b.clientHeight,e.clientHeight)):Math.max(Math.max(b.scrollWidth,e.scrollWidth),Math.max(b.clientWidth,e.clientWidth))}}}();
-
-/* start slideshow */
-var slideshow=new TINY.fader.fade('slideshow',
-{
-  id:'slides',
-  auto:5,
-  visible:true,
-  position:Math.floor(Math.random()*4),
-  resume:true
-});
-
-/* slide click events */
-var content1 = '<img src="http://cdn.xfce.org/frontpage/intro-1.png" width="900" height="600" alt="" />';
-T$('intro1').onclick = function(){TINY.box.show(content1,0,900,600,0)}
-
-var content2 = '<img src="http://cdn.xfce.org/frontpage/intro-2.png" width="900" height="600" alt="" />';
-T$('intro2').onclick = function(){TINY.box.show(content2,0,900,600,0)}
-
-var content3 = '<img src="http://cdn.xfce.org/frontpage/intro-3.png" width="900" height="600" alt="" />';
-T$('intro3').onclick = function(){TINY.box.show(content3,0,900,600,0)}
-
-var content4 = '<img src="http://cdn.xfce.org/frontpage/intro-4.png" width="900" height="600" alt="" />';
-T$('intro4').onclick = function(){TINY.box.show(content4,0,900,600,0)}
diff --git a/style/tinyslider.js b/style/tinyslider.js
new file mode 100644
index 0000000..9eaeb71
--- /dev/null
+++ b/style/tinyslider.js
@@ -0,0 +1,48 @@
+var TINY={};
+function T$(i){return document.getElementById(i)}
+function T$$(e,p){return p.getElementsByTagName(e)}
+TINY.slider=function(){
+function slide(n,p){this.n=n; this.init(p)}
+slide.prototype.init=function(p){
+var s=this.x=T$(p.id), u=this.u=T$$('ul',s)[0], c=this.m=T$$('li',u), l=c.length, i=this.l=this.c=0; this.b=1;
+if(p.navid&&p.activeclass){this.g=T$$('li',T$(p.navid)); this.s=p.activeclass}
+this.a=p.auto||0; this.p=p.resume||0; this.r=p.rewind||0; this.e=p.elastic||false; this.v=p.vertical||0; s.style.overflow='hidden';
+for(i;i<l;i++){if(c[i].parentNode==u){this.l++}}
+if(this.v){;
+u.style.top=0; this.h=p.height||c[0].offsetHeight; u.style.height=(this.l*this.h)+'px'}else{
+u.style.left=0; this.w=p.width||c[0].offsetWidth; u.style.width=(this.l*this.w)+'px'}
+this.nav(p.position||0);
+if(p.position){this.pos(p.position||0,this.a?1:0,1)}else if(this.a){this.auto()}
+if(p.left){this.sel(p.left)}
+if(p.right){this.sel(p.right)}},
+slide.prototype.auto=function(){
+this.x.ai=setInterval(new Function(this.n+'.move(1,1,1)'),this.a*1000)},
+slide.prototype.move=function(d,a){
+var n=this.c+d;if(this.r){n=d==1?n==this.l?0:n:n<0?this.l-1:n}
+this.pos(n,a,1)},slide.prototype.pos=function(p,a,m){
+var v=p; clearInterval(this.x.ai); clearInterval(this.x.si);
+if(!this.r){if(m){if(p==-1||(p!=0&&Math.abs(p)%this.l==0)){this.b++;
+for(var i=0;i<this.l;i++){this.u.appendChild(this.m[i].cloneNode(1))}
+this.v?this.u.style.height=(this.l*this.h*this.b)+'px':this.u.style.width=(this.l*this.w*this.b)+'px';}
+if(p==-1||(p<0&&Math.abs(p)%this.l==0)){
+this.v?this.u.style.top=(this.l*this.h*-1)+'px':this.u.style.left=(this.l*this.w*-1)+'px'; v=this.l-1}}else if(this.c>this.l&&this.b>1){
+v=(this.l*(this.b-1))+p; p=v}}
+var t=this.v?v*this.h*-1:v*this.w*-1, d=p<this.c?-1:1; this.c=v; var n=this.c%this.l; this.nav(n);
+if(this.e){t=t-(8*d)}
+this.x.si=setInterval(new Function(this.n+'.slide('+t+','+d+',1,'+a+')'),10)},
+slide.prototype.nav=function(n){
+if(this.g){for(var i=0;i<this.l;i++){this.g[i].className=i==n?this.s:''}}},
+slide.prototype.slide=function(t,d,i,a){
+var o=this.v?parseInt(this.u.style.top):parseInt(this.u.style.left);
+if(o==t){clearInterval(this.x.si);
+if(this.e&&i<3){
+this.x.si=setInterval(new Function(this.n+'.slide('+(i==1?t+(12*d):t+(4*d))+','+(i==1?(-1*d):(-1*d))+','+(i==1?2:3)+','+a+')'),10)}else{
+if(a||(this.a&&this.p)){this.auto()}
+if(this.b>1&&this.c%this.l==0){this.clear()}}}else{
+var v=o-Math.ceil(Math.abs(t-o)*.1)*d+'px';
+this.v?this.u.style.top=v:this.u.style.left=v}},
+slide.prototype.clear=function(){
+var c=T$$('li',this.u), t=i=c.length; this.v?this.u.style.top=0:this.u.style.left=0; this.b=1; this.c=0;
+for(i;i>0;i--){var e=c[i-1];if(t>this.l&&e.parentNode==this.u){this.u.removeChild(e); t--}}},slide.prototype.sel=function(i){
+var e=T$(i); e.onselectstart=e.onmousedown=function(){return false}}
+return{slide:slide}}();


More information about the Xfce4-commits mailing list