From: Reini U. <ru...@us...> - 2007-07-01 09:36:10
|
Update of /cvsroot/phpwiki/phpwiki/themes/MacOSX In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28390/themes/MacOSX Modified Files: themeinfo.php Log Message: themes are now easier derivable classes from other themes. removed global code setters, switched to $WikiTheme->load() in main Index: themeinfo.php =================================================================== RCS file: /cvsroot/phpwiki/phpwiki/themes/MacOSX/themeinfo.php,v retrieving revision 1.55 retrieving revision 1.56 diff -u -2 -b -p -d -r1.55 -r1.56 --- themeinfo.php 14 Jun 2004 11:26:49 -0000 1.55 +++ themeinfo.php 1 Jul 2007 09:36:10 -0000 1.56 @@ -86,63 +86,61 @@ class Theme_MacOSX extends Theme { return $link; } -} - -$WikiTheme = new Theme_MacOSX('MacOSX'); -// CSS file defines fonts, colors and background images for this -// style. The companion '*-heavy.css' file isn't defined, it's just -// expected to be in the same directory that the base style is in. + function load() { + // CSS file defines fonts, colors and background images for this + // style. The companion '*-heavy.css' file isn't defined, it's just + // expected to be in the same directory that the base style is in. -// This should result in phpwiki-printer.css being used when -// printing or print-previewing with style "PhpWiki" or "MacOSX" selected. -$WikiTheme->setDefaultCSS('MacOSX', + // This should result in phpwiki-printer.css being used when + // printing or print-previewing with style "PhpWiki" or "MacOSX" selected. + $this->setDefaultCSS('MacOSX', array('' => 'MacOSX.css', 'print' => 'phpwiki-printer.css')); -// This allows one to manually select "Printer" style (when browsing page) -// to see what the printer style looks like. -$WikiTheme->addAlternateCSS(_("Printer"), 'phpwiki-printer.css', 'print, screen'); -$WikiTheme->addAlternateCSS(_("Top & bottom toolbars"), 'MacOSX-topbottombars.css'); + // This allows one to manually select "Printer" style (when browsing page) + // to see what the printer style looks like. + $this->addAlternateCSS(_("Printer"), 'phpwiki-printer.css', 'print, screen'); + $this->addAlternateCSS(_("Top & bottom toolbars"), 'MacOSX-topbottombars.css'); -/** + /** * The logo image appears on every page and links to the HomePage. */ -$WikiTheme->addImageAlias('logo', WIKI_NAME . 'Logo.png'); + $this->addImageAlias('logo', WIKI_NAME . 'Logo.png'); -/** + /** * The Signature image is shown after saving an edited page. If this * is set to false then the "Thank you for editing..." screen will * be omitted. */ -$WikiTheme->addImageAlias('signature', WIKI_NAME . "Signature.png"); -// Uncomment this next line to disable the signature. -//$WikiTheme->addImageAlias('signature', false); + $this->addImageAlias('signature', WIKI_NAME . "Signature.png"); + // Uncomment this next line to disable the signature. + //$this->addImageAlias('signature', false); -/* + /* * Link icons. */ -$WikiTheme->setLinkIcon('http'); -$WikiTheme->setLinkIcon('https'); -$WikiTheme->setLinkIcon('ftp'); -$WikiTheme->setLinkIcon('mailto'); -$WikiTheme->setLinkIcon('interwiki'); -$WikiTheme->setLinkIcon('wikiuser'); -$WikiTheme->setLinkIcon('*', 'url'); + $this->setLinkIcon('http'); + $this->setLinkIcon('https'); + $this->setLinkIcon('ftp'); + $this->setLinkIcon('mailto'); + $this->setLinkIcon('interwiki'); + $this->setLinkIcon('wikiuser'); + $this->setLinkIcon('*', 'url'); -$WikiTheme->setButtonSeparator(""); //use no separator instead of default + $this->setButtonSeparator(""); //use no separator instead of default -$WikiTheme->addButtonAlias('?', 'uww'); -$WikiTheme->addButtonAlias(_("Lock Page"), "Lock Page"); -$WikiTheme->addButtonAlias(_("Unlock Page"), "Unlock Page"); -$WikiTheme->addButtonAlias(_("Page Locked"), "Page Locked"); -$WikiTheme->addButtonAlias("...", "alltime"); + $this->addButtonAlias('?', 'uww'); + $this->addButtonAlias(_("Lock Page"), "Lock Page"); + $this->addButtonAlias(_("Unlock Page"), "Unlock Page"); + $this->addButtonAlias(_("Page Locked"), "Page Locked"); + $this->addButtonAlias("...", "alltime"); -/** + /** * WikiWords can automatically be split by inserting spaces between * the words. The default is to leave WordsSmashedTogetherLikeSo. */ -//$WikiTheme->setAutosplitWikiWords(false); + //$this->setAutosplitWikiWords(false); -/* + /* * You may adjust the formats used for formatting dates and times * below. (These examples give the default formats.) @@ -152,6 +150,10 @@ $WikiTheme->addButtonAlias("...", "allti * user's time zone. */ -$WikiTheme->setDateFormat("%A, %B %d, %Y"); // must not contain time -$WikiTheme->setTimeFormat("%I:%M:%S %p"); + $this->setDateFormat("%A, %B %d, %Y"); // must not contain time + $this->setTimeFormat("%I:%M:%S %p"); + } +} + +$WikiTheme = new Theme_MacOSX('MacOSX'); // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |