Hi. I have a situation for which I cannot make any test program, so it will be just "teoretical" question. I have done an App using OpenGL. Besides the "little" problem that I cannot use debugger and OpenGL to see the data, I have another weird problem. I am using a Panel to display Maps with OpenGL. On this panel, I have put some labels. I use some of them just to display the results of some calculations. These labels are set initially "Not Visible" and "not enabled" in the Designer. As a matter of fact, the data that they must display depend on cursor position: if cursor is in determinate positions, perhaps these data have no sense and the relative label must not appear. Ok. I could display them empty, but this is not the matter. In fact I am forced to do it, and it works: I have put a button "Activate labels" and, when I click it, they are set Visible,Enabled and BringToFront, even if the cursor position is such that it is nonsense to display them empty. No problem working in this way. Instead, the question is another: same activation cannot be done "dynamically" while I am moving the cursor. In fact I get, in this case:
android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views.
Resuming:
1) Labels invisible and inactive initially
2) Labels activated by a Button: they are shown empty and display data when cursor is in determinate positions.
3) Labels activated directly when the cursor moves: crash
With debugger, despite not seeing the image .. both cases work and labels may be actvated dinamically.. Attach more log lines, for experts.. Maybe I miss something ..
Thanks for reading
android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views.
Resuming:
1) Labels invisible and inactive initially
2) Labels activated by a Button: they are shown empty and display data when cursor is in determinate positions.
3) Labels activated directly when the cursor moves: crash
With debugger, despite not seeing the image .. both cases work and labels may be actvated dinamically.. Attach more log lines, for experts.. Maybe I miss something ..
Thanks for reading