[sip-comm-dev] Re: svn commit: r5226 - trunk/src/net/java/sip/communicator/impl/gui: customcontrols/events customcontrols/wizard event lookandfeel main main/account m...


#1

Hi Werner,

Is the warning-silencing serialVersionUID only being added to classes which really support serialization? For example, classes which have fields of type Call or Hashtable with values of type CallParticipant cannot be automatically serialized because (the implementations of) Call and CallParticipant do not implement Serializable. I think I saw such cases in your commit and I consider the additions of serialVersionUID in them to just hide the truth that these classes indeed have issues with serialization. Not that I expect to serialize Swing components but if the warnings do warn...

Best regards,
Lubo

···

On Apr 4, 2009, at 8:32 PM, wernerd@dev.java.net wrote:

Author: wernerd
Date: 2009-04-04 17:32:03+0000
New Revision: 5226

Modified:
  trunk/src/net/java/sip/communicator/impl/gui/customcontrols/events/CloseTabbedPaneEvent.java
  trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/Wizard.java
  trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/WizardEvent.java
  trunk/src/net/java/sip/communicator/impl/gui/event/PluginComponentEvent.java
  trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommComboBoxEditor.java
  trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommDefaultTheme.java
  trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommSplitPaneDivider.java
  trunk/src/net/java/sip/communicator/impl/gui/main/MainFrame.java
  trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegSummaryPage.java
  trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegWizardContainerImpl.java
  trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountsConfigurationPanel.java
  trunk/src/net/java/sip/communicator/impl/gui/main/account/EmptyAccountRegistrationWizardPage.java
  trunk/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java
  trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationRequestedDialog.java
  trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationResponseDialog.java
  trunk/src/net/java/sip/communicator/impl/gui/main/authorization/RequestAuthorizationDialog.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/AccountSelectorBox.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/CallComboBox.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/CallDialog.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/CallPanel.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/CallParticipantPanel.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/DialPanel.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/DialpadDialog.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/GuiCallRecord.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/HoldButton.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/LocalVideoButton.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/MainCallPanel.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/MuteButton.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/ReceivedCallDialog.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityPanel.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityStatusLabel.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallButton.java
  trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallDialog.java
  trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatContactRightButtonMenu.java
  trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatConversationPanel.java
  trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java

Log:
Remove warning, mostly serialVersionUID stuff. This is part of the effort to resolve issue #637

Modified: trunk/src/net/java/sip/communicator/impl/gui/customcontrols/events/CloseTabbedPaneEvent.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/customcontrols/events/CloseTabbedPaneEvent.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/customcontrols/events/CloseTabbedPaneEvent.java&p2=trunk/src/net/java/sip/communicator/impl/gui/customcontrols/events/CloseTabbedPaneEvent.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/customcontrols/events/CloseTabbedPaneEvent.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/customcontrols/events/CloseTabbedPaneEvent.java 2009-04-04 17:32:03+0000
@@ -19,6 +19,8 @@
* @author Yana Stamcheva
*/
public class CloseTabbedPaneEvent extends Event {
+ private static final long serialVersionUID = 1L;
+
    private final String description;

