Re: Avoid selection marking on cell tap

2015-11-24 Thread Quincey Morris
On Nov 24, 2015, at 16:04 , Rick Mann wrote: > > The iOS Photos app is a perfect example of the behavior I've been asked to > implement. I don’t think your approach is wrong, I just don’t know what the recommended behavior is. The other thing that confuses me is that

Re: Avoid selection marking on cell tap

2015-11-24 Thread Rick Mann
> On Nov 24, 2015, at 16:10 , Quincey Morris > wrote: > > On Nov 24, 2015, at 16:04 , Rick Mann wrote: >> >> The iOS Photos app is a perfect example of the behavior I've been asked to >> implement. > > I don’t think your approach

Re: -[NSWindow parentWindow] for sheet never works?

2015-11-24 Thread Graham Cox
> On 25 Nov 2015, at 3:47 AM, Jerry Krinock wrote: > > ’m updating an old project which used the -[NSApp beginSheet:] methods to > use -[NSWindow beginSheet:completionHandler:]. In so doing, I now need the > parent window in my action methods, so I can send the -[NSWindow

Re: Avoid selection marking on cell tap

2015-11-24 Thread Rick Mann
> On Nov 24, 2015, at 16:00 , Quincey Morris > wrote: > > On Nov 24, 2015, at 15:38 , Rick Mann wrote: > >> Our selection marking doesn't really work for the tap that segues into the >> detail view. We only use the selection

Re: Swift - internal class conforming to public protocol

2015-11-24 Thread Quincey Morris
On Nov 24, 2015, at 16:16 , Roland King wrote: > if I define an internal class which implements a public protocol, who is able > to call the methods in that protocol? Anyone (it’s a public protocol), only > classes in the same framework or source file (the class is internal)?

Re: -[NSWindow parentWindow] for sheet never works?

2015-11-24 Thread Jerry Krinock
> On 2015 Nov 24, at 09:46, Quincey Morris > wrote: > > wrong property … The parent window in relation to *sheets* is “sheetParent”. Yes. Thank you. Another “bingo” for Quincey :) ___ Cocoa-dev mailing list

Re: -[NSWindow endSheet?], was parentWindow

2015-11-24 Thread Jerry Krinock
> On 2015 Nov 24, at 14:54, Graham Cox wrote: > > You don’t send the parent window endSheet to run the completion handler - you > close the sheet itself by sending -endSheet to the SHEET, not its parent. Graham, I cannot find such a method, endSheet with no colon. >

Re: -[NSWindow parentWindow] for sheet never works?

2015-11-24 Thread Quincey Morris
On Nov 24, 2015, at 14:54 , Graham Cox wrote: > > you close the sheet itself by sending -endSheet to the SHEET, not its parent I’ve been puzzling over this statement for a while. At first I thought, “Oh, that’s right, you can. I guess you can send it to the sheet or

Re: Swift - internal class conforming to public protocol

2015-11-24 Thread Andreas Mayer
> if I define an internal class which implements a public protocol, who is able > to call the methods in that protocol? Anyone (it’s a public protocol), only > classes in the same framework or source file (the class is internal)? If you declare it internal it's internal. Adopting a public

Re: Avoid selection marking on cell tap

2015-11-24 Thread Quincey Morris
On Nov 24, 2015, at 15:38 , Rick Mann wrote: > Our selection marking doesn't really work for the tap that segues into the > detail view. We only use the selection marking when in edit mode (e.g. > deleting a bunch of items). I believe the old iOS HIG used to say that

Re: Swift - internal class conforming to public protocol

2015-11-24 Thread Roland King
> On 25 Nov 2015, at 00:59, Andreas Mayer wrote: > > >> Am 24.11.2015 um 15:10 schrieb Roland King : >> >> in this class, centralManagerDidUpdateState() is an internal function >> however the compiler is happy that the class satisfies >>

Re: Swift - internal class conforming to public protocol

