[webkit-reviews] review canceled: [Bug 71625] Web Inspector: Preserve an indentation level when inserting a new line : [Attachment 113782] First try
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Nov 7 17:03:20 PST 2011
Nikita Vasilyev <me at elv1s.ru> has canceled Nikita Vasilyev <me at elv1s.ru>'s
request for review:
Bug 71625: Web Inspector: Preserve an indentation level when inserting a new
line
https://bugs.webkit.org/show_bug.cgi?id=71625
Attachment 113782: First try
https://bugs.webkit.org/attachment.cgi?id=113782&action=review
------- Additional Comments from Nikita Vasilyev <me at elv1s.ru>
We used to revert selection range twice. From now on a selection start point is
always ≤ the end point:
handleTabKeyPress:
- if (range.startLine > range.endLine || (range.startLine ===
range.endLine && range.startColumn > range.endColumn))
- range = new WebInspector.TextRange(range.endLine, range.endColumn,
range.startLine, range.startColumn);
_getSelection:
- if (selection.anchorNode === selectionRange.startContainer &&
selection.anchorOffset === selectionRange.startOffset)
- return new WebInspector.TextRange(start.line, start.column,
end.line, end.column);
- else
- return new WebInspector.TextRange(end.line, end.column,
start.line, start.column);
+ return new WebInspector.TextRange(start.line, start.column, end.line,
end.column);
None of the shortcuts work in readOnly mode, so I've moved readOnly check into
_handleKeyDown.
I haven't simplified the rest. I don't think I can.
More information about the webkit-reviews
mailing list