User:PerfektesChaos/js/citoidWikitext/core/d.js: Difference between revisions

Content deleted Content added
-1.21
 
-1.22
Line 1:
/// User:PerfektesChaos/js/citoidWikitext/core.js
// Execute core functionality for citoid on wikitext source editing
/// 2015-06-0405 PerfektesChaos@de.wikipedia
// ResourceLoader: compatible;
// dependencies: --
Line 17:
( function ( mw, $ ) {
"use strict";
var VERSION = -1.2122,
MW_LIB = "citoidWikitext",
APIC = { },
Line 141:
// TASK.follow()
// Remark: Used as event handler -- 'this' is not APIC
// 2015-0506-0105 PerfektesChaos@de.wikipedia
var got, i, leap, lone, n, q;
if ( arrived &&
typeof arrived === "object" &&
Line 148:
got = arrived[ 0 ];
if ( typeof got.url === "string" ) {
forn ( i = 0; i < APIC.queries.length; i++ ) {
lone = ( n === 1 );
if ( lone ) {
lone = APIC.queries[ 0 ];
if ( lone === got.url ) {
lone = false;
} else {
APIC.queries[ 0 ] = got.url;
}
}
for ( i = 0; i < n; i++ ) {
q = APIC.queries[ i ];
if ( q === got.url ) {
Line 157 ⟶ 167:
} // for i
if ( ! leap ) {
if ( lone ) {
APIC.queries[ 0 ].urlQuery = lone;
}
TASK.follow();
}