docs/scripts/sunlight.js
function switchToEmbeddedLanguageIfNecessary(context) {
			var i,
				embeddedLanguage;
			
			for (i = 0; i < context.language.embeddedLanguages.length; i++) {
				if (!languages[context.language.embeddedLanguages[i].language]) {
					//unregistered language
					continue;
				}
				
				embeddedLanguage = clone(context.language.embeddedLanguages[i]);
				
				if (embeddedLanguage.switchTo(context)) {
					embeddedLanguage.oldItems = clone(context.items);
					context.embeddedLanguageStack.push(embeddedLanguage);
					context.language = languages[embeddedLanguage.language];
					context.items = merge(context.items, clone(context.language.contextItems));
					break;
				}
			}
		}
function switchToEmbeddedLanguageIfNecessary(context) {
			var i,
				embeddedLanguage;
			
			for (i = 0; i < context.language.embeddedLanguages.length; i++) {
				if (!languages[context.language.embeddedLanguages[i].language]) {
					//unregistered language
					continue;
				}
				
				embeddedLanguage = clone(context.language.embeddedLanguages[i]);
				
				if (embeddedLanguage.switchTo(context)) {
					embeddedLanguage.oldItems = clone(context.items);
					context.embeddedLanguageStack.push(embeddedLanguage);
					context.language = languages[embeddedLanguage.language];
					context.items = merge(context.items, clone(context.language.contextItems));
					break;
				}
			}
		}
function switchToEmbeddedLanguageIfNecessary ( context ) { var i , embeddedLanguage ; for ( i = 0 ; i < context . language . embeddedLanguages . length ; i ++ ) { if ( ! languages [ context . language . embeddedLanguages [ i ] . language ] ) { //unregistered language continue ; } embeddedLanguage = clone ( context . language . embeddedLanguages [ i ] ) ; if ( embeddedLanguage . switchTo ( context ) ) { embeddedLanguage . oldItems = clone ( context . items ) ; context . embeddedLanguageStack . push ( embeddedLanguage ) ; context . language = languages [ embeddedLanguage . language ] ; context . items = merge ( context . items , clone ( context . language . contextItems ) ) ; break ; } } }
called before processing the current
called before processing the current