mirror of
https://github.com/igniterealtime/Spark.git
synced 2025-12-01 12:27:58 +00:00
SPARK-1160 removed some deprecations
git-svn-id: http://svn.igniterealtime.org/svn/repos/spark/trunk@12269 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
committed by
wolf.posdorfer
parent
7babeccf36
commit
4233d97b7b
@ -473,21 +473,21 @@ public class LoginSettingDialog implements PropertyChangeListener {
|
|||||||
if(Default.getString("PROXY_PROTOCOL").length()>0)
|
if(Default.getString("PROXY_PROTOCOL").length()>0)
|
||||||
{
|
{
|
||||||
protocolBox.setSelectedItem(Default.getString("PROXY_PROTOCOL"));
|
protocolBox.setSelectedItem(Default.getString("PROXY_PROTOCOL"));
|
||||||
protocolBox.disable();
|
protocolBox.setEnabled(false);
|
||||||
useProxyBox.setSelected(true);
|
useProxyBox.setSelected(true);
|
||||||
useProxyBox.setVisible(false);
|
useProxyBox.setVisible(false);
|
||||||
}
|
}
|
||||||
if(Default.getString("PROXY_HOST").length()>0)
|
if(Default.getString("PROXY_HOST").length()>0)
|
||||||
{
|
{
|
||||||
hostField.setText(Default.getString("PROXY_HOST"));
|
hostField.setText(Default.getString("PROXY_HOST"));
|
||||||
hostField.disable();
|
hostField.setEnabled(false);
|
||||||
useProxyBox.setSelected(true);
|
useProxyBox.setSelected(true);
|
||||||
useProxyBox.setVisible(false);
|
useProxyBox.setVisible(false);
|
||||||
}
|
}
|
||||||
if(Default.getString("PROXY_PORT").length()>0)
|
if(Default.getString("PROXY_PORT").length()>0)
|
||||||
{
|
{
|
||||||
portField.setText(Default.getString("PROXY_PORT"));
|
portField.setText(Default.getString("PROXY_PORT"));
|
||||||
portField.disable();
|
portField.setEnabled(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -90,7 +90,7 @@ public class PluginClassLoader extends URLClassLoader {
|
|||||||
|
|
||||||
for (File jar : jars) {
|
for (File jar : jars) {
|
||||||
if (jar.isFile()) {
|
if (jar.isFile()) {
|
||||||
final URL url = jar.toURL();
|
final URL url = jar.toURI().toURL();
|
||||||
addURL(url);
|
addURL(url);
|
||||||
try {
|
try {
|
||||||
checkForSmackProviders(url);
|
checkForSmackProviders(url);
|
||||||
|
|||||||
@ -22,6 +22,8 @@ package org.jivesoftware.spark.ui;
|
|||||||
import java.awt.event.MouseEvent;
|
import java.awt.event.MouseEvent;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
|
|
||||||
|
import org.jivesoftware.spark.plugin.ContextMenuListener;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The ContactGroupListener interface is one of the interfaces extension writers use to add functionality to Spark.
|
* The ContactGroupListener interface is one of the interfaces extension writers use to add functionality to Spark.
|
||||||
* <p/>
|
* <p/>
|
||||||
@ -63,7 +65,7 @@ public interface ContactGroupListener {
|
|||||||
*
|
*
|
||||||
* @param e the MouseEvent that triggered the event.
|
* @param e the MouseEvent that triggered the event.
|
||||||
* @param item the ContactItem clicked within the ContactGroup.
|
* @param item the ContactItem clicked within the ContactGroup.
|
||||||
* @deprecated see <code>ContextMenuListener</code>
|
* @deprecated see {@link ContextMenuListener}
|
||||||
*/
|
*/
|
||||||
public void showPopup(MouseEvent e, ContactItem item);
|
public void showPopup(MouseEvent e, ContactItem item);
|
||||||
|
|
||||||
|
|||||||
@ -242,5 +242,39 @@ public class LayoutSettingsManager {
|
|||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* converts a Rectangle to a String
|
||||||
|
* @param r
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public static String rectangleToString(Rectangle r) {
|
||||||
|
return r.x + "," + r.y + "," + r.width + "," + r.height;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* converts a String to a Rectangle
|
||||||
|
* @param s
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public static Rectangle stringToRectangle(String s) {
|
||||||
|
|
||||||
|
if(s == null)
|
||||||
|
{
|
||||||
|
return new Rectangle(0,0,0,0);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!s.matches("[0-9]*,[0-9]*,[0-9]*,[0-9]*")) {
|
||||||
|
return new Rectangle(0,0,0,0);
|
||||||
|
} else {
|
||||||
|
String[] arr = s.split(",");
|
||||||
|
|
||||||
|
|
||||||
|
return new Rectangle(Integer.parseInt(arr[0]),
|
||||||
|
Integer.parseInt(arr[1]), Integer.parseInt(arr[2]),
|
||||||
|
Integer.parseInt(arr[3]));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -671,7 +671,7 @@ public class CallProcessing {
|
|||||||
// CSeq
|
// CSeq
|
||||||
CSeqHeader cSeqHeader;
|
CSeqHeader cSeqHeader;
|
||||||
try {
|
try {
|
||||||
cSeqHeader = sipManCallback.headerFactory.createCSeqHeader(1,
|
cSeqHeader = sipManCallback.headerFactory.createCSeqHeader(1L,
|
||||||
Request.INVITE);
|
Request.INVITE);
|
||||||
}
|
}
|
||||||
catch (ParseException ex) {
|
catch (ParseException ex) {
|
||||||
|
|||||||
@ -1005,7 +1005,7 @@ public class SipManager implements SipListener {
|
|||||||
*/
|
*/
|
||||||
public ArrayList<ViaHeader> getLocalViaHeaders() throws CommunicationsException {
|
public ArrayList<ViaHeader> getLocalViaHeaders() throws CommunicationsException {
|
||||||
|
|
||||||
ListeningPoint lp = sipProvider.getListeningPoint();
|
ListeningPoint lp = sipProvider.getListeningPoints()[0];
|
||||||
viaHeaders = new ArrayList<ViaHeader>();
|
viaHeaders = new ArrayList<ViaHeader>();
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
|||||||
@ -70,7 +70,7 @@ public class TransferProcessing {
|
|||||||
Log.error("hold", e);
|
Log.error("hold", e);
|
||||||
}
|
}
|
||||||
|
|
||||||
int cseq = ((CSeq) (refer.getHeader(CSeq.NAME)))
|
long cseq = ((CSeq) (refer.getHeader(CSeq.NAME)))
|
||||||
.getSequenceNumber() + 1;
|
.getSequenceNumber() + 1;
|
||||||
refer.removeHeader(CSeq.NAME);
|
refer.removeHeader(CSeq.NAME);
|
||||||
try {
|
try {
|
||||||
|
|||||||
@ -173,7 +173,7 @@ public class MessageProcessing {
|
|||||||
// CSeq
|
// CSeq
|
||||||
CSeqHeader cSeqHeader;
|
CSeqHeader cSeqHeader;
|
||||||
try {
|
try {
|
||||||
cSeqHeader = sipManCallback.headerFactory.createCSeqHeader(1,
|
cSeqHeader = sipManCallback.headerFactory.createCSeqHeader(1L,
|
||||||
Request.MESSAGE);
|
Request.MESSAGE);
|
||||||
}
|
}
|
||||||
catch (Exception ex) {
|
catch (Exception ex) {
|
||||||
@ -361,7 +361,7 @@ public class MessageProcessing {
|
|||||||
// CSeq
|
// CSeq
|
||||||
CSeqHeader cSeqHeader;
|
CSeqHeader cSeqHeader;
|
||||||
try {
|
try {
|
||||||
cSeqHeader = sipManCallback.headerFactory.createCSeqHeader(1,
|
cSeqHeader = sipManCallback.headerFactory.createCSeqHeader(1L,
|
||||||
Request.MESSAGE);
|
Request.MESSAGE);
|
||||||
}
|
}
|
||||||
catch (Exception ex) {
|
catch (Exception ex) {
|
||||||
|
|||||||
@ -27,6 +27,7 @@ import java.io.FileOutputStream;
|
|||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.io.InputStreamReader;
|
import java.io.InputStreamReader;
|
||||||
import java.io.OutputStreamWriter;
|
import java.io.OutputStreamWriter;
|
||||||
|
import java.text.DateFormat;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
@ -137,8 +138,8 @@ public class LogManagerImpl implements SoftPhoneListener, LogManager {
|
|||||||
e.setValue("numB", numB);
|
e.setValue("numB", numB);
|
||||||
e.setValue("duration", String
|
e.setValue("duration", String
|
||||||
.valueOf(call.getElapsedTime()));
|
.valueOf(call.getElapsedTime()));
|
||||||
e.setValue("datetime", new Date().toGMTString());
|
|
||||||
|
|
||||||
|
e.setValue("datetime",DateFormat.getInstance().format(new Date()));
|
||||||
e.setValue("type", type.name());
|
e.setValue("type", type.name());
|
||||||
|
|
||||||
LogPacket.logEvent(SparkManager.getConnection(), e);
|
LogPacket.logEvent(SparkManager.getConnection(), e);
|
||||||
|
|||||||
@ -161,7 +161,7 @@ public class RoundLabel extends JPanel {
|
|||||||
vFrame.add(label, new GridBagConstraints(0, 1, 1, 1, 1.0, 0.0, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 5, 5, 5), 0, 10));
|
vFrame.add(label, new GridBagConstraints(0, 1, 1, 1, 1.0, 0.0, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 5, 5, 5), 0, 10));
|
||||||
|
|
||||||
vFrame.setTitle("Aqua Button");
|
vFrame.setTitle("Aqua Button");
|
||||||
vFrame.show();
|
vFrame.setVisible(true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user