2013年10月31日 星期四

Native Wallpaper picker

That is my question. For them who dont know what i am asking, I want to make this menu to appear in my app http://db.tt/GQX9GBYF . The thing is that I Dont have any idea how to do it. I think that I have to create an intent, from it obtain image path and then, set it as background. But i dont know the exact way to do it...
Please, anyone could post me an example, please???? ;)
I have to say that I managed to do it by launching native gallery app, but I want to set live wallpapers too
share|improve this question
You Intent.ACTION_SET_WALLPAPER for starting ContaxtMenu for Selecting Wallpaper as:
Intent intent = new Intent(Intent.ACTION_SET_WALLPAPER);
startActivity(Intent.createChooser(intent, "Select Wallpaper"));
share|improve this answer
 
ok it worked, but it sets launcher background, and I only want to set wallpaper for my app... any idea?? THANKS A LOT!! –  BamsBamx May 27 '12 at 16:13
 
myLayout.setBackgroundDrawable(getWallpaper()); gets the wallpaper and sets it for your layout – user1446632 Feb 10 at 19:07

沒有留言:

張貼留言

Related Posts Plugin for WordPress, Blogger...