    private final MouseEvent e;

Modified: trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/Wizard.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/Wizard.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/Wizard.java&p2=trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/Wizard.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/Wizard.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/Wizard.java 2009-04-04 17:32:03+0000
@@ -34,6 +34,8 @@
                PropertyChangeListener
{

+ private static final long serialVersionUID = 1L;
+
    /**
     * Indicates that the 'Finish' button was pressed to close the dialog.
     */

Modified: trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/WizardEvent.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/WizardEvent.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/WizardEvent.java&p2=trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/WizardEvent.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/WizardEvent.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/customcontrols/wizard/WizardEvent.java 2009-04-04 17:32:03+0000
@@ -11,6 +11,8 @@
public class WizardEvent
    extends EventObject
{
+ private static final long serialVersionUID = 1L;
+
    private final int eventCode;

    /**

Modified: trunk/src/net/java/sip/communicator/impl/gui/event/PluginComponentEvent.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/event/PluginComponentEvent.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/event/PluginComponentEvent.java&p2=trunk/src/net/java/sip/communicator/impl/gui/event/PluginComponentEvent.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/event/PluginComponentEvent.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/event/PluginComponentEvent.java 2009-04-04 17:32:03+0000
@@ -17,6 +17,8 @@
public class PluginComponentEvent
    extends EventObject
{
+ private static final long serialVersionUID = 1L;
+
    private final int eventID;

    /**

Modified: trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommComboBoxEditor.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommComboBoxEditor.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommComboBoxEditor.java&p2=trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommComboBoxEditor.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommComboBoxEditor.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommComboBoxEditor.java 2009-04-04 17:32:03+0000
@@ -41,6 +41,8 @@
    private static class EditorBorder
        extends AbstractBorder
    {
+ private static final long serialVersionUID = 1L;
+
        public void paintBorder(Component c, Graphics g, int x, int y, int w,
                int h) {
            g = g.create();

Modified: trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommDefaultTheme.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommDefaultTheme.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommDefaultTheme.java&p2=trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommDefaultTheme.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommDefaultTheme.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommDefaultTheme.java 2009-04-04 17:32:03+0000
@@ -333,12 +333,12 @@

    public void addCustomEntriesToTable(UIDefaults table)
    {
- List buttonGradient
+ List<Object> buttonGradient
            = Arrays.asList(new Object[]
               { new Float(.3f), new Float(0f), BUTTON_GRADIENT_DARK_COLOR,
                getWhite(), BUTTON_GRADIENT_LIGHT_COLOR });

- List sliderGradient
+ List<Object> sliderGradient
            = Arrays.asList(new Object[]
               { new Float(.3f), new Float(.2f), SLIDER_GRADIENT_DARK_COLOR,
                getWhite(), SLIDER_GRADIENT_LIGHT_COLOR });

Modified: trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommSplitPaneDivider.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommSplitPaneDivider.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommSplitPaneDivider.java&p2=trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommSplitPaneDivider.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommSplitPaneDivider.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/lookandfeel/SIPCommSplitPaneDivider.java 2009-04-04 17:32:03+0000
@@ -23,6 +23,8 @@
*/
class SIPCommSplitPaneDivider extends BasicSplitPaneDivider {

+ private static final long serialVersionUID = 1L;
+
    private final BufferedImage horizontalDivider
        = ImageLoader.getImage(ImageLoader.SPLITPANE_HORIZONTAL);
    private final BufferedImage verticalDivider
@@ -60,6 +62,8 @@
    */
    protected JButton createLeftOneTouchButton() {
        JButton b = new JButton() {
+ private static final long serialVersionUID = 1L;
+
        // Sprite buffer for the arrow image of the left button
        int[][] buffer = {{0, 0, 0, 2, 2, 0, 0, 0, 0},
                      {0, 0, 2, 1, 1, 1, 0, 0, 0},
@@ -152,6 +156,7 @@
    */
    protected JButton createRightOneTouchButton() {
    JButton b = new JButton() {
+ private static final long serialVersionUID = 1L;
    // Sprite buffer for the arrow image of the right button
    int[][] buffer = {{2, 2, 2, 2, 2, 2, 2, 2},
                  {0, 1, 1, 1, 1, 1, 1, 3},
@@ -306,11 +311,11 @@
    */

    int getOneTouchSizeFromSuper() {
- return super.ONE_TOUCH_SIZE;
+ return BasicSplitPaneDivider.ONE_TOUCH_SIZE;
    }

    int getOneTouchOffsetFromSuper() {
- return super.ONE_TOUCH_OFFSET;
+ return BasicSplitPaneDivider.ONE_TOUCH_OFFSET;
    }

    int getOrientationFromSuper() {

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/MainFrame.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/MainFrame.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/MainFrame.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/MainFrame.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/MainFrame.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/MainFrame.java 2009-04-04 17:32:03+0000
@@ -54,6 +54,8 @@
    implements ExportedWindow,
                PluginComponentListener
{
+ private static final long serialVersionUID = 1L;
+
    private final Logger logger = Logger.getLogger(MainFrame.class);

    private final TransparentPanel mainPanel
@@ -1379,6 +1381,9 @@
     */
    public void setParams(Object[] windowParams) {}

+ /**
+ * @param event Not used in this method
+ */
    protected void windowClosed(WindowEvent event)
    {
        if(GuiActivator.getUIService().getExitOnMainWindowClose())
@@ -1401,6 +1406,9 @@
        }
    }

+ /**
+ * @param event Not used in this method
+ */
    protected void windowClosing(WindowEvent event)
    {
        if (!GuiActivator.getUIService().getExitOnMainWindowClose())

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegSummaryPage.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegSummaryPage.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegSummaryPage.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegSummaryPage.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegSummaryPage.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegSummaryPage.java 2009-04-04 17:32:03+0000
@@ -28,6 +28,8 @@
    extends SCScrollPane
    implements WizardPage
{
+ private static final long serialVersionUID = 1L;
+
    private final Logger logger = Logger.getLogger(AccountRegSummaryPage.class);

    private final JPanel keysPanel

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegWizardContainerImpl.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegWizardContainerImpl.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegWizardContainerImpl.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegWizardContainerImpl.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegWizardContainerImpl.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountRegWizardContainerImpl.java 2009-04-04 17:32:03+0000
@@ -31,6 +31,8 @@
    implements WizardContainer,
                ServiceListener
{
+ private static final long serialVersionUID = 1L;
+
    private static final Logger logger =
        Logger.getLogger(AccountRegWizardContainerImpl.class);

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountsConfigurationPanel.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountsConfigurationPanel.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountsConfigurationPanel.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountsConfigurationPanel.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountsConfigurationPanel.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/account/AccountsConfigurationPanel.java 2009-04-04 17:32:03+0000
@@ -32,6 +32,8 @@
                ServiceListener,
                ProviderPresenceStatusListener
{
+ private static final long serialVersionUID = 1L;
+
    private final JPanel accountsPanel = new TransparentPanel();

    private final JButton newButton =
@@ -186,7 +188,7 @@
        }
        else if (event.getType() == ServiceEvent.UNREGISTERING)
        {
- this.accountsPanel.remove((JPanel) accounts.get(pps));
+ this.accountsPanel.remove(accounts.get(pps));
            this.accountsPanel.revalidate();
            this.accountsPanel.repaint();
        }
@@ -210,6 +212,8 @@
        extends TransparentPanel
        implements ActionListener
    {
+ private static final long serialVersionUID = 1L;
+
        private JLabel protocolLabel = new JLabel();

        private JLabel accountLabel = new JLabel();

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/account/EmptyAccountRegistrationWizardPage.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/account/EmptyAccountRegistrationWizardPage.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/account/EmptyAccountRegistrationWizardPage.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/account/EmptyAccountRegistrationWizardPage.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/account/EmptyAccountRegistrationWizardPage.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/account/EmptyAccountRegistrationWizardPage.java 2009-04-04 17:32:03+0000
@@ -148,6 +148,7 @@
    /**
     * Empty interface method implementation, unused in the case of the
     * {@link EmptyAccountRegistrationWizardPage}
+ * @param e Not used in this method
     */
    public void changedUpdate(DocumentEvent e)
    {

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java 2009-04-04 17:32:03+0000
@@ -25,6 +25,8 @@
    extends SIPCommDialog
    implements ActionListener
{
+ private static final long serialVersionUID = 1L;
+
    private final Logger logger = Logger.getLogger(NewAccountDialog.class);

    private TransparentPanel mainPanel

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationRequestedDialog.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationRequestedDialog.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationRequestedDialog.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationRequestedDialog.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationRequestedDialog.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationRequestedDialog.java 2009-04-04 17:32:03+0000
@@ -26,6 +26,8 @@
    extends SIPCommDialog
    implements ActionListener {

+ private static final long serialVersionUID = 1L;
+
    public static final int ACCEPT_CODE = 0;

    public static final int REJECT_CODE = 1;

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationResponseDialog.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationResponseDialog.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationResponseDialog.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationResponseDialog.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationResponseDialog.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/authorization/AuthorizationResponseDialog.java 2009-04-04 17:32:03+0000
@@ -22,6 +22,8 @@
public class AuthorizationResponseDialog extends SIPCommDialog
    implements ActionListener {

+ private static final long serialVersionUID = 1L;
+
    private JTextArea infoTextArea = new JTextArea();

    private JTextArea responseArea = new JTextArea();

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/authorization/RequestAuthorizationDialog.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/authorization/RequestAuthorizationDialog.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/authorization/RequestAuthorizationDialog.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/authorization/RequestAuthorizationDialog.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/authorization/RequestAuthorizationDialog.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/authorization/RequestAuthorizationDialog.java 2009-04-04 17:32:03+0000
@@ -28,6 +28,8 @@
    extends SIPCommDialog
    implements ActionListener
{
+ private static final long serialVersionUID = 1L;
+
    public static final int OK_RETURN_CODE = 1;

    public static final int CANCEL_RETURN_CODE = 0;

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/AccountSelectorBox.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/AccountSelectorBox.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/AccountSelectorBox.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/AccountSelectorBox.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/AccountSelectorBox.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/AccountSelectorBox.java 2009-04-04 17:32:03+0000
@@ -33,6 +33,8 @@
    extends SIPCommMenuBar
    implements ActionListener
{
+ private static final long serialVersionUID = 1L;
+
    private static final Logger logger =
        Logger.getLogger(AccountSelectorBox.class);

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/CallComboBox.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/CallComboBox.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/CallComboBox.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/CallComboBox.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/CallComboBox.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/CallComboBox.java 2009-04-04 17:32:03+0000
@@ -31,6 +31,8 @@
                DocumentListener,
                FocusListener
{
+ private static final long serialVersionUID = 1L;
+
    public final static int MAX_HISTORY_SIZE = 30;

    private final MainCallPanel parentCallPanel;
@@ -155,6 +157,8 @@
    private class CreateCallAction
        extends AbstractAction
    {
+ private static final long serialVersionUID = -6697604161662302091L;
+
        public void actionPerformed(ActionEvent e)
        {
            String item = getEditor().getItem().toString();

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/CallDialog.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/CallDialog.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/CallDialog.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/CallDialog.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/CallDialog.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/CallDialog.java 2009-04-04 17:32:03+0000
@@ -29,6 +29,8 @@
    implements ActionListener,
               MouseListener
{
+ private static final long serialVersionUID = 1L;
+
    private static final String DIAL_BUTTON = "DIAL_BUTTON";

    private static final String HANGUP_BUTTON = "HANGUP_BUTTON";

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/CallPanel.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/CallPanel.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/CallPanel.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/CallPanel.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/CallPanel.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/CallPanel.java 2009-04-04 17:32:03+0000
@@ -35,6 +35,8 @@
                PropertyChangeListener,
                CallParticipantSecurityListener
{
+ private static final long serialVersionUID = 1L;
+
    private final TransparentPanel mainPanel = new TransparentPanel();

    private final Hashtable<CallParticipant, CallParticipantPanel>

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/CallParticipantPanel.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/CallParticipantPanel.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/CallParticipantPanel.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/CallParticipantPanel.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/CallParticipantPanel.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/CallParticipantPanel.java 2009-04-04 17:32:03+0000
@@ -31,6 +31,8 @@
public class CallParticipantPanel
    extends TransparentPanel
{
+ private static final long serialVersionUID = 1L;
+
    private static final Logger logger =
        Logger.getLogger(CallParticipantPanel.class);

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/DialPanel.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/DialPanel.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/DialPanel.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/DialPanel.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/DialPanel.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/DialPanel.java 2009-04-04 17:32:03+0000
@@ -32,6 +32,8 @@
    extends JPanel
    implements MouseListener
{
+ private static final long serialVersionUID = 1L;
+
    private final Logger logger = Logger.getLogger(DialPanel.class);

    /**

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/DialpadDialog.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/DialpadDialog.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/DialpadDialog.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/DialpadDialog.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/DialpadDialog.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/DialpadDialog.java 2009-04-04 17:32:03+0000
@@ -24,6 +24,7 @@
    extends JDialog
    implements WindowFocusListener
{
+ private static final long serialVersionUID = 1L;
    private DialPanel dialPanel;

    /**
@@ -83,6 +84,8 @@
     */
    private static class BackgroundPanel extends JPanel
    {
+ private static final long serialVersionUID = 1L;
+
        public void paintComponent(Graphics g)
        {
            super.paintComponent(g);

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/GuiCallRecord.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/GuiCallRecord.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/GuiCallRecord.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/GuiCallRecord.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/GuiCallRecord.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/GuiCallRecord.java 2009-04-04 17:32:03+0000
@@ -19,7 +19,7 @@
*/
public class GuiCallRecord
{
- private Vector participants;
+ private Vector<GuiCallParticipantRecord> participants;

    private Date startTime;

@@ -32,7 +32,7 @@
     * @param startTime call start time
     * @param endTime call end time
     */
- public GuiCallRecord(Vector guiParticipantRecords,
+ public GuiCallRecord(Vector<GuiCallParticipantRecord> guiParticipantRecords,
            Date startTime,
            Date endTime)
    {
@@ -55,13 +55,13 @@

        this.endTime = callRecord.getEndTime();

- this.participants = new Vector();
+ this.participants = new Vector<GuiCallParticipantRecord>();

- Iterator records = callRecord.getParticipantRecords().iterator();
+ Iterator<CallParticipantRecord> records = callRecord.getParticipantRecords().iterator();

        while(records.hasNext()) {
            CallParticipantRecord record
- = (CallParticipantRecord)records.next();
+ = records.next();

            GuiCallParticipantRecord newRecord
                = new GuiCallParticipantRecord(
@@ -76,7 +76,7 @@
        return endTime;
    }

- public Iterator getParticipants()
+ public Iterator<GuiCallParticipantRecord> getParticipants()
    {
        return participants.iterator();
    }

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/HoldButton.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/HoldButton.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/HoldButton.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/HoldButton.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/HoldButton.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/HoldButton.java 2009-04-04 17:32:03+0000
@@ -92,6 +92,7 @@
        implements ActionListener
    {

+ private static final long serialVersionUID = 1L;
        /**
         * The <tt>CallParticipant</tt> whose state is being adapted for the
         * purposes of depicting as a toggle button.

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/LocalVideoButton.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/LocalVideoButton.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/LocalVideoButton.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/LocalVideoButton.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/LocalVideoButton.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/LocalVideoButton.java 2009-04-04 17:32:03+0000
@@ -44,6 +44,8 @@
        implements ActionListener,
                   Runnable
    {
+ private static final long serialVersionUID = 1L;
+
        private final Call call;

        private Thread runner;

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/MainCallPanel.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/MainCallPanel.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/MainCallPanel.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/MainCallPanel.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/MainCallPanel.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/MainCallPanel.java 2009-04-04 17:32:03+0000
@@ -41,6 +41,8 @@
                PluginComponentListener,
                MouseListener
{
+ private static final long serialVersionUID = 1L;
+
    private final Logger logger = Logger.getLogger(MainCallPanel.class);

    private static final String CALL_BUTTON = "CALL_BUTTON";

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/MuteButton.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/MuteButton.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/MuteButton.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/MuteButton.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/MuteButton.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/MuteButton.java 2009-04-04 17:32:03+0000
@@ -88,6 +88,7 @@
        implements ActionListener
    {

+ private static final long serialVersionUID = 1L;
        /**
         * The <tt>CallParticipant</tt> whose state is being adapted for the
         * purposes of depicting as a toggle button.

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/ReceivedCallDialog.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/ReceivedCallDialog.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/ReceivedCallDialog.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/ReceivedCallDialog.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/ReceivedCallDialog.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/ReceivedCallDialog.java 2009-04-04 17:32:03+0000
@@ -30,6 +30,8 @@
    implements ActionListener,
                CallListener
{
+ private static final long serialVersionUID = 1L;
+
    private static final String CALL_BUTTON = "CallButton";

    private static final String HANGUP_BUTTON = "HangupButton";

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityPanel.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityPanel.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityPanel.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityPanel.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityPanel.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityPanel.java 2009-04-04 17:32:03+0000
@@ -19,6 +19,8 @@
public class SecurityPanel
    extends TransparentPanel
{
+ private static final long serialVersionUID = 1L;
+
    private final CallParticipant participant;

    private final Image iconEncr;

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityStatusLabel.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityStatusLabel.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityStatusLabel.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityStatusLabel.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityStatusLabel.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/SecurityStatusLabel.java 2009-04-04 17:32:03+0000
@@ -16,6 +16,8 @@
public class SecurityStatusLabel
    extends JLabel
{
+ private static final long serialVersionUID = 1L;
+
    private final CallParticipantPanel callParticipantPanel;

    public SecurityStatusLabel( CallParticipantPanel callParticipantPanel,

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallButton.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallButton.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallButton.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallButton.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallButton.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallButton.java 2009-04-04 17:32:03+0000
@@ -28,6 +28,8 @@
public class TransferCallButton
    extends SIPCommButton
{
+ private static final long serialVersionUID = 1L;
+
    private static final Logger logger =
        Logger.getLogger(TransferCallButton.class);

@@ -170,12 +172,13 @@
     * @param address the address to locate the associated
     * <code>CallParticipant</code> of
     */
+
    private CallParticipant findCallParticipant(
        OperationSetBasicTelephony telephony, String address)
    {
- for (Iterator callIter = telephony.getActiveCalls(); callIter.hasNext():wink:
+ for (Iterator<Call> callIter = telephony.getActiveCalls(); callIter.hasNext():wink:
        {
- Call call = (Call) callIter.next();
+ Call call = callIter.next();

            for (Iterator<CallParticipant> participantIter =
                call.getCallParticipants(); participantIter.hasNext():wink:

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallDialog.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallDialog.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallDialog.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallDialog.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallDialog.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/call/TransferCallDialog.java 2009-04-04 17:32:03+0000
@@ -26,6 +26,8 @@
public class TransferCallDialog
    extends SIPCommDialog
{
+ private static final long serialVersionUID = 1L;
+
    private final JButton cancelButton;

    private final JButton okButton;

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatContactRightButtonMenu.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatContactRightButtonMenu.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatContactRightButtonMenu.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatContactRightButtonMenu.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatContactRightButtonMenu.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatContactRightButtonMenu.java 2009-04-04 17:32:03+0000
@@ -30,6 +30,8 @@
    extends JPopupMenu
    implements ActionListener
{
+ private static final long serialVersionUID = 1L;
+
    private Logger logger = Logger.getLogger(ChatContactRightButtonMenu.class);

    private JMenuItem kickItem = new JMenuItem(
@@ -103,6 +105,8 @@

    private class ReasonDialog extends SIPCommDialog
    {
+ private static final long serialVersionUID = 1L;
+
        private JLabel iconLabel = new JLabel(new ImageIcon(
            ImageLoader.getImage(ImageLoader.REASON_DIALOG_ICON)));

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatConversationPanel.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatConversationPanel.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatConversationPanel.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatConversationPanel.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatConversationPanel.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatConversationPanel.java 2009-04-04 17:32:03+0000
@@ -40,6 +40,8 @@
                MouseListener,
                ClipboardOwner
{
+ private static final long serialVersionUID = 1L;
+
    private static final Logger logger =
        Logger.getLogger(ChatConversationPanel.class);

@@ -602,10 +604,9 @@
        // new lines, but only the smilies.
        if (contentType == null || !contentType.equals(HTML_CONTENT_TYPE))
        {
- String linkProcessedString = processLinks(message, contentType);
+ String linkProcessedString = processLinks(message);

- processedString = processNewLines(linkProcessedString,
- contentType);
+ processedString = processNewLines(linkProcessedString);
        }
        // If the message content is HTML, we process br and img tags.
        else if(contentType.equals(HTML_CONTENT_TYPE))
@@ -625,7 +626,7 @@
     * @param message The source message string.
     * @return The message string with properly formatted links.
     */
- private String processLinks(String message, String contentType)
+ private String processLinks(String message)
    {
        String startPlainTextTag = "<PLAINTEXT>";
        String endPlainTextTag = "</PLAINTEXT>";
@@ -674,7 +675,7 @@
     * @param message The source message string.
     * @return The message string with properly formatted new lines.
     */
- private String processNewLines(String message, String contentType)
+ private String processNewLines(String message)
    {
        String startPlainTextTag = "<PLAINTEXT>";
        String endPlainTextTag = "</PLAINTEXT>";

Modified: trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java
Url: https://sip-communicator.dev.java.net/source/browse/sip-communicator/trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java?view=diff&rev=5226&p1=trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java&p2=trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java&r1=5225&r2=5226

--- trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java (original)
+++ trunk/src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java 2009-04-04 17:32:03+0000
@@ -46,6 +46,8 @@
                Chat,
                ChatConversationContainer
{
+ private static final long serialVersionUID = 1L;
+
    private static final Logger logger = Logger.getLogger(ChatPanel.class);

    private final JSplitPane messagePane = new JSplitPane(JSplitPane.VERTICAL_SPLIT);

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

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


#2

Lubo,

Lubomir Marinov schrieb:

Hi Werner,

Is the warning-silencing serialVersionUID only being added to classes
which really support serialization? For example, classes which have
fields of type Call or Hashtable with values of type CallParticipant
cannot be automatically serialized because (the implementations of) Call
and CallParticipant do not implement Serializable. I think I saw such
cases in your commit and I consider the additions of serialVersionUID in
them to just hide the truth that these classes indeed have issues with
serialization. Not that I expect to serialize Swing components but if
the warnings do warn...

hmmmm - how to bring them to "slience" then? I see several options:

- switch off the warning - if we never serialize the objects then
  don't worry about this and Emil can switch off the warning flag
  in build.xml :slight_smile: . However, if you serialize an object that
  does not contaion the serialVersionUID then the Java runtime computes
  one
- add the default serialVersionUID 1L - this shows that no "real serialization"
  is expected for this class
- add the supress warning tag

Any other ideas?

Regards,
Werner

···

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