Which tutorials should I watch or read to understand the difference between Node, B4XView, View, Control and other screen objects and also the behaviour of the global variables that the Visual Designer can generate?
I find some confusing terms. For example, GetAllViewsRecursive is explained as "Returns an iterator that iterates over all the child nodes[...]" - so why is it not called GetAllNodesRecursive?
If I create a new tab page by loading a Layout into a Tab Pane, I cannot use that tab page as the root of nodes, I have to use TabPage.Content. So what is a TabPage? Control? View? But View does not exist in B4J(View is B4I?), it should be B4XView, and that is a construct specific for [Controls|Nodes|Screen objects] that are OS-independent.
I can use the Tag of each screen object created with the Visual Designer to iterate nodes and find my screen object... except a CustomListView. This is a strange one. Automatically, its name is CustomListView1 in the Visual Designer. But in the same Visual Designer, its Type is shown as CustomView, an object that does not exist in code. I can force a CustomListView to behave as a B4X object by saying CustomListView1.AsView, but if I iterate the nodes of the root, all I find is some non-resize panels, so the conversion does not work backwards, so I cannot put a tag to it and find it on a Root Pane.
That leaves the Global variable that I create from the Visual Designer. But that may or may not be the solution.
What if I have a TabPane, I load several TabPages into it, and each TabPage has a CustomListView? Then the global variable would not know which one to refer to. I was thinking that when I load a layout, the global variable points to the newly loaded layout's screen objects, I guess I would have to insert a Sleep(0) after loading the layout. That way I can grab the CustomListView and put it into a real Node's tag. Would that be the intended behaviour?
I realize these are several questions disguised as one, but I don't expect anyone to write an essay about it or answer all. I just wanted to explain why I am confused. My question is still the same: is there a tutorial I can read or watch that would make all these things clear?
I find some confusing terms. For example, GetAllViewsRecursive is explained as "Returns an iterator that iterates over all the child nodes[...]" - so why is it not called GetAllNodesRecursive?
If I create a new tab page by loading a Layout into a Tab Pane, I cannot use that tab page as the root of nodes, I have to use TabPage.Content. So what is a TabPage? Control? View? But View does not exist in B4J(View is B4I?), it should be B4XView, and that is a construct specific for [Controls|Nodes|Screen objects] that are OS-independent.
I can use the Tag of each screen object created with the Visual Designer to iterate nodes and find my screen object... except a CustomListView. This is a strange one. Automatically, its name is CustomListView1 in the Visual Designer. But in the same Visual Designer, its Type is shown as CustomView, an object that does not exist in code. I can force a CustomListView to behave as a B4X object by saying CustomListView1.AsView, but if I iterate the nodes of the root, all I find is some non-resize panels, so the conversion does not work backwards, so I cannot put a tag to it and find it on a Root Pane.
That leaves the Global variable that I create from the Visual Designer. But that may or may not be the solution.
What if I have a TabPane, I load several TabPages into it, and each TabPage has a CustomListView? Then the global variable would not know which one to refer to. I was thinking that when I load a layout, the global variable points to the newly loaded layout's screen objects, I guess I would have to insert a Sleep(0) after loading the layout. That way I can grab the CustomListView and put it into a real Node's tag. Would that be the intended behaviour?
I realize these are several questions disguised as one, but I don't expect anyone to write an essay about it or answer all. I just wanted to explain why I am confused. My question is still the same: is there a tutorial I can read or watch that would make all these things clear?