Re: KVO can be unsafe in -init?

2009-09-12 Thread Uli Kusterer
Am 09.09.2009 um 11:02 schrieb John Chang: No, it's a singleton. Basically it's a "manager" object that wants to continually monitor something else for changes. Also, - addObserver is the last line of code in -init, before the return. This article may be of interest to you: http://zathras.de

How to display AboutBox window in Agent Application

2009-09-12 Thread cocoa learner
Hi All, I have created an Agent Application using key - Application is agent (UIElement) = true in Info.plist file. Problem # 1). my AboutBox window is not getting displayed. Here is my code snippet - AppController.h @interface AppController : NSObject { // some more data member to run app a

Re: KVO can be unsafe in -init?

2009-09-12 Thread Jerry Krinock
On 2009 Sep 11, at 05:55, John Chang wrote: Just to update you guys. We managed to reproduce the problem in- house and catch it in the debugger. I'd be interested to know how John is going to fix this problem. I myself have used the performSelector:withObject:afterDelay:0.0 solution in

Re: Not receiving mouseDown/Up events in borderless window . . .

2009-09-12 Thread Michael A. Crawford
Since the window is transparent and the view is not, maybe the view is actually getting the mouse event? Maybe. But why does it work on Snow Leopard? I will test your theory out and get back to you. I'm not even sure the content-view is a responder but I'll check that out too. -Michae

Re: Not receiving mouseDown/Up events in borderless window . . .

2009-09-12 Thread Ken Thomases
On Sep 12, 2009, at 9:12 PM, Michael A. Crawford wrote: I have created a borderless window that is used to display a custom graphic, which need to respond to the enter key or a mouse click by closing itself. Seems straightforward enough. It works great on Snow Leopard (10.6) but I do not

Not receiving mouseDown/Up events in borderless window . . .

2009-09-12 Thread Michael A. Crawford
I have created a borderless window that is used to display a custom graphic, which need to respond to the enter key or a mouse click by closing itself. Seems straightforward enough. It works great on Snow Leopard (10.6) but I do not get the mouse events on Leopard (10.5). Hitting the ent

Re: NSString and UIWebView load

