iOS 7 - Display user wallpaper as UIWindow background
Asked Answered
C

2

16

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...

Charkha answered 20/9, 2013 at 19:8 Comment(1)
In iOS 13, this is finally possible! See my answer here: https://mcmap.net/q/539893/-how-can-i-get-a-transparent-background-in-my-ios-app-so-i-can-see-the-home-screen-wallpaperContredanse
F
14

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 = [UIColor clearColor];
self.window.opaque = NO;

3 - set the UIViewController.view background color to [UIColor clearColor]

This works for us currently. If you try to do a screen capture or actually use the wallpaper it just returns solid black (so privacy concerns don't apply since you can't do anything with the wallpaper).

Fortitude answered 20/9, 2013 at 19:17 Comment(4)
Any word as to whether apps are rejected for using this method?Bibliomancy
Yet another feature that Apple makes available to himself (we can for example see it in the Phone app dialer), but not to third party developers…Garamond
Is this working anymore? I tried these steps and it's no longer working. At one point it was... at 7.0.2/3 it seems to no longer be working. Can anyone confirm or deny?Hide
You can't even attempt to submit apps with this plist key, it will not pass validation. There was a way to do this through a private method in UIApplication, but they nuked that in 7.0.3.Rendon
S
3

This functionality is not available to third-party developers due to privacy concerns.

If you could do this in a third-party app, you could capture the background image without asking the user.

Stereography answered 20/9, 2013 at 19:14 Comment(1)
This isn't true. The wallpaper shows up as black when a screenshot is taken programmatically by the app.Strother

© 2022 - 2024 — McMap. All rights reserved.