1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-23 08:08:00 +01:00

Unbreak wrapping completion list in reverse.

This commit is contained in:
Kris Maglione
2008-11-28 09:17:00 +00:00
parent 6f0ff1992e
commit 92b0ffa75c
2 changed files with 4 additions and 1 deletions

View File

@@ -124,8 +124,9 @@ CompletionContext.prototype = {
// Temporary // Temporary
get allSubstrings() get allSubstrings()
{ {
let lists = [c.substrings for ([i, c] in Iterator(this.contextList)) if (c.hasItems && c.items.length)];
let minStart = Math.min.apply(Math, [c.offset for ([k, c] in Iterator(this.contextList)) if (c.hasItems && c.items.length)]);
let self = this; let self = this;
let minStart = Math.min.apply(Math, [context.offset for ([k, context] in Iterator(this.contexts)) if (context.items.length && context.hasItems)]);
let items = this.contextList.map(function (context) { let items = this.contextList.map(function (context) {
if (!context.hasItems) if (!context.hasItems)
return []; return [];

View File

@@ -1417,6 +1417,8 @@ function ItemList(id) //{{{
nodes[i] = row; nodes[i] = row;
for (let [i, row] in util.Array.iterator2(nodes)) for (let [i, row] in util.Array.iterator2(nodes))
{ {
if (!row)
continue;
let display = (i >= start && i < end); let display = (i >= start && i < end);
if (display && row.parentNode != items) if (display && row.parentNode != items)
{ {