views:

27

answers:

0

Hello,

I'm trying to hook up a custom protocol handler to my application on OSX so that I can do test://argument

In my plist I have the following:

<key>CFBundleURLTypes</key>
<array>
    <dict>
        <key>CFBundleTypeRole</key>
        <string>Viewer</string>
        <key>CFBundleURLIconFile</key>
        <string></string>
        <key>CFBundleURLName</key>
        <string>test</string>
        <key>CFBundleURLSchemes</key>
        <array>
            <string>test</string>
        </array>
    </dict>
</array>

This successfully launches the application, however my argument list is always empty. Why is this?

Under the covers it launches a Java\Scala application, the main method is: object LoadJS { def main(args: Array[String]) {

I can pass in arguments when using the "open" command on the command line. Tried from both Chrome and Firefox but either work.

Any ideas?

Thanks

Ben