osx-snow-leopard

Finder Plugin in Snow Leopard

本小妞迷上赌 提交于 2019-12-12 17:50:29
问题 Since the Finder in Snow Leopard has been rewritten to use Cocoa instead of Carbon, I'd like to know if there's a new API to write Finder plugins. The old way involved writing a CFPlugin but this doesn't seem to work anymore. 回答1: If by plug-in you mean contextual menu, you can do this via the services API. 回答2: I believe they prefer that you write Services instead of Finder plugins now. 来源: https://stackoverflow.com/questions/1651075/finder-plugin-in-snow-leopard

For Windows there is Win32 API, what about for Mac?

风格不统一 提交于 2019-12-12 14:57:56
问题 For Windows there is Win32 API, what about for Mac? On Wikipedia http://en.wikipedia.org/wiki/Cocoa_(API) it is said that Cocoa is "one of" the API... what about the full story? 回答1: At what level? The low level API is largely but not entirely FreeBSD, and below that there is still a Mach API (some things still use Mach ports for IPC, I believe; at least, launchd supports them). At the upper level are two APIs: Cocoa and Carbon. Cocoa is the native API; Carbon is intended for programs ported

Mac load commands corruption

陌路散爱 提交于 2019-12-12 10:56:39
问题 Signing (codesign) on one of our app is failing with malformed object (unknown load command 9) . After doing some research online I found that load commands are special commands in executable's header that are used by kernel for segment loading ( http://0xfe.blogspot.in/2006/03/how-os-x-executes-applications.html ). So, I ran otool -l command on my app. Where I found that and command 30 were corrupt. But, launching app works absolutely fine. How can I resolve this issue? I have no idea about

How can I capture iSight frames with Python in Snow Leopard?

空扰寡人 提交于 2019-12-12 08:09:11
问题 I have the following PyObjC script: from Foundation import NSObject import QTKit error = None capture_session = QTKit.QTCaptureSession.alloc().init() print 'capture_session', capture_session device = QTKit.QTCaptureDevice.defaultInputDeviceWithMediaType_(QTKit.QTMediaTypeVideo) print 'device', device, type(device) success = device.open_(error) print 'device open success', success, error if not success: raise Exception(error) capture_device_input = QTKit.QTCaptureDeviceInput.alloc()

Why won't this Scripting Addition run from a Mail rule?

本秂侑毒 提交于 2019-12-12 05:42:20
问题 When I access the satimage.osax scripting addition (which I'm using for its regex capability) from a Mail rule on Snow Leopard, I get errors, but it runs fine in Script Editor. The code below illustrates the problem. The first line executes fine, but the line inside the tell block throws an error (below), from the mail rule version, which I had catching the error. set substr to find text "a" in "abcd" tell application "Mail" set substr to find text "a" in "abcd" end tell So I tried a

Hide all desktop icons under Mac OS

牧云@^-^@ 提交于 2019-12-12 04:59:41
问题 I am looking for a way to show/hide desktop icons programmatically in objective-c under Mac OS X. Do you have any idea on how I can achieve this? Thanks for your help, Regards, 回答1: The Finder has a hidden preference for this. Set the value of CreateDesktop under com.apple.finder to kCFBooleanFalse , then kill the Finder. To put the desktop icons back, delete the CreateDesktop preference and kill the Finder again. Of course, this isn't a supported API feature; it could go away at any time.

How to read a file from USB Device using Mac OS X?

夙愿已清 提交于 2019-12-12 04:46:00
问题 I am very new to Mac OS X development. I am implementing a USB based application. In my application When my USB device is connected to the system I need to read a file from USB and upload it to a web server. I go through Google and some documents but I didn't get any information on this. Can you guys please suggest a best document or sample code to do this? 回答1: Probably the best places where to start are USB Device Interface Guide Networking & Internet Starting Point There you can also find

installing scipy on mac 10.6.8

假如想象 提交于 2019-12-12 03:49:46
问题 I try to install scipy on my mac 10.6.8 but always have problem with it. I've installed ipython ( sudo /usr/bin/easy_install-2.6 ipython ) and numpy ( python setup.py build/install ), but when I installed scipy by the same way, I got always this error message: RuntimeError: Running cythonize failed! Could someone tell me how to solve this problem? 回答1: Have you tried using the binaries provided for OSX? That should ensure everything works. EDIT The easiest way I've found to keep package

SCP client for MAC OS Lion [closed]

江枫思渺然 提交于 2019-12-12 03:10:26
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 7 years ago . I have just upgraded to Mac OS Lion and I have a problem with Fugu application that I used to use on Snow Leopard, I can't run it on Lion now. Do you know how a patch for running it on Lion or have you alternative applications which does the same things ? I know there is the Terminal (scp localPath login@ip

Could not find gem 'rails' headaches

偶尔善良 提交于 2019-12-11 23:49:10
问题 I'm on Mac OS X 10.6 Snow Leopard. I just updated my Ruby stuff using: sudo gem update Unfortunately, it broke everything. When I try to run a simple command in my website directory, like: rails generate model User It failed, with this error: Could not find gem 'rails (= 3.0.3, runtime)' in any of the gem sources listed in your Gemfile. Try running bundle install . So I tried running bundle install rails . It succeeded! So I tried running rails . It failed. So I tried getting the Rails