Create and use local NSPasteboard object in -performService:....

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@13815 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Alexander Malmberg 2002-06-09 23:25:58 +00:00
parent 1242cd434e
commit cf79e927c7
2 changed files with 15 additions and 2 deletions

View file

@ -1,11 +1,16 @@
2002-06-10 Alexander Malmberg <alexander@malmberg.org>
* Source/GSServicesManager.m (-performService:...): Create
and use a local copy of the NSPasteboard.
2002-06-08 Alexander Malmberg <alexander@malmberg.org>
* Source/NSWindow (-_initDefaults): Make _miniaturizedImage
* Source/NSWindow.m (-_initDefaults): Make _miniaturizedImage
default to the application icon.
2002-06-08 Alexander Malmberg <alexander@malmberg.org>
* Source/GSServicesProvider.m (-doService:): Only try to
* Source/GSServicesManager.m (-doService:): Only try to
write/read selection if the send/return type isn't nil.
Fix calls to NSRunAlertPanel() so they don't do printf()
expansion on the message twice.

View file

@ -316,6 +316,14 @@ NSRegisterServicesProvider(id provider, NSString *name)
SEL msgSel = NSSelectorFromString(name);
IMP msgImp;
/*
Create a local NSPasteboard object for this pasteboard. If we try to
use the remote NSPasteboard object, we get trouble when setting property
lists since the remote NSPasteboard fails to serialize the local property
list objects for sending to gpbs.
*/
pb = [NSPasteboard pasteboardWithName: [pb name]];
if (obj != nil && [obj respondsToSelector: msgSel])
{
msgImp = [obj methodForSelector: msgSel];