motion/core/app.rb in bubble-wrap-1.3.0 vs motion/core/app.rb in bubble-wrap-1.4.0
- old
+ new
@@ -41,20 +41,24 @@
def states
@states
end
+ def info_plist
+ NSBundle.mainBundle.infoDictionary
+ end
+
def name
- NSBundle.mainBundle.objectForInfoDictionaryKey 'CFBundleDisplayName'
+ info_plist['CFBundleDisplayName']
end
def identifier
NSBundle.mainBundle.bundleIdentifier
end
def version
- NSBundle.mainBundle.infoDictionary['CFBundleVersion']
+ info_plist['CFBundleVersion']
end
# @return [NSLocale] locale of user settings
def current_locale
languages = NSLocale.preferredLanguages
@@ -88,7 +92,8 @@
def ios?
Kernel.const_defined?(:UIApplication)
end
end
+
end
::App = BubbleWrap::App unless defined?(::App)