Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-18852

Ti.App.iOS.UserDefaults needs ability to set the suiteName in order for it to work with Apple Watch

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: High
    • Resolution: Invalid
    • Affects Version/s: None
    • Fix Version/s: Release 4.0.0
    • Component/s: TiAPI
    • Labels:
      None

      Description

      I was looking at the new UserDefaults API we have for sharing data between iOS extensions and it's missing the ability to specify a suiteName. Without this, this API cannot share data across extensions.

      Example in a watch extension:

      let sampleDefaults = NSUserDefaults(suiteName: "group.com.myapp.here")
      

      Currently you can only do something like:

      		Ti.App.iOS.UserDefaults.setObject('myKey', {});
      

      Which points to the standard user defaults...which the apple watch can't access. Maybe a 3rd param needs to be introduced in these methods where you can specify the suiteName.

      Ref. http://stackoverflow.com/questions/27007288/watchkit-sdk-not-retrieving-data-from-nsuserdefaults

        Attachments

          Activity

            People

            • Assignee:
              ingo Ingo Muschenetz
              Reporter:
              rblalock Rick Blalock (Inactive)
            • Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Backbone Issue Sync

                • Backbone Issue Sync is enabled for your project, but we do not have any synchronization info for this issue.

                  Git Source Code