Skip to main content
DBarranca
Legend
February 21, 2014
Question

com.adobe.csxs.events list

  • February 21, 2014
  • 2 replies
  • 11526 views

Hello,

is there a list of Panel's related (minimized, closed, iconized, moved, resized, etc) events that are supported so far?

 

Thank you

 

Davide Barranca

 

(Link removed)

 

 

    This topic has been closed for replies.

    2 replies

    Hallgrimur Bjornsson
    Inspiring
    April 8, 2014

    Does the list here not help? : http://adobe.ly/1cWBggl

    DBarranca
    DBarrancaAuthor
    Legend
    April 8, 2014

    Hallgrimur,

    you read my mind - I was exactly on that PDF!

    Besides:

    • documentAfterActivate,
    • documentAfterDeactivate,
    • documentAfterSave,
    • applicationBeforeQuit,
    • applicationActivate

    which are about the host app and its open documents (say Photoshop and an open image), talking about strictly Panel's stuff, there's only the possibility to RegisterExtensionUnloadCallback() - that is, before the extension closes, am I right? No resize / collapse events if I understand correctly (to my needs the unload is enough).

    Also, do I get it right that GetWorkingDirectory(), IsRunning(), OnQuit(), they all refer to Processes - that is external commands such as "ls" in the terminal - and not the extension (the panel) itself?

    Thank you!

    Davide

    ----

    UPDATE

    As a side note, it's not clear from the CC_Extension_SDK.pdf that we should use it like "window.cep.category.method", where category is either fs, process, util, encoding. You get it if you inspect the source code.

    Hallgrimur Bjornsson
    Inspiring
    April 8, 2014

    Hi,

     

    There is no resize/collapse event at this time. I'm copying a response to a similar question raised elsewhere:

     

    This API is to register a callback which can be triggered while unloading extension. But no heavy or blocking code is expected in this callback. Here I think alert is sort of blocking call to show up a message box, but you could try to use console.log or example below to see if this callback is working.

     

    Example

    window.cep.util.registerExtensionUnloadCallback(function(){

    window.cep.fs.writeFile("C:
    test.txt", "Hello");

    });

     

    Also please keep in mind that there're some limitations for this API.

    1. If registerExtensionUnloadCallback is called more than once, the last callback function that's successfully registered will be used.

    2. The callback function must be context-independent and it is executed in the mainframe's context.

    3. The callback function must not use APIs defined in CSInterface.js.

     

    The GetWorkingDirectory(), IsRunning(), OnQuit() callbacks are not 'events' like documentAfterActivate, documentAfterDeactivate and the others you listed. You are correct that it refers to external processes, like 'ls'. But external processes can be any executable programs or scripts. You could write to a database oor ftp a file or copy a folder. Whatever you want to do.

     

     

    Best regards,

    Hallgrimur

    --

    Hallgrimur Th. Bjornsson | Product Manager | Adobe | Tel: ( removed)

     

     

    DBarranca
    DBarrancaAuthor
    Legend
    April 8, 2014

    Bump!