Log in or register to post comments

Adding Android buttons

May 24, 2011 - 3:59am #1

Hi,

I was wondering if it is possible to add some buttons from Android in main.xml (like Button or ImageView) directly on the screen, when the camera has started?

I tried to do it via the Graphical Layout for the xml file, and in the Activity for the java file. But the button does not appear!

Thanks

Re: Adding Android buttons

May 24, 2011 - 8:18am #3

Oh! I forgot thie Dominoes' example! Thanks :)

Re: Adding Android buttons

May 24, 2011 - 5:39am #2

You probably want to add the buttons to a separate xml file and add this to the view hierarchy at runtime, after the glView has been added. See the Dominoes sample for details, it does just that. Look for calls to addContentView in Dominoes.java.

- Kim

Log in or register to post comments