Does [myObject valueForString:@"param"] == [NSNull nul] ? @"X":@"Y" mean the same as [myObject valueForString:@"param"] ? @"X":@"Y"

2010-11-17 Thread Devraj Mukherjee
Hi all, Does these two things mean the same? [myObject valueForString:@"param"] == [NSNull nul] ? @"X":@"Y" [myObject valueForString:@"param"] ? @"X":@"Y" Thanks. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin request

Re: Does [myObject valueForString:@"param"] == [NSNull nul] ? @"X":@"Y" mean the same as [myObject valueForString:@"param"] ? @"X":@"Y"

2010-11-17 Thread Graham Cox
On 17/11/2010, at 8:24 PM, Devraj Mukherjee wrote: > Does these two things mean the same? > > [myObject valueForString:@"param"] == [NSNull nul] ? @"X":@"Y" > [myObject valueForString:@"param"] ? @"X":@"Y" No. First, I assume you mean -valueForKey:, not -valueForString:, plus it's +null, not

Re: What is Mac's "custom" for an agent to display its GUI?

2010-11-17 Thread Bill Cheeseman
On Nov 16, 2010, at 8:27 PM, eveningnick eveningnick wrote: > All i could think of - is installing a global event tap (but i need > accessibility Enabled then all the time - it is neither a good idea) > and watch some Shortcut pressed on a keyboard. If you decide to use a hot key (keyboard shor

Core Data Document-Based Application with Global Persistent Store

2010-11-17 Thread Dalmazio Brisinda
I've got a document-based Core Data application which works as is. I would like to add support for a global persistent store to hold a library of items. I've read most of the relevant docs, and understand that I should use configurations in the managed object models. I've defined two configurati

NSBrowser

2010-11-17 Thread Bruno Causse
hi, i can navigate in a tree through the NSbrowser (mouse or keyboard), I would like to view the properties of representedObject during my browsing. but I don't find delegate's method (passif delegate). ( kind: selectedDidChange:) is it possible? who have a track? a link? thank ___

Re: [iPhone] Toolbar button and "Touch Down"

2010-11-17 Thread Matt Neuburg
On Nov 16, 2010, at 9:26 AM, Jonathon Kuo wrote: > I agree: that's how I expected it to work, too, but that's not how it does > work (Xcode 3.2.4). If I drag a Round Rect Button onto the Toolbar, it > instantly gets promoted to a UIBarButtonItem (really!), and I can't set > "Touch Down" on it,

Re: NSBrowser

2010-11-17 Thread Dave DeLong
NSBrowser is a subclass of NSControl, which happens to have a target and action mechanism. Have you tried hooking up your browser's target and action? Dave On Nov 17, 2010, at 8:52 AM, Bruno Causse wrote: > i can navigate in a tree through the NSbrowser (mouse or keyboard), > I would like to v

Re: [iPhone] Toolbar button and "Touch Down"

2010-11-17 Thread Jonathon Kuo
On Nov 17, 2010, at 8:47 AM, Matt Neuburg wrote: > > On Nov 16, 2010, at 9:26 AM, Jonathon Kuo wrote: > >> I agree: that's how I expected it to work, too, but that's not how it does >> work (Xcode 3.2.4). If I drag a Round Rect Button onto the Toolbar, it >> instantly gets promoted to a UIBarBu

Re: NSSavePanel panel:shouldShowFilename:

2010-11-17 Thread Corbin Dunn
On Nov 15, 2010, at 7:57 PM, Leo wrote: > From: Quincey Morris > >> a number of system extensions (like Default Folder, but I think that wasn't >> the first) added the ability to option-click on a disabled item to prefill >> the >> text field with an existing name, > >> At some point (possibl

Re: [iPhone] Toolbar button and "Touch Down"

2010-11-17 Thread Matt Neuburg
On Nov 17, 2010, at 10:25 AM, Jonathon Kuo wrote: > On Nov 17, 2010, at 8:47 AM, Matt Neuburg wrote: >> >> On Nov 16, 2010, at 9:26 AM, Jonathon Kuo wrote: >> >>> I agree: that's how I expected it to work, too, but that's not how it does >>> work (Xcode 3.2.4). If I drag a Round Rect Button on

Re: [iPhone] Toolbar button and "Touch Down"

2010-11-17 Thread Jonathon Kuo
On Nov 17, 2010, at 10:54 AM, Matt Neuburg wrote: > > On Nov 17, 2010, at 10:25 AM, Jonathon Kuo wrote: > >> One question though: Taking another poster's suggestion, I placed a UISwitch >> in the toolbar and set Touch Down on it. It does register, but only for the >> OFF -> ON transition. Switc

Re: [iPhone] Toolbar button and "Touch Down"

2010-11-17 Thread Matt Neuburg
On Nov 17, 2010, at 11:48 AM, Jonathon Kuo wrote: > Heh, this is kinda what I'm afraid of doing - screwing around with stuff I can sense that, and I'm telling you to excise those fear neurons. You're not going to break anything serious. It's only a computer program, not a space shuttle - no li

NSTimer firedate randomly changes

2010-11-17 Thread Lorenzo Thurman
I use two NSTimers in my app. One runs a "mini" data fetch at regular intervals. I use another to run a "full" data fetch every 4 hours. The problem I'm running into is that while the mini fetch runs as scheduled, the full fetch never runs. I put some NSLog statements in the code to output the fire

Running JavaScript in iOS WebView.

2010-11-17 Thread Geoffrey Holden
I've written an app for the Mac (which runs rather nicely) and now I'm trying to port it to iOS (where it won't run at all). The particular line of code which is causing a problem is this: [webView stringByEvaluatingJavaScriptFromString:cmdStr]; cmdStr contains the following: rcs.inv

Re: NSTimer firedate randomly changes

2010-11-17 Thread Kyle Sluder
On Wed, Nov 17, 2010 at 12:41 PM, Lorenzo Thurman wrote: > I use two NSTimers in my app. One runs a "mini" data fetch at regular > intervals. I use another to run a "full" data fetch every 4 hours. The > problem I'm running into is that while the mini fetch runs as scheduled, > the > full fetch ne

Re: NSTimer firedate randomly changes

2010-11-17 Thread Greg Parker
On Nov 17, 2010, at 1:35 PM, Kyle Sluder wrote: > That's not how timers work. They only fire if something wakes the runloop > after their time has expired. Usually this is an event. Not true. A timer may fire some time after its fire date for any number of reasons, but "no event to wake the run l

Re: NSTimer firedate randomly changes

2010-11-17 Thread Kyle Sluder
On Wed, Nov 17, 2010 at 1:54 PM, Greg Parker wrote: > On Nov 17, 2010, at 1:35 PM, Kyle Sluder wrote: > > That's not how timers work. They only fire if something wakes the runloop > > after their time has expired. Usually this is an event. > > Not true. A timer may fire some time after its fire d

Re: Running JavaScript in iOS WebView.

2010-11-17 Thread Laurent Daudelin
On Nov 17, 2010, at 13:33, Geoffrey Holden wrote: > I've written an app for the Mac (which runs rather nicely) and now I'm trying > to port it to iOS (where it won't run at all). The particular line of code > which is causing a problem is this: > > [webView stringByEvaluatingJavaScriptFr

Re: NSTimer firedate randomly changes

2010-11-17 Thread Shawn Erickson
Timers will cause a runloop to fire (depending on run mode of course) without any other source having to fire. #import @interface TimerTest : NSObject @end @implementation TimerTest - (void)runTest { NSLog(@"Test Thread Running"); NSAutoreleasePool* pool = [[NSAutoreleasePool alloc] in

Re: NSTimer firedate randomly changes

2010-11-17 Thread Shawn Erickson
On Wed, Nov 17, 2010 at 1:54 PM, Kyle Sluder wrote: > On Wed, Nov 17, 2010 at 1:54 PM, Greg Parker wrote: > >> On Nov 17, 2010, at 1:35 PM, Kyle Sluder wrote: >> > That's not how timers work. They only fire if something wakes the runloop >> > after their time has expired. Usually this is an event

Re: NSTimer firedate randomly changes

2010-11-17 Thread Wim Lewis
On 17 Nov 2010, at 1:54 PM, Kyle Sluder wrote: > Okay, that's two people who have corrected me on this now. What am I > misinterpreting about this documentation: > > http://developer.apple.com/library/mac/#documentation/Cocoa/Conceptual/Multithreading/RunLoopManagement/RunLoopManagement.html Whi

Re: NSTimer firedate randomly changes

2010-11-17 Thread Dave DeLong
Here's what I got from that documentation: - An NSTimer is a run loop source. - NSRunLoop monitors its sources for events, provided that the run loop is running in the mode that the source is scheduled in. - If the run loop is processing an event from a different source and a timer fires, then

Re: Running JavaScript in iOS WebView.

2010-11-17 Thread Conrad Shultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 11/17/10 1:33 PM, Geoffrey Holden wrote: > void SendDelegateMessage(NSInvocation*): delegate (webViewDidLayout:) > failed to return after waiting 10 seconds. main run loop mode: > GSEventReceiveRunLoopMode > > I have got webViewDidFinishLoad (that'

Re: NSTimer firedate randomly changes

2010-11-17 Thread Kyle Sluder
On Wed, Nov 17, 2010 at 2:07 PM, Dave DeLong wrote: > Here's what I got from that documentation: > > - An NSTimer is a run loop source. > Ah, I think this is where my brain went all funny, because the NSRunLoop documentation mentions multiple times that "A timer is not considered an input source

Re: Running JavaScript in iOS WebView.

2010-11-17 Thread glenn andreas
On Nov 17, 2010, at 3:33 PM, Geoffrey Holden wrote: > I've written an app for the Mac (which runs rather nicely) and now I'm trying > to port it to iOS (where it won't run at all). The particular line of code > which is causing a problem is this: > > [webView stringByEvaluatingJavaScrip

Control Focus Issue

2010-11-17 Thread koko
In an NSPanel I have an NSComboBox and an NSTableView. I make a selection in the NSComboBox , it has focus, its action method is called. I use the mouse wheel to scroll the table view. I click an entry in the table view, the combo box action is called. Correct since the combo box has focu

Re: NSTimer firedate randomly changes

2010-11-17 Thread Greg Parker
On Nov 17, 2010, at 2:12 PM, Kyle Sluder wrote: > On Wed, Nov 17, 2010 at 2:07 PM, Dave DeLong wrote: > Here's what I got from that documentation: > > - An NSTimer is a run loop source. > > Ah, I think this is where my brain went all funny, because the NSRunLoop > documentation mentions multipl

Re: Running JavaScript in iOS WebView.

2010-11-17 Thread Glenn R. Martin
On 17 Nov 2010, at 17:28 , cocoa-dev-requ...@lists.apple.com wrote: > > JavaScript execution time is limited to 10 seconds for each top-level entry > point. If your script executes for more than 10 seconds, the web view stops > executing the script. This is likely to occur at a random place in

Re: Running JavaScript in iOS WebView.

2010-11-17 Thread Laurent Daudelin
On Nov 17, 2010, at 14:40, Glenn R. Martin wrote: > On 17 Nov 2010, at 17:28 , cocoa-dev-requ...@lists.apple.com wrote: > >> >> JavaScript execution time is limited to 10 seconds for each top-level entry >> point. If your script executes for more than 10 seconds, the web view stops >> executin

BSD Libs

2010-11-17 Thread koko
I have a number of BSD static libs that link with my Cocoa apps. I want to bring this functionality to iPhone / iPad apps. So, before I jump in I thought I would ask: Can I build BSD static libs using iPhone sdks as my base sdk? -koko __

Re: BSD Libs

2010-11-17 Thread Wim Lewis
On 17 Nov 2010, at 3:51 PM, k...@highrolls.net wrote: > I have a number of BSD static libs that link with my Cocoa apps. I want to > bring this functionality to iPhone / iPad apps. So, before I jump in I > thought I would ask: > > Can I build BSD static libs using iPhone sdks as my base

Re: BSD Libs

2010-11-17 Thread Brad Garton
Speaking of static libs, whatever happened to libstdc++-static.a in iOS? Some of legacy code I'm using still seems to require it when linking. My hack-o solution is to keep dragging the old (I think from XCode 3.1) static libs along for the simulator and device sysroots. I wish I could lose t

Re: BSD Libs

2010-11-17 Thread koko
OK. Static it is! Thx -koko On Nov 17, 2010, at 6:15 PM, Wim Lewis wrote: On 17 Nov 2010, at 3:51 PM, k...@highrolls.net wrote: I have a number of BSD static libs that link with my Cocoa apps. I want to bring this functionality to iPhone / iPad apps. So, before I jump in I thought I woul