2

I looked online and was not able to find a working example of the PopupWindow class. The code examples I found online either compile but do not work, or are using methods which have since been removed (such as Activity.getViewInflate()).

Is there a simple working example that displays a PopupWindow?

Lukas Knuth
  • 25,449
  • 15
  • 83
  • 111
Shabbir Panjesha
  • 1,851
  • 5
  • 20
  • 29
  • Hello, did you tried this one? http://www.ceveni.com/2009/09/popup-window-in-android-sample-program.html – Cata Nov 11 '11 at 10:02

2 Answers2

2

Any Activity can be a "popup window" it just has to show up on top of the previous activity and not take up all the screen real estate! :)

Here's an example of how this works...

How do I create a transparent Activity on Android?

Or are you just looking for an Alert that gets dismissed by being touched anywhere (rather than with an "OK" button?

Community
  • 1
  • 1
Yevgeny Simkin
  • 27,946
  • 39
  • 137
  • 236
  • i am using an activity with background as transparent and whose layout parameters are half of the window size what i want to do is disable background activity when this activity is shown. – Shabbir Panjesha Nov 11 '11 at 10:19
0

May be AlertDialog can solve your problem you can full screen dialog window it just look like a window it is an alternative