[sip-comm] Several bugs...


#1

I and a couple others at my company have been testing SIP Communicator and other open source SIP clients to see if they fit our particular needs. SIP Communicator is the best client we've tested by far, but there are some rather limiting problems too. I'm hoping someone can offer some help.

1) Plugins: We want to build a plugin to insert a custom button onto the main toolbar, but I couldn't get plugins to work. I went all through the example plugin tutorial and never got the example to work, and I tried my own, bare bones plugin and couldn't get that to work either. For now I gave up and went into the source code for the GUI itself and figured out how to add it there, so I could learn how the SC GUI works. Obviously I wouldn't want to leave my code there, though. Is the tutorial out of date or am I just missing something?

Also, what is the difference between impl.gui.main.menus.QuickMenu and impl.gui.main.menus.ExtendedQuickMenu?

2) SRV records for SIP calls: are they supported? They appear not to be. We can (apparently) register to our SIP server using SRV records, but we can't make a call from SC to a user on another domain unless we use A records. We can call from other clients to SC using SRV without a problem. I noticed you do have a feature request open for SRV, but I'm not sure this is the exact problem:
https://sip-communicator.dev.java.net/issues/show_bug.cgi?id=301

SRV records are used in impl.protocol.sip.ProtocolProviderServiceSipImpl This appears to be the registration process..?

There appears to be support for SRV in impl.protocol.sip.AddressResolverImpl as well but this class is never called from anywhere else, as far as I can tell.

3) Camera support: The webcams (iRez K2r) we are using on our test machines cause the SC splashscreen to hang permanently while loading, at "Contactlist Services Interfaces." If we unplug the camera, SC instantly loads. When we first started playing with SC, the cameras seemed to work fine. We've re-installed, and tried other machines, with no success. We found that a Logitec brand camera would allow SC to load part of the time, but it still takes about 90 seconds. This appears to the a problem that was already mentioned on your mailing list a while ago. I found this in the archives:
http://osdir.com/ml/voip.sip-communicator.user/2007-08/msg00020.html

My current hypothesis, based upon the Felix output (below), is that FMJ is not working for some reason, and it is defaulting to JMF. But I really know nothing about video handling, so I could be way off.

···

------------------------------

[...]

15:14:19.695 FINE: impl.media.MediaActivator.start().53 Started.
15:14:19.710 FINEST: impl.media.device.JmfDeviceDetector.setupJMF().324 [entry] setupJMF
15:14:19.710 FINEST: impl.fileaccess.FileAccessServiceImpl.getPrivatePersistentFile().117 [entry] getPrivatePersistentFile
15:14:19.710 FINEST: impl.fileaccess.FileAccessServiceImpl.accessibleFile().323 [entry] accessibleFile
15:14:19.710 FINEST: impl.fileaccess.FileAccessServiceImpl.accessibleFile().358 [exit] accessibleFile
15:14:19.710 FINEST: impl.fileaccess.FileAccessServiceImpl.getPrivatePersistentFile().130 [exit] getPrivatePersistentFile
IOException in readRegistry: java.io.EOFException
15:14:19.991 INFO: impl.media.device.JmfDeviceDetector.detectCaptureDevices().125 Looking for Audio capturer
15:14:19.991 INFO: impl.media.device.DirectSoundAuto.<init>().55 DirectSound Capture Supported = true
15:14:20.710 INFO: impl.media.device.DirectSoundAuto.<init>().102 DirectSoundAuto: Committed ok
15:14:20.726 INFO: impl.media.device.JavaSoundAuto.<init>().43 JavaSound Capture Supported = true
15:14:20.741 INFO: impl.media.device.JavaSoundAuto.<init>().69 JavaSoundAuto: Committed ok
15:14:20.741 FINE: impl.media.device.JmfDeviceDetector.detectCaptureDevices().154 No FMJ javasound detected: *** Class 'net.sf.fmj.media.cdp.javasound.CaptureDevicePlugger' was not found. Bundle 178 does not import package 'net.sf.fmj.media.cdp.javasound', nor is the package exported by any other bundle or available from the system class loader. ***
15:14:20.741 INFO: impl.media.device.JmfDeviceDetector.detectCaptureDevices().175 Looking for video capture devices
15:14:20.741 FINE: impl.media.device.VFWAuto.autoDetectDevices().61 Found device Microsoft WDM Image Capture (Win32)
15:14:20.741 FINE: impl.media.device.VFWAuto.autoDetectDevices().62 Querying device. Please wait...

