[sip-comm-dev] [GSoC09] Java interface for Mac OS X's Growl

Romain KUNTZ kuntz at lsiit.u-strasbg.fr
Thu Jul 16 15:05:05 CEST 2009


Hi,

On 2009/07/15, at 14:32, Egidijus Jankauskas wrote:
>> - Detect if Growl is available on the system (do you know if it is  
>> possible?)
>
> Yes, this is possible. Growl Cocoa API has methods to check if Growl  
> is installed and running. I have added these two as static methods  
> in my growl4java API.

Ok.

>> - if yes, use the Growl notification by default,
>> - if not, use the other notification system by default,
>> - handle the special cases:
>> -- the user has Growl installed, but switches to the other  
>> notification system (i.e. record the preference using the  
>> configuration service, and ensure that the user preference will be  
>> kept on the next start),
>> -- the user uninstall Growl (i.e. growl is not detected on SC  
>> startup, so it switches back to the default notification type)
>>
>> Do you think these are possible?
>
> Yes, I think these are possible. I will try to do it in the next few  
> days.

Ok great!

>> Also, it would be nice to be able to use Growl when using "ant  
>> run". At the moment Growl is activated only when building a MacOSX  
>> package. I think you could add permanently the Growl package to  
>> felix.properties, making sure that it does not raise issues when it  
>> is run on another system (I can help you to test on linux if needed).
>
> I am using ant run in my branch, so you can test it on linux to see  
> if it works.

I've tested your branch on linux, it works fine. The  
growlnotification.jar is not deployed when doing "ant run" on another  
OS than MacOSX, so it simply fails to start.

However, you'll need to modify slightly the resources/install/ 
build.xml file: there is a reference to growlnotification.jar that  
should be removed in the "macosx" target (otherwise we will end up  
with 2 references to the bundle in the felix.properties file).

> Also, can you check if I am using my growl4java API correctly. I  
> have put it in lib/os-specific/mac. Is it the right folder?

Yes, this is the right place. I've seen you also put the  
libgrowl.dylib in lib/native/mac, which is also right.

By the way, do we still need the lib/os-specific/mac/growl.jar ? I  
guess it was useful when we used the java bindings.

> And should I add the source files of the library to src/native/ 
> macosx ?

I've discussed with Emil, who is a man of action :-) He has registered  
the growl4j.org domain name, and created a java.net project dedicated  
for this library:
https://growl4j.dev.java.net  (http://growl4j.org points to it)

You have the commit rights on this project, so you can add the library  
source files there, as well as the JNI source file. You'll have to  
rename the library into growl4j, path should be org.growl4j.

You'll also have to rename the JNI accordingly (I've seen it is  
located in native/macosx/growl/ at the moment, you should move it to  
growl4j.org too).

The only remaining source file in the SC branch should be the one  
related to the growlnotification bundle.

Could you take care of these changes and update the libraries in your  
Sc branch? Sorry for these changes, but this should not change anymore  
in the future. Having a dedicated project for this library will be  
easier to handle and to advertise. If you have any questions, don't  
hesitate to ask!

Cheers,
romain


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe at sip-communicator.dev.java.net
For additional commands, e-mail: dev-help at sip-communicator.dev.java.net





More information about the dev mailing list