wallpaper

How to start the “set as” intent (wallpaper, contact picture, etc)

大憨熊 提交于 2019-11-29 05:14:39
问题 I searched over the web during the last few weeks (seriously) but I can't find what I need. I just would like to start an intent corresponding to the set as action. It generally offers either Set as wallpaper or Set as contact picture . And then, if more application are installed on the device, they can be listed as well. Here is an example of what I want : I precise that I need to support API level 14 and higher. I found getCropAndSetWallpaperIntent but it works only with content URI which

Android app to change wallpaper at regular intervals using Timer

此生再无相见时 提交于 2019-11-29 04:52:11
I wish to create an app, which would change the wallpaper of the Android device at fixed intervals, say every hour or so. Currently in my code, I start a service and am using a Timer object. The Timer object would be invoked at regular intervals and change the wallpaper. This is the code I am using currently. The wallpaper gets changed only once and not after that. Please let me know what should I do? public class Wallpaper extends Service { Timer mytimer; int interval=60000; Drawable drawable; WallpaperManager wpm; int prev=1; @Override public void onCreate() { super.onCreate(); mytimer=new

Android set image as wallpaper

為{幸葍}努か 提交于 2019-11-29 02:44:56
Please show me an example code on how to set image as wallpaper using Android WallpaperManager. I have shortened and edited my question. Hopefully you guys could understand my question. I will show some attempts I have made. HomeActivity.class public class HomeActivity extends BaseActivity { String[] imageUrls; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.ac_home); ArrayList<String> url = new ArrayList<String>(); try { URL url_link = new URL("http://mywebsite.net/web/thumb.xml"); DocumentBuilderFactory dbf =

android - save image from web server and set it as wallpaper

时间秒杀一切 提交于 2019-11-29 02:39:57
Can anyone please provide me some idea/guidance on how to save an image from a webserver and set it as wallpaper? i am developing an android application which needs to do that and i am new in android. Thanks a lot. I had tried writing my own code but it doesn't work as i can't find my images after download but the wallpaper has change to the downloaded picture. here is my existing code. Bitmap bmImg; void downloadFile(String fileUrl) { URL myFileUrl = null; try { myFileUrl = new URL(fileUrl); } catch (MalformedURLException e) { // TODO Auto-generated catch block e.printStackTrace(); } try {

iOS 7 - Display user wallpaper as UIWindow background

只愿长相守 提交于 2019-11-28 22:55:28
问题 How would it be possible to have an iOS app display the user's wallpaper? Apple uses this in places like the tab view in Safari and the keypad in Phone. Setting the transparency of UIWindow proved to no avail... 回答1: This is no longer available. Too bad, because it allowed a sweet native looking effect there are a few things you need to do to show the user wallpaper 1 - set UIApplicationIsOpaque to false in the project plist 2 - In the app delegate load function self.window.backgroundColor =

Android wallpaper/background dimensions

跟風遠走 提交于 2019-11-28 21:36:14
问题 Which are the default dimension of the Home wallpaper/background for the various Android screen configurations (small, normal and large screens with low, medium and high density)? Are 9-patch PNG files supported for the wallpaper? Should I be using these instead? I found a method in API level 5 that gives you the minimum size of the wallpaper, but I would like to support previous versions of Android as well. Thanks! 回答1: A wallpaper is twice as wide as the device held in portrait mode. So

Simplest example of an Android live wallpaper [closed]

空扰寡人 提交于 2019-11-28 20:22:11
问题 I'm trying to make an android live wallpaper. I am looking for just a simple example that just displays a solid background and does nothing else to get me started. I've looked up quite a few tutorials but they all have preference activities and I can't get any of them to work. I've even tried removing everything that it does not need other than the required override functions. Can anyone post the code for just a simple live wallpaper or post a link to an example that definitely works. I've

Changing Wallpaper with a batch file, on program close. Possible? [closed]

拥有回忆 提交于 2019-11-28 09:23:41
I'm trying to create a batch file that will change my background when a program closes on Windows 7. I've tried using this, but it doesn't work, even when I log off and log back in: @echo off reg /add HKCU\Control Panel\Desktop\WallPaper /v wallpaper /t REG_SZ /d c:\images\wallpaper.bmp refaim There are some errors in your command: You have added unnecessarry / to add command. You don't enclose registry key name in quotes (for space escape). You have specified wrong path (extra WallPaper at the end). This should do the trick: reg add "HKCU\Control Panel\Desktop" /v Wallpaper /f /t REG_SZ /d c:

How to exlude all the devices which have low GPU in Android Manifest?

点点圈 提交于 2019-11-28 08:14:30
问题 Basically, I created a live wallpaper for Android and tried it in my Droid X, Galaxy S, and Fascinate. And I noticed that it runs smootly in Galaxy S and Fasciante but not in Droid X which has lower GPU. My question is, is there anyway to exlude all the devices which has low GPU in Android Manifest? I am planning to publish this live wallpaper soon. Please help me! 回答1: You can add supports-screens to the manifest, and pass in a true false valuefor each size. The below example would exclude

Android shared preferences not saving

时光怂恿深爱的人放手 提交于 2019-11-28 07:11:50
I've created an Android live wallpaper and i'm trying to let a user choose an image from their phone and apply it as a background image, but when I launch the activity that start the intent to pick the images, my shared preferences don't seem to save properly. Below is my onCreate method of the activity I start when the users presses the preference button, and the onActivityResult which gets the path of the image on the device (all that seems to work). The println after I commit the preferences prints out nothing. @Override public void onCreate(Bundle savedInstanceState) { super.onCreate