[Then it freezes, and I unplug the camera]

15:16:00.336 INFO: impl.media.device.JmfDeviceDetector.detectCaptureDevices().182 Detected 0 VFW video capture device(s).
15:16:00.351 INFO: impl.media.device.JmfDeviceDetector.detectCaptureDevices().197 Detected 0 SUN Video capture device(s).
15:16:00.351 INFO: impl.media.device.JmfDeviceDetector.detectCaptureDevices().212 Detected 0 SUN Video Plus device(s).
15:16:00.351 FINE: impl.media.device.JmfDeviceDetector.detectCaptureDevices().232 No V4l video detected: com/sun/media/protocol/v4l/V4LDeviceQuery
15:16:00.351 FINEST: impl.media.device.JmfDeviceDetector.setupJMF().375 [exit] setupJMF
15:16:00.351 INFO: impl.media.device.DeviceConfiguration.extractConfiguredCaptureDevices().81 Scanning for configured Audio Devices.
15:16:00.367 FINE: impl.media.device.DeviceConfiguration.extractConfiguredCaptureDevices().89 Found 2 capture devices: [DirectSoundCapture : dsound://
LINEAR, 48000.0 Hz, 16-bit, Stereo, LittleEndian, Signed

[...]

LINEAR, 8000.0 Hz, 16-bit, Mono, LittleEndian, Signed
]
15:16:00.367 INFO: impl.media.device.DeviceConfiguration.extractConfiguredCaptureDevices().92 Found DirectSoundCapture as an audio capture device.
15:16:00.367 INFO: impl.media.device.DeviceConfiguration.extractConfiguredCaptureDevices().96 Scanning for configured Video Devices.
15:16:00.367 INFO: impl.media.device.DeviceConfiguration.extractConfiguredCaptureDevices().101 Found vfw:Microsoft WDM Image Capture (Win32):0 as an RGB Video Device.
15:16:00.367 FINE: impl.media.MediaControl.registerCustomPackages().1184 Adding package : net.java.sip.communicator.impl
15:16:00.383 FINE: impl.media.MediaControl.registerCustomPackages().1190 Registering new protocol prefix list : [javax, com.sun, com.ibm, net.java.sip.communicator.impl]
15:16:00.383 INFO: impl.media.MediaControl.createDataSource().693 Creating datasource for:dsound://
15:16:00.414 INFO: impl.media.MediaControl.createDataSource().693 Creating datasource for:vfw://0
java.io.IOException: Could not connect to capture device
15:16:00.461 SEVERE: impl.media.MediaControl.createDataSource().701 Could not create data source for vfw://0
javax.media.NoDataSourceException: Error instantiating class: com.sun.media.protocol.vfw.DataSource : java.io.IOException: Could not connect to capture device
        at javax.media.Manager.createDataSource(Manager.java:1012)
        at net.java.sip.communicator.impl.media.MediaControl.createDataSource(MediaControl.java:697)
        at net.java.sip.communicator.impl.media.MediaControl.initCaptureDevices(MediaControl.java:381)
        at net.java.sip.communicator.impl.media.MediaControl.initialize(MediaControl.java:213)
        at net.java.sip.communicator.impl.media.MediaServiceImpl$DeviceConfigurationThread.run(MediaServiceImpl.java:396)
        at net.java.sip.communicator.impl.media.MediaServiceImpl.start(MediaServiceImpl.java:224)
        at net.java.sip.communicator.impl.media.MediaActivator.start(MediaActivator.java:60)
        at org.apache.felix.framework.util.SecureAction.startActivator(SecureAction.java:589)
        at org.apache.felix.framework.Felix._startBundle(Felix.java:1536)
        at org.apache.felix.framework.Felix.startBundle(Felix.java:1470)
        at org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:1065)
        at org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:258)
        at java.lang.Thread.run(Thread.java:619)