2009-09-12 Thread Jens Alfke
There aren't any obvious ref-counting problems in the code you posted. What's the backtrace of the crash? Also, have you tried using the new Build And Analyze command in Xcode 3.2? It can help find some problems like these. *[newWebView **loadHTMLString**:htmlContentTemp **baseURL**: [**NSUR

Re: Retaining a NSURL and retaining its -path

2009-09-12 Thread Ken Thomases
In addition to what others have already said... On Sep 12, 2009, at 11:43 AM, John Love wrote: In my controller, one of my instance variables is a NSURL and I retain it because I pass it to a 2nd controller. This sentence seems misguided. If it's an instance variable of the first controll

Re: NSString and UIWebView load

2009-09-12 Thread Dragos Ionel
I still cannot figure this out, so any help would be kind appreciated. I followed the debugging steps from hereand here is what I obtained: Code except: .h file: ...

Re: Retaining a NSURL and retaining its -path

2009-09-12 Thread Jens Alfke
On Sep 12, 2009, at 9:43 AM, John Love wrote: Basic question: if a parent object is retained, why isn't each sibling component object of that parent retained?? It's not a component object in the implementation. Whenever you call - path, the NSURL implementation copies out and decodes the pa

Re: Retaining a NSURL and retaining its -path

2009-09-12 Thread Greg Guerin
John Love wrote: My first attempt was to pass that NSURL in the same manner and then place the extracted [myURL path] into an instance variable of the 2nd controller. Okay so far .. and then I assumed that if myURL was retained in the 1st controller, then "naturally" its NSString -path wa

Re: Retaining a NSURL and retaining its -path

2009-09-12 Thread BJ Homer
On Sat, Sep 12, 2009 at 10:43 AM, John Love wrote: > In my controller, one of my instance variables is a NSURL and I retain it > because I pass it to a 2nd controller. In my second controller, I extract > [myURL path] and look at it in a secondary thread loop and everything works > fine. I bega

Retaining a NSURL and retaining its -path

2009-09-12 Thread John Love
In my controller, one of my instance variables is a NSURL and I retain it because I pass it to a 2nd controller. In my second controller, I extract [myURL path] and look at it in a secondary thread loop and everything works fine. I began to think if I could eliminate that call to [myURL p

Re: AffineTransform

2009-09-12 Thread Gregory Weston
Development wrote: I am using the following to rotate an image and Im having a problem. After the transform when I attempt to move the image it collapses to 0 width and does other unpredictable and strange things. What am I forgetting to do so that the image is movable? self.transform =

Re: Subversion and Interface Builder

2009-09-12 Thread Andy Lee
On Aug 27, 2009, at 7:04 PM, Alexander Hartner wrote: Every time I localise the .svn folder seem to be removed or get broken in other ways. I don't know much about localization, but can you spell out exactly how you're doing it? It seems odd to me that sometimes the .svn folder would be r

Re: Cocoa-dev Digest, Vol 6, Issue 1304

2009-09-12 Thread Roland King
you want to be a little thoughtful if you go that way, if you cross a daylight savings time boundary you may find you have one more or one less hour than you might expect, ie it may not be a multiple of 24. Not hard to sort out, but something you need to be aware of. On 12-Sep-2009, at 9:15

Re: Printing with Snow Leopard

2009-09-12 Thread Gerriet M. Denkmann
On 11 Sep 2009, at 21:28, Corbin Dunn wrote: Hi Gerriet, Have you tried running with Zombies? Yes. Run -> Run With Performance Tool -> Zombies If so, does that show an overrelease anywhere? No. Can you please log a bug on bugreporter.apple.com if you believe it is a bug in the Apple fr

Re: Cocoa-dev Digest, Vol 6, Issue 1304

2009-09-12 Thread Jesse Armand
Read the data into NSDate object, and compare it with timeIntervalSinceDate: method. This way, you'll get the time interval in seconds and then convert it to unit of days. Jesse Armand (http://jessearmand.com) On Sat, Sep 12, 2009 at 6:25 PM, Rajashekha

Re: Cocoa-dev Digest, Vol 6, Issue 1304

2009-09-12 Thread Michael Paluszek
One way is the convert the dates to Julian date http://en.wikipedia.org/wiki/Julian_day and subtract the Julian day numbers. Sincerely, Mike On Sep 12, 2009, at 7:25 AM, Rajashekhar Managoli wrote: Hi All, I am new to Objective C and COCOA and Iphone Delopment I am reading two dates from

Re: Cocoa-dev Digest, Vol 6, Issue 1304

2009-09-12 Thread Rajashekhar Managoli
Hi All, I am new to Objective C and COCOA and Iphone Delopment I am reading two dates from UIDatepicker i want find the diffrence between to days say 12/09/2009 in DDMM format 16/09/2009 DDMM for and finde the number of days in between. Thnaks in advance Regards Raj __

Re: Subversion and Interface Builder

2009-09-12 Thread Uli Kusterer
Am 28.08.2009 um 01:04 schrieb Alexander Hartner: For some time now I have been struggling with interface builder's NIB files and subversion. Every time I localise the .svn folder seem to be removed or get broken in other ways. You must be missing something else. We're using NIBs and SVN

Re: Adding an associated reference is memory expensive (was: Adding an observer is memory expensive)

2009-09-12 Thread Greg Parker
On Sep 12, 2009, at 12:59 AM, Kai BrĂ¼ning wrote: On 12.9.2009, at 00:35, Greg Parker wrote: We have your earlier report rdar://7212101. Thanks, Torsten. (Ken didn't see it because the bug didn't pass through his group's hands on its way to my group.) This is a bug in the associated referenc

Re: Adding an associated reference is memory expensive (was: Adding an observer is memory expensive)

2009-09-12 Thread Kai BrĂ¼ning
On 12.9.2009, at 00:35, Greg Parker wrote: We have your earlier report rdar://7212101. Thanks, Torsten. (Ken didn't see it because the bug didn't pass through his group's hands on its way to my group.) This is a bug in the associated reference machinery. That code keeps a C++ std::hash_m