mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 07:00:46 +00:00
Make print info changes of a document undoable as in Cocoa.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@31671 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
942841a1d4
commit
9d5e012476
2 changed files with 18 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
|||
2010-11-27 Wolfgang Lux <wolfgang.lux@gmail.com>
|
||||
|
||||
* Source/NSDocument.m (-setPrintInfo:): Record old print info with
|
||||
the document's undo manager (if there is one) as in Cocoa.
|
||||
|
||||
2010-11-26 Gregory John Casamento <greg.casamento@gmail.com>
|
||||
|
||||
* Source/GSThemeDrawing.m: Added methods to draw NSSliderCell view.
|
||||
|
@ -54,7 +59,7 @@
|
|||
* Headers/Additions/GNUstepGUI/GSTheme.h:
|
||||
Added declaration for new method.
|
||||
|
||||
2010-11-26 Wolfgang Lux <wolfgang.lux@gmail.com>>
|
||||
2010-11-26 Wolfgang Lux <wolfgang.lux@gmail.com>
|
||||
|
||||
* Source/NSWindow.m (-performClose:): Do not discard close
|
||||
requests for a window in a modal session when the window has
|
||||
|
|
|
@ -1294,8 +1294,19 @@ originalContentsURL: (NSURL *)orig
|
|||
|
||||
- (void) setPrintInfo: (NSPrintInfo *)printInfo
|
||||
{
|
||||
NSUndoManager *undoManager = [self undoManager];
|
||||
|
||||
if (undoManager != nil)
|
||||
{
|
||||
[[undoManager prepareWithInvocationTarget: self]
|
||||
setPrintInfo: _print_info];
|
||||
// FIXME undoManager -setActionName:
|
||||
}
|
||||
ASSIGN(_print_info, printInfo);
|
||||
[self updateChangeCount: NSChangeDone];
|
||||
if (undoManager == nil)
|
||||
{
|
||||
[self updateChangeCount: NSChangeDone];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue