"TheEndless" wrote:
All objects are passed by reference, but as far as my testing has gone, it seems the data used for display is a copy, so you'll need to call SetContent and/or SetContentList again with the updated data to get the Poster and Springboard screens to update.
I imagine since components are supposed to be implemented in C/C++ that they are converting the data structures to a native format for the component, copying implicitly.
We routinely use shortcuts like so in KidPaint for purely brightscript constructs:
config = {
ui: {
tools: {
shape: { img: "file_path", size: "size_data", handler: "handler_routine" }
stamps: { img: "file_path", size: "size_data", handler: "handler_routine" }
}
}
}
shapeMeta = config.ui.tools.shape
shapeMeta.handler = "new_handler_routine"
print config.ui.tools.shape.handler ' prints "new_handler_routine"