Search results for

missing package product

50,272 results found

Post

Replies

Boosts

Views

Activity

Do Generics not inherit initializers?
Four classes, first two normal, Two inherits from One, Two inherits One's initializers as expected.Second two are generic, Four<T> inherits from Three<T>, but everything else is the same. However Four doesn't inherit Three's initializer.Is that a bug or have I missed yet something else in the Swift book?public class One { public var value : Int public init( value : Int ) { self.value = value } } public class Two : One { public func foo() { print( value is (value) ) } } public class Three<T> { public var value : T public init( value : T ) { self.value = value } } public class Four<T> : Three<T> { public func foo() { print( value is (value) ) } } let x = Two( value : 123 ) // *** WORKS ****, Two inherits One's init(value:) method x.foo() let y = Four<Int>( value : 123 ) // Four<Int>' cannot be constructed because it has no accessible initializers y.foo()
0
0
966
Jun ’15
UITextView lineHeightMultiple Clips Top, first line, of Text
In iOS 8, I have a vanilla UITextView that clips the top of the 1st line when a lineHeightMultiple is applied to it's NSMutableParagraphStyle, see image below:It appears as though lineHeightMultiple affects the 1st line of text in addition to subsequent lines.Setting clipsToBounds = false on the UITextView will at least enable the clipped part to show, but you can see from the image below that now the top part of the text is obviously above it's frame:I can fix this by just setting the top constraint on the offending UITextView to compensate for clipsToBounds = false but that feels like a hack to me.I have also tried using a WKWebView for the offending text, and just setting the css line-heightproperty, and that works just fine. There must simply be something I am missing when it comes to UITextView though.Additionally, setting lineSpacing on the paragraph style to less than 0 has no affect, per the docs:The distance in points between the bottom of one line fragment and the top of the next. **This va
Topic: UI Frameworks SubTopic: UIKit Tags:
2
0
3.2k
Jun ’15
loyalty card notification won't dismiss
I tried adding a few loyalty cards into the Wallet since that's now supported in iOS 9 / Watch 2.0.I visited Kroger a few days ago, and although I didn't actually use the loyalty card feature a notification showed on the watch. And now that notification won't go away -- there's no dismiss button, and every time I swipe down to see notifications it is there (even after a reboot).Is there something I'm missing here on how to dismiss the notification, or is this a bug?
5
0
1k
Jun ’15
New behavior for `Create NSManagedObject Subclass…` bug?
With Xcode 7, two different files are created when you choose to `Create NSManagedObject Subclass`. One file is an extension that adds the properties that are added in the model editor. You aren't supposed to edit this file. Instead you edit the second file, the class file, that's created. This is where you add any custom functionality you want your NSManagedObject subclass to have. The point of this, as far as I can tell, is so that you can add your custom functionality, but when you later change the model, you can regenerate a new extension with the updated attributes/relationships without affecting or overwriting the custom code that you wrote.But...Xcode 7 beta 1 isn't doing this. Selecting `Create NSManagedObject Subclass` blows away both files. Is this a bug or am I missing something?Erik
1
0
415
Jun ’15
Reply to Can't archive app: "Command failed due to signal: Abort trap: 6"
If possible, please file a bug for this issue and attach the project which is causing the crash.If you are unable to attach the full project, please look at the build log and try to determine exactly what command is crashing with the Abort 6 message. If it is the compiler, you should be able to open the source file which is crashing, then use Product > Perform Action > Preprocess ... to generate a preprocessed source file which can be attached to the bug and used by us to isolate the crash.
Jun ’15
Error trying to build watchOS 2 app in Xcode 7
Extension error:target specifies product type 'com.apple.product-type.watchkit2-extension', but there's no such product type for the 'iphonesimulator' platformMy watch app also has this error:Xcode/DerivedData/AnxietyTracker-aabqxayllohhlydulhldvvzxqkzv/Build/Products/Debug-watchsimulator/AnxietyTracker WatchKit Extension.appex: No such file or directoryAnyone have any suggestions or insight?
8
0
14k
Jun ’15
Autosave issues. What's the best solution?
The app I am writing is UIDocument based.A user is halfway through editing my iCloud document. A text field is being typed into. The on-screen keyboard is displayed. UIDocument automatically undertakes a save operation. The saved document goes to iCloud. iCloud notifies the app there is an updated version.The app then updates the UI. Causing the text field to lose first-responder. The text field is emptied, and the keyboard vanishes.What's a safe and simple way to avoid this?C.
0
0
191
Jun ’15
Reply to iOS 9 Beta battery life
I see lots of discussion of things people tried on the phone, but did anybody (else) plug it into Instruments?Mine has been hit and miss. Sometimes it's burning through the battery and other times it seems normal.I noticed that my iPhone 6 was getting extremely hot after using it to browse a few articles during lunch. I hooked it up to Instruments and found that locationd was taking up 40%-75% of the CPU. I disabled Location Services and immediately the load went down.
Topic: App & System Services SubTopic: Core OS Tags:
Jun ’15
Module file's minimum deployment target is ios9.0 v9.0
When creating a new playground in Xcode 7 beta (7A120f) and using a custom Cocoa Touch Framework I get the error:Playground execution failed: Game.playground:4:8: error: module file's minimum deployment target is ios9.0 v9.0The custom framework does use specific iOS9 code. When adding a class to the Sources folder using GKEntity the compiler also shows an error explaining I should use:@available(iOS 9.0, *)The meta data of the playground does not show any indication the Playground uses a deployment target (8.4 or some other version).What am I missing here? Why can't I use a custom framework created with iOS9?
1
0
4.7k
Jun ’15
Reply to CFNotificationCenterAddObserver
Xcode 7 is more helpful and complains about captures:> A C function pointer cannot be formed from a closure that captures contextI can get it to compile if I change the closure to contain only a call to print(). Kinda misses the point since most of the time you'd want to capture a reference to an object you want to act on.
Topic: Programming Languages SubTopic: Swift Tags:
Jun ’15
Reply to error itms-90023
In general itms errors like this mean exactly what they say: your final submitted binary is missing that icon. I don't have any good suggestions for how to debug it. If you move the thread over to App Submission and Review someone there might have some ideas.<https://forums.developer.apple.com/community/distribution/app-submission-and-review>Share and Enjoy--Quinn The Eskimo!Apple Developer Relations, Developer Technical Support, Core OS/Hardware
Jun ’15
dependency injection and protocols
I had a posting in the older forums about this issue. I never really found a solution. Maybe I can try posting again and see if anyone has some good advice.I am a big fan of TDD. One of the techniques I picked up was dependency-injection. Objective-C is a very laid-back language when it comes to type-checking. It is very easy for the compiler to let you swap a test-double class for a production class. I am having a problem in Swift that you might be able to help with.class ChildClass { } class ParentClass { func child() -> ChildClass { return ChildClass() } } protocol ChildProtocol { } extension ChildClass: ChildProtocol { } protocol ParentProtocol { func child() -> ChildProtocol } extension ParentClass: ParentProtocol { }This code is failing to build. Swift does not believe that ParentClass can conform to ParentProtocol. This is a contrived example. I will show you a real example where I would use this pattern in a real app.import Foundation protocol SessionTaskType { } extension NSURLSessionD
5
0
1.5k
Jun ’15