morega
Visitor

m.top

Hi,

I'm new to Roku dev, and I have some pretty noob questions which I couldn't find direct answers to when I searched on the forum.

in the Scene Graph xml, what does "m" specifically refer to?
and what does "m.top" refer to? the parent Scene?


Thanks,
Tags (1)
0 Kudos
2 REPLIES 2
squirreltown
Roku Guru

Re: m.top

Component Global Associative Array
All components have a global associative array designated as m. including Task node objects.
Kinetics Screensavers
Tags (1)
0 Kudos
EnTerr
Roku Guru

Re: m.top

When a function defined in <script/> gets called, in `m.top` it will find a pointer to the <component/> that declared it.

I was confused too (i only hope i am not anymore!). The use of "top" is a misnomer - it does not mean the Scene under which everything is attached, it's a top just from the point of view of the XML file <component/> unit. A better naming would have been "m.component" or "m.this" or "m.self" or "m.node" or "m.m" :). But that naming ship has sailed.
Tags (1)
0 Kudos
Community is Temporarily in Read-Only Mode!

We’re upgrading Roku Community to bring you a faster, more mobile-friendly experience. You may notice limited functionality or read-only access during this time. You will not be able to log in or post new comments or kudos during this time. Read more here.

Planned Downtime:
Community will be unavailable for up to 24–48 hours during the upgrade window during the week of May 12 and you may notice reduced functionality. In the meantime, for additional assistance, visit our Support Site.

Thanks for your patience — we’re excited to share what’s next!