Re: [MacRuby-devel] String methods missing in MacRuby

2010-01-06 Thread Conrad Taylor
Bob, I really don't have any information about the Ruby.pdf. In any case, I would recommend consulting an update to date reference like the ones that I mentioned below. Good luck, -Conrad On Sun, Nov 29, 2009 at 2:36 PM, Robert Rice wrote: > Hi Conrad: > > I don't remember where I downloaded

Re: [MacRuby-devel] [MacRuby] #504: sequel 3.7.0 gem unusable.

2010-01-06 Thread MacRuby
#504: sequel 3.7.0 gem unusable. ---+ Reporter: nie...@… | Owner: lsansone...@… Type: defect | Status: new Priority: critical | Milestone: MacRuby 0.5

Re: [MacRuby-devel] Behaviour when local variables pointing to non-auto-retained objects go out of scope?

2010-01-06 Thread Laurent Sansonetti
Hi Michael, I did not give your snippet a try, but looking quickly at the documentation for -[NSStatusBar statusItemWithLength:] I saw: "The receiver does not retain a reference to the status item, so you need to retain it. Otherwise, the object is removed from the status bar when it is d

Re: [MacRuby-devel] Behaviour when local variables pointing to non-auto-retained objects go out of scope?

2010-01-06 Thread Laurent Sansonetti
FYI, the alloc.init pattern is correct in MacRuby too. As in pure Objective-C, calling +new in MacRuby is a shortcut for +alloc and -init. Doing +new then -initWithContentsOfFile will result in initializing the object twice, probably not what you want. Laurent On Jan 5, 2010, at 1:52 AM, M

Re: [MacRuby-devel] Behaviour when local variables pointing to non-auto-retained objects go out of scope?

2010-01-06 Thread Michael Johnston
I figured that was the case, and that is why I switched to using an instance variable which will stick around after applicationDidFinishLaunching finishes, but I'm still puzzled by why the local variable does not get if I add a "sleep 1". IE, in my original snippet, leaving status_item as

Re: [MacRuby-devel] Behaviour when local variables pointing to non-auto-retained objects go out of scope?

2010-01-06 Thread Laurent Sansonetti
I believe the reason is because your sleep 1 prevented a non- deterministic garbage collection cycle. In the presence of a Cocoa run loop the GC might be triggered by a few different ways. I believe you're just lucky that it works :) Laurent On Jan 6, 2010, at 10:03 PM, Michael Johnston wro