(originalPos, newPos, fillOnly)
| 1406 | return result; |
| 1407 | } |
| 1408 | function trackbackPositions(originalPos, newPos, fillOnly) { |
| 1409 | var result; |
| 1410 | if (originalPos === undefined) { |
| 1411 | for (originalPos = newPos - 1; originalPos > 0; originalPos--) { |
| 1412 | if (getMaskSet().validPositions[originalPos]) break; |
| 1413 | } |
| 1414 | } |
| 1415 | for (var ps = originalPos; ps < newPos; ps++) { |
| 1416 | if (getMaskSet().validPositions[ps] === undefined && !isMask(ps, true)) { |
| 1417 | var vp = ps == 0 ? getTest(ps) : getMaskSet().validPositions[ps - 1]; |
| 1418 | if (vp) { |
| 1419 | var tests = getTests(ps).slice(); |
| 1420 | if (tests[tests.length - 1].match.def === "") tests.pop(); |
| 1421 | var bestMatch = determineTestTemplate(ps, tests); |
| 1422 | bestMatch = $.extend({}, bestMatch, { |
| 1423 | input: getPlaceholder(ps, bestMatch.match, true) || bestMatch.match.def |
| 1424 | }); |
| 1425 | bestMatch.generatedInput = true; |
| 1426 | revalidateMask(ps, bestMatch, true); |
| 1427 | if (fillOnly !== true) { |
| 1428 | var cvpInput = getMaskSet().validPositions[newPos].input; |
| 1429 | getMaskSet().validPositions[newPos] = undefined; |
| 1430 | result = isValid(newPos, cvpInput, true, true); |
| 1431 | } |
| 1432 | } |
| 1433 | } |
| 1434 | } |
| 1435 | return result; |
| 1436 | } |
| 1437 | function revalidateMask(pos, validTest, fromSetValid, validatedPos) { |
| 1438 | function IsEnclosedStatic(pos, valids, selection) { |
| 1439 | var posMatch = valids[pos]; |
no test coverage detected