2015-11-24 Thread Quincey Morris
On Nov 24, 2015, at 23:13 , Marco S Hyman wrote: > As I read that adopting a public protocol requires the methods that implement > the protocol to be public (but only those methods). As I said earlier, this isn’t true any more. (I think this change was made in the Swift that

Re: Swift - internal class conforming to public protocol

2015-11-24 Thread Marco S Hyman
>> if I define an internal class which implements a public protocol, who is >> able to call the methods in that protocol? Anyone (it’s a public protocol), >> only classes in the same framework or source file (the class is internal)? > > If you declare it internal it's internal. Adopting a

Re: -[NSWindow parentWindow] for sheet never works?

2015-11-24 Thread Quincey Morris
On Nov 24, 2015, at 08:47 , Jerry Krinock wrote: > > In so doing, I now need the parent window in my action methods, so I can send > the -[NSWindow endSheet::] message which runs the completion handler. In > many cases, the sheet is handy but the parent window is not. No

Re: Swift - internal class conforming to public protocol

2015-11-24 Thread Quincey Morris
On Nov 24, 2015, at 06:10 , Roland King wrote: > > How can this be, how can an internal function make a class conform to a > public method on a public protocol. IIRC, until fairly recently (i.e. WWDC 2015 or one of the later Xcode releases), it worked as your intuition tells

-[NSWindow parentWindow] for sheet never works?

2015-11-24 Thread Jerry Krinock
I’m updating an old project which used the -[NSApp beginSheet:] methods to use -[NSWindow beginSheet:completionHandler:]. In so doing, I now need the parent window in my action methods, so I can send the -[NSWindow endSheet::] message which runs the completion handler. In many cases, the

Re: Swift - internal class conforming to public protocol

2015-11-24 Thread Andreas Mayer
> Am 24.11.2015 um 15:10 schrieb Roland King : > > in this class, centralManagerDidUpdateState() is an internal function however > the compiler is happy that the class satisfies CBCentralManagerDelegate even > though that protocol is public and centralManagerDidUpdateState() is

Re: Question about getBytes:length:

2015-11-24 Thread Wim Lewis
On Nov 23, 2015, at 8:57 PM, Charles Srstka wrote: > Is there a possible typo here? It looks like you’re reading in 16 *bytes* of > data, and then comparing it against an integer that is 16 *bits* in size. Is > that what you meant to do? Bluetooth has a number of

Re: Question about getBytes:length:

2015-11-24 Thread Charles Srstka
> On Nov 24, 2015, at 12:58 PM, Wim Lewis wrote: > > On Nov 23, 2015, at 8:57 PM, Charles Srstka > wrote: >> Is there a possible typo here? It looks like you’re reading in 16 *bytes* of >> data, and then comparing

Avoid selection marking on cell tap

2015-11-24 Thread Rick Mann
I have a UICollectionView with a bunch of cells, like ya do. Our selection marking doesn't really work for the tap that segues into the detail view. We only use the selection marking when in edit mode (e.g. deleting a bunch of items). I can't figure out how to tell the collection view to not

Re: Bunch of CoreData based NSDocument questions.

2015-11-24 Thread Quincey Morris
On Nov 23, 2015, at 22:34 , Motti Shneor wrote: > > All that […] I think perhaps you’re making my argument for me. ;) Much of what you say *demonstrates* the difficulty of using a NSDocument-based design for your app. (Core Data makes it harder, because it does slow

Swift - internal class conforming to public protocol

2015-11-24 Thread Roland King
I have the following class, it was internal by default, but I’ve made it so explicitly for the purpose of the question. internal class ControllerBTLEListener: NSObject, CBCentralManagerDelegate { // the queue for all our operations static let queue : dispatch_queue_t =

Re: Making custom table cells for view-based tables on mac?

2015-11-24 Thread Ken Thomases
On Nov 24, 2015, at 12:08 AM, Quincey Morris wrote: > >> Furthermore, I want my image on the right, not the left, unless there's a >> HIG reason not to do that? Even if the thumbnails end up being on the left, >> I want to understand how to change that if