Generate layout in Android at runtime?

view story

http://stackoverflow.com – I am working for generating a layout at runtime in my application, as shown in image: I am using the below code for generating the Popup on click of the above button. The pop up generated in the Galaxy device with 480 x 800 resolution is perfect but it is not permanent with other smaller device like what I am using for above click, of 320 x 480 resolution. // Get the x and y position after the button is draw on screen // (It's important to note that we can't get the position in the onCreate(), // because at that stage most probably the view isn't drawn yet, so it will return (0, 0)) @Overr (HowTos)