15:16:00.492 FINE: impl.media.MediaControl.registerCustomCodecs().1132 Codec : net.java.sip.communicator.impl.media.codec.audio.alaw.JavaEncoder is succsefully registered : true

[...]

------------------------------

Thanks

Alan Kelly

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


#2

I sent an email about a problem with plugin components and the top toolbar a few days ago. It turns out to be a problem in the QuickMenu class itself.

The reason plugins cannot add toolbar buttons to the impl.gui.main.menus.QuickMenu toolbar is that the constructor never calls the initPluginComponents() method.

ExtendedQuickMenu has the same defect.

Also, the plugin and uiservice documentation on the website is badly out of date. It would be nice to have that updated at some point. It's almost impossible to figure out how to write a plugin from the current docs as addComponent() no longer exists.

Hope this helps. Thanks.

Alan Kelly

···

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


#3

Hey Alan,

Yes indeed, we have changed the way we install plugins recently.
Basically the main difference is that plugins are no longer supposed to
add themselves into the UI. Instead they have to register into the OSGi
bundle context as implementations of one of the services in

net.java.sip.communicator.service.gui

You can look around the code for examples

Also, the plugin and uiservice documentation on the website is badly
out of date. It would be nice to have that updated at some point.

True, sorry about that. Want to give it a try?

Cheers
Emil

···

It's almost impossible to figure out how to write a plugin from the
current docs as addComponent() no longer exists.

Hope this helps. Thanks.

Alan Kelly

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

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


#4

Hi Emil,

Thanks fo the quick response to a newb question.

So if I understand correctly, the current way of handling plugins would be something like this, where My ToolbarrButton() is a class that extends JButton and implements net.java.sip.communicator.service.gui.PluginComponent

···

------

MyToolbarButton btn = new MyToolbarButton(
    MyImage,
    new Dimension(BUTTON_WIDTH, BUTTON_HEIGHT),
    "My text here");

Hashtable<String, String> containerFilter
    = new Hashtable<String, String>();
    
containerFilter.put(Container.CONTAINER_ID,
    Container.CONTAINER_MAIN_TOOL_BAR.getID());

bc.registerService(PluginComponent.class.getName(),btn,
    containerFilter);

------

That is basically how the current code for the example plugin is structured. But even when I do it this way, the component never gets added to net.java.sip.communicator.impl.gui.menus.QuickMenu. Each GUI component has an initPluginComponents() method which searches for registered components, but unlike net.java.sip.communicator.impl.gui.main.contactlist.ContactRightButtonMenu or any of the others, the constructor (or actually the init() method that the constructor calls), QuickMenu never calls its initPluginComponents() method, so the registered plugin items are never actually painted to the screen.

Adding the call to initPluginComponents() ended up being the only change I needed to make to my code to my button appear.

Alan Kelly

----- Original Message -----

From: Emil Ivov <emcho@sip-communicator.org>

Date: Thursday, July 17, 2008 5:56 pm
Subject: Re: [sip-comm] Plugins can't add components to top (QuickMenu) toolbar

Hey Alan,

Yes indeed, we have changed the way we install plugins recently.
Basically the main difference is that plugins are no longer
supposed to
add themselves into the UI. Instead they have to register into the
OSGi bundle context as implementations of one of the services in

net.java.sip.communicator.service.gui

You can look around the code for examples

> Also, the plugin and uiservice documentation on the website is badly
> out of date. It would be nice to have that updated at some point.

True, sorry about that. Want to give it a try?

Cheers
Emil

