QuickActions like the Twitter app - android

I want to add Pattern 6: QuickActions from android's blog to my app.
Any code snippet?
Anyone try to do it already?
Should this work on android 1.5?

I just found this question right after I posted my own question/answer. Here's the code I developed for this. http://code.google.com/p/simple-quickactions/

I also have been searching for this and found someone through the wave of the Google IO session who has implemented such thing.
He posted the code on GitHub. I just tested it, and it works just great!
You'll also need some ressources from the project (drawables, styles..).

Look at line 1310 of ContactsListActivity.java from the Contacts application. It's the code that creates the intent for the contact shortcuts on the home screen that launch the quick actions intent for a contact.
This won't work before eclair.

Until the official Twitter app is open sourced by Google, you may want to take a look at this implementation:
It's really easy to use and works great.

That app is going to be open sourced at some point so you may want to wait until then. But it could be done with a Dialog with a custom background drawable, and using Window.LayoutParams to position the dialog.

Related

How to add a custom button on contact's to open with my app?

Well, I wanna know if it possible open a contact with a cordova app from "contacts" app like WhatsApp.
See here a example:
I search on Google and npm, but nothing...
Thanks
There's really good documentation about this on Android's website here:
https://developer.android.com/guide/topics/providers/contacts-provider
Make sure you read the entire post, but specifically check out this section that talks about adding your stuff into the Contact's screen:
https://developer.android.com/guide/topics/providers/contacts-provider#SocialStreamInteraction
Also, if you haven't yet, you might want to create your own Account and SyncProvider, check out these tutorials:
http://blog.udinic.com/2013/04/24/write-your-own-android-authenticator/
and
http://blog.udinic.com/2013/07/24/write-your-own-android-sync-adapter
You should probably investigate using a plugin to display Contacts, see:
https://cordova.apache.org/plugins/?q=contacts

Make selfcontained browser app?

Is there a easy way to create an Android and/or/both IPhone app that lunches any or specific browser and goes to specified URL ?
I want to make it, so it look like an app ..i.e. installed as widget or app ..
Any pointers to documentation are welcome too ?
I would prefer if no coding is necessary :), but is OK if it is needed.
thank you.
Yup http://cordova.apache.org
Refer to the link and follow the hello world tutorials... Very useful for your purpose.

Start Androidapp with a link in a email

Hallo Developers,
is it possible to start a activity with a link from a Email like in Iphone SDK and start this aktivity with params.
Iphone example:
Appname:///?param1=value1&param2=value2
It appears to be possible - check these other answers on stackoverflow:
How to implement my very own URI scheme on Android
Android Respond To URL in Intent
Not to my knowledge in stock Android. However they've made a link scheme that will open up the Market application to a specific page, so this is possible. I would think however that in order to set something like that up the app you are wanting to start from link would have to be listening for clicks on that specific type of link and tell the system that it can handle them. I have no idea how you'd go about implementing that though, and it would only be able to start specific apps that were designed that way.
Try content://com.user.package.ActivityClass/. I haven't tried it so I am not sure if it will work though.
See here for more information: http://developer.android.com/reference/android/content/Intent.html

Android popup menu

I am making an Android app. I have a list of items displaying. I am looking to create a popup menu just like the one that pops up when you tap the avatar of a contact in the contact list. I have tried looking through the Android reference but can not find it.
Has anyone created one of these popup menus? A link to the reference or a code sample is fine.
Screenshot of menu:
http://www.youchoob.org/pics/popup.jpg
What you are describing is called a 'Quick Action'. This is actually a user interface pattern - there isn't an existing widget or anything in the API for this. They discussed it at Google IO (See in this video here, at the 15:40 mark), and also there has been some discussion on how to implement it on stack overflow, specifically this question. If you start digging around (now that you know the name of what you are looking for) you might find more.
you can find "QuickAction" widget in
https://github.com/cyrilmottier/GreenDroid
below is a demo activity
https://github.com/cyrilmottier/GreenDroid/blob/master/GDCatalog/src/com/cyrilmottier/android/gdcatalog/QuickActionActivity.java
Please find the code OR framework from here :
http://www.londatiga.net/it/how-to-create-quickaction-dialog-in-android/
The source code for the contacts is open source. You should look around here and see if you can find it.
https://android.googlesource.com/platform/packages/apps/Contacts
I'm looking now if I find it I will edit.

share feature of menu in android application

i asked so many question regarding my title but i could not get my proper answer till yet.I need to implement androd's menu feature in my application ie when we goes to gallery in android phone, when we press menu than it comes with lots of option like share...etc.My question is can i implement same menu feature in my application? It is possible or not?
Thanks
To implement a "Share" feature, all you need to do is use createChooser() and an ACTION_SEND Intent.
Here is a blog post covering the technique.
If I am understanding your question you want to know if you can duplicate the feature of tapping on the menu button on the phone and having it pull up an options menu that you can then share via, gmail or some other posting medium?
If this is correct then I would have to say I would assume that you could duplicate this feature.
In short YES!
If you are wondering how you are to do this then I would start at here http://developer.android.com/guide/topics/ui/menus.html
Droidnova .com (I posted it like this because as a new user I can only post one link) also has a good little how to on menu's.
I would also like to add that this is my first time posting on stackoverflow so please let me know if this was a good post or what I should do next time.
Thanks,
Bactos

Categories

Resources