Skip to content

Commit

Permalink
Remove commented-out code
Browse files Browse the repository at this point in the history
  • Loading branch information
Tim committed May 10, 2015
1 parent 7b382c0 commit 9c1c06d
Showing 1 changed file with 0 additions and 16 deletions.
16 changes: 0 additions & 16 deletions src/modules/rangy-textrange.js
Original file line number Diff line number Diff line change
Expand Up @@ -680,7 +680,6 @@ rangy.createModule("TextRange", ["WrappedSelection"], function(api, module) {

/*----------------------------------------------------------------------------------------------------------------*/


function Position(nodeWrapper, offset) {
this.offset = offset;
this.nodeWrapper = nodeWrapper;
Expand Down Expand Up @@ -887,13 +886,6 @@ rangy.createModule("TextRange", ["WrappedSelection"], function(api, module) {
(!getPreviousPos() || previousPos.isTrailingSpace || previousPos.character == "\n" || (previousPos.character == " " && previousPos.characterType == COLLAPSIBLE_SPACE))) {
log.info("Current possible character is a collapsible space and preceding character either non-existent, a trailing space, follows a line break or a collapsible space, so current space is collapsed");
}
/*
// Disallow a collapsible space that follows a collapsible included space
else if (thisChar == " " &&
(!getPreviousPos() || previousPos.isTrailingSpace || previousPos.character == "\n")) {
log.info("Preceding character is a trailing space or non-existent or follows a line break and current possible character is a collapsible space, so space is collapsed");
}
*/
// Allow a leading line break unless it follows a line break
else if (thisChar == "\n" && this.isLeadingSpace) {
if (getPreviousPos() && previousPos.character != "\n") {
Expand Down Expand Up @@ -960,14 +952,6 @@ rangy.createModule("TextRange", ["WrappedSelection"], function(api, module) {
}
}

/*
// Collapse a br element that is followed by a trailing space
else if (thisChar == "\n" &&
(!(nextPos = this.nextUncollapsed()) || nextPos.isTrailingSpace)) {
log.debug("Character is a br which is followed by a trailing space or nothing. This is always collapsed.");
}
*/

if (ignoredChars.indexOf(character) > -1) {
log.debug("Character " + character + " is ignored in character options");
character = "";
Expand Down

0 comments on commit 9c1c06d

Please sign in to comment.