Re: Safari downloader-like behavior

2011-12-10 Thread Scott Anguish
If you’re working on a fairly recent OS, it’s much easier to use NSCollectionView for this. getting progress views into tableviews (except view based table views in Lion) is not trivial. But either a table view or collectionview would work in this case. I’d opt for collection view most likely.

NSTextField odd background colour behaviour

2011-12-10 Thread Peter Hudson
Hi All I have an NSTextField in an app. For some years I have set the background colour with, not unsurprisingly, setBackgroundColor: Recently I noticed that when attempting to set the BG colour instead of the whole area of the text field changing colour, I get a thin line of colour

Re: Locks

2011-12-10 Thread Scott Ribe
On Dec 9, 2011, at 4:48 PM, Ian Joyner wrote: You are probably looking for something like Dahm locks (invented by Dave Dahm on the Burroughs B5000 in the 1960s). Here is a long paper on locks including this origin: http://pages.cs.wisc.edu/~remzi/OSFEP/threads-locks.pdf Here is an idea

Re: Best way to manage double-clicked files?

2011-12-10 Thread julius
On Fri, 09 Dec 2011 13:14:26 -0700 C.W. Betts wrote What is the best way to handle double-clicked files in an application that doesn't use documents? The reason I ask is because a project I'm working on, PCSX-R, currently uses NSDocument subclasses to handle opening of files

Re: How to initiate dragdrop for a filename outside of NSView mouseDown

2011-12-10 Thread Vojtěch Meluzín
I need to initiate a simple drag drop operation for a single filename, but it will not be called within NSView mouseDown, but shortly afterwards (internal reasons). What does “shortly afterwards” mean, exactly? Assuming you returned from the -mouseDown: method, what are you starting the

Re: NSTextField odd background colour behaviour

2011-12-10 Thread Ross Carter
Just to make sure: are you certain that the text field is not being edited (and therefore obscured by the field editor) when you set the bg color? On Dec 10, 2011, at 3:50 AM, Peter Hudson wrote: Hi All I have an NSTextField in an app. For some years I have set the background colour

Re: NSTextField odd background colour behaviour

2011-12-10 Thread Peter Hudson
The text field is in a sheet and the order of the code that shows the sheet and then sets the bg Color has been the same for a long time. Strangely, exacly the same ui and code is used elsewhere and it works perfectly. How could I check if the field editor was covering the text field ? How

AU Cocoa GUI sometimes not showing up

2011-12-10 Thread Vojtěch Meluzín
Hi, I have a really weird problem - in AudioUnits the Cocoa GUI is available like this - host asks the plugin for information about the objc class that creates the GUI, creates the object, asks it to create the GUI. But on some computers the GUI just don't show up, or even weirder it does NOT

Re: NSTextField odd background colour behaviour

2011-12-10 Thread Ross Carter
If the field editor is active it will be firstResponder. The sheet will tell you who is firstResponder. If that is what is happening (granted, a long shot), make some other text field firstReponder and see what happens. On Dec 10, 2011, at 11:22 AM, Peter Hudson wrote: The text field is in a

Custom View for hierarchy -- NSTreeController or Data Source?

2011-12-10 Thread John Velman
(Using Xcode 4.2, writing for OS X Lion) I have a hierarchy of stuff I want to display (at the same time) in both outline view and a custom view. Sort of analagous to the Buck and Yacktman (Cocoa Design Patterns) example in CH. 29, but with Outline instead of Table. I'll most likely have a detail

Re: Locks

2011-12-10 Thread Ian Joyner
On 11 Dec 2011, at 01:50, Scott Ribe wrote: On Dec 9, 2011, at 4:48 PM, Ian Joyner wrote: You are probably looking for something like Dahm locks (invented by Dave Dahm on the Burroughs B5000 in the 1960s). Here is a long paper on locks including this origin:

Re: How to initiate dragdrop for a filename outside of NSView mouseDown

2011-12-10 Thread Kyle Sluder
2011/12/10 Vojtěch Meluzín meldaproduct...@gmail.com: I need to initiate a simple drag drop operation for a single filename, but it will not be called within NSView mouseDown, but shortly afterwards (internal reasons). What does “shortly afterwards” mean, exactly? Assuming you returned

Re: Best way to manage double-clicked files?

2011-12-10 Thread C.W. Betts
On Dec 10, 2011, at 8:23 AM, julius wrote: On Fri, 09 Dec 2011 13:14:26 -0700 C.W. Betts wrote What is the best way to handle double-clicked files in an application that doesn't use documents? The reason I ask is because a project I'm working on, PCSX-R, currently uses NSDocument

Re: Best way to manage double-clicked files?

2011-12-10 Thread Lee Ann Rucker
Try the application delegate method application:openFile: - it gets called before the NSDocument handling gets a shot at it. - Original Message - From: C.W. Betts computer...@hotmail.com To: julius jul...@juliuspaintings.co.uk, Cocoa Development cocoa-dev@lists.apple.com Sent: Saturday,

Re: Best way to manage double-clicked files?

2011-12-10 Thread Quincey Morris
On Dec 10, 2011, at 16:51 , C.W. Betts wrote: - (BOOL)readFromFileWrapper:(NSFileWrapper *)fileWrapper ofType:(NSString *)typeName error:(NSError **)outError { int chosen = [self showMemoryCardChooserForFile:[fileWrapper filename]]; if (chosen == 0) { return NO;