Search results for

xcode github

94,047 results found

Post

Replies

Boosts

Views

Activity

Reply to Swift - Insert [AnyObject] into [NSMutableDictionnary]
This code: dataArray = [[jobs: ctlelems[x], unload: 0]];is replacing the whole content of dataArray with the single element array. It does not work as Insert.To append an element to Array: dataArray += [[jobs: ctlelems[x], unload: 0]]or dataArray.append([jobs: ctlelems[x], unload: 0])Found nil is another problem. You use too much unwrapping operators (!), without checking the optional value is nil or not.Put nil checking code before using !.
Topic: Programming Languages SubTopic: Swift Tags:
Jul ’15
Reply to Transparent Proxy seems to break Mail.app on Big Sur
Greetings, @meaton! I've put the code on github: https://github.com/ngorskikh/transparentproxyrepro I've updated the feedback, too, but it looks like attachments don't work for some reason -- or at least I can't see my own attachments, even though the original feedback request contained some automatically collected logs, as well as a zip with an xcode project and a couple of screenshots. Kind regards, ngorskikh.
Sep ’20
Reply to Decodable and CGPoint
It depends a bit on the scale of the problem.One solution would be just to write the manual decoding for types like Circle that contain a CGPoint. The synthesized code is almost trivial to re-create manually, so it's just a question of source code size.Or, you could try to finagle the types like Circle like this:struct MyPointStruct: Decodable { let x: CGFloat let y: CGFloat } struct Circle: Decodable { private var _center: MyPointStruct var center: CGPoint { get { return CGPoint (x: _center.x, y: _center.y) } set { _center = MyPointStruct (x: newValue.x, y: newValue.y) } } }Or perhaps slightly more cleanly, if you have lot of point-containing structs:struct MyPointStruct: Decodable { var x: CGFloat var y: CGFloat var point: CGPoint { get { return CGPoint (x: x, y: y) } set { x = newValue.x; y = newValue.y } } } struct Circle: Decodable { private var _center: MyPointStruct var center: CGPoint { get { return _center.point } set {
Topic: Programming Languages SubTopic: Swift Tags:
Dec ’17
Reply to Are iOS 11 apps backwards compatible?
An app built strictly for iOS 11.x and with iOS 11-specific APIs would not run on older OSs.With APIs such as UIDocumentBrowserViewController, the dev would choose to either stick w/supporting iOS 11.x and up, effectively forcing users to update, or, sniff the iOS version in use (see: idioms), code around them (and set the Deployment OS via build settings), accordingly when run on an unsupported/lower iOS version, where existing/new users haven't moved up.Be sure your testing confirms the app can handle whichever configuration you choose.As for running old and new Xcode - in that example, you can install both, but run only one at a time. Note, however, that Xcode9.x now support running two instances simultaneously.
Topic: App & System Services SubTopic: Core OS Tags:
Jun ’17