Difference between revisions 137879 and 137887 on testwiki/// mw:User:PerfektesChaos/js/paneMarker/?.js /// 2012-06-19 [email protected] /// Fingerprint: #0#0# // Mark browser panes (tabbed or window) if particular action taken. // Try to exchange wiki-favicon for a red one if editing a wiki page. // Insert indicating character before document title. // Requires: JavaScript 1.3 (contracted; show full) // < .leave // mw.config.get() // Requires: JavaScript 1.3 String.fromCharCode() // 2012-06-19 [email protected] var c = true, learn = true; if ( this.config.leave ) { document.title = ⏎ ⏎ mw.config.get( "wgPageName" ) + " * ".replace( /_/g, " " ) + " * " + mw.config.get( "wgSiteName" ); } else if ( this.heads.indexOf( this.site ) < 0 ) { c = this.config[ "char" + action ]; learn = false; } if ( typeof this.config.chars === "boolean" ) { if ( c === true ) { c = this.config.chars; } } if ( c ) { if ( learn ) { c = this.config[ "char" + action ]; if ( c !== undefined ) { learn = false; } } if ( learn ) { switch ( action ) { case "Diff" : c = ( this.config.lowChar ? "±" : 916 ); // 'Δ' break; case "History" : c = ( this.config.lowChar ? "^" : 8595 ); // '↓' break; case "Links" : c = ( this.config.lowChar ? ">" : 8594 ); // '→' break; case "Vitally" : if ( c === -1true && ! this.lazy ) { c = false; break; } c = "*"; break; default: c = false; (contracted; show full) // Run paneMarker in this particular situation // Precondition: // Page may be under loading, but not necessarily ready. // .using( [ "user", "mediawiki.util" ] ) // Uses: // > .opt.* // > .jQuery.browser // > .config.favicon⏎ // >< this.* // < .config.* // < .site // < .nsN // < .lazy // .flag() // mw.config.get() // mw.util.getParamValue() (contracted; show full)// Emacs // Local Variables: // encoding: utf-8-dos // coding: utf-8-dos // fill-column: 80 // End: /// EOF </nowiki> paneMarker/?.js All content in the above text box is licensed under the Creative Commons Attribution-ShareAlike license Version 4 and was originally sourced from https://test.wikipedia.org/w/index.php?diff=prev&oldid=137887.
![]() ![]() This site is not affiliated with or endorsed in any way by the Wikimedia Foundation or any of its affiliates. In fact, we fucking despise them.
|