Re: [SOLVED] System Services and Mail.app
Re: [SOLVED] System Services and Mail.app
- Subject: Re: [SOLVED] System Services and Mail.app
- From: "Dr. Rolf Jansen" <email@hidden>
- Date: Thu, 27 Apr 2006 16:33:05 -0300
Am 27.04.2006 um 15:01 schrieb Dr. Rolf Jansen:
Thank you so much for your reply. Your explanation sounds very
reasonable and it is supported by further tests I have made in
the meantime. Indeed, the "Capitalize String" sample service
pastes back the contents of the generalPasteboard.
I definitely will give your workaround a try at the next weekend.
Sorry, but I could not wait until the weekend, because I was somewhat
exited to see the solution. Thanks to Mark Munz very helpfull reply,
I managed to solve the problem.
My solution according to the suggestion from Mark Munz goes like this:
NSString *activeAppName = [[[NSWorkspace sharedWorkspace]
activeApplication] objectForKey:@"NSApplicationName"];
...
... // do the service
...
if ([activeAppName isEqualToString:@"Mail"])
replyPBoard = [NSPasteboard generalPasteboard];
else
replyPBoard = inputPBoard; // the NSPasteboard parameter
// of the do service method
This works very well for me now.
Mark, thank you so much again.
Best regards
Dr. Rolf Jansen
Director R&D
SurTec International GmbH
Zwingenberg Bergstrasse
Germany
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden