Copy link to clipboard
Copied
Is there a way to know that a new project (and specifically, a new bin) was opened from a JSX panel ?
Thanks,
Oran
Copy link to clipboard
Copied
There is no programmatic way of distinguishing between a "pure" user interaction (point&click) and an "automated" Panel action.
Copy link to clipboard
Copied
Thanks.
I don't want to differ between bins that were added "automatically" (a bin added by a panel) or "manually" (added by the user).
What I'd like to be aware of is that a new bin was added (be it by the user or by the panel).
I can of course use polling to enumerate the bins - and find out that a new bin is added. But I'm trying to avoid polling.
Copy link to clipboard
Copied
Ah. So you want an event listener which in this specific case is listening to a "bin created" event. Well if you create a function in your panel which creates a bin and emits a catchable event, that's feasible, but if a user created the bin from the PrPro UI there'd be no event (please somebody correct me if I'm wrong here...).
Polling (through a timer or timeout) is bad practice in general...