Roku Developer Program

Developers and content creators—a complete solution for growing an audience directly.
cancel
Showing results for 
Search instead for 
Did you mean: 
vjani
Level 7

TaskNode callback scope

Hello,

So, just came across a limitation while creating TaskNodes that the callback function registered with observeField is sent as a string, so it has be defined in the component brs file for the owning component and not anywhere else. For example, if my component brs uses other objects that themselves have member functions, there is no way for those member functions to create TaskNodes and listen for events on them as the observeField doesn't take in the scope for the callback. Am I missing something or this is as designed? Because this essentially means that for any component, all Task Nodes and their callbacks have to be defined inside the component brs.
0 Kudos