mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-22 16:33:29 +00:00
Futher improvements to NSUndoManager.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@20593 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
142eee89f4
commit
5cc2211a8e
2 changed files with 15 additions and 2 deletions
|
@ -1,3 +1,12 @@
|
|||
2005-01-21 22:08 Gregory John Casamento <greg_casamento@yahoo.com>
|
||||
|
||||
* Source/NSUndoManager.m: [NSUndoManager redo] and
|
||||
[NSUndoManager undoNestedGroup] moved the call to actionName
|
||||
to a later point in both methods to get the name from the
|
||||
"groupToRedo" or the "groupToUndo" respectively. This
|
||||
corrects the issue with the wrong name sometimes appearing
|
||||
in the redo/undo menu items.
|
||||
|
||||
2005-01-16 07:59 Gregory John Casamento <greg_casamento@yahoo.com>
|
||||
|
||||
* Source/NSUndoManager.m: Added code to properly set the
|
||||
|
|
|
@ -582,7 +582,7 @@
|
|||
*/
|
||||
- (void) redo
|
||||
{
|
||||
NSString *name = [NSString stringWithString: [self redoActionName]];
|
||||
NSString *name = nil;
|
||||
|
||||
if (_isUndoing || _isRedoing)
|
||||
{
|
||||
|
@ -604,6 +604,8 @@
|
|||
groupToRedo = RETAIN([_redoStack lastObject]);
|
||||
[_redoStack removeLastObject];
|
||||
|
||||
name = [NSString stringWithString: [groupToRedo actionName]];
|
||||
|
||||
oldGroup = _group;
|
||||
_group = nil;
|
||||
_isRedoing = YES;
|
||||
|
@ -965,7 +967,7 @@
|
|||
*/
|
||||
- (void) undoNestedGroup
|
||||
{
|
||||
NSString *name = [NSString stringWithString: [self undoActionName]];
|
||||
NSString *name = nil;
|
||||
PrivateUndoGroup *oldGroup;
|
||||
PrivateUndoGroup *groupToUndo;
|
||||
|
||||
|
@ -1011,6 +1013,8 @@
|
|||
[_undoStack removeLastObject];
|
||||
}
|
||||
|
||||
name = [NSString stringWithString: [groupToUndo actionName]];
|
||||
|
||||
[self beginUndoGrouping];
|
||||
[groupToUndo perform];
|
||||
RELEASE(groupToUndo);
|
||||
|
|
Loading…
Reference in a new issue