Skip navigation
Currently Being Moderated

[CS5]csxs::event is not  being register in  PostStartupPlugin()

Aug 31, 2011 5:15 AM

Hi All,

 

I was looking in FreeGrid Plugin that uses flex for UI.To do so it register the csxs events (for communication b/w flex panel and c++ plug-in) in PostStartupPlugin().

here is the code..

 

///Start

ASErr FreeGridPlugin::PostStartupPlugin()

{

if(csxs::event::kEventErrorCode_Success == freeGridDialogController->RegisterCSXSEventListeners())

     fIsRegistered = true;

 

return kNoErr;

}

//End

But it is not being registered here.

It also put the same code in handling the

 
Replies
  • Currently Being Moderated
    Aug 31, 2011 6:11 AM   in reply to DeepAlone

    Hi,

     

    This is a bug in this sample - you should try to register your event listeners when you recieve a kAICSXSPlugPlugSetupCompleteNotifier notification, not post startup. You can add a notifier handle and listen out for it in the usual way - FreeGrid actually does this in addition to trying to register on PostStartup.

     

    We've already fixed this for the next release of the SDK - thanks for spotting it!

     

    Louis

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 5, 2011 4:26 AM   in reply to lomorgan

    Hi Louis,

     

    I tried kAICSXSPlugPlugSetupCompleteNotifier but I was gettting compiling error showing this is undeclare.

    How did you fix it? can you plz tell?

     

    thanks

    R.

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 5, 2011 5:52 AM   in reply to INeedSol

    :-)

     

    My mistake - looks like there isn't a notification for this at all - I would try registering for event listeners as late as you can - it depends what your plugin is doing. Maybe take a look at how FreeGrid and StrokeFilter do it.

     

    Louis

     
    |
    Mark as:
  • Currently Being Moderated
    Mar 8, 2012 9:33 AM   in reply to DeepAlone

    I'm in the same boat.  Any word on when to register for these listeners?  I really need a Notifier that will allow me to do this before the user makes any moves.  Strokefilter doesn't provide any answers.

     
    |
    Mark as:
  • Currently Being Moderated
    Mar 8, 2012 12:17 PM   in reply to TheDollarBill

    HERE'S A WORKAROUND FOR THE BUG!

    It comes from David_a_Clark in another forum:

    "Ah, this is a known issue. For CS5 the workaround I used was to start an AI Timer in my plug-in's startup code which went off after '1 tick' (AI SDK terminology, IIRC). After 1 tick, PlugPlug has started up and is available to use.

     

    In the next version of AI SDK I believe there will be a 'PlugPlug set up' notifier which removes the need for the timer workaround."

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points