added simple implementation of AppPreferences plugin for saving to NSUserDefaults, works in JS, but have not tested from native code