• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: How to copy something to the pasteboard in a service call
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to copy something to the pasteboard in a service call


  • Subject: Re: How to copy something to the pasteboard in a service call
  • From: Graham Cox <email@hidden>
  • Date: Sun, 18 Apr 2010 22:54:13 +1000

On 16/04/2010, at 4:41 PM, Kay Jurkuhn wrote:

> Hi list!
>
> I'm implementing an application service. The desired result of the action is to copy a string to the pasteboard.
> But as the communication between caller and called service goes via the pasteboard the caller will delete
> the content of the pasteboard at the end of the call.
>
> What would be the best way to keep my string on the pasteboard publicly accessible after the call?
>
> Set up a timer?


Application services communicate through *A* pasteboard, not through *THE* pasteboard. From the introduction to services:

"Services are performed by transferring data back and forth between applications through a shared pasteboard. Note that the two applications—service requester and service provider—are completely separate; they do not run in a shared memory space. The pasteboard holding the data is specific to the service request and does not normally interfere with the standard Copy/Paste pasteboard."

So you can place your string on the services pasteboard you're passed and the general pasteboard for normal use.

--Graham


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >How to copy something to the pasteboard in a service call (From: Kay Jurkuhn <email@hidden>)

  • Prev by Date: Re: Strange "autoreleased with no pool in place" message
  • Next by Date: Re: Text file
  • Previous by thread: How to copy something to the pasteboard in a service call
  • Next by thread: Any Cocoa Developers in Denver?
  • Index(es):
    • Date
    • Thread