* Source/NSTextView.m (-selectionRangeForProposedRange:granularity:):

Remove a special case which caused this method to refuse to
expand a range {[string length], 0}.
This was why the align left/center/right menu items didn't work
in Ink when the insertion point was at the end of a document.
The behaviour should match OS X now.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@32935 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Eric Wasylishen 2011-04-27 09:19:53 +00:00
parent a2f673e468
commit ea58698be4
2 changed files with 9 additions and 7 deletions

View file

@ -1,3 +1,12 @@
2011-04-27 Eric Wasylishen <ewasylishen@gmail.com>
* Source/NSTextView.m (-selectionRangeForProposedRange:granularity:):
Remove a special case which caused this method to refuse to
expand a range {[string length], 0}.
This was why the align left/center/right menu items didn't work
in Ink when the insertion point was at the end of a document.
The behaviour should match OS X now.
2011-04-26 Eric Wasylishen <ewasylishen@gmail.com>
* Headers/AppKit/NSSavePanel.h:

View file

@ -3451,13 +3451,6 @@ afterString in order over charRange.
NSString *string = [self string];
unsigned length = [string length];
if (proposedCharRange.location >= length)
{
proposedCharRange.location = length;
proposedCharRange.length = 0;
return proposedCharRange;
}
if (NSMaxRange (proposedCharRange) > length)
{
proposedCharRange.length = length - proposedCharRange.location;