diff options
author | Juan Linietsky <reduzio@gmail.com> | 2015-06-30 11:59:33 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2015-06-30 11:59:33 -0300 |
commit | b4d5f7e154973e8fb93a9a0af6ffa0b065e2c50c (patch) | |
tree | 67551f833464dc31c7d48e68e93b68c161e404b2 /platform/iphone/app_delegate.mm | |
parent | 4613a3f2c0d8f060cac610e2a7a401aee2ece78f (diff) | |
parent | 55b34e05b3d735a84e1af9833e19c0b816c18252 (diff) |
Merge branch 'master' of https://github.com/okamstudio/godot
Diffstat (limited to 'platform/iphone/app_delegate.mm')
-rw-r--r-- | platform/iphone/app_delegate.mm | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/platform/iphone/app_delegate.mm b/platform/iphone/app_delegate.mm index 2c7a0a0790..dba37ab1b8 100644 --- a/platform/iphone/app_delegate.mm +++ b/platform/iphone/app_delegate.mm @@ -138,6 +138,29 @@ static int frame_count = 0; Main::setup2(); ++frame_count; + // this might be necessary before here + for (NSString* key in [[NSBundle mainBundle] infoDictionary]) { + NSObject* value = [xyz objectForKey:key]; + String ukey = String::utf8([key UTF8String]); + + // we need a NSObject to Variant conversor + + if ([value isKindOfClass:[NSString class]]) { + NSString* str = (NSString*)value; + String uval = String::utf8([str UTF8String]); + + Globals::get_singleton()->set("Info.plist/"+ukey, uval); + + } else if ([value isKindOfClass:[NSNumber class]]) { + + NSNumber* n = (NSNumber*)value; + double dval = [n doubleValue]; + + Globals::get_singleton()->set("Info.plist/"+ukey, dval); + }; + // do stuff + } + } break; /* case 3: { |