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 requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 +nul. Pedantry aside, the comparisons are still not equivalent, even 
allowing for the logical inversion you have introduced. 

In the second case, @"X" will be chosen if the expression evaluates to true. 
That will be when the value returned is NOT nil. In the first case, @"X" will 
be chosen when the expression evaluates to equal the address (pointer) of the 
object [NSNull null]. Since that's a real, concrete object, it will be some 
valid address, not nil.

If you want @"X" to be chosen if the value is nil OR [NSNull null], then the 
correct expression would be just that:

if([myObject valueForKey:key] == nil || [myObject valueForKey:key] == [NSNull 
null])
return @"X";
else
return @"Y";

You could write this using the tertiary operator syntax, but since it's clearly 
confusing you, I'd stick with if/else.


--Graham


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 shortcut), don't use Event Taps. 
Instead, use the Carbon hot key API. It does not require that accessibility be 
enabled, and it's more efficient. Sample code is available on Apple's Developer 
site.

(Note that I am NOT suggesting that a hot key is the best option for what 
you're doing. Others have made better suggestions already.)

--

Bill Cheeseman - b...@cheeseman.name

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 configurations: 
"DocumentConfiguration" and "LibraryConfiguration". The entities in the 
document configuration are only in the document configuration, and the entities 
in the library configuration are only in the library configuration -- i.e., no 
overlap.

The docs then say "You then use this model when you create a coordinator". But 
I don't actually create my own persistent store coordinator since I'm using the 
default NSPersistentDocument coordinator.

A few questions on how best to proceed and help clear up any misunderstandings 
I might have:

1. Would I obtain the NSPersistentStoreCoordinator in the NSPersistentDocument 
and then add a new persistent store to it along the lines of:

NSPersistentStoreCoordinator * coordinator = [[myDocument 
managedObjectContext] persistentStoreCoordinator];
[coordinator addPersistentStoreWithType:NSXMLStoreType 
configuration:@"LibraryConfiguration" 
URL:url 
options:nil 
error:&error];

?

I'm thinking that this may be a problem because I haven't provided the other 
configuration definition ("DocumentConfiguration") in the 
NSPersistentDocument's persistent store coordinator as I'm using the default 
provided by NSPersistentDocument. I'm guessing it would probably use nil when 
the time came to save the document. And if so, would this be a problem? I.e., 
how would the coordinator know which persistent store to save an entity with a 
given configuration definition if the same configurations are not defined for 
all the persistent stores (in this case two)? Am I able to set the 
configuration (to "DocumentConfiguration") of the NSPersistentDocument's 
persistent store before it has been created/saved? From the 
NSPersistentDocument docs:

"Saving a new document adds a store of the default type with the chosen URL and 
invokes save: on the context. For an existing document, a save just invokes 
save: on the context."

2. Would it be better to create my own NSPersistentStoreCoordinator and 
NSManagedObjectContext instances, adding the two persistent stores with 
configurations defined, and then make the NSPersistentDocument use these 
NSPersistentStoreCoordinator and NSManagedObjectContext instances, and free the 
old ones? If so, how would I specify the url for the NSPersistentDocument for 
the addPersistentStoreWithType:... method? It seems this URL is only known once 
the untitled document has been saved. (Testing this, there does not appear to 
be any temporary persistent store (via method persistentStores on the 
persistent store coordinator) until the document is saved for the first time).

3. Or would it be better to leave NSPersistentDocument alone, and create my own 
NSPersistentStoreCoordinator instance that I use exclusively for the persistent 
library store and managed library object model? The docs say that multiple 
instances of NSPersistentStoreCoordinator should be used in multithreaded Core 
Data applications, but I don't require multithreaded Core Data support. Is it 
desirable to have two instances of NSPersistentStoreCoordinator -- one for the 
library and one for documents (intuition says that this not necessary and 
probably not the correct approach)?

Any suggestions?


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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, nor can I change the class of it in IB. That's why I'm 
> confused...


The Round Rect button that is dragged into the toolbar is not "promoted" to 
anything. It is wrapped in a UIBarButtonItem, exactly as Dave (and I advised). 
If you don't understand how to select the button itself using the design 
window, then use List View in the nib's main document window and drill down 
until you find it. m.

--
matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/
pantes anthropoi tou eidenai oregontai phusei
Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf
AppleScript: the Definitive Guide, 2nd edition
http://www.tidbits.com/matt/default.html#applescriptthings
Take Control of Exploring & Customizing Snow Leopard
http://tinyurl.com/kufyy8
RubyFrontier! http://www.apeth.com/RubyFrontierDocs/default.html
TidBITS, Mac news and reviews since 1990, http://www.tidbits.com


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 view the properties of representedObject during my browsing.
> but I don't find delegate's method (passif delegate).  ( kind: 
> selectedDidChange:)
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 UIBarButtonItem (really!), and I can't set 
>> "Touch Down" on it, nor can I change the class of it in IB. That's why I'm 
>> confused...
> 
> The Round Rect button that is dragged into the toolbar is not "promoted" to 
> anything. It is wrapped in a UIBarButtonItem, exactly as Dave (and I 
> advised). If you don't understand how to select the button itself using the 
> design window, then use List View in the nib's main document window and drill 
> down until you find it. m.

Thank you Matt for the clear explanation (and your patience with a noob)! I got 
access to the button from the List view and set the Touch Down event on the 
button. It works!

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. Switching it from ON -> OFF doesn't invoke the action method. 
Should I be using one of the other events to capture both state transitions?

Thanks again!

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 (possibly Mac OS X 10.0), Apple quietly adopted this very 
>> useful
>> convention.
> 
> I once submitted a request to Apple, maybe I'm in minority, but I hope this
> behavior will be optional one day. Like Opt-click would be perfect.
> 
> I worked at a major ad agency for several years, and this behavior caused
> major problems, misunderstandings and loss of time.
> 
> Most of the time, people click on the file list occasionally (maybe to
> type-scroll to desired folder), the file gets "quietly" renamed, you save it
> - and can never find it because it was saved under a name you never wanted
> or thought about.
> 
> I had myself to cancel the Save dialog countless times to avoid saving files
> under unwanted names.

Undo works to undo the change.

corbin


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 onto the Toolbar, it 
>>> instantly gets promoted to a UIBarButtonItem (really!), and I can't set 
>>> "Touch Down" on it, nor can I change the class of it in IB. That's why I'm 
>>> confused...
>> 
>> The Round Rect button that is dragged into the toolbar is not "promoted" to 
>> anything. It is wrapped in a UIBarButtonItem, exactly as Dave (and I 
>> advised). If you don't understand how to select the button itself using the 
>> design window, then use List View in the nib's main document window and 
>> drill down until you find it. m.
> 
> Thank you Matt for the clear explanation (and your patience with a noob)! I 
> got access to the button from the List view and set the Touch Down event on 
> the button. It works!
> 
> 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. Switching it from ON -> OFF doesn't invoke the action 
> method. Should I be using one of the other events to capture both state 
> transitions?

Yes. Just connect the switch to the controller in the nib to form an action; 
the correct event will be selected automatically.

Please understand that I am trying to educate, not criticize, when I say that 
for success in programming (for iOS or anything else) you must be willing to 
try stuff - on your own. This has nothing to do with being a newbie - it's a 
matter of character and determination. You could have selected the UIButton 
within the UIBarButtonItem; you just didn't try hard enough. If you had, 
repeated clicking and playing around would have led you to the truth. 
Similarly, to discover what event is appropriate for a UISwitch, try different 
events and see. m. 

--
matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/
pantes anthropoi tou eidenai oregontai phusei
Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf
AppleScript: the Definitive Guide, 2nd edition
http://www.tidbits.com/matt/default.html#applescriptthings
Take Control of Exploring & Customizing Snow Leopard
http://tinyurl.com/kufyy8
RubyFrontier! http://www.apeth.com/RubyFrontierDocs/default.html
TidBITS, Mac news and reviews since 1990, http://www.tidbits.com


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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. Switching it from ON -> OFF doesn't invoke the action 
>> method. Should I be using one of the other events to capture both state 
>> transitions?
> 
> Yes. Just connect the switch to the controller in the nib to form an action; 
> the correct event will be selected automatically.

Yep, using "Value Changed" it invokes the action for both switch transitions. I 
can just look at [sender state] and tell what's going on. Cool.
> 
> Please understand that I am trying to educate, not criticize, when I say that 
> for success in programming (for iOS or anything else) you must be willing to 
> try stuff - on your own. This has nothing to do with being a newbie - it's a 
> matter of character and determination. You could have selected the UIButton 
> within the UIBarButtonItem; you just didn't try hard enough. If you had, 
> repeated clicking and playing around would have led you to the truth. 
> Similarly, to discover what event is appropriate for a UISwitch, try 
> different events and see. m. 

Heh, this is kinda what I'm afraid of doing - screwing around with stuff and 
getting things to work, but not in the Cocoa Way.™  I guess there's a bit of 
intimidation to it so I try to follow where its leading me and not force it. 
But I suppose you're right, success awaits those who go where angels fear to 
tread (or whatever that saying is!)

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 lives are going to be lost. You could confuse yourself, of course, 
but that's part of the learning process too. The big mistake that I find 
beginners make (and even experienced programmers seem to be guilty of this) is 
that they start creating an app, and then, when it has some complexity, they 
become paralyzed with fear of breaking what is already working. But: (1) you 
should have been using version control so that you can always go back to an 
earlier phase of development if things don't work out; and (2) you can always 
make a new temporary project and perform your experiments there, in a much 
smaller, simpler environment. m.

--
matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/
pantes anthropoi tou eidenai oregontai phusei
Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf
AppleScript: the Definitive Guide, 2nd edition
http://www.tidbits.com/matt/default.html#applescriptthings
Take Control of Exploring & Customizing Snow Leopard
http://tinyurl.com/kufyy8
RubyFrontier! http://www.apeth.com/RubyFrontierDocs/default.html
TidBITS, Mac news and reviews since 1990, http://www.tidbits.com


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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
firedate for both timers whenever the either fetch runs. What I see is that
only the mini timer fires, always on schedule, but the full fetch timer's
firedate is always offset forward by some random value in minutes so far
(+35, +42, +72, etc.) and as a consequence, it never fires. I would expect
its firedate to remain constant until it fires. I reset the mini timer after
it fires as it needs to check if the user has changed the interval, but
there is no code that resets the full fetch timer; no need, it should run
every 4 hours.

Here is the code I use to initialize the mini timer:

miniTimer = [[NSTimer scheduledTimerWithTimeInterval:[[self fetchInterval]
floatValue] * 60.0

  target:self selector:@selector(myMethod) userInfo:nil repeats:NO] retain];

This code gets called after every mini fetch to ensure the timer is set

The full fetch timer is setup in init as:

fullFetchTimer = [[NSTimer scheduledTimerWithTimeInterval:14400.00

target:selfselector:
@selector(clearOldData) userInfo:nil repeats:YES] retain];


I also subscribe to the NSWorkSpaceDidWakeNotification to ensure the timers
fire if an interval was missed due to sleep, conditionally. If the full
fetch should run, then the mini fetch does not and vice-versa.



Any have any ideas whats going on?
TIA

-- 
"My break-dancing days are over, but there's always the funky chicken"
--The Full Monty
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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.invoke(dojo.fromJson('{"pw":"password","type":"signIn","email":"geoff.hol...@45rpmsoftware.com"}'));

I'm using the JSON framework on Google code 
(http://code.google.com/p/json-framework/), which (I'm assured) is iOS 
compatible.  It certainly builds without trouble.  

The error I get when this line (fails to) execute is:

void SendDelegateMessage(NSInvocation*): delegate (webViewDidLayout:) failed to 
return after waiting 10 seconds. main run loop mode: GSEventReceiveRunLoopMode

I have got webViewDidFinishLoad (that's where this code is called) - so it 
isn't that it's trying to run on nothing.

If you have any ideas about what I could do to fix this, I'd be most interested 
to hear them!

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 never runs. I put some NSLog statements in the code to output
> the
> firedate for both timers whenever the either fetch runs. What I see is that
> only the mini timer fires, always on schedule, but the full fetch timer's
> firedate is always offset forward by some random value in minutes so far
> (+35, +42, +72, etc.) and as a consequence, it never fires. I would expect
> its firedate to remain constant until it fires. I reset the mini timer
> after
> it fires as it needs to check if the user has changed the interval, but
> there is no code that resets the full fetch timer; no need, it should run
> every 4 hours.
>

That's not how timers work. They only fire if something wakes the runloop
after their time has expired. Usually this is an event.

Read the Overview section of the NSTimer reference:
http://developer.apple.com/library/mac/#documentation/Cocoa/Reference/Foundation/Classes/NSTimer_Class/Reference/NSTimer.html

--Kyle Sluder
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 loop" is not one of them. If the run 
loop is idle (and in the right run loop mode, and not stopped, etc), then a 
timer's expiration is itself sufficient to wake the run loop and call the 
timer's code. No other event is necessary.


-- 
Greg Parker gpar...@apple.com Runtime Wrangler


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 date for any number of
> reasons, but "no event to wake the run loop" is not one of them. If the run
> loop is idle (and in the right run loop mode, and not stopped, etc), then a
> timer's expiration is itself sufficient to wake the run loop and call the
> timer's code. No other event is necessary.
>

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

--Kyle Sluder
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 stringByEvaluatingJavaScriptFromString:cmdStr]; 
> 
> cmdStr contains the following: 
> rcs.invoke(dojo.fromJson('{"pw":"password","type":"signIn","email":"geoff.hol...@45rpmsoftware.com"}'));
> 
> I'm using the JSON framework on Google code 
> (http://code.google.com/p/json-framework/), which (I'm assured) is iOS 
> compatible.  It certainly builds without trouble.  
> 
> The error I get when this line (fails to) execute is:
> 
> void SendDelegateMessage(NSInvocation*): delegate (webViewDidLayout:) failed 
> to return after waiting 10 seconds. main run loop mode: 
> GSEventReceiveRunLoopMode
> 
> I have got webViewDidFinishLoad (that's where this code is called) - so it 
> isn't that it's trying to run on nothing.
> 
> If you have any ideas about what I could do to fix this, I'd be most 
> interested to hear them!

Must be something with the JSON framework, maybe the syntax is incorrect, 
because I just started using a WebView with 
stringByEvaluatingJavaScriptFromString: and it works flawlessly like the 
WebView for OS X. In my case, the code I execute is much simpler, things like 
"document.forms[0].user.value=\"%...@\". No problem with this kind of scripting 
but, like I said, it's very basic...

-Laurent.
-- 
Laurent Daudelin
AIM/iChat/Skype:LaurentDaudelin 
http://www.nemesys-soft.com/
Logiciels Nemesys Software  
laur...@nemesys-soft.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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] init];

[NSTimer scheduledTimerWithTimeInterval:5.0
 target:self
   selector:@selector(timerFired:)
   userInfo:nil
repeats:YES];

[[NSRunLoop currentRunLoop] run]; // will sit here until app termination

[pool release];
}

- (void) timerFired:(NSTimer*)timer {
NSLog(@"Timer Fired - %@", timer);
}
@end

int main (int argc, const char * argv[]) {
NSAutoreleasePool* pool = [[NSAutoreleasePool alloc] init];

NSLog(@"Test Starting");

TimerTest* tt = [[TimerTest alloc] init];

[NSThread detachNewThreadSelector:@selector(runTest)
 toTarget:tt
   withObject:nil];

sleep(60);

NSLog(@"Test Completed");

[pool release];
}



run
[Switching to process 61896]
2010-11-17 13:59:19.329 TimerTest[61896:a0f] Test Starting
2010-11-17 13:59:19.332 TimerTest[61896:1503] Test Thread Running
Running…
2010-11-17 13:59:24.333 TimerTest[61896:1503] Timer Fired -

2010-11-17 13:59:29.333 TimerTest[61896:1503] Timer Fired -

2010-11-17 13:59:34.333 TimerTest[61896:1503] Timer Fired -

2010-11-17 13:59:39.333 TimerTest[61896:1503] Timer Fired -

2010-11-17 13:59:44.334 TimerTest[61896:1503] Timer Fired -

2010-11-17 13:59:49.334 TimerTest[61896:1503] Timer Fired -

2010-11-17 13:59:54.334 TimerTest[61896:1503] Timer Fired -

2010-11-17 13:59:59.334 TimerTest[61896:1503] Timer Fired -

2010-11-17 14:00:04.334 TimerTest[61896:1503] Timer Fired -

2010-11-17 14:00:09.334 TimerTest[61896:1503] Timer Fired -

2010-11-17 14:00:14.335 TimerTest[61896:1503] Timer Fired -

2010-11-17 14:00:19.334 TimerTest[61896:a0f] Test Completed
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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.
>>
>> Not true. A timer may fire some time after its fire date for any number of
>> reasons, but "no event to wake the run loop" is not one of them. If the run
>> loop is idle (and in the right run loop mode, and not stopped, etc), then a
>> timer's expiration is itself sufficient to wake the run loop and call the
>> timer's code. No other event is necessary.
>>
>
> 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

What exactly do you see on the page that leads to your statement about timers?

-Shawn
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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

Which particular sentence are you (mis)interpreting?

The caveats about timers firing seem to be:
  - The timer won't fire if the run loop is currently called out to some other 
handler (processing some other event). This is reasonable, but might not be 
expected if someone's expecting timers to act more like signals or interrupts.
  - The timer won't fire if the run loop isn't running at all (no surprise).
  - The timer won't fire if it's scheduled in some mode that the run loop isn't 
running in.



___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 the run loop will process the timer event on a subsequent iteration.

- If the run loop is not running at all (like, you created an NSThread and 
didn't -run the run loop, or you are creating a foundation tool and didn't -run 
the run loop), then the timer events will not be processed, because the run 
loop is not processing *any* events.

- If the run loop is not operating in the mode that the timer is scheduled in, 
then the timer events will not be processed until the run loop begins running 
in that mode again.

Seemed like pretty straight-forward documentation to me.

Dave

On Nov 17, 2010, at 2: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
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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's where this code is called) -
> so it isn't that it's trying to run on nothing.
> 
> If you have any ideas about what I could do to fix this, I'd be most
> interested to hear them!

Hmm.  I haven't seen this myself, but are you by any chance trying to do
this on a secondary thread?

- -- 
Conrad Shultz

Synthetiq Solutions
www.synthetiqsolutions.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iD8DBQFM5FIuaOlrz5+0JdURApjsAJ4uPKnHEFVUJkiJJb7gtLx9dVMnDQCfSi9O
gMRqrPoelphoQuTmbPt4esc=
=mRgF
-END PGP SIGNATURE-
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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."
http://developer.apple.com/library/mac/#documentation/Cocoa/Reference/Foundation/Classes/NSRunLoop_Class/Reference/Reference.html

I suspect what is meant is that it's not considered an input source for the
purpose of deciding when to stop looping and return from the -run… methods.

Sorry for the distraction.

--Kyle Sluder
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 stringByEvaluatingJavaScriptFromString:cmdStr]; 
> 
> cmdStr contains the following: 
> rcs.invoke(dojo.fromJson('{"pw":"password","type":"signIn","email":"geoff.hol...@45rpmsoftware.com"}'));
> 
> I'm using the JSON framework on Google code 
> (http://code.google.com/p/json-framework/), which (I'm assured) is iOS 
> compatible.  It certainly builds without trouble.  
> 
> The error I get when this line (fails to) execute is:
> 
> void SendDelegateMessage(NSInvocation*): delegate (webViewDidLayout:) failed 
> to return after waiting 10 seconds. main run loop mode: 
> GSEventReceiveRunLoopMode
> 
> I have got webViewDidFinishLoad (that's where this code is called) - so it 
> isn't that it's trying to run on nothing.
> 
> If you have any ideas about what I could do to fix this, I'd be most 
> interested to hear them!
> 

>From the documentation 
>:

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 your code, 
so unintended consequences may result. This limit is imposed because JavaScript 
execution may cause the main thread to block, so when scripts are running, the 
user is not able to interact with the webpage.



So one of your routines (I'm guessing rcs.invoke) is taking a long time (more 
than 10 seconds - perhaps it is waiting for some networked based action to 
complete).  So if your JavaScript code is waiting for completion, you're going 
to have to refactor that code to work more asynchronously and not block.



Glenn Andreas  gandr...@gandreas.com 
The most merciful thing in the world ... is the inability of the human mind to 
correlate all its contents - HPL

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 focus but disturbing to users as the  
combo box action has reason to scroll the table view.


So, how can I set focus to the table view when it is scrolled by the  
mouse wheel so that the combo box action is not called?


-koko
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 multiple times that "A timer is not considered an 
> input source." 
> http://developer.apple.com/library/mac/#documentation/Cocoa/Reference/Foundation/Classes/NSRunLoop_Class/Reference/Reference.html
> 
> I suspect what is meant is that it's not considered an input source for the 
> purpose of deciding when to stop looping and return from the -run… methods.

A timer is a "source" but not an "input source". "The Run Loop Sequence of 
Events" says that both timers and port-based input sources are able to wake a 
sleeping run loop.


-- 
Greg Parker gpar...@apple.com Runtime Wrangler


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 your code, 
> so unintended consequences may result. This limit is imposed because 
> JavaScript execution may cause the main thread to block, so when scripts are 
> running, the user is not able to interact with the webpage.
> 
> 
> 
> So one of your routines (I'm guessing rcs.invoke) is taking a long time (more 
> than 10 seconds - perhaps it is waiting for some networked based action to 
> complete).  So if your JavaScript code is waiting for completion, you're 
> going to have to refactor that code to work more asynchronously and not block.

Another limitation i have noticed is that if the end point is secure (ie 
HTTPS), scripts dont seem to execute.
  

Glenn R. Martin___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 
>> executing the script. This is likely to occur at a random place in your 
>> code, so unintended consequences may result. This limit is imposed because 
>> JavaScript execution may cause the main thread to block, so when scripts are 
>> running, the user is not able to interact with the webpage.
>> 
>> 
>> 
>> So one of your routines (I'm guessing rcs.invoke) is taking a long time 
>> (more than 10 seconds - perhaps it is waiting for some networked based 
>> action to complete).  So if your JavaScript code is waiting for completion, 
>> you're going to have to refactor that code to work more asynchronously and 
>> not block.
> 
> Another limitation i have noticed is that if the end point is secure (ie 
> HTTPS), scripts dont seem to execute.

Seems to work for me on a secured connection (HTTPS)...

-Laurent.
-- 
Laurent Daudelin
AIM/iChat/Skype:LaurentDaudelin 
http://www.nemesys-soft.com/
Logiciels Nemesys Software  
laur...@nemesys-soft.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 sdk?

Yes.

(In fact you're not allowed to use your own dynamic libraries or frameworks; 
static libraries or "one big project" are the options you have.)


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 them, but no matter how I set various flags for both the 
legacy Makefiles (which build some static libs of their own) or the XCode 
projects they still want libstdc++-static.

brad
http://music.columbia.edu/~brad


On Nov 17, 2010, at 8: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 would ask:
>> 
>>  Can I build BSD static libs using iPhone sdks as my base sdk?
> 
> Yes.
> 
> (In fact you're not allowed to use your own dynamic libraries or frameworks; 
> static libraries or "one big project" are the options you have.)
> 
> 
> ___
> 
> Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
> 
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
> 
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/cocoa-dev/garton%40columbia.edu
> 
> This email sent to gar...@columbia.edu
> 

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


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 would ask:


Can I build BSD static libs using iPhone sdks as my base sdk?


Yes.

(In fact you're not allowed to use your own dynamic libraries or  
frameworks; static libraries or "one big project" are the options  
you have.)






___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com