> It's almost impossible to figure out how to write a plugin from the
> current docs as addComponent() no longer exists.
>
> Hope this helps. Thanks.
>
> Alan Kelly
>
> -----------------------------------------------------------------
----
> To unsubscribe, e-mail:
> users-unsubscribe@sip-communicator.dev.java.net For additional
> commands, e-mail: users-help@sip-communicator.dev.java.net
>
>

-------------------------------------------------------------------
--
To unsubscribe, e-mail: users-unsubscribe@sip-
communicator.dev.java.netFor additional commands, e-mail: users-
help@sip-communicator.dev.java.net

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


#5

Hey Alan,

Must have misread your previous letter, my bad.

The invitation to update the doc still holds though :wink:

Emil

Alan C Kelly написа:

···

Hi Emil,

Thanks fo the quick response to a newb question.

So if I understand correctly, the current way of handling plugins would be something like this, where My ToolbarrButton() is a class that extends JButton and implements net.java.sip.communicator.service.gui.PluginComponent

------

MyToolbarButton btn = new MyToolbarButton(
    MyImage,
    new Dimension(BUTTON_WIDTH, BUTTON_HEIGHT),
    "My text here");

Hashtable<String, String> containerFilter
    = new Hashtable<String, String>();
    
containerFilter.put(Container.CONTAINER_ID,
    Container.CONTAINER_MAIN_TOOL_BAR.getID());

bc.registerService(PluginComponent.class.getName(),btn,
    containerFilter);

------

That is basically how the current code for the example plugin is structured. But even when I do it this way, the component never gets added to net.java.sip.communicator.impl.gui.menus.QuickMenu. Each GUI component has an initPluginComponents() method which searches for registered components, but unlike net.java.sip.communicator.impl.gui.main.contactlist.ContactRightButtonMenu or any of the others, the constructor (or actually the init() method that the constructor calls), QuickMenu never calls its initPluginComponents() method, so the registered plugin items are never actually painted to the screen.

Adding the call to initPluginComponents() ended up being the only change I needed to make to my code to my button appear.

Alan Kelly

----- Original Message -----
From: Emil Ivov <emcho@sip-communicator.org>
Date: Thursday, July 17, 2008 5:56 pm
Subject: Re: [sip-comm] Plugins can't add components to top (QuickMenu) toolbar

Hey Alan,

Yes indeed, we have changed the way we install plugins recently.
Basically the main difference is that plugins are no longer
supposed to
add themselves into the UI. Instead they have to register into the
OSGi bundle context as implementations of one of the services in

net.java.sip.communicator.service.gui

You can look around the code for examples

Also, the plugin and uiservice documentation on the website is badly
out of date. It would be nice to have that updated at some point.

True, sorry about that. Want to give it a try?

Cheers
Emil

It's almost impossible to figure out how to write a plugin from the
current docs as addComponent() no longer exists.

Hope this helps. Thanks.

Alan Kelly

-----------------------------------------------------------------

----

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

-------------------------------------------------------------------
--
To unsubscribe, e-mail: users-unsubscribe@sip-
communicator.dev.java.netFor additional commands, e-mail: users-
help@sip-communicator.dev.java.net

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

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


#6

Hi Emil,

I just looked over the plugin wiki pages again, I'd be willing to try to update them, there isn't that much there.

Alan

···

----- Original Message -----

From: Emil Ivov <emcho@sip-communicator.org>

Date: Friday, July 18, 2008 6:51 pm
Subject: Re: [sip-comm] Plugins can't add components to top (QuickMenu) toolbar

Hey Alan,

Must have misread your previous letter, my bad.

The invitation to update the doc still holds though :wink:

Emil

