Sms Gratis Indosat

Phone Numbers
0 -
Example : 83832867987 Without 0

Type your Messages

Question: + =

Create a PendingIntent for Notification to do nothing

Refer to the last post "error of using NotificationCompat.Builder, IllegalArgumentException: contentIntent required", if you want no action perform when user click on the Notification, you can insert a PendingIntent with a dummy Intent.

Example:


PendingIntent pendingIntent = PendingIntent.getActivity(
MainActivity.this,
0,
new Intent(), //Dummy Intent do nothing
Intent.FLAG_ACTIVITY_NEW_TASK);

myNotification = new NotificationCompat.Builder(context)
.setContentTitle("Exercise of Notification!")
.setContentText("http://android-er.blogspot.com/")
.setTicker("Notification!")
.setWhen(System.currentTimeMillis())
.setContentIntent(pendingIntent)
.setDefaults(Notification.DEFAULT_SOUND)
.setAutoCancel(true)
.setSmallIcon(R.drawable.ic_launcher)
.build();



Get inside your favorite movies with Google Play

“What’s his name again? Wasn’t he the guy in that movie with the battle of the bands?” Now, while you're watching a movie on Google Play, you can find out that it’s Jack Black (of course!), who was born in Hermosa Beach and is 43 years old. And with one click you can search the web and learn the fun fact that his parents are both rocket scientists.

We’ve added info cards to the Google Play Movies & TV app so you can easily learn more about the actors, related films and even what song is playing in many of your favorite movies. When you’re watching a film on your tablet, simply press pause and cards will pop up with information about actors on screen. You can tap on an actor’s face to learn more about him, like his age, place of birth, his character in the movie, and his recent work, or scroll through the info cards to learn more about the movie or soundtrack. When you resume the movie, the cards will disappear.


This new feature is offered for hundreds of movies in Google Play and we’re adding more every day. If you’re in the U.S. and have a tablet running Android 4.0 (Ice Cream Sandwich) and higher, download the latest version of the Google Play Movies & TV app to check it out. We hope to bring info cards to more movies in more countries and devices soon.

Posted by Ben Serridge, Product Manager for Google Play

The World’s Languages in Your Pocket (No Internet Required)

Have you ever found yourself in a foreign country, wishing you knew how to say "I'm lost!" or "I'm allergic to peanuts”? The Internet and services like Google Translate can help—but what if you don't have a connection? 

Today we're launching offline language packages for Google Translate on Android (2.3 and above) with support for fifty languages, from French and Spanish to Chinese and Arabic. 

You can select [Offline Languages] in the app menu to see all the offline language packages available for download. To enable offline translation between any two languages, you just need to select them in the offline languages menu. Once the packages are downloaded, you're good to go.

 

While the offline models are less comprehensive than their online equivalents, they are perfect for translating in a pinch when you are traveling abroad with poor reception or without mobile data access.
  

So go out and explore another language or another culture without worrying about Internet access. There’s a whole world offline out there.

Posted by Minqi Jiang, Associate Product Manager

Alfa Romeo 4C Launch Edition

S4 / 1.742 cc / 240 PS / 258 ft/lb (350 Nm) / turbo / 0 - 62 mph (100 km/h): 4,5 s / Vmax: 155 mph (250 km/h) / Limited edition (1000 cars)

(click images for a larger view)










error of using NotificationCompat.Builder, IllegalArgumentException: contentIntent required

Refer to the exercise "Example of using NotificationCompat.Builder"; if the statement of new NotificationCompat.Builder...build() modified to remove .setContentIntent(pendingIntent), error of java.lang.IllegalArgumentException: contentIntent required MAY be thrown.

It will have no error in compile time, and no error when run on HTC One X (Android 4.1.1) and HTC Fly (Android 3.2.1). But error when run on Nexus One (Android 2.3.6), with error:

03-27 21:33:40.631: D/AndroidRuntime(24248): Shutting down VM
03-27 21:33:40.631: W/dalvikvm(24248): threadid=1: thread exiting with uncaught exception (group=0x40015560)
03-27 21:33:40.651: E/AndroidRuntime(24248): FATAL EXCEPTION: main
03-27 21:33:40.651: E/AndroidRuntime(24248): java.lang.IllegalArgumentException: contentIntent required: pkg=com.example.androidnotificationbuilder id=1 notification=Notification(vibrate=null,sound=default,defaults=0x1,flags=0x10)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.os.Parcel.readException(Parcel.java:1326)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.os.Parcel.readException(Parcel.java:1276)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.app.INotificationManager$Stub$Proxy.enqueueNotificationWithTag(INotificationManager.java:274)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.app.NotificationManager.notify(NotificationManager.java:111)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.app.NotificationManager.notify(NotificationManager.java:91)
03-27 21:33:40.651: E/AndroidRuntime(24248): at com.example.androidnotificationbuilder.MainActivity$1.onClick(MainActivity.java:52)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.view.View.performClick(View.java:2485)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.view.View$PerformClick.run(View.java:9080)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.os.Handler.handleCallback(Handler.java:587)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.os.Handler.dispatchMessage(Handler.java:92)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.os.Looper.loop(Looper.java:130)
03-27 21:33:40.651: E/AndroidRuntime(24248): at android.app.ActivityThread.main(ActivityThread.java:3683)
03-27 21:33:40.651: E/AndroidRuntime(24248): at java.lang.reflect.Method.invokeNative(Native Method)
03-27 21:33:40.651: E/AndroidRuntime(24248): at java.lang.reflect.Method.invoke(Method.java:507)
03-27 21:33:40.651: E/AndroidRuntime(24248): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
03-27 21:33:40.651: E/AndroidRuntime(24248): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
03-27 21:33:40.651: E/AndroidRuntime(24248): at dalvik.system.NativeStart.main(Native Method)

IllegalArgumentException: contentIntent required on Nexus One

Run on HTC One X

Run on HTC Flyer


If you want no action perform when user click on the Notification, you can create a PendingIntent with empty Intent for Notification to do nothing.


 
Copyright © 2015. About - Web Version - Mobile Version Sitemap - Contact - Privacy