Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • EspaƱol
      • FranƧais
      • PortuguĆŖs
  • ę—„ęœ¬čŖžć‚³ćƒŸćƒ„ćƒ‹ćƒ†ć‚£
  • ķ•œźµ­ ģ»¤ė®¤ė‹ˆķ‹°
0

Event register problem

Guest
Apr 11, 2013 Apr 11, 2013

hi,

i am new in adobe bridge.

when i select a thumbnail or file in content that time i want to $.writeln("someting");

for this i register e event but that is not working please help me in this regards. i'm working on adobe bridge cs5

i'm writing this code in  SnpListenDocEvents.jsx file.

onThumbnailEvent = function( event ){

          if( event.object .constructor.name == "Thumbnail" ){  // also use if( event.object instanceof Thumbnail ){

                    if( event.type == "select" ) {

                              $.writeln("your code is here");

                              return {handled:true};//stop processing event handlers

                    }

          }

}

// register the handler

allDocEventHandlers = { handler: onThumbnailEvent };

app.eventHandlers.push( allDocEventHandlers );

TOPICS
Scripting
733
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Guru , Apr 11, 2013 Apr 11, 2013

#target bridge

thumbSelected = function( event ) {

   

    if  ( event.object instanceof Document && event.type == 'selectionsChanged' ) {

       

        $.writeln( 'Fluff…' );

   

    } return { handled:false };

   

};

app.eventHandlers.push( {handler: thumbSelected} );

Translate
Guru ,
Apr 11, 2013 Apr 11, 2013

#target bridge

thumbSelected = function( event ) {

   

    if  ( event.object instanceof Document && event.type == 'selectionsChanged' ) {

       

        $.writeln( 'Fluff…' );

   

    } return { handled:false };

   

};

app.eventHandlers.push( {handler: thumbSelected} );

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Apr 15, 2013 Apr 15, 2013

Hi,

thank you very much for your valuable reply.

would you pls give me reference of list event type like event.type == 'selectionsChanged' and more

which is help me to build custom plugin

thanks

mahedi

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guru ,
Apr 15, 2013 Apr 15, 2013
LATEST

These are all listed in the Bridge Scripting Guide… This is available as PDF as part of the SDK download from the dev center… or you can find them listed in the ESTK Object Model Viewer…

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines