Last active
March 19, 2021 09:20
-
-
Save Geri-Borbas/87096bd70d070f7093fd0234b187facb to your computer and use it in GitHub Desktop.
A quick way to override / extend app delegate (UIAppDelegate) in iOS Unity Player. Read more on why you should / should not use this approach at http://eppz.eu/blog/override-app-delegate-unity-ios-osx-1/
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // | |
| // Copyright (c) 2017 eppz! mobile, Gergely Borbás (SP) | |
| // | |
| // http://www.twitter.com/_eppz | |
| // | |
| // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, | |
| // INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A | |
| // PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT | |
| // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF | |
| // CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE | |
| // OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | |
| // | |
| #import "UnityAppController.h" | |
| @interface OverrideAppDelegate : UnityAppController | |
| @end | |
| IMPL_APP_CONTROLLER_SUBCLASS(OverrideAppDelegate) | |
| @implementation OverrideAppDelegate | |
| -(BOOL)application:(UIApplication*) application didFinishLaunchingWithOptions:(NSDictionary*) options | |
| { | |
| NSLog(@"[OverrideAppDelegate application:%@ didFinishLaunchingWithOptions:%@]", application, options); | |
| return [super application:application didFinishLaunchingWithOptions:options]; | |
| } | |
| @end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
extremely helpful...just works ..thanks