0

I want to show an activity in dialog as shown in the picture below. Does any one know how can to achieve this result? enter image description here

I tried using this code for that activity but it didn't help me.

android:theme="@android:style/Theme.Dialog"

It shows in middle of screen can I change its position ?

Chirag Patel
  • 11,416
  • 3
  • 26
  • 38
  • Can you add your Manifest file? – Shashank Kadne Apr 09 '12 at 09:40
  • 1
    Please add a few more details about what you are looking for. That screen grab looks like an Action Bar. Specifically, an Action Provider from here: http://developer.android.com/guide/topics/ui/actionbar.html#ActionProvider. Do you want to add your app to that list when a user clicks on the share button? Or you want your application to look like that? – Siddharth Lele Apr 09 '12 at 09:43
  • I want to open that type of dialog in my activity when I click on my button (not on Action Bar ) – Chirag Patel Apr 09 '12 at 09:54
  • So you want the functionality of that popup replicated in your activity, except on a button click and not on / in the action bar? And also, what API level are you using for this app? To my knowledge, this UI is specific to ICS and not available in any other API levels lesser than 14 – Siddharth Lele Apr 09 '12 at 10:05
  • @SiddharthLele I want same functionality as shown in picture. As on click on action bar button and open popup like that.I also want ListView in that but in that data for that list view will come from webservice. Is it possible ? and if yes how can I achieve that ? Thanks for reply .. – Chirag Patel Apr 10 '12 at 05:03

1 Answers1

0

Instead of creating a new Activity with Theme.Dialog, I would suggest you to use Custom View to appear on that action and later hide it.

There are open source custom Views called as QuickAction.

Please have a look at this post.

And specially this git repo, pointed in the post linked in the accepted answer.

Community
  • 1
  • 1
Adil Soomro
  • 37,609
  • 9
  • 103
  • 153