Sophie

Sophie

distrib > Mageia > 6 > armv5tl > by-pkgid > e1cc3578eeb13a8f3dc35d7ed58dbb61 > files > 3

dokuwiki-plugin-s5-20140521-4.mga6.src.rpm

diff -b -u .s5/renderer.php s5/renderer.php
--- a/renderer.php	2010-02-12 05:54:20.000000000 -0500
+++ b/renderer.php	2010-02-15 16:46:50.561469800 -0500
@@ -45,7 +45,7 @@
         );
         p_set_metadata($ID,array('format' => array('s5' => $headers) ));
         $this->base = DOKU_BASE.'lib/plugins/s5/ui/';
-        $this->tpl  = $this->getConf('template');
+        $this->tpl  = isset($_GET['s5theme'])?$_GET['s5theme']:$this->getConf('template');
     }
 
     /**
diff -b -u .s5/syntax.php s5/syntax.php
--- a/syntax.php	2010-02-12 05:54:20.000000000 -0500
+++ b/syntax.php	2010-02-15 16:44:57.731469800 -0500
@@ -43,7 +43,7 @@
      * Connect pattern to lexer
      */
     function connectTo($mode) {
-        $this->Lexer->addSpecialPattern('~~SLIDESHOW~~',$mode,'plugin_s5');
+        $this->Lexer->addSpecialPattern('~~SLIDESHOW[^~]*~~',$mode,'plugin_s5');
     }
 
 
@@ -51,6 +51,7 @@
      * Handle the match
      */
     function handle($match, $state, $pos, &$handler){
+    	if($match!='~~SLIDESHOW~~') return array(trim(substr($match,11,-2)));
         return array();
     }
 
@@ -61,7 +62,7 @@
         global $ID;
         if($format != 'xhtml') return false;
 
-        $renderer->doc .= '<a href="'.exportlink($ID, 's5').'" title="'.$this->getLang('view').'">';
+        $renderer->doc .= '<a href="'.exportlink($ID, 's5',sizeof($data)?array('s5theme'=>$data[0]):null).'" title="'.$this->getLang('view').'">';
         $renderer->doc .= '<img src="'.DOKU_BASE.'lib/plugins/s5/screen.gif" align="right" alt="'.$this->getLang('view').'" width="48" height="48" />';
         $renderer->doc .= '</a>';
         return true;