Fix an oversight in the previous check-in that was causing a crash

when moving text via drag and drop to the end of a text view.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@27126 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Wolfgang Lux 2008-11-24 10:27:10 +00:00
parent 30fb47d4bb
commit 7e739d6fa3
2 changed files with 1 additions and 2 deletions

View file

@ -50,7 +50,6 @@
* Source/NSTextView.m (-updateDragTypeRegistration): Register drag
types for non-rich text NSTextViews, too.
>>>>>>> .r27123
2008-11-22 20:46-EST Gregory John Casamento <greg_casamento@yahoo.com>
* Source/GSNibCompatibility.m: Further improvements to nib loading

View file

@ -4618,11 +4618,11 @@ other than copy/paste or dragging. */
[self _draggingReleaseInsertionPoint];
return NO;
}
[self replaceCharactersInRange: changeRange withString: @""];
if (_dragTargetLocation >= NSMaxRange(changeRange))
_dragTargetLocation -= changeRange.length;
else if (_dragTargetLocation >= changeRange.location)
_dragTargetLocation = changeRange.location;
[self replaceCharactersInRange: changeRange withString: @""];
}
return [self readSelectionFromPasteboard: [sender draggingPasteboard]];
}