Re: x86_64 Symbol not found problem

2009-08-30 Thread Jean-Daniel Dupas
Le 30 août 2009 à 12:27, Donnie Lee a écrit : Hello, I have a problem with loadable plugin bundle for an application. I compile my plugin under Snow Leopard with -undefined dynamic_lookup option, because it uses classes from a main app. While I compile it as 32-bit all works OK (both plugin

Re: Framebuffer question

2009-08-30 Thread Jean-Daniel Dupas
Le 30 août 2009 à 17:04, Development a écrit : I cannot seem to find a answer to this in google or the docs so I'm asking here. Is there a way to get a filehandle to the screen? Preferably spitting out NSData or a compatible datatype? Screen capture code is to slow for what I'm working on

Re: libcrypto on Snow Leopard

2009-08-29 Thread Jean-Daniel Dupas
Make sure to also use the headers from 10.5 SDK if you choose this solution. Le 29 août 2009 à 10:59, Thomas Clement a écrit : Another solution is to copy the libcrypto.0.9.7.dylib from the 10.5 SDK into your project directory and link against that. It works well. Regards, Thomas On Aug

Re: libcrypto on Snow Leopard

2009-08-29 Thread Jean-Daniel Dupas
Le 29 août 2009 à 11:27, Kyle Sluder a écrit : On Aug 29, 2009, at 1:59 AM, Thomas Clement thoma...@free.fr wrote: Another solution is to copy the libcrypto.0.9.7.dylib from the 10.5 SDK into your project directory and link against that. Aren't the SDK dylibs just stubs for linking

Re: Get error message about registered observers when Object receives dealloc message

2009-08-29 Thread Jean-Daniel Dupas
Le 29 août 2009 à 14:08, Andreas Grosam a écrit : On Aug 29, 2009, at 2:29 AM, Graham Cox wrote: Thank you Graham for your reply. Hi Andreas, There is a strong code smell here. How does your observee know who its observers are? Actually, it does not. My example code is an

Re: Testing localizations in 10.6

2009-08-29 Thread Jean-Daniel Dupas
Le 29 août 2009 à 21:29, Dylan McNamee a écrit : Way back before Snow Leopard, I was able to test a localization by right-clicking on my application, and un-checking all of the languages except for the one I wanted to test. Today, however, I see that portion of the Get Info window is

Re: QuickTime Animation Rendering

2009-08-28 Thread Jean-Daniel Dupas
Le 28 août 2009 à 03:31, Kevin Cathey a écrit : (1) Is there a way for me to create the animations with CoreAnimation Layers (CALayer and sublayers) and simply tell some object to write to file? If so, how? Yes, check out CARenderer. This will require some knowledge of OpenGL to do it

Re: Snow Leopard SDK for non Premier or Select ADC members

2009-08-28 Thread Jean-Daniel Dupas
Le 28 août 2009 à 16:34, Daniel Demiss a écrit : Hi guys, I'm currently checking ADC each hour for Snow Leopard development resources. However, when I log into the Mac Dev Center I always get the Access to Mac OS X Snow Leopard You must be an ADC Premier or Select member to access the

Re: Snow Leopard SDK for non Premier or Select ADC members

2009-08-28 Thread Jean-Daniel Dupas
Le 28 août 2009 à 19:48, Shawn Erickson a écrit : Snow Leopard information appears to be live now... http://developer.apple.com/mac/library/navigation/ Does not look like what I'm used to. Are you sure this is the reference Library link ; -)

Re: Snow Leopard Development Discussion

2009-08-28 Thread Jean-Daniel Dupas
You can at least discuss everything that is published on the Snow Leopard dev center as it's public. Le 28 août 2009 à 21:35, Rick Langschultz a écrit : Hey Moderators, Is it alright to discuss Snow Leopard Development and all the underlying technologies under 10.6 since it is available

Re: Stop automatic editing of NSTextField

2009-08-25 Thread Jean-Daniel Dupas
Note that it can also be defined in Interface Builder. Le 25 août 2009 à 18:50, bryscomat a écrit : Nevermind. It's the [NSWindow setInitialFirstResponder:] method. Duh. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post

Re: authorization services

2009-08-24 Thread Jean-Daniel Dupas
Le 24 août 2009 à 18:35, Kyle Sluder a écrit : On Mon, Aug 24, 2009 at 6:10 AM, Rick C.jo_p...@yahoo.com wrote: if i can follow up please about authorization services i just want to be sure i'm on the right track. if i'm just trying to do a simple movePath but i don't have access is the

Re: Why would +[initialize] be called twice?

2009-08-24 Thread Jean-Daniel Dupas
Le 24 août 2009 à 19:19, Michael A. Crawford a écrit : Why would the class initializer be called more than once when my app starts up? Is this expected behavior? In case you're wondering, it is called twice. + (void)initialize { // Create the defaults dictionary, fill it with the

Re: Syntax Coloring?

2009-08-22 Thread Jean-Daniel Dupas
Le 22 août 2009 à 14:33, Keitaroh Kobayashi a écrit : Hello, I'm writing a code editor and so far, i've been using Flex for regex-matching the whole document every time the text is changed and coloring appropriately... I got this idea from some CocoaBuilders or CocoaDev forum/mailing list

Re: Displaying svg image with WebKit - scaling issues

2009-08-22 Thread Jean-Daniel Dupas
Le 22 août 2009 à 16:27, Peter Zegelin a écrit : Hi, I would like to display a simple svg image in my app using webkit. Unfortunately I also need to be able to scale the image to the size of the view. The webview class has makeTextLarger and makeTextSmaller which works, but limits the

Re: When do I need to override hash?

2009-08-21 Thread Jean-Daniel Dupas
Le 21 août 2009 à 10:55, Alastair Houghton a écrit : On 21 Aug 2009, at 05:44, Quincey Morris wrote: On Aug 20, 2009, at 20:51, Seth Willits wrote: The documentation, nor did many others' comments on this topic, make it clear that the mutability is only a problem for the *keys*. Others

Re: When do I need to override hash?

2009-08-21 Thread Jean-Daniel Dupas
No, not true. Key values cannot be mutated while used in a collection, period. Correct. Excuse my intrusion in this discussion, but I don't really understand why 'isEqual:' and 'compare:' results must not change when an object is used as key. My though was that as long as the hash

Re: When to 'release' in Cocoa management?

2009-08-21 Thread Jean-Daniel Dupas
Don't try to guess what implementation is, and what variable's life- time will be. Just follow the rules. You don't create the date object (by calling alloc or new or copy, …) you don't have to release it. Le 21 août 2009 à 14:50, DairyKnight a écrit : Thanks for the reply. So the

Re: Authorization Question (Possibly a simple POSIX question?)

2009-08-21 Thread Jean-Daniel Dupas
Le 21 août 2009 à 18:55, Todd Heberlein a écrit : I don't understand how the app allowed to use that file descriptor to read the file's contents. Its a general UNIX thing. If you have a book on UNIX interprocess communications, you can probably find some details in it. And as others

Re: Dynamically open file with application of end user choise......

2009-08-21 Thread Jean-Daniel Dupas
Le 21 août 2009 à 09:08, Sutapalli Satyanarayana a écrit : Hi, I am using Cocoa with Obj C. I am using the following method to open a file associated with a particular application. [[NSWorkspace sharedWorkspace] openFile:some file path] But if the file is associated with certain

Re: Choose applications dialog?

2009-08-21 Thread Jean-Daniel Dupas
Le 21 août 2009 à 12:42, Sutapalli Satyanarayana a écrit : Hi, I want to launch Choose Application dialog. How? You know, you can safely assume that everybody on this list know read. Posting two time the same question will not give you better result.

Re: devil of a time with an NSImageView

2009-08-20 Thread Jean-Daniel Dupas
Le 20 août 2009 à 01:13, I. Savant a écrit : On Aug 19, 2009, at 6:49 PM, Jean-Daniel Dupas wrote: You're probably calling setImage: before the nib is loaded (and so the outlet is connected). You can force it to load by calling [aWindowController window] before trying to set the image

Re: devil of a time with an NSImageView

2009-08-20 Thread Jean-Daniel Dupas
Le 20 août 2009 à 13:55, I. Savant a écrit : On Aug 20, 2009, at 3:41 AM, Jean-Daniel Dupas wrote: The -[NSWindowController loadWindow] methods says you can call - [NSWindowController window] to load the window, so I don't think it should be an issue.. Just a point, I think

Re: devil of a time with an NSImageView

2009-08-20 Thread Jean-Daniel Dupas
Le 20 août 2009 à 16:21, I. Savant a écrit : On Aug 20, 2009, at 9:37 AM, Jean-Daniel Dupas wrote: I managed to find a issue when you don't bind the window outlet and try to call [self window] in awakeFromNib. Instead of returning nil, it try to load the nib again, falls in a infinite

Re: devil of a time with an NSImageView

2009-08-20 Thread Jean-Daniel Dupas
Le 20 août 2009 à 20:02, I. Savant a écrit : On Aug 20, 2009, at 1:12 PM, Quincey Morris wrote: a. I'm not sure how 'loadWindow' got into this discussion -- the documentation says not to call 'loadWindow' directly but to call 'window' instead and let *it* call 'loadWindow'. You're

Re: Get size of folder

2009-08-19 Thread Jean-Daniel Dupas
Le 19 août 2009 à 09:52, Charles Srstka a écrit : On Aug 18, 2009, at 11:17 PM, PCWiz wrote: Hi, I need a good method to find the size of a file or folder exactly as displayed in Finder. I've tried every method I could find on the internet, from using the du shell utility with NSTask to

Re: Get size of folder

2009-08-19 Thread Jean-Daniel Dupas
Le 19 août 2009 à 11:47, Charles Srstka a écrit : On Aug 19, 2009, at 4:24 AM, Alastair Houghton wrote: As I think I may have mentioned before, contrary to apparently widespread opinion, Carbon isn't magic. The Carbon file manager APIs are based on BSD APIs, and calling the BSD APIs in

Re: Get size of folder

2009-08-19 Thread Jean-Daniel Dupas
Le 19 août 2009 à 17:29, PCWiz a écrit : Hi, It would probably be a good idea to tell you guys some of the methods I have tried. First of all, I've tried just using NSFileManager and NSEnumerator to enumerate through the directory. This didn't add up resource forks AND it didn't round up

Re: Get size of folder

2009-08-19 Thread Jean-Daniel Dupas
for the former. Dave On Aug 19, 2009, at 10:01 AM, Jean-Daniel Dupas wrote: Use The Core Services File Manager API : http://developer.apple.com/documentation/Performance/Conceptual/FileSystem/Articles/IteratingFiles.html ___ Cocoa-dev mailing list (Cocoa-dev

Re: devil of a time with an NSImageView

2009-08-19 Thread Jean-Daniel Dupas
You're probably calling setImage: before the nib is loaded (and so the outlet is connected). You can force it to load by calling [aWindowController window] before trying to set the image. Le 20 août 2009 à 00:39, Jack Carbaugh a écrit : You are correct. Logging of boxPic is indeed null.

Re: observeValueForKeyPath returns null in the change directory???

2009-08-15 Thread Jean-Daniel Dupas
Le 15 août 2009 à 21:18, Sandro Noel a écrit : Greetings. I would like to watch to prefeences change in my application. so i add these observers as so: settings = [NSUserDefaultsController sharedUserDefaultsController]; [settings addObserver:self forKeyPath:@values.filesPath

Re: scroll view is now disabled after switching to snowleopard

2009-08-13 Thread Jean-Daniel Dupas
Le 13 août 2009 à 21:46, Stephane Huaulme a écrit : this is an app with a couple of scrollviews, and after upgrading to snowleopard and recompiling, one of the 2 scrollviews is disabled. it's content is getting updated but it's grey'd out and i can't focus it. when i compare that view

Re: FSDetermineIfRefIsEnclosedByFolder(): No const for Cocoa's Temp Dir?

2009-08-12 Thread Jean-Daniel Dupas
Le 12 août 09 à 16:10, Jerry Krinock a écrit : Because my application deals with a small number of documents -- most users will have only one, and because these documents have agents associated with them and are often not edited, I want my app to warn the user immediately upon opening a

Re: Rescheduling an NSTimer from a completion method

2009-08-12 Thread Jean-Daniel Dupas
Le 12 août 09 à 17:55, Christopher Kane a écrit : On Aug 11, 2009, at 10:28 AM, Fritz Anderson wrote: iPhone OS 3.0 Can an NSTimer be rescheduled after firing, and after another trip through the run loop? I'd like to reschedule a NON-repeating timer in my own code. I assume that in

Re: NSString and regular expressions

2009-07-31 Thread Jean-Daniel Dupas
Le 31 juil. 09 à 11:30, Alastair Houghton a écrit : On 31 Jul 2009, at 01:04, BareFeet wrote: The documentation notes: Warning: Apple does not officially support linking to the libicucore.dylib library. In reality, how worried should I be about this? I wouldn't lose much sleep over it,

Re: Checks required for multiple asynchronous NSURLConnections?

2009-07-28 Thread Jean-Daniel Dupas
Le 28 juil. 09 à 09:07, Debajit Adhikary a écrit : I have multiple asynchronous HTTP requests being made at the same time. All these use the same NSURLConnection delegate functions. (The receivedData object is different for each connection though—this is done using a dictionary with the

Re: Cocoa Document-Based App v. Windows MDI App

2009-07-28 Thread Jean-Daniel Dupas
Le 28 juil. 09 à 11:53, Alastair Houghton a écrit : On 28 Jul 2009, at 09:09, Kyle Sluder wrote: On Jul 28, 2009, at 12:29 AM, Graham Cox graham@bigpond.com wrote: MDI is a solution to a problem of Windows' own making, where window == process. Please don't spread misinformation

Re: Dictionary with enum keys?

2009-07-27 Thread Jean-Daniel Dupas
Le 27 juil. 09 à 10:48, Debajit Adhikary a écrit : I need to create a dictionary/hashmap where the - Keys are enums - Values are some subclass of NSObject NSDictionary won't work here (enums don't conform to NSCopying). I could perhaps use a CFDictionaryRef here, but I'd like to know

Re: Cocoa Document-Based App v. Windows MDI App

2009-07-27 Thread Jean-Daniel Dupas
Le 27 juil. 09 à 10:49, Aaron Burghardt a écrit : On Jul 27, 2009, at 12:50 AM, David Blanton wrote: I think I'll use: The Mac frameworks just don't support that approach. Sorry. I could re-implement MDI on the Mac, but it would be about a man-year's work. Do you want me to do that?

Re: NSDictionary crash

2009-07-25 Thread Jean-Daniel Dupas
Le 25 juil. 09 à 21:59, slasktrattena...@gmail.com a écrit : On Sat, Jul 25, 2009 at 9:39 PM, Kyle Sluderkyle.slu...@gmail.com wrote: As I mentioned, look at NSPropertyListSerialization. NSDictionary is a plist type and can be decoded from an NSData. OK, thanks. Also, is the NSData

Re: NSSliderCell question

2009-07-23 Thread Jean-Daniel Dupas
Le 23 juil. 09 à 21:09, livinginlosange...@mac.com a écrit : I am employing an NSSliderCell in my table view, and I want to slow down the rate of change or increase the resolution of change using a modifier key like commands as I drag. This is employed in a few audio programs to assist a

Re: List classes in Bundle?

2009-07-22 Thread Jean-Daniel Dupas
You can listen NSBundleDidLoadNotification notifications. it contains @NSLoadedClasses key in the userinfo dictionary. This probably won't work for frameworks loaded at launch time, but may be helpful in some cases. Le 22 juil. 09 à 19:29, Keith Duncan a écrit : I've not used it but I

Re: iTunes COM interface for Windows; need the equivalent for

2009-07-17 Thread Jean-Daniel Dupas
Le 17 juil. 09 à 22:39, Brad Gibbs a écrit : Thanks for sharing your code, George. Is there any way to access AirTunes with Objective-C / Cocoa or AppleScript? I've seen some information on daap that allows the use of AirTunes, but it's a private API, so I'm hesitant to use it, even

Re: Efficiency of loading Localizable.strings and NSUserDefaults

2009-07-16 Thread Jean-Daniel Dupas
Le 16 juil. 09 à 04:55, Graham Cox a écrit : On 16/07/2009, at 6:45 AM, Development wrote: Anyone has some comments or ideas about this? Possibly someone with some inner understanding of how localized strings are read? Optimise later. You are fretting about the speed of loading

Re: Undo without Redo

2009-07-12 Thread Jean-Daniel Dupas
Le 12 juil. 09 à 16:10, John Nairn a écrit : I added an option to cancel some action in the middle of the action. The most convenient coding was to implement the cancel by calling undo in the NSUndoManager, but this adds a Redo action to redo the partial or incomplete changes (and leaves

Re: Wake computer from sleep

2009-07-10 Thread Jean-Daniel Dupas
Le 9 juil. 09 à 18:28, Mr. Gecko a écrit : Hello, I'm working on an alarm and I'm wondering what would be the best way to make it wake up the computer. I've heard of IOPMSchedulePowerEvent and I think it's the best way, but I'll need root privileges and I'm guessing the best way to do

Re: Bound array item is repeatedly copied and collected while scrolling table view

2009-07-07 Thread Jean-Daniel Dupas
Le 7 juil. 09 à 14:24, Rick Hoge a écrit : I have a nib file in which entries in an NSTableView are bound to an NSMutableArray via an NSArrayController. It is used in an application running under garbage collection. The array items are NSDictionaries, and one of these dictionaries

Re: NSTableView bug?

2009-07-02 Thread Jean-Daniel Dupas
I've created a simple application with an NSTableView. I have written a delegate for this table, numberOfRowsInTableView:objectValueForTableColumn:row:, that returns the number of rows in the table when requested. My application uses the table view to display hexadecimal data on a flash

Re: icns to Icon\r

2009-06-25 Thread Jean-Daniel Dupas
Le 25 juin 09 à 00:45, Michael Hanna a écrit : Hi all, my goal is to create custom installer icons for a couple of Installer .pkg packages. I'm following the instructions at: http://www.khiltd.com/Downloads/prettypackages.html At the section Into the Fray he suggests to use the Finder to

Re: Screen capture Cocoa framework

2009-06-24 Thread Jean-Daniel Dupas
Le 24 juin 09 à 11:38, Andy Bell a écrit : Hi All, Does anyone know if there is a screen recording Cocoa framework out there? I want to record the screen much like Camtasia studio does on Windows and don't want to reinvent the wheel. I'm not aware of any OpenSource framework, but I

Re: Screen capture Cocoa framework

2009-06-24 Thread Jean-Daniel Dupas
just draw the cursor before calling glReadPixel()). Le 24 juin 09 à 13:47, Andy Bell a écrit : Hi Jean-Daniel, Thanks for that, do you know if it captures the mouse pointer as well? Are there any commercial frameworks? Thanks Andy On Wed, Jun 24, 2009 at 12:37 PM, Jean-Daniel Dupas

Re: Crash in KVO when using -keyPathsForValuesAffectingKey

2009-06-21 Thread Jean-Daniel Dupas
Le 21 juin 09 à 11:26, Quincey Morris a écrit : On Jun 20, 2009, at 14:15, Jean-Daniel Dupas wrote: Thank you for the suggestion, but it does not solve the problem. Even trying w1.object = nil before unregistring the observer has no effect. When I looked at your code a little harder, I

Crash in KVO when using -keyPathsForValuesAffectingKey

2009-06-20 Thread Jean-Daniel Dupas
Hello, I'm experiencing some difficulties with KVO and auto dependent keys. Am I doing something wrong, or should I fill a bug report ? Here is a test case. MyObject is a class with a single property: name. MyWrapper is a class that wrap a MyObject instance. It also declares a property

Re: Crash in KVO when using -keyPathsForValuesAffectingKey

2009-06-20 Thread Jean-Daniel Dupas
Le 20 juin 09 à 20:56, Quincey Morris a écrit : On Jun 20, 2009, at 11:08, Jean-Daniel Dupas wrote: - (void)dealloc { [_object release]; [super dealloc]; } Try changing this to: - (void) dealloc { self.object = nil; [super dealloc]; } 'keyPathsForValuesAffectingName

Re: Crash in KVO when using -keyPathsForValuesAffectingKey

2009-06-20 Thread Jean-Daniel Dupas
Le 20 juin 09 à 21:39, Jeff Johnson a écrit : Sorry, scratch that, I apparently misread your example. As Phil would say, I'm an idiot. Does +keyPathsForValuesAffecting... actually support true keypaths? The documentation is unclear. -Jeff If this is not supported, I will fill a bug

Re: Group CGAffineTransform Animations?

2009-06-17 Thread Jean-Daniel Dupas
Le 17 juin 09 à 10:53, Chunk 1978 a écrit : is have this animation block with both Enlarge and Rotate, but only one work properly (the last one listed). what is the proper way to group the two transforms together: -=-=-=- //Animation Block [UIView beginAnimations:nil

Re: Group CGAffineTransform Animations?

2009-06-17 Thread Jean-Daniel Dupas
Concatenation is just a matrix multiplication: http://developer.apple.com/documentation/graphicsimaging/Conceptual/drawingwithquartz2d/dq_affine/dq_affine.html#/ /apple_ref/doc/uid/TP30001066-CH204-CJBECIAD So yes, you can do that. It's just a matter of taste, but I would write it like that

Re: Any Good Core Animation Tutorials?

2009-06-16 Thread Jean-Daniel Dupas
Le 16 juin 09 à 17:49, Chunk 1978 a écrit : humm... ok, so CA is 3D, which means X (length), Y (height) and Z (depth, or width), while CG is 2D so it only uses X and Y... so if i want to only have one layer on the screen at one time, is there still an advantage to using Z for enlargements in

Re: finding bundle identifiers

2009-06-10 Thread Jean-Daniel Dupas
Le 10 juin 09 à 11:51, Ken Thomases a écrit : On Jun 10, 2009, at 4:27 AM, Rick C. wrote: to be more specific on what i'm trying to do i would like to be able to review the files in a preferences folder and find the related app on the system. so i was trying to come up with a list of

Re: Reducing the Window size

2009-06-10 Thread Jean-Daniel Dupas
Le 10 juin 09 à 12:51, Arnab Ganguly a écrit : Hi All, From NSButton in the nib file is it possible to minimize part of the application window? Like in case of Itunes when I click on the + button the player content's lists get reduced and only the playing station can be visible.How can I

Re: App does not start on a different machine

2009-06-10 Thread Jean-Daniel Dupas
Le 11 juin 09 à 00:26, Martin Batholdy a écrit : hi, my app works fine on my macbook, but on a macbook pro it starts and then just disappears immediately after the start (nor error message). The OS version is the same, and the app is pretty simple (no graphic stuff or something like

Re: Help with SHA class

2009-06-04 Thread Jean-Daniel Dupas
An other alternative is using the CommonCrypto API (which does not require to link on other library like OpenSSL). man Common Crypto Le 4 juin 09 à 18:23, KK a écrit : I ran into a similar problem - but I decided to use libcrypto: man 3 sha1 or man 3 EVP_DigestInit Keita On Thu, Jun 4,

Re: Performance, Efficiency - Coding practice

2009-05-29 Thread Jean-Daniel Dupas
Le 29 mai 09 à 11:31, Alexander Spohr a écrit : Am 29.05.2009 um 02:55 schrieb John Ku: And yeah, NSMutableString will be initialized else where and released later. Why use a mutable string at all? Just retain the new string and dump the old one. Use @property (retain) NSString

Re: [OT] default boot device

2009-05-26 Thread Jean-Daniel Dupas
Le 26 mai 09 à 15:43, Тимофей Даньшин a écrit : Hello. I installed another version of MacOS X in a separate partition of my hard disc. And now whenever i start the computer, it boots from that partition by default (unless i press option to select the partition to boot from this time).

Re: Adding a Timer to a Thread

2009-05-26 Thread Jean-Daniel Dupas
Le 26 mai 09 à 20:15, Andreas Grosam a écrit : What would you suggest is the preferred way to add a timer to a different running thread? Normally, I would use: NSRunLoop *runLoop = [NSRunLoop currentRunLoop]; [runLoop addTimer:aTimer forMode:NSDefaultRunLoopMode]; However, this

Re: Is there two streams with CFReadStreamRead happend in two threads?

2009-05-19 Thread Jean-Daniel Dupas
Le 19 mai 09 à 09:27, Chris Gardner a écrit : Hi, Now I have created two threads and want to download files through the method below in each thread: 1. Create the stream using CFReadStreamCreateWithFTPURL() 2. Set up my callbacks wiht CFReadStreamSetClient() 3. Add it to the

Re: When init returns nil does it cause a leak

2009-05-19 Thread Jean-Daniel Dupas
Le 19 mai 09 à 18:24, Reza Farhad a écrit : Hi all we have an object that gets initialized like most other objects -(id)init { self = [ super init ]; if ( self ){ ...do something; } return self; } if [ super init ] returns nil does this cause

Re: LMSetKey[Rep]Thresh

2009-05-18 Thread Jean-Daniel Dupas
Le 18 mai 09 à 08:27, Eric Schlegel a écrit : On May 17, 2009, at 9:37 PM, Christopher Hansen wrote: First of all, I want to be able to set them, so I primarily need the setters, but I also want the getters because I want to be able to restore the previous values when my app exits or is

Re: Packages vs bundles vs folders etc

2009-05-12 Thread Jean-Daniel Dupas
Le 11 mai 09 à 23:06, Alastair Houghton a écrit : On 11 May 2009, at 19:08, Sean McBride s...@rogue-research.com wrote: On 5/11/09 1:55 PM, Alastair Houghton said: I'm not sure whether this is now classed as legacy behaviour, but on HFS+ at least, Finder looks at the bundle bit to

Re: converting a characer to a keycode

2009-05-11 Thread Jean-Daniel Dupas
Le 9 mai 09 à 22:29, kvic...@pobox.com a écrit : At 9:14 PM -0700 5/8/09, glgue...@amug.org wrote: ken wrote: the only way i can think to perform this conversion is to itereate over the virtual key codes 0-127 (with various combinations of shift and option keys) until i find the one

Re: Subject: detect option key on startup

2009-05-11 Thread Jean-Daniel Dupas
Try in - applicationDidFinishLaunching: Le 10 mai 09 à 00:58, Mitchell Livingston a écrit : In what method would that need to be in to get the key on startup? I tried without luck in init and awakeFromNib. On Saturday, May 09, 2009, at 06:48PM, Kirk Kerekes kirkkere...@gmail.com wrote:

Re: Trouble with property (copy) and retain counts

2009-05-06 Thread Jean-Daniel Dupas
Search NSZombie in Google. It may be what you need. Le 6 mai 09 à 01:04, Malayil George a écrit : I don't think I have a leak...quite the opposite. I think the sample app I'm playing with is crashing because I might be releasing an object too soon. Which is why I resorted to retainCounts

Re: Vector Graphic Dock Icon?

2009-05-06 Thread Jean-Daniel Dupas
Le 6 mai 09 à 16:44, Chris Idou a écrit : Is it possible to use a vector graphic as a dock icon? The Apple doco seems to encourage using vector graphics, but I can't find it documented what format it would expect. I tried a PDF but that didn't seem to work. What do you mean by Try

Re: Trouble with property (copy) and retain counts

2009-05-05 Thread Jean-Daniel Dupas
If the retain count confuses you, you stop to using it as it's almost never relevant. That said, have a look at the atomic section in the property references: http://developer.apple.com/documentation/Cocoa/Conceptual/ObjectiveC/Articles/ocProperties.html Le 5 mai 09 à 06:34, Malayil George

Re: Discussion on how to draw text like that seen in toolbars

2009-05-04 Thread Jean-Daniel Dupas
Le 2 mai 09 à 00:42, Alex Kac a écrit : I know there was a discussion about this a few months ago on this list, but I cannot find the right terms to search for. The discussion was how to draw text so that it was sunken much like you see in the toolbar. I just remember there was a specific

Re: Programmatically Changing Display(s) to Greyscale

2009-05-04 Thread Jean-Daniel Dupas
Le 4 mai 09 à 19:23, Grant Erickson a écrit : While the Displays preference pane doesn't appear to allow it, the Universal Access preference pane allows setting all active, online displays to greyscale mode. However, when using CGDisplayAvailableModes, the only modes that appear for the

Re: Integer as key in NSMutableDictionary

2009-05-04 Thread Jean-Daniel Dupas
Le 4 mai 09 à 22:58, Alexander Heinz a écrit : On May 4, 2009, at 3:22 AM, Weydson Lima wrote: I know that these methods are expecting pointers as parameters and I am passing a scalar. So, what's the best way to approach that? That's correct. You really shouldn't put any scalar types in an

Re: C language in obj-c

2009-04-29 Thread Jean-Daniel Dupas
Le 29 avr. 09 à 12:04, fawad shafi a écrit : Dear All, may be this question is odd, but i wana use .obj file created in c language, in objective-c. is it possible?? thanks in advance. Obj-C is a superset of C and can access any C code just like you can from any other C file.

Re: C language in obj-c

2009-04-29 Thread Jean-Daniel Dupas
Le 29 avr. 09 à 12:25, Alastair Houghton a écrit : On 29 Apr 2009, at 11:04, fawad shafi wrote: may be this question is odd, but i wana use .obj file created in c language, in objective-c. is it possible?? It depends what you mean. If you're asking if it's possible to use C code in a

Re: C language in obj-c

2009-04-29 Thread Jean-Daniel Dupas
Le 29 avr. 09 à 12:39, Alastair Houghton a écrit : On 29 Apr 2009, at 11:35, Jean-Daniel Dupas wrote: Le 29 avr. 09 à 12:25, Alastair Houghton a écrit : Just for the record, with gcc-llvm, you can no longer assume that .o files are Mach-O object files. When you use Link-Time-Optimization

Re: Second frontmost app?

2009-04-28 Thread Jean-Daniel Dupas
Le 28 avr. 09 à 05:02, Dave DeLong a écrit : Hey everyone, Is there a way to get the second frontmost app? For example, right now Mail.app is the frontmost, then Safari, because Safari was the active app before I switched to Mail. Is there any sort of API to that tells me that if I

Re: Second frontmost app?

2009-04-28 Thread Jean-Daniel Dupas
that, I always get: Error for next process: -600 (-600 = No eligible process with specified process serial number.) Any ideas? Thanks, Dave On Apr 28, 2009, at 1:44 AM, Jean-Daniel Dupas wrote: You can use the ProcessManager API. AFAK, the GetNextProcess() will returns the processes

Re: Why is NSString-FSRef so hard?

2009-04-28 Thread Jean-Daniel Dupas
Le 28 avr. 09 à 17:47, Michael Ash a écrit : On Tue, Apr 28, 2009 at 1:13 AM, Erg Consultant erg_consult...@yahoo.com wrote: Apple's doc's specifically say to stay away from using the CString routines which require encodings. So now the encoding issue goes away. The problem is

Re: Second frontmost app?

2009-04-28 Thread Jean-Daniel Dupas
returns the front process? This will not be your application if you're in the background. On 04/28/2009 9:57 AM, Jean-Daniel Dupas devli...@shadowlab.org wrote: Don't bother with that. I did a try, and it look like the Process Manager order has nothing to do with the cmd + tab order

Re: CF autorelease?

2009-04-25 Thread Jean-Daniel Dupas
Le 25 avr. 09 à 07:57, Charles Srstka a écrit : On Apr 23, 2009, at 3:42 PM, Todd Heberlein wrote: Many of the Cocoa object allocation methods automatically do an autorelease before returning the pointer to the object, so I can call something like: foo( [NSString stringWithCString: bar

Re: [NSOutlineView] _outlineCell and _trackingOutlineCell vs 64-bit

2009-04-25 Thread Jean-Daniel Dupas
Le 25 avr. 09 à 15:12, Iceberg-Dev a écrit : On Apr 22, 2009, at 8:16 PM, Corbin Dunn wrote: [...] There is no way to replace the outlinecell How could one then draw the disclosure triangle in white Leopard has a bug with them looking too dark; that is a known issue, and it will be

Re: NSButtonCell binds only readonly; Non-bool bindings OK.

2009-04-25 Thread Jean-Daniel Dupas
Le 26 avr. 09 à 00:00, Jerry Krinock a écrit : On 2009 Apr 25, at 14:29, Kyle Sluder wrote: There's been some discussion on this list in the recent past regarding whether it was more useful to file bugs in radar (bugreport.apple.com) or use the documentation feedback thingy. it gave

Re: How to clone a mutable dictionary

2009-04-24 Thread Jean-Daniel Dupas
Le 24 avr. 09 à 10:35, Steve Cronin a écrit : Folks; Its been a long day and maybe I'm just in need of sleep but I'm bamboozeled... I have an NSMutableDictionary (newThing) that is set up based on some user defaults and current contextual data. newThing is fine. What I want to do is

Re: How to clone a mutable dictionary

2009-04-24 Thread Jean-Daniel Dupas
Le 24 avr. 09 à 10:50, Graham Cox a écrit : On 24/04/2009, at 6:44 PM, Jean-Daniel Dupas wrote: NSMutableDictionary *newThing2 = [newThing mutableCopy]; [newThing2 setObject:foo forKey:bar]; This doesn't copy the contents of the dictionary, it only makes a mutable copy

Re: NSOpenPanel listing .app's and Mac OS X executables

2009-04-23 Thread Jean-Daniel Dupas
Write your own filter: use the NSOpenPanel delegate method: - (BOOL)panel:(id)sender shouldShowFilename:(NSString *)filename Le 23 avr. 09 à 09:40, Arun a écrit : I have used [NSArray arrayWithObjects:@public.executable,@app,nil] . This will allow me to choose only executables and

Re: How to make app login window to look like OS X user login window ?

2009-04-22 Thread Jean-Daniel Dupas
Le 22 avr. 09 à 20:31, Shawn Erickson a écrit : On Wed, Apr 22, 2009 at 9:06 AM, Chris Williams ch...@clwill.com wrote: blah blah... Far better than a spinning beach ball. If written well an application can launch quickly and then get into UI that informs the user that a lengthy process

Re: Undo (UI Concept)

2009-04-17 Thread Jean-Daniel Dupas
The problem with the 2 undo approach is when you start to think about redo. What append if you undo twice and redo once. - You restore only one value, and get a state that should not be possible as the inference function would have complete the last row if it was done by the user. - You

Re: Best way to pass large objects between tasks?

2009-04-16 Thread Jean-Daniel Dupas
I don't know about other OS X technologies, but IIRC CFMessagePort is optimized to exchange large amount of data between processes. http://developer.apple.com/documentation/CoreFoundation/Reference/CFMessagePortRef/Reference/reference.html Le 16 avr. 09 à 10:44, Oleg Krupnov a écrit :

Re: C: treated as a path component

2009-04-15 Thread Jean-Daniel Dupas
Le 15 avr. 09 à 01:57, Dragan Milić a écrit : Hell all, Let's suppose I've got NSString @C:omponent , which represents the name of a file. Is there a way to instruct NSString class not to treat a leading single letter followed by a column as a path separator? Namely, I need this one

Re: Best way to get a non-repeating random number?

2009-04-14 Thread Jean-Daniel Dupas
Le 14 avr. 09 à 12:26, Luca C. a écrit : 2009/4/14 Uli Kusterer witness.of.teacht...@gmx.net On 14.04.2009, at 01:44, Luca C. wrote: You can put every (unsigned) value you want in there, though in general it's used passing (unsigned)time(NULL) as parameter. This way you'll always get a

Re: Best way to get a non-repeating random number?

2009-04-14 Thread Jean-Daniel Dupas
Le 14 avr. 09 à 13:08, WT a écrit : On Apr 14, 2009, at 12:56 PM, Jean-Daniel Dupas wrote: reading /dev/random is currently the best way to generate random number on OS X. http://lists.apple.com/archives/apple-cdsa/2009/Mar/msg00077.html Yes, and those are *true* random numbers, since

Re: Undocumented flags in LSCopyItemInfoForRef

2009-04-10 Thread Jean-Daniel Dupas
Le 10 avr. 09 à 07:06, Gerriet M. Denkmann a écrit : LSItemInfoFlags, returned by LSCopyItemInfoForRef() when the queried item is an application, contains several undocumented flags (i.e. flags which are NOT documented in LSInfo.h nor in the Launch Services Reference). E.g. iTunes.app

Re: How to find whether the file directory is a valid Mac OS X App?

2009-04-08 Thread Jean-Daniel Dupas
Le 8 avr. 09 à 08:58, Arun a écrit : Hi All How to find whether the file / directory is a valid Mac OS X App? You can use LSCopyItemInfoForURL() and check for the kLSItemInfoIsApplication flags. ___ Cocoa-dev mailing list

Re: Difference between SEL and const char* when sending a message?

2009-04-08 Thread Jean-Daniel Dupas
A good way to understand the runtime is to read the sources: http://www.opensource.apple.com/darwinsource/10.5.6/objc4-371.2/ Le 8 avr. 09 à 15:07, Daqi Pei a écrit : Thanks for all your answers. I was doing that basically trying to understand how the runtime works. Guess I've got what I

Re: Difference between SEL and const char* when sending a message?

2009-04-08 Thread Jean-Daniel Dupas
I remember I read that somewhere in an Apple document, but I don't managed to find where, and I don't find any proof of that in the sources. Le 8 avr. 09 à 15:26, Julien Jalon a écrit : 64bit runtime selectors are not char* as far as I know. In general, you should use

<    1   2   3   4   5   6   7   8   9   10   >