User:Cizagna/global.js

if( wgNamespaceNumber == -1 ) { importScriptPage('User:Cizagna/contribtools.js', 'www'); importScriptPage('User:Cizagna/filelisttools.js', 'www'); } else { importScriptPage('User:Cizagna/mwcustomeditbtns.js', 'www'); importScriptPage('User:Cizagna/forumtools.js', 'www'); importScriptPage('User:Cizagna/ajaxpatrollinks.js', 'www'); importScriptPage('FastDelete/code.js', 'dev'); // *****************************************************************	// Adds custom automatic one-click delete tabs to any deletable page. var fdButtons = []; fdButtons[fdButtons.length] = { 'summary': 'Spam', 'label' : 'S'}; // *****************************************************************	// Subpages tab if(wgNamespaceNumber!=-1) addOnloadHook(function { addTabForXSkin('ca-subpages','/wiki/Special:Prefixindex/' + encodeURIComponent(wgPageName),'Show subages of ' + wgPageName,'SubP') } ); }

// ***************************************************************** // Alternating skin tabs function skinview { var skinlink = document.location.href; var antiskin;

if(skinlink.indexOf('?')==-1) skinlink += '?'; else skinlink += '&'; skinlink += 'useskin=';

switch( skin ) { case 'awesome': case 'monaco_old': case 'monaco': antiskin = 'monobook'; break;

case 'uncyclopedia': case 'wowwiki': case 'lostbook': case 'monobook': antiskin = 'monaco'; break;

case 'answers': return; }	skinlink += antiskin;

addTabForXSkin('ca-skin0',skinlink,'Change skin to ' + antiskin,'CS');

switch( skin ) { case 'uncyclopedia': case 'wowwiki': case 'lostbook': case 'monobook': addTabForXSkin('ca-skin1',skinlink + '&usetheme=custom','Change skin to ' + antiskin + ' custom','CS-C'); break; } } addOnloadHook(skinview);

// ***************************************************************** // Add Tab For X Skin function addTabForXSkin(id,href,title,text) { switch( skin ) { case 'answers': case 'awesome': case 'monaco_old': case 'monaco': $(' ' + text + '').appendTo('#page_controls'); break; case 'uncyclopedia': case 'wowwiki': case 'lostbook': case 'monobook': $('' + text + '').appendTo('#p-cactions > .pBody > ul'); break; } };