use of org.jivesoftware.phone.client.event.PhoneEventPacketExtensionProvider in project Spark by igniterealtime.
the class PhonePlugin method initialize.
public void initialize() {
ProviderManager.addExtensionProvider("phone-event", "http://jivesoftware.com/xmlns/phone", new PhoneEventPacketExtensionProvider());
ProviderManager.addIQProvider("phone-action", "http://jivesoftware.com/xmlns/phone", new PhoneActionIQProvider());
final XMPPConnection con = SparkManager.getConnection();
SwingWorker worker = new SwingWorker() {
public Object construct() {
try {
phoneClient = new PhoneClient(con);
// Add BaseListener
phoneClient.addEventListener(new PhoneListener());
} catch (Exception e) {
// Ignore because the user does not have support.
// Log.debug(e);
}
return phoneClient;
}
public void finished() {
if (phoneClient != null) {
setupPhoneSystem();
}
}
};
worker.start();
}
Aggregations