Alan C Kelly &#1085;&#1072;&#1087;&#1080;&#1089;&#1072;:
> Hi Emil,
>
> Thanks fo the quick response to a newb question.
>
> So if I understand correctly, the current way of handling
plugins would be something like this, where My ToolbarrButton() is
a class that extends JButton and implements
net.java.sip.communicator.service.gui.PluginComponent>
> ------
>
> MyToolbarButton btn = new MyToolbarButton(
> MyImage,
> new Dimension(BUTTON_WIDTH, BUTTON_HEIGHT),
> "My text here");
>
> Hashtable<String, String> containerFilter
> = new Hashtable<String, String>();
>
> containerFilter.put(Container.CONTAINER_ID,
> Container.CONTAINER_MAIN_TOOL_BAR.getID());
>
> bc.registerService(PluginComponent.class.getName(),btn,
> containerFilter);
>
> ------
>
> That is basically how the current code for the example plugin is
structured. But even when I do it this way, the component never
gets added to net.java.sip.communicator.impl.gui.menus.QuickMenu.
Each GUI component has an initPluginComponents() method which
searches for registered components, but unlike
net.java.sip.communicator.impl.gui.main.contactlist.ContactRightButtonMenu or any of the others, the constructor (or actually the init() method that the constructor calls), QuickMenu never calls its initPluginComponents() method, so the registered plugin items are never actually painted to the screen.
>
> Adding the call to initPluginComponents() ended up being the
only change I needed to make to my code to my button appear.
>
> Alan Kelly
>
> ----- Original Message -----
> From: Emil Ivov <emcho@sip-communicator.org>
> Date: Thursday, July 17, 2008 5:56 pm
> Subject: Re: [sip-comm] Plugins can't add components to top
(QuickMenu) toolbar
>
>> Hey Alan,
>>
>> Yes indeed, we have changed the way we install plugins recently.
>> Basically the main difference is that plugins are no longer
>> supposed to
>> add themselves into the UI. Instead they have to register into
the
>> OSGi bundle context as implementations of one of the services in
>>
>> net.java.sip.communicator.service.gui
>>
>> You can look around the code for examples
>>
>>> Also, the plugin and uiservice documentation on the website is
>>> out of date. It would be nice to have that updated at
some point.
>> True, sorry about that. Want to give it a try?
>>
>> Cheers
>> Emil
>>
>>
>>
>>> It's almost impossible to figure out how to write a plugin
from the
>>> current docs as addComponent() no longer exists.
>>>
>>> Hope this helps. Thanks.
>>>
>>> Alan Kelly
>>>
>>> ---------------------------------------------------------------
--
>> ----
>>> To unsubscribe, e-mail:
>>> users-unsubscribe@sip-communicator.dev.java.net For additional
>>> commands, e-mail: users-help@sip-communicator.dev.java.net
>>>
>>>
>> ----------------------------------------------------------------
---
>> --
>> To unsubscribe, e-mail: users-unsubscribe@sip-
>> communicator.dev.java.netFor additional commands, e-mail: users-
>> help@sip-communicator.dev.java.net
>>
>>
>
> -----------------------------------------------------------------
----
> To unsubscribe, e-mail: users-unsubscribe@sip-
communicator.dev.java.net> For additional commands, e-mail: users-
help@sip-communicator.dev.java.net
>
>

-------------------------------------------------------------------
--
To unsubscribe, e-mail: users-unsubscribe@sip-
communicator.dev.java.netFor additional commands, e-mail: users-
help@sip-communicator.dev.java.net

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


#7

Hey Alan

Sorry for the delay, I just got back from vacation and am only now
seeing your mail.

I am very glad to hear you've decided to contribute some docs. I've just
created a user name for you on our wiki:

username:alan
passwd:D0b@v|<1

I have given you write access to all sections.

There used to be some keyboard shortcuts that allowed quick access to
edit mode but they don't work with the recent versions of firefox so
you'd have to tweak the url-s by yourself by adding "?action=edit"
behind the url of the page you'd like to edit.

For the plugin documentation for example this would give you:
http://www.sip-communicator.org/index.php/Documentation/HowToWriteGuiPlugins?action=edit

That's where you get prompted to log in. If you check the persistent
login checkbox you will be logged in automatically from now on and won't
have to touch the url in the future.

Let me know if you have any questions.

Cheers
Emil

Alan C Kelly написа:

···

Hi Emil,

I just looked over the plugin wiki pages again, I'd be willing to try to update them, there isn't that much there.

Alan

----- Original Message -----
From: Emil Ivov <emcho@sip-communicator.org>
Date: Friday, July 18, 2008 6:51 pm
Subject: Re: [sip-comm] Plugins can't add components to top (QuickMenu) toolbar

Hey Alan,

Must have misread your previous letter, my bad.

The invitation to update the doc still holds though :wink:

Emil

Alan C Kelly &#1085;&#1072;&#1087;&#1080;&#1089;&#1072;:

Hi Emil,

Thanks fo the quick response to a newb question.

So if I understand correctly, the current way of handling

plugins would be something like this, where My ToolbarrButton() is
a class that extends JButton and implements
net.java.sip.communicator.service.gui.PluginComponent>

------

MyToolbarButton btn = new MyToolbarButton(
          MyImage,
          new Dimension(BUTTON_WIDTH, BUTTON_HEIGHT),
          "My text here");

Hashtable<String, String> containerFilter
          = new Hashtable<String, String>();
          
containerFilter.put(Container.CONTAINER_ID,
          Container.CONTAINER_MAIN_TOOL_BAR.getID());

bc.registerService(PluginComponent.class.getName(),btn,
          containerFilter);

------

That is basically how the current code for the example plugin is

structured. But even when I do it this way, the component never
gets added to net.java.sip.communicator.impl.gui.menus.QuickMenu.
Each GUI component has an initPluginComponents() method which
searches for registered components, but unlike
net.java.sip.communicator.impl.gui.main.contactlist.ContactRightButtonMenu or any of the others, the constructor (or actually the init() method that the constructor calls), QuickMenu never calls its initPluginComponents() method, so the registered plugin items are never actually painted to the screen.

Adding the call to initPluginComponents() ended up being the

only change I needed to make to my code to my button appear.

Alan Kelly

----- Original Message -----
From: Emil Ivov <emcho@sip-communicator.org>
Date: Thursday, July 17, 2008 5:56 pm
Subject: Re: [sip-comm] Plugins can't add components to top

(QuickMenu) toolbar

Hey Alan,

Yes indeed, we have changed the way we install plugins recently.
Basically the main difference is that plugins are no longer
supposed to
add themselves into the UI. Instead they have to register into

the

OSGi bundle context as implementations of one of the services in

net.java.sip.communicator.service.gui

You can look around the code for examples

Also, the plugin and uiservice documentation on the website is

>>> out of date. It would be nice to have that updated at
some point.

True, sorry about that. Want to give it a try?

Cheers
Emil

It's almost impossible to figure out how to write a plugin

from the

current docs as addComponent() no longer exists.

Hope this helps. Thanks.

Alan Kelly

---------------------------------------------------------------

--

----

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

----------------------------------------------------------------

---

--
To unsubscribe, e-mail: users-unsubscribe@sip-
communicator.dev.java.netFor additional commands, e-mail: users-
help@sip-communicator.dev.java.net

-----------------------------------------------------------------

----

To unsubscribe, e-mail: users-unsubscribe@sip-

communicator.dev.java.net> For additional commands, e-mail: users-
help@sip-communicator.dev.java.net

-------------------------------------------------------------------
--
To unsubscribe, e-mail: users-unsubscribe@sip-
communicator.dev.java.netFor additional commands, e-mail: users-
help@sip-communicator.dev.java.net

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

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


#8

Ooops wrong address sorry. I am changing your account properties and
sending you the new details by mail.

Emil

Emil Ivov написа:

···

Hey Alan

Sorry for the delay, I just got back from vacation and am only now
seeing your mail.

I am very glad to hear you've decided to contribute some docs. I've just
created a user name for you on our wiki:

username:alan
passwd:D0b@v|<1

I have given you write access to all sections.

There used to be some keyboard shortcuts that allowed quick access to
edit mode but they don't work with the recent versions of firefox so
you'd have to tweak the url-s by yourself by adding "?action=edit"
behind the url of the page you'd like to edit.

For the plugin documentation for example this would give you:
http://www.sip-communicator.org/index.php/Documentation/HowToWriteGuiPlugins?action=edit

That's where you get prompted to log in. If you check the persistent
login checkbox you will be logged in automatically from now on and won't
have to touch the url in the future.

Let me know if you have any questions.

Cheers
Emil

Alan C Kelly написа:

Hi Emil,

I just looked over the plugin wiki pages again, I'd be willing to try to update them, there isn't that much there.

Alan

----- Original Message -----
From: Emil Ivov <emcho@sip-communicator.org>
Date: Friday, July 18, 2008 6:51 pm
Subject: Re: [sip-comm] Plugins can't add components to top (QuickMenu) toolbar

Hey Alan,

Must have misread your previous letter, my bad.

The invitation to update the doc still holds though :wink:

Emil

Alan C Kelly &#1085;&#1072;&#1087;&#1080;&#1089;&#1072;:

Hi Emil,

Thanks fo the quick response to a newb question.

So if I understand correctly, the current way of handling

plugins would be something like this, where My ToolbarrButton() is
a class that extends JButton and implements
net.java.sip.communicator.service.gui.PluginComponent>

------

MyToolbarButton btn = new MyToolbarButton(
          MyImage,
          new Dimension(BUTTON_WIDTH, BUTTON_HEIGHT),
          "My text here");

Hashtable<String, String> containerFilter
          = new Hashtable<String, String>();
          
containerFilter.put(Container.CONTAINER_ID,
          Container.CONTAINER_MAIN_TOOL_BAR.getID());

bc.registerService(PluginComponent.class.getName(),btn,
          containerFilter);

------

That is basically how the current code for the example plugin is

structured. But even when I do it this way, the component never
gets added to net.java.sip.communicator.impl.gui.menus.QuickMenu.
Each GUI component has an initPluginComponents() method which
searches for registered components, but unlike
net.java.sip.communicator.impl.gui.main.contactlist.ContactRightButtonMenu or any of the others, the constructor (or actually the init() method that the constructor calls), QuickMenu never calls its initPluginComponents() method, so the registered plugin items are never actually painted to the screen.

Adding the call to initPluginComponents() ended up being the

only change I needed to make to my code to my button appear.

Alan Kelly

----- Original Message -----
From: Emil Ivov <emcho@sip-communicator.org>
Date: Thursday, July 17, 2008 5:56 pm
Subject: Re: [sip-comm] Plugins can't add components to top

(QuickMenu) toolbar

Hey Alan,

Yes indeed, we have changed the way we install plugins recently.
Basically the main difference is that plugins are no longer
supposed to
add themselves into the UI. Instead they have to register into

the

OSGi bundle context as implementations of one of the services in

net.java.sip.communicator.service.gui

You can look around the code for examples

Also, the plugin and uiservice documentation on the website is

>>> out of date. It would be nice to have that updated at
some point.

True, sorry about that. Want to give it a try?

Cheers
Emil

It's almost impossible to figure out how to write a plugin

from the

current docs as addComponent() no longer exists.

Hope this helps. Thanks.

Alan Kelly

---------------------------------------------------------------

--

----

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

----------------------------------------------------------------

---

--
To unsubscribe, e-mail: users-unsubscribe@sip-
communicator.dev.java.netFor additional commands, e-mail: users-
help@sip-communicator.dev.java.net

-----------------------------------------------------------------

----

To unsubscribe, e-mail: users-unsubscribe@sip-

communicator.dev.java.net> For additional commands, e-mail: users-
help@sip-communicator.dev.java.net
-------------------------------------------------------------------
--
To unsubscribe, e-mail: users-unsubscribe@sip-
communicator.dev.java.netFor additional commands, e-mail: users-
help@sip-communicator.dev.java.net

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

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

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