Lightroom SDK: add wait 'n validate param to some functions.

  • 4
  • Idea
  • Updated 7 years ago
There are several functions that initiate things that won't be complete by the time the function returns, i.e. they get done asynchronously by Lightroom in the background, some examples:

catalog:setActiveSources
catalog:setSelectedPhoto
catalog:setViewFilter

For functions like these, it would be good to be able to pass a flag to delay return until settling is complete and a meaningful status can be provided.

I have too much code in my plugins to initiate a function, sleep, see if its settled yet, initiate again, sleep, see if its settled yet, until it "takes", or I give up.

I would prefer to be able to offload the wait-and-validate to Lightroom.

Rob
Photo of Rob Cole

Rob Cole

  • 4831 Posts
  • 382 Reply Likes

Posted 7 years ago

  • 4
Photo of jdv

jdv, Champion

  • 728 Posts
  • 56 Reply Likes
Mmmm. Busy waits are so awesome.