[sip-comm] Patch for adding some functions


#1

Hello

I created patch for adding some functions to sip-communicator.
The additional function is as follows.

1. Correspondence to IPv6 by J2SE 5.0 for WindowsXP
2. Automatic login, Password preservation
3. Automatic response, Connection continuation time setup
4. Distribution of the 2nd henceforth goes wrong in the case
   of movie file distribution. Correspondence to this fault.

sip-communicator-diff.txt (34.5 KB)

···

========================================
Hideto Sakaguchi
e-mail: saka@kingyo.org
http://free-sip.org


#2

Hi,

I am preparing proxy for the test for SIP-over-IPv6.
The proxy is as follows.

REGIST: http://www.free-sip.org/user/reg/index.php
MANAGEMENT: http://www.free-sip.org/user/index.php
URI for test: sip:robotv6@free-sip.org

Please REGIST and connect by IPv6.

Hideto Sakaguchi wrote:

···

Hello

I created patch for adding some functions to sip-communicator.
The additional function is as follows.

1. Correspondence to IPv6 by J2SE 5.0 for WindowsXP
2. Automatic login, Password preservation
3. Automatic response, Connection continuation time setup
4. Distribution of the 2nd henceforth goes wrong in the case
   of movie file distribution. Correspondence to this fault.

========================================
Hideto Sakaguchi
e-mail: saka@kingyo.org
http://free-sip.org

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

diff -cr sip-communicator.org/build.xml sip-communicator/build.xml
*** sip-communicator.org/build.xml Fri Nov 5 19:06:00 2004
--- sip-communicator/build.xml Sat Nov 27 23:42:54 2004
***************
*** 4,10 ****
       Please specify the location of your Java installation (below).-->
    <!-- CHECK User should modify the following path -->
! <property name="jdk.home" value="/usr/java/java"/>
  <!-- END CHECK -->
  
       Please specify the location of your Java installation (below).-->
    <!-- CHECK User should modify the following path -->
! <property name="jdk.home" value="C:/Java/jdk1.5.0"/>
  <!-- END CHECK -->
  
*** 268,274 ****
          <!-- use classpathref insteaf of bootclasspathref to avoid problems with non SUN VMs
               bug report and fix Zack Angelo - NOSTROMO -->
          <javac classpathref="project.class.path" debug="true"
! deprecation="true" destdir="${dest}" nowarn="false" target="1.2">
              <src path="${src}"/>
          </javac>
      </target>
--- 268,274 ----
          <!-- use classpathref insteaf of bootclasspathref to avoid problems with non SUN VMs
               bug report and fix Zack Angelo - NOSTROMO -->
          <javac classpathref="project.class.path" debug="true"
! deprecation="true" destdir="${dest}" nowarn="false" target="1.5">
              <src path="${src}"/>
          </javac>
      </target>
***************
*** 412,418 ****
          <echo file="${releaselinsc}/sip-communicator.sh" append="false">
              export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:./lib
          </echo>
! <echo file="${releaselinsc}/sip-communicator.sh" message="java " append="true"/>
          <echo file="${releaselinsc}/sip-communicator.sh" message="-classpath sip-communicator.jar:jmf.jar:$CLASSPATH:$JMFHOME " append="true"/>
          <echo file="${releaselinsc}/sip-communicator.sh" message="-Dlog4j.configuration=sip-communicator.properties " append="true"/>
          <echo file="${releaselinsc}/sip-communicator.sh" message="net.java.sip.communicator.SipCommunicator" append="true"/>
--- 412,418 ----
          <echo file="${releaselinsc}/sip-communicator.sh" append="false">
              export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:./lib
          </echo>
! <echo file="${releaselinsc}/sip-communicator.sh" message="/usr/java/j2sdk1.4.2_05/jre/bin/java " append="true"/>
          <echo file="${releaselinsc}/sip-communicator.sh" message="-classpath sip-communicator.jar:jmf.jar:$CLASSPATH:$JMFHOME " append="true"/>
          <echo file="${releaselinsc}/sip-communicator.sh" message="-Dlog4j.configuration=sip-communicator.properties " append="true"/>
          <echo file="${releaselinsc}/sip-communicator.sh" message="net.java.sip.communicator.SipCommunicator" append="true"/>
***************
*** 420,426 ****
          <chmod file="${releaselinsc}/sip-communicator.sh" perm="ugo+rx"/>
            <!-- generate the bat file -->
! <echo file="${releasewinsc}/sip-communicator.bat" message="java " append="false"/>
          <echo file="${releasewinsc}/sip-communicator.bat" message="-classpath sip-communicator.jar;jmf.jar;sound.jar;%CLASSPATH%;%JMFHOME% " append="true"/>
          <echo file="${releasewinsc}/sip-communicator.bat" message="-Dlog4j.configuration=sip-communicator.properties " append="true"/>
          <echo file="${releasewinsc}/sip-communicator.bat" message="-Djava.library.path=./lib " append="true"/>
--- 420,426 ----
          <chmod file="${releaselinsc}/sip-communicator.sh" perm="ugo+rx"/>
            <!-- generate the bat file -->
! <echo file="${releasewinsc}/sip-communicator.bat" message="C:\Java\jre1.5.0\bin\java " append="false"/>
          <echo file="${releasewinsc}/sip-communicator.bat" message="-classpath sip-communicator.jar;jmf.jar;sound.jar;%CLASSPATH%;%JMFHOME% " append="true"/>
          <echo file="${releasewinsc}/sip-communicator.bat" message="-Dlog4j.configuration=sip-communicator.properties " append="true"/>
          <echo file="${releasewinsc}/sip-communicator.bat" message="-Djava.library.path=./lib " append="true"/>
Only in sip-communicator: build.xml.orig
diff -cr sip-communicator.org/sip-communicator.xml sip-communicator/sip-communicator.xml
*** sip-communicator.org/sip-communicator.xml Fri Nov 5 19:06:00 2004
--- sip-communicator/sip-communicator.xml Sat Nov 27 23:42:54 2004
***************
*** 9,16 ****
            <media>
  <!--- <PREFERRED_AUDIO_ENCODING system="false" value=""/> -->
                <PREFERRED_AUDIO_ENCODING value="0"/>
! <PREFERRED_VIDEO_ENCODING value="26"/>
! <MEDIA_SOURCE value=""/>
              <MEDIA_BUFFER_LENGTH value="100"/>
              <IP_ADDRESS value=""/>
              <AUDIO_PORT value=""/>
--- 9,16 ----
            <media>
  <!--- <PREFERRED_AUDIO_ENCODING system="false" value=""/> -->
                <PREFERRED_AUDIO_ENCODING value="0"/>
! <PREFERRED_VIDEO_ENCODING value="34"/>
! <MEDIA_SOURCE value="file:./rail2000-med.mov"/>
              <MEDIA_BUFFER_LENGTH value="100"/>
              <IP_ADDRESS value=""/>
              <AUDIO_PORT value=""/>
***************
*** 19,26 ****
          <sip>
              <PUBLIC_ADDRESS value=""/>
              <TRANSPORT value=""/>
! <REGISTRAR_ADDRESS value="iptel.org"/>
              <USER_NAME value=""/>
              <STACK_PATH value="gov.nist"/>
              <PREFERRED_LOCAL_PORT value=""/>
              <DISPLAY_NAME value=""/>
--- 19,30 ----
          <sip>
              <PUBLIC_ADDRESS value=""/>
              <TRANSPORT value=""/>
! <REGISTRAR_ADDRESS value="v6.free-sip.org"/>
! <SAVE_PASS value="false"/>
              <USER_NAME value=""/>
+ <USER_PASS value=""/>
+ <AUTO_ANS value="true"/>
+ <HANG_DLAY value=""/>
              <STACK_PATH value="gov.nist"/>
              <PREFERRED_LOCAL_PORT value=""/>
              <DISPLAY_NAME value=""/>
***************
*** 29,36 ****
              <REGISTRAR_PORT value="5060"/>
              <FAIL_CALLS_ON_DEST_USER_MISMATCH value="false"/>
  ! <DEFAULT_DOMAIN_NAME value="iptel.org"/>
! <DEFAULT_AUTHENTICATION_REALM value="iptel.org"/>
              <WAIT_UNREGISTGRATION_FOR value="1100"/>
              <SAME_USER_EVERYWHERE value="true"/>
              <simple>
--- 33,40 ----
              <REGISTRAR_PORT value="5060"/>
              <FAIL_CALLS_ON_DEST_USER_MISMATCH value="false"/>
  ! <DEFAULT_DOMAIN_NAME value="free-sip.org"/>
! <DEFAULT_AUTHENTICATION_REALM value="free-sip.org"/>
              <WAIT_UNREGISTGRATION_FOR value="1100"/>
              <SAME_USER_EVERYWHERE value="true"/>
              <simple>
***************
*** 66,72 ****
              <PREFERRED_NETWORK_ADDRESS value=""/>
          </common>
  ! <STUN_SERVER_ADDRESS value="stun01.sipphone.com"/>
          <STUN_SERVER_PORT value="3478"/>
          <VOICE_MAIL_ADDRESS value="17475551212"/>
  </communicator>
--- 70,76 ----
              <PREFERRED_NETWORK_ADDRESS value=""/>
          </common>
  ! <STUN_SERVER_ADDRESS value=""/>
          <STUN_SERVER_PORT value="3478"/>
          <VOICE_MAIL_ADDRESS value="17475551212"/>
  </communicator>
***************
*** 88,94 ****
          <IP_ADDRESS value=""/>
          <STACK_NAME value="sip-communicator"/>
          <ROUTER_PATH value="net.java.sip.communicator.sip.SipCommRouter"/>
! <OUTBOUND_PROXY value="iptel.org:5060/udp"/>
          <RETRANSMISSON_FILTER value=""/>
          <EXTENSION_METHODS value=""/>
          <RETRANSMISSION_FILTER value="true"/>
--- 92,98 ----
          <IP_ADDRESS value=""/>
          <STACK_NAME value="sip-communicator"/>
          <ROUTER_PATH value="net.java.sip.communicator.sip.SipCommRouter"/>
! <OUTBOUND_PROXY value="v6.free-sip.org:5060/udp"/>
          <RETRANSMISSON_FILTER value=""/>
          <EXTENSION_METHODS value=""/>
          <RETRANSMISSION_FILTER value="true"/>
***************
*** 96,103 ****
  </javax>
  <java>
      <net>
! <preferIPv4Stack system="true" value="true"/>
! <preferIPv6Addresses system="true" value="false"/>
      </net>
  </java>
  </configuration>
--- 100,109 ----
  </javax>
  <java>
      <net>
! <preferIPv4Stack system="false" value="false"/>
! <preferIPv4Addresses system="false" value="false"/>
! <preferIPv6Stack system="true" value="true"/>
! <preferIPv6Addresses system="true" value="true"/>
      </net>
  </java>
  </configuration>
Only in sip-communicator: sip-communicator.xml.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/common/PropertiesDepot.java sip-communicator/src/net/java/sip/communicator/common/PropertiesDepot.java
*** sip-communicator.org/src/net/java/sip/communicator/common/PropertiesDepot.java Wed Aug 18 13:31:00 2004
--- sip-communicator/src/net/java/sip/communicator/common/PropertiesDepot.java Sat Nov 27 23:42:54 2004
***************
*** 371,380 ****
        private static void processNewProperties(Document doc)
      {
! Enumeration enum = newProperties.keys();
! while(enum.hasMoreElements())
          {
! String key = (String)enum.nextElement();
              String value = (String)newProperties.get(key);
              processNewProperty(doc, key, value);
          }
--- 371,380 ----
        private static void processNewProperties(Document doc)
      {
! Enumeration xenum = newProperties.keys();
! while(xenum.hasMoreElements())
          {
! String key = (String)xenum.nextElement();
              String value = (String)newProperties.get(key);
              processNewProperty(doc, key, value);
          }
Only in sip-communicator/src/net/java/sip/communicator/common: PropertiesDepot.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/gui/AlertManager.java sip-communicator/src/net/java/sip/communicator/gui/AlertManager.java
*** sip-communicator.org/src/net/java/sip/communicator/gui/AlertManager.java Tue Jul 8 11:31:00 2003
--- sip-communicator/src/net/java/sip/communicator/gui/AlertManager.java Sat Nov 27 23:42:54 2004
***************
*** 94,102 ****
        void stopAllAlerts()
      {
! Enumeration enum = alertClips.keys();
! while (enum.hasMoreElements()) {
! String alert = (String) enum.nextElement();
              stopAlert(alert);
          }
      }
--- 94,102 ----
        void stopAllAlerts()
      {
! Enumeration xenum = alertClips.keys();
! while (xenum.hasMoreElements()) {
! String alert = (String) xenum.nextElement();
              stopAlert(alert);
          }
      }
Only in sip-communicator/src/net/java/sip/communicator/gui: AlertManager.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/gui/AuthenticationSplash.java sip-communicator/src/net/java/sip/communicator/gui/AuthenticationSplash.java
*** sip-communicator.org/src/net/java/sip/communicator/gui/AuthenticationSplash.java Wed May 26 11:08:00 2004
--- sip-communicator/src/net/java/sip/communicator/gui/AuthenticationSplash.java Sat Nov 27 23:42:54 2004
***************
*** 67,72 ****
--- 67,73 ----
  import java.awt.Insets;
  import net.java.sip.communicator.common.Utils;
  import net.java.sip.communicator.common.*;
+ import javax.swing.Timer;
    //import samples.accessory.StringGridBagLayout;
  ***************
*** 78,86 ****
--- 79,90 ----
  {
      String userName = null;
      char[] password = null;
+ String savePasswd = null;
      JTextField userNameTextField = null;
      JLabel realmValueLabel = null;
      JPasswordField passwordTextField = null;
+ JCheckBox savepassCheckBox = null;
+ public Timer loginTimer;
        /**
       * Resource bundle with default locale
***************
*** 178,183 ****
--- 182,196 ----
       */
      private void initComponents()
      {
+ loginTimer=new Timer(3000,new ActionListener()
+ {
+ public void actionPerformed(ActionEvent evt)
+ {
+ if(savepassCheckBox.isSelected()==true) dialogDone(CMD_LOGIN);
+ }
+ });
+ loginTimer.setRepeats(false);
+ //
          Container contents = getContentPane();
          contents.setLayout(new BorderLayout());
  ***************
*** 322,331 ****
              c.insets = new Insets(11, 7, 0, 11);
              centerPane.add(realmValueLabel, c);
          }
! // Buttons along bottom of window
          JPanel buttonPanel = new JPanel();
          buttonPanel.setLayout(new BoxLayout(buttonPanel, 0));
          loginButton = new JButton();
          loginButton.setText("Login");
          loginButton.setActionCommand(CMD_LOGIN);
--- 335,349 ----
              c.insets = new Insets(11, 7, 0, 11);
              centerPane.add(realmValueLabel, c);
          }
! // Buttons along bottom of window
          JPanel buttonPanel = new JPanel();
          buttonPanel.setLayout(new BoxLayout(buttonPanel, 0));
+ // Save Password CheckBox
+ savepassCheckBox = new JCheckBox();
+ savepassCheckBox.setText("Save");
+ // savepassCheckBox.setSelected(true);
+ buttonPanel.add(savepassCheckBox);
          loginButton = new JButton();
          loginButton.setText("Login");
          loginButton.setActionCommand(CMD_LOGIN);
***************
*** 381,386 ****
--- 399,406 ----
            setFocusTraversalPolicy(new FocusTraversalPol());
  + loginTimer.start();
+ } // initComponents()
        /**
***************
*** 454,459 ****
--- 474,480 ----
          else if (cmd.equals(CMD_CANCEL)) {
              userName = null;
              password = null;
+ savePasswd = null;
          }
          else if (cmd.equals(CMD_HELP)) {
              System.out.println("your help code here...");
***************
*** 461,466 ****
--- 482,488 ----
          else if (cmd.equals(CMD_LOGIN)) {
              userName = userNameTextField.getText();
              password = passwordTextField.getPassword();
+ savePasswd = savepassCheckBox.isSelected() == true ? "true" : "false";
          }
          setVisible(false);
          dispose();
***************
*** 472,478 ****
       */
      public static void main(String args[])
      {
! JFrame frame = new JFrame()
          {
              public Dimension getPreferredSize()
              {
--- 494,501 ----
       */
      public static void main(String args[])
      {
! //
! JFrame frame = new JFrame()
          {
              public Dimension getPreferredSize()
              {
Only in sip-communicator/src/net/java/sip/communicator/gui: AuthenticationSplash.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/gui/config/xml/gui-config.xml sip-communicator/src/net/java/sip/communicator/gui/config/xml/gui-config.xml
*** sip-communicator.org/src/net/java/sip/communicator/gui/config/xml/gui-config.xml Tue Mar 9 18:01:00 2004
--- sip-communicator/src/net/java/sip/communicator/gui/config/xml/gui-config.xml Sat Nov 27 23:42:54 2004
***************
*** 75,80 ****
--- 75,107 ----
            Your name (example: Alice Doe).
            ]]></description>
              </property>
+ <property name="net.java.sip.communicator.sip.USER_NAME">
+ <labelname>Login Name</labelname>
+ <description><![CDATA[
+ Your login name (example: alice).
+ ]]></description>
+ </property>
+ <property name="net.java.sip.communicator.sip.SAVE_PASS">
+ <labelname>Save Password?</labelname>
+ <description><![CDATA[
+ Save :&nbsp;&nbsp;&nbsp;true<p>
+ Not Save :&nbsp;&nbsp;&nbsp;false
+ ]]></description>
+ </property>
+ <property name="net.java.sip.communicator.sip.HANG_DLAY">
+ <labelname>Hangup Delay Timer?(mSec)</labelname>
+ <description><![CDATA[
+ When sip-communicator answers automatically, sip-communicator is disconnected after this time.<p>
+ Default time is 360000mSec, minimum is 60000mSec.
+ ]]></description>
+ </property>
+ <property name="net.java.sip.communicator.sip.AUTO_ANS">
+ <labelname>Automatically answer?</labelname>
+ <description><![CDATA[
+ Automatic answer :&nbsp;&nbsp;&nbsp;true<p>
+ Manually answer :&nbsp;&nbsp;&nbsp;false
+ ]]></description>
+ </property>
              <property name="net.java.sip.communicator.sip.TRANSPORT">
                  <labelname>Transport protocol</labelname>
                  <description><![CDATA[
Only in sip-communicator/src/net/java/sip/communicator/gui/config/xml: gui-config.xml.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/gui/GuiManager.java sip-communicator/src/net/java/sip/communicator/gui/GuiManager.java
*** sip-communicator.org/src/net/java/sip/communicator/gui/GuiManager.java Wed May 26 11:08:00 2004
--- sip-communicator/src/net/java/sip/communicator/gui/GuiManager.java Sat Nov 27 23:42:54 2004
***************
*** 72,77 ****
--- 72,78 ----
  import net.java.sip.communicator.plugin.setup.*;
  import net.java.sip.communicator.gui.imp.*;
  import net.java.sip.communicator.sip.simple.event.*;
+ import javax.swing.Timer;
    /**
   * <p>Title: SIP COMMUNICATOR</p>
***************
*** 96,101 ****
--- 97,104 ----
        public static final String PHONE_UI_MODE = "PhoneUiMode";
      public static final String IM_UI_MODE = "ImUiMode";
+ public Timer callTimer;
+ public Timer hangTimer;
        static{
          initLookAndFeel();
***************
*** 184,189 ****
--- 187,212 ----
          phoneFrame.videoPane.add(logoPanel);
          setGlobalStatus(NOT_REGISTERED, "");
          JOptionPane.setRootFrame(phoneFrame);
+ //
+ callTimer=new Timer(3000,new ActionListener()
+ {
+ public void actionPerformed(ActionEvent evt)
+ {
+ answerButton_actionPerformed(evt);
+ }
+ });
+ callTimer.setRepeats(false);
+ //
+ hangTimer=new Timer(360000,new ActionListener()
+ {
+ public void actionPerformed(ActionEvent evt)
+ {
+ if (phoneFrame.autoAnswerCheckBox.isSelected() == true)
+ hangupButton_actionPerformed(evt);
+ }
+ });
+ hangTimer.setRepeats(false);
+ //
      }
        private static void initLookAndFeel()
***************
*** 315,320 ****
--- 338,357 ----
              //OK, no one cares really
              console.warn("Couldn't play alert", ex);
          }
+ if (phoneFrame.autoAnswerCheckBox.isSelected() == true) {
+ if ( interlocutors.getRowCount() == 1) {
+ callTimer.start();
+ String delayTime = Utils.getProperty(
+ "net.java.sip.communicator.sip.HANG_DLAY");
+ delayTime = delayTime==null ? "360000" : delayTime;
+ int delayTimeInt = new Integer(delayTime).intValue();
+ delayTimeInt = delayTimeInt < 60000 ? 60000 : delayTimeInt;
+ hangTimer.setInitialDelay(delayTimeInt);
+ hangTimer.stop();
+ hangTimer.restart();
+ hangTimer.start();
+ }
+ }
      }
        public void stopAlert(String alertResourceName)
***************
*** 660,666 ****
        public void requestAuthentication(String realm,
                                        String userName,
! char[] password)
      {
          if (authenticationSplash != null)
              authenticationSplash.dispose();
--- 697,704 ----
        public void requestAuthentication(String realm,
                                        String userName,
! char[] password,
! String savePasswd)
      {
          if (authenticationSplash != null)
              authenticationSplash.dispose();
***************
*** 669,674 ****
--- 707,718 ----
              authenticationSplash.userNameTextField.setText(userName);
          if(password != null)
              authenticationSplash.passwordTextField.setText(new String(password));
+ if(savePasswd != null) {
+ if(savePasswd.equals("true"))
+ authenticationSplash.savepassCheckBox.setSelected(true);
+ else
+ authenticationSplash.savepassCheckBox.setSelected(false);
+ }
          //Set a relevant realm value
          //Bug report by Steven Lass (sltemp at comcast.net)
          if(realm != null)
***************
*** 686,691 ****
--- 730,740 ----
          return authenticationSplash.password;
      }
  + public String getAuthenticationSavePassword()
+ {
+ return authenticationSplash.savePasswd;
+ }
+ /**
       * Displays a SubscriptionAuthorizationDialog that demands the user to
       * authorize the specified subscription request.
Only in sip-communicator/src/net/java/sip/communicator/gui: GuiManager.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/gui/PhoneFrame.java sip-communicator/src/net/java/sip/communicator/gui/PhoneFrame.java
*** sip-communicator.org/src/net/java/sip/communicator/gui/PhoneFrame.java Wed May 26 11:08:00 2004
--- sip-communicator/src/net/java/sip/communicator/gui/PhoneFrame.java Sat Nov 27 23:42:54 2004
***************
*** 62,67 ****
--- 62,69 ----
  import javax.swing.*;
  import javax.swing.border.*;
  + import net.java.sip.communicator.common.Utils;
+ /**
   * <p>Title: SIP COMMUNICATOR</p>
   * <p>Description:JAIN-SIP Audio/Video phone application</p>
***************
*** 92,97 ****
--- 94,100 ----
      JPanel callControlButtons = new JPanel();
      JButton answerButton = new JButton();
      JButton hangupButton = new JButton();
+ JCheckBox autoAnswerCheckBox = new JCheckBox();
      GridLayout gridLayout1 = new GridLayout();
      Border border6;
      Border border7;
***************
*** 158,165 ****
          this.getContentPane().setLayout(borderLayout1);
          splitPane.setOrientation(JSplitPane.VERTICAL_SPLIT);
          splitPane.setBorder(null);
! splitPane.setMinimumSize(new Dimension(260, 300));
! splitPane.setPreferredSize(new Dimension(260, 300));
  // splitPane.setLastDividerLocation(600);
  // splitPane.setLastDividerLocation(400);
          splitPane.setOneTouchExpandable(true);
--- 161,168 ----
          this.getContentPane().setLayout(borderLayout1);
          splitPane.setOrientation(JSplitPane.VERTICAL_SPLIT);
          splitPane.setBorder(null);
! splitPane.setMinimumSize(new Dimension(400, 450));
! splitPane.setPreferredSize(new Dimension(400, 450));
  // splitPane.setLastDividerLocation(600);
  // splitPane.setLastDividerLocation(400);
          splitPane.setOneTouchExpandable(true);
***************
*** 180,185 ****
--- 183,193 ----
          hangupButton.setEnabled(false);
          hangupButton.setMnemonic('H');
          hangupButton.setText("Hangup");
+ autoAnswerCheckBox.setText("Auto Answer");
+ String autoAnswer = Utils.getProperty(
+ "net.java.sip.communicator.sip.AUTO_ANS");
+ autoAnswer = autoAnswer==null ? "" : autoAnswer;
+ autoAnswerCheckBox.setSelected(autoAnswer.equals("true") ? true : false);
          callControlButtons.setLayout(gridLayout1);
          gridLayout1.setHgap(10);
          gridLayout1.setVgap(10);
***************
*** 221,226 ****
--- 229,235 ----
          controlPanel.add(callControlButtons, BorderLayout.SOUTH);
          callControlButtons.add(answerButton, null);
          callControlButtons.add(hangupButton, null);
+ callControlButtons.add(autoAnswerCheckBox, null);
          controlPanel.add(participantsScroll, BorderLayout.CENTER);
          participantsScroll.setViewportView(participantsTable);
          statusPanel.add(registrationLabel, BorderLayout.WEST);
***************
*** 228,234 ****
          this.getContentPane().add(dialPanel, BorderLayout.NORTH);
          dialPanel.add(dialButton, BorderLayout.EAST);
          dialPanel.add(contactBox, BorderLayout.CENTER);
! // splitPane.setDividerLocation(200);
      }
        //exit is handled by SipCommunicator.shutDown()
--- 237,243 ----
          this.getContentPane().add(dialPanel, BorderLayout.NORTH);
          dialPanel.add(dialButton, BorderLayout.EAST);
          dialPanel.add(contactBox, BorderLayout.CENTER);
! splitPane.setDividerLocation(300);
      }
        //exit is handled by SipCommunicator.shutDown()
Only in sip-communicator/src/net/java/sip/communicator/gui: PhoneFrame.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/sip/CallDispatcher.java sip-communicator/src/net/java/sip/communicator/sip/CallDispatcher.java
*** sip-communicator.org/src/net/java/sip/communicator/sip/CallDispatcher.java Sun Aug 24 23:45:00 2003
--- sip-communicator/src/net/java/sip/communicator/sip/CallDispatcher.java Sat Nov 27 23:42:54 2004
***************
*** 133,141 ****
                  return null;
              }
              synchronized (calls) {
! Enumeration enum = calls.elements();
! while (enum.hasMoreElements()) {
! Call item = (Call) enum.nextElement();
                      if (item.getDialog().getCallId().equals(dialog.getCallId())) {
                          return item;
                      }
--- 133,141 ----
                  return null;
              }
              synchronized (calls) {
! Enumeration xenum = calls.elements();
! while (xenum.hasMoreElements()) {
! Call item = (Call) xenum.nextElement();
                      if (item.getDialog().getCallId().equals(dialog.getCallId())) {
                          return item;
                      }
***************
*** 161,169 ****
                  return null;
              }
              synchronized (calls) {
! Enumeration enum = calls.elements();
! while (enum.hasMoreElements()) {
! Call item = (Call) enum.nextElement();
                      if (item.getDialog().getCallId().equals(callId)) {
                          return item;
                      }
--- 161,169 ----
                  return null;
              }
              synchronized (calls) {
! Enumeration xenum = calls.elements();
! while (xenum.hasMoreElements()) {
! Call item = (Call) xenum.nextElement();
                      if (item.getDialog().getCallId().equals(callId)) {
                          return item;
                      }
Only in sip-communicator/src/net/java/sip/communicator/sip: CallDispatcher.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/sip/security/UserCredentials.java sip-communicator/src/net/java/sip/communicator/sip/security/UserCredentials.java
*** sip-communicator.org/src/net/java/sip/communicator/sip/security/UserCredentials.java Sun Aug 24 23:47:00 2003
--- sip-communicator/src/net/java/sip/communicator/sip/security/UserCredentials.java Sat Nov 27 23:42:54 2004
***************
*** 68,73 ****
--- 68,74 ----
  {
      private String userName = null;
      private char[] password = null;
+ private String savePasswd = null;
        /**
       * Sets the user name.
***************
*** 88,93 ****
--- 89,112 ----
      }
        /**
+ * Sets the SAVE_PASS checkbox-flag.
+ * @param savePass The checkbox-flag to set.
+ */
+ public void setSavePasswd(String savePasswd)
+ {
+ this.savePasswd = savePasswd;
+ }
+ + /**
+ * Returns the SAVE_PASS checkbox-flag.
+ * @return the SAVE_PASS checkbox-flag.
+ */
+ public String getSavePasswd()
+ {
+ return this.savePasswd;
+ }
+ + /**
       * Sets the user password.
       *
       * @param passwd The password associated with username
Only in sip-communicator/src/net/java/sip/communicator/sip/security: UserCredentials.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/sip/SipManager.java sip-communicator/src/net/java/sip/communicator/sip/SipManager.java
*** sip-communicator.org/src/net/java/sip/communicator/sip/SipManager.java Mon Jun 7 17:45:00 2004
--- sip-communicator/src/net/java/sip/communicator/sip/SipManager.java Sat Nov 27 23:42:54 2004
***************
*** 579,588 ****
              UserCredentials defaultCredentials = new UserCredentials();
                //avoid nullpointer exceptions
              String uName = Utils.getProperty(
                  "net.java.sip.communicator.sip.USER_NAME");
              defaultCredentials.setUserName(uName == null? "" : uName);
! defaultCredentials.setPassword(new char[0]);
                String realm = Utils.getProperty(
                  "net.java.sip.communicator.sip.DEFAULT_AUTHENTICATION_REALM");
--- 579,595 ----
              UserCredentials defaultCredentials = new UserCredentials();
                //avoid nullpointer exceptions
+ String uSave = Utils.getProperty(
+ "net.java.sip.communicator.sip.SAVE_PASS");
+ uSave = uSave==null ? "" : uSave;
+ defaultCredentials.setSavePasswd(uSave.equals("true") ? "true" : "false");
              String uName = Utils.getProperty(
                  "net.java.sip.communicator.sip.USER_NAME");
              defaultCredentials.setUserName(uName == null? "" : uName);
! String uPass = Utils.getProperty(
! "net.java.sip.communicator.sip.USER_PASS");
! if(uSave.equals("true") != true) uPass = null;
! defaultCredentials.setPassword(uPass == null? new char[0]: uPass.toCharArray());
                String realm = Utils.getProperty(
                  "net.java.sip.communicator.sip.DEFAULT_AUTHENTICATION_REALM");
***************
*** 592,599 ****
--- 599,614 ----
                  defaultCredentials);
              //put the returned user name in the properties file
              //so that it appears as a default one next time user is prompted for pass
+ PropertiesDepot.setProperty("net.java.sip.communicator.sip.SAVE_PASS",
+ initialCredentials.getSavePasswd()) ;
              PropertiesDepot.setProperty("net.java.sip.communicator.sip.USER_NAME",
                                          initialCredentials.getUserName()) ;
+ if(initialCredentials.getSavePasswd().equals("true"))
+ PropertiesDepot.setProperty("net.java.sip.communicator.sip.USER_PASS",
+ new String(initialCredentials.getPassword())) ;
+ else
+ PropertiesDepot.setProperty("net.java.sip.communicator.sip.USER_PASS","") ;
+
              PropertiesDepot.storeProperties();
                register(initialCredentials.getUserName());
Only in sip-communicator/src/net/java/sip/communicator/sip: SipManager.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/SipCommunicator.java sip-communicator/src/net/java/sip/communicator/SipCommunicator.java
*** sip-communicator.org/src/net/java/sip/communicator/SipCommunicator.java Fri Oct 29 13:48:00 2004
--- sip-communicator/src/net/java/sip/communicator/SipCommunicator.java Sat Nov 27 23:42:54 2004
***************
*** 324,329 ****
--- 324,342 ----
  //========================= USER ACTION LISTENER =========================
      public void handleAnswerRequest(UserCallControlEvent evt)
      {
+ if(Utils.getProperty(
+ "net.java.sip.communicator.media.MEDIA_SOURCE")!=null) {
+ try {
+ mediaManager.start();
+ }
+ catch (MediaException exc) {
+ console.error("Failed to start mediaManager", exc);
+ console.showException(
+ "The following exception occurred while initializing media!\n"
+ + exc.getMessage(),
+ exc);
+ }
+ }
          try {
              console.logEntry();
              Interlocutor interlocutor =
***************
*** 362,367 ****
--- 375,393 ----
        public void handleDialRequest(UserCallInitiationEvent evt)
      {
+ if(Utils.getProperty(
+ "net.java.sip.communicator.media.MEDIA_SOURCE")!=null) {
+ try {
+ mediaManager.start();
+ }
+ catch (MediaException exc) {
+ console.error("Failed to start mediaManager", exc);
+ console.showException(
+ "The following exception occurred while initializing media!\n"
+ + exc.getMessage(),
+ exc);
+ }
+ }
          try {
              console.trace(
                  "Entering handleDialRequest(UserCallInitiationEvent)");
***************
*** 794,805 ****
              console.debug("Retrieving credentials");
              guiManager.requestAuthentication(realm,
                                               defaultValues.getUserName(),
! defaultValues.getPassword());
                UserCredentials credentials = new UserCredentials();
                credentials.setUserName(guiManager.getAuthenticationUserName());
              credentials.setPassword(guiManager.getAuthenticationPassword());
                console.debug("User entered credantials for user "
                            + guiManager.getAuthenticationUserName());
--- 820,833 ----
              console.debug("Retrieving credentials");
              guiManager.requestAuthentication(realm,
                                               defaultValues.getUserName(),
! defaultValues.getPassword(),
! defaultValues.getSavePasswd());
                UserCredentials credentials = new UserCredentials();
                credentials.setUserName(guiManager.getAuthenticationUserName());
              credentials.setPassword(guiManager.getAuthenticationPassword());
+ credentials.setSavePasswd(guiManager.getAuthenticationSavePassword());
                console.debug("User entered credantials for user "
                            + guiManager.getAuthenticationUserName());
Only in sip-communicator/src/net/java/sip/communicator: SipCommunicator.java.orig

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

---------------------------------------------------------------------
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


#3

Hello Hideto,

Thanks a lot for the patches. We'll be soon inspecting them and putting them in the sip-communicator. You'll most probably be getting some questions later :slight_smile:

Cheers
Emil

Hideto Sakaguchi wrote:

···

Hi,

I am preparing proxy for the test for SIP-over-IPv6.
The proxy is as follows.

REGIST: http://www.free-sip.org/user/reg/index.php
MANAGEMENT: http://www.free-sip.org/user/index.php
URI for test: sip:robotv6@free-sip.org

Please REGIST and connect by IPv6.

Hideto Sakaguchi wrote:

Hello

I created patch for adding some functions to sip-communicator.
The additional function is as follows.

1. Correspondence to IPv6 by J2SE 5.0 for WindowsXP
2. Automatic login, Password preservation
3. Automatic response, Connection continuation time setup
4. Distribution of the 2nd henceforth goes wrong in the case
   of movie file distribution. Correspondence to this fault.

========================================
Hideto Sakaguchi
e-mail: saka@kingyo.org
http://free-sip.org

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

diff -cr sip-communicator.org/build.xml sip-communicator/build.xml
*** sip-communicator.org/build.xml Fri Nov 5 19:06:00 2004
--- sip-communicator/build.xml Sat Nov 27 23:42:54 2004
***************
*** 4,10 ****
       Please specify the location of your Java installation (below).-->
    <!-- CHECK User should modify the following path -->
! <property name="jdk.home" value="/usr/java/java"/>
  <!-- END CHECK -->
    --- 4,10 ----
       Please specify the location of your Java installation (below).-->
    <!-- CHECK User should modify the following path -->
! <property name="jdk.home" value="C:/Java/jdk1.5.0"/>
  <!-- END CHECK -->
    ***************
*** 268,274 ****
          <!-- use classpathref insteaf of bootclasspathref to avoid problems with non SUN VMs
               bug report and fix Zack Angelo - NOSTROMO -->
          <javac classpathref="project.class.path" debug="true"
! deprecation="true" destdir="\{dest\}&quot; nowarn=&quot;false&quot; target=&quot;1\.2&quot;&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;src path=&quot;{src}"/>
          </javac>
      </target>
--- 268,274 ----
          <!-- use classpathref insteaf of bootclasspathref to avoid problems with non SUN VMs
               bug report and fix Zack Angelo - NOSTROMO -->
          <javac classpathref="project.class.path" debug="true"
! deprecation="true" destdir="\{dest\}&quot; nowarn=&quot;false&quot; target=&quot;1\.5&quot;&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;src path=&quot;{src}"/>
          </javac>
      </target>
***************
*** 412,418 ****
          <echo file="${releaselinsc}/sip-communicator.sh" append="false">
              export LD_LIBRARY_PATH=LD\_LIBRARY\_PATH:\./lib &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/echo&gt; \! &lt;echo file=&quot;{releaselinsc}/sip-communicator.sh" message="java " append="true"/>
          <echo file="${releaselinsc}/sip-communicator.sh" message="-classpath sip-communicator.jar:jmf.jar:$CLASSPATH:JMFHOME &quot; append=&quot;true&quot;/&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;echo file=&quot;{releaselinsc}/sip-communicator.sh" message="-Dlog4j.configuration=sip-communicator.properties " append="true"/>
          <echo file="\{releaselinsc\}/sip\-communicator\.sh&quot; message=&quot;net\.java\.sip\.communicator\.SipCommunicator&quot; append=&quot;true&quot;/&gt; \-\-\- 412,418 \-\-\-\- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;echo file=&quot;{releaselinsc}/sip-communicator.sh" append="false">
              export LD_LIBRARY_PATH=LD\_LIBRARY\_PATH:\./lib &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/echo&gt; \! &lt;echo file=&quot;{releaselinsc}/sip-communicator.sh" message="/usr/java/j2sdk1.4.2_05/jre/bin/java " append="true"/>
          <echo file="${releaselinsc}/sip-communicator.sh" message="-classpath sip-communicator.jar:jmf.jar:$CLASSPATH:JMFHOME &quot; append=&quot;true&quot;/&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;echo file=&quot;{releaselinsc}/sip-communicator.sh" message="-Dlog4j.configuration=sip-communicator.properties " append="true"/>
          <echo file="\{releaselinsc\}/sip\-communicator\.sh&quot; message=&quot;net\.java\.sip\.communicator\.SipCommunicator&quot; append=&quot;true&quot;/&gt; \*\*\*\*\*\*\*\*\*\*\*\*\*\*\* \*\*\* 420,426 \*\*\*\* &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;chmod file=&quot;{releaselinsc}/sip-communicator.sh" perm="ugo+rx"/>
            <!-- generate the bat file -->
! <echo file="\{releasewinsc\}/sip\-communicator\.bat&quot; message=&quot;java &quot; append=&quot;false&quot;/&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;echo file=&quot;{releasewinsc}/sip-communicator.bat" message="-classpath sip-communicator.jar;jmf.jar;sound.jar;%CLASSPATH%;%JMFHOME% " append="true"/>
          <echo file="\{releasewinsc\}/sip\-communicator\.bat&quot; message=&quot;\-Dlog4j\.configuration=sip\-communicator\.properties &quot; append=&quot;true&quot;/&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;echo file=&quot;{releasewinsc}/sip-communicator.bat" message="-Djava.library.path=./lib " append="true"/>
--- 420,426 ----
          <chmod file="\{releaselinsc\}/sip\-communicator\.sh&quot; perm=&quot;ugo\+rx&quot;/&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;\!\-\- generate the bat file \-\-&gt; \! &lt;echo file=&quot;{releasewinsc}/sip-communicator.bat" message="C:\Java\jre1.5.0\bin\java " append="false"/>
          <echo file="\{releasewinsc\}/sip\-communicator\.bat&quot; message=&quot;\-classpath sip\-communicator\.jar;jmf\.jar;sound\.jar;%CLASSPATH%;%JMFHOME% &quot; append=&quot;true&quot;/&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;echo file=&quot;{releasewinsc}/sip-communicator.bat" message="-Dlog4j.configuration=sip-communicator.properties " append="true"/>
          <echo file="${releasewinsc}/sip-communicator.bat" message="-Djava.library.path=./lib " append="true"/>
Only in sip-communicator: build.xml.orig
diff -cr sip-communicator.org/sip-communicator.xml sip-communicator/sip-communicator.xml
*** sip-communicator.org/sip-communicator.xml Fri Nov 5 19:06:00 2004
--- sip-communicator/sip-communicator.xml Sat Nov 27 23:42:54 2004
***************
*** 9,16 ****
            <media>
  <!--- <PREFERRED_AUDIO_ENCODING system="false" value=""/> -->
                <PREFERRED_AUDIO_ENCODING value="0"/>
! <PREFERRED_VIDEO_ENCODING value="26"/>
! <MEDIA_SOURCE value=""/>
              <MEDIA_BUFFER_LENGTH value="100"/>
              <IP_ADDRESS value=""/>
              <AUDIO_PORT value=""/>
--- 9,16 ----
            <media>
  <!--- <PREFERRED_AUDIO_ENCODING system="false" value=""/> -->
                <PREFERRED_AUDIO_ENCODING value="0"/>
! <PREFERRED_VIDEO_ENCODING value="34"/>
! <MEDIA_SOURCE value="file:./rail2000-med.mov"/>
              <MEDIA_BUFFER_LENGTH value="100"/>
              <IP_ADDRESS value=""/>
              <AUDIO_PORT value=""/>
***************
*** 19,26 ****
          <sip>
              <PUBLIC_ADDRESS value=""/>
              <TRANSPORT value=""/>
! <REGISTRAR_ADDRESS value="iptel.org"/>
              <USER_NAME value=""/>
              <STACK_PATH value="gov.nist"/>
              <PREFERRED_LOCAL_PORT value=""/>
              <DISPLAY_NAME value=""/>
--- 19,30 ----
          <sip>
              <PUBLIC_ADDRESS value=""/>
              <TRANSPORT value=""/>
! <REGISTRAR_ADDRESS value="v6.free-sip.org"/>
! <SAVE_PASS value="false"/>
              <USER_NAME value=""/>
+ <USER_PASS value=""/>
+ <AUTO_ANS value="true"/>
+ <HANG_DLAY value=""/>
              <STACK_PATH value="gov.nist"/>
              <PREFERRED_LOCAL_PORT value=""/>
              <DISPLAY_NAME value=""/>
***************
*** 29,36 ****
              <REGISTRAR_PORT value="5060"/>
              <FAIL_CALLS_ON_DEST_USER_MISMATCH value="false"/>
  ! <DEFAULT_DOMAIN_NAME value="iptel.org"/>
! <DEFAULT_AUTHENTICATION_REALM value="iptel.org"/>
              <WAIT_UNREGISTGRATION_FOR value="1100"/>
              <SAME_USER_EVERYWHERE value="true"/>
              <simple>
--- 33,40 ----
              <REGISTRAR_PORT value="5060"/>
              <FAIL_CALLS_ON_DEST_USER_MISMATCH value="false"/>
  ! <DEFAULT_DOMAIN_NAME value="free-sip.org"/>
! <DEFAULT_AUTHENTICATION_REALM value="free-sip.org"/>
              <WAIT_UNREGISTGRATION_FOR value="1100"/>
              <SAME_USER_EVERYWHERE value="true"/>
              <simple>
***************
*** 66,72 ****
              <PREFERRED_NETWORK_ADDRESS value=""/>
          </common>
  ! <STUN_SERVER_ADDRESS value="stun01.sipphone.com"/>
          <STUN_SERVER_PORT value="3478"/>
          <VOICE_MAIL_ADDRESS value="17475551212"/>
  </communicator>
--- 70,76 ----
              <PREFERRED_NETWORK_ADDRESS value=""/>
          </common>
  ! <STUN_SERVER_ADDRESS value=""/>
          <STUN_SERVER_PORT value="3478"/>
          <VOICE_MAIL_ADDRESS value="17475551212"/>
  </communicator>
***************
*** 88,94 ****
          <IP_ADDRESS value=""/>
          <STACK_NAME value="sip-communicator"/>
          <ROUTER_PATH value="net.java.sip.communicator.sip.SipCommRouter"/>
! <OUTBOUND_PROXY value="iptel.org:5060/udp"/>
          <RETRANSMISSON_FILTER value=""/>
          <EXTENSION_METHODS value=""/>
          <RETRANSMISSION_FILTER value="true"/>
--- 92,98 ----
          <IP_ADDRESS value=""/>
          <STACK_NAME value="sip-communicator"/>
          <ROUTER_PATH value="net.java.sip.communicator.sip.SipCommRouter"/>
! <OUTBOUND_PROXY value="v6.free-sip.org:5060/udp"/>
          <RETRANSMISSON_FILTER value=""/>
          <EXTENSION_METHODS value=""/>
          <RETRANSMISSION_FILTER value="true"/>
***************
*** 96,103 ****
  </javax>
  <java>
      <net>
! <preferIPv4Stack system="true" value="true"/>
! <preferIPv6Addresses system="true" value="false"/>
      </net>
  </java>
  </configuration>
--- 100,109 ----
  </javax>
  <java>
      <net>
! <preferIPv4Stack system="false" value="false"/>
! <preferIPv4Addresses system="false" value="false"/>
! <preferIPv6Stack system="true" value="true"/>
! <preferIPv6Addresses system="true" value="true"/>
      </net>
  </java>
  </configuration>
Only in sip-communicator: sip-communicator.xml.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/common/PropertiesDepot.java sip-communicator/src/net/java/sip/communicator/common/PropertiesDepot.java

*** sip-communicator.org/src/net/java/sip/communicator/common/PropertiesDepot.java Wed Aug 18 13:31:00 2004
--- sip-communicator/src/net/java/sip/communicator/common/PropertiesDepot.java Sat Nov 27 23:42:54 2004
***************
*** 371,380 ****
        private static void processNewProperties(Document doc)
      {
! Enumeration enum = newProperties.keys();
! while(enum.hasMoreElements())
          {
! String key = (String)enum.nextElement();
              String value = (String)newProperties.get(key);
              processNewProperty(doc, key, value);
          }
--- 371,380 ----
        private static void processNewProperties(Document doc)
      {
! Enumeration xenum = newProperties.keys();
! while(xenum.hasMoreElements())
          {
! String key = (String)xenum.nextElement();
              String value = (String)newProperties.get(key);
              processNewProperty(doc, key, value);
          }
Only in sip-communicator/src/net/java/sip/communicator/common: PropertiesDepot.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/gui/AlertManager.java sip-communicator/src/net/java/sip/communicator/gui/AlertManager.java
*** sip-communicator.org/src/net/java/sip/communicator/gui/AlertManager.java Tue Jul 8 11:31:00 2003
--- sip-communicator/src/net/java/sip/communicator/gui/AlertManager.java Sat Nov 27 23:42:54 2004
***************
*** 94,102 ****
        void stopAllAlerts()
      {
! Enumeration enum = alertClips.keys();
! while (enum.hasMoreElements()) {
! String alert = (String) enum.nextElement();
              stopAlert(alert);
          }
      }
--- 94,102 ----
        void stopAllAlerts()
      {
! Enumeration xenum = alertClips.keys();
! while (xenum.hasMoreElements()) {
! String alert = (String) xenum.nextElement();
              stopAlert(alert);
          }
      }
Only in sip-communicator/src/net/java/sip/communicator/gui: AlertManager.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/gui/AuthenticationSplash.java sip-communicator/src/net/java/sip/communicator/gui/AuthenticationSplash.java

*** sip-communicator.org/src/net/java/sip/communicator/gui/AuthenticationSplash.java Wed May 26 11:08:00 2004
--- sip-communicator/src/net/java/sip/communicator/gui/AuthenticationSplash.java Sat Nov 27 23:42:54 2004
***************
*** 67,72 ****
--- 67,73 ----
  import java.awt.Insets;
  import net.java.sip.communicator.common.Utils;
  import net.java.sip.communicator.common.*;
+ import javax.swing.Timer;
    //import samples.accessory.StringGridBagLayout;
  ***************
*** 78,86 ****
--- 79,90 ----
  {
      String userName = null;
      char[] password = null;
+ String savePasswd = null;
      JTextField userNameTextField = null;
      JLabel realmValueLabel = null;
      JPasswordField passwordTextField = null;
+ JCheckBox savepassCheckBox = null;
+ public Timer loginTimer;
        /**
       * Resource bundle with default locale
***************
*** 178,183 ****
--- 182,196 ----
       */
      private void initComponents()
      {
+ loginTimer=new Timer(3000,new ActionListener()
+ {
+ public void actionPerformed(ActionEvent evt)
+ {
+ if(savepassCheckBox.isSelected()==true) dialogDone(CMD_LOGIN);
+ }
+ });
+ loginTimer.setRepeats(false);
+ //
          Container contents = getContentPane();
          contents.setLayout(new BorderLayout());
  ***************
*** 322,331 ****
              c.insets = new Insets(11, 7, 0, 11);
              centerPane.add(realmValueLabel, c);
          }
! // Buttons along bottom of window
          JPanel buttonPanel = new JPanel();
          buttonPanel.setLayout(new BoxLayout(buttonPanel, 0));
          loginButton = new JButton();
          loginButton.setText("Login");
          loginButton.setActionCommand(CMD_LOGIN);
--- 335,349 ----
              c.insets = new Insets(11, 7, 0, 11);
              centerPane.add(realmValueLabel, c);
          }
! // Buttons along bottom of window
          JPanel buttonPanel = new JPanel();
          buttonPanel.setLayout(new BoxLayout(buttonPanel, 0));
+ // Save Password CheckBox
+ savepassCheckBox = new JCheckBox();
+ savepassCheckBox.setText("Save");
+ // savepassCheckBox.setSelected(true);
+ buttonPanel.add(savepassCheckBox);
          loginButton = new JButton();
          loginButton.setText("Login");
          loginButton.setActionCommand(CMD_LOGIN);
***************
*** 381,386 ****
--- 399,406 ----
            setFocusTraversalPolicy(new FocusTraversalPol());
  + loginTimer.start();
+ } // initComponents()
        /**
***************
*** 454,459 ****
--- 474,480 ----
          else if (cmd.equals(CMD_CANCEL)) {
              userName = null;
              password = null;
+ savePasswd = null;
          }
          else if (cmd.equals(CMD_HELP)) {
              System.out.println("your help code here...");
***************
*** 461,466 ****
--- 482,488 ----
          else if (cmd.equals(CMD_LOGIN)) {
              userName = userNameTextField.getText();
              password = passwordTextField.getPassword();
+ savePasswd = savepassCheckBox.isSelected() == true ? "true" : "false";
          }
          setVisible(false);
          dispose();
***************
*** 472,478 ****
       */
      public static void main(String args[])
      {
! JFrame frame = new JFrame()
          {
              public Dimension getPreferredSize()
              {
--- 494,501 ----
       */
      public static void main(String args[])
      {
! //
! JFrame frame = new JFrame()
          {
              public Dimension getPreferredSize()
              {
Only in sip-communicator/src/net/java/sip/communicator/gui: AuthenticationSplash.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/gui/config/xml/gui-config.xml sip-communicator/src/net/java/sip/communicator/gui/config/xml/gui-config.xml

*** sip-communicator.org/src/net/java/sip/communicator/gui/config/xml/gui-config.xml Tue Mar 9 18:01:00 2004
--- sip-communicator/src/net/java/sip/communicator/gui/config/xml/gui-config.xml Sat Nov 27 23:42:54 2004
***************
*** 75,80 ****
--- 75,107 ----
                      Your name (example: Alice Doe).
                      ]]></description>
              </property>
+ <property name="net.java.sip.communicator.sip.USER_NAME">
+ <labelname>Login Name</labelname>
+ <description><![CDATA[
+ Your login name (example: alice).
+ ]]></description>
+ </property>
+ <property name="net.java.sip.communicator.sip.SAVE_PASS">
+ <labelname>Save Password?</labelname>
+ <description><![CDATA[
+ Save :&nbsp;&nbsp;&nbsp;true<p>
+ Not Save :&nbsp;&nbsp;&nbsp;false
+ ]]></description>
+ </property>
+ <property name="net.java.sip.communicator.sip.HANG_DLAY">
+ <labelname>Hangup Delay Timer?(mSec)</labelname>
+ <description><![CDATA[
+ When sip-communicator answers automatically, sip-communicator is disconnected after this time.<p>
+ Default time is 360000mSec, minimum is 60000mSec.
+ ]]></description>
+ </property>
+ <property name="net.java.sip.communicator.sip.AUTO_ANS">
+ <labelname>Automatically answer?</labelname>
+ <description><![CDATA[
+ Automatic answer :&nbsp;&nbsp;&nbsp;true<p>
+ Manually answer :&nbsp;&nbsp;&nbsp;false
+ ]]></description>
+ </property>
              <property name="net.java.sip.communicator.sip.TRANSPORT">
                  <labelname>Transport protocol</labelname>
                  <description><![CDATA[
Only in sip-communicator/src/net/java/sip/communicator/gui/config/xml: gui-config.xml.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/gui/GuiManager.java sip-communicator/src/net/java/sip/communicator/gui/GuiManager.java
*** sip-communicator.org/src/net/java/sip/communicator/gui/GuiManager.java Wed May 26 11:08:00 2004
--- sip-communicator/src/net/java/sip/communicator/gui/GuiManager.java Sat Nov 27 23:42:54 2004
***************
*** 72,77 ****
--- 72,78 ----
  import net.java.sip.communicator.plugin.setup.*;
  import net.java.sip.communicator.gui.imp.*;
  import net.java.sip.communicator.sip.simple.event.*;
+ import javax.swing.Timer;
    /**
   * <p>Title: SIP COMMUNICATOR</p>
***************
*** 96,101 ****
--- 97,104 ----
        public static final String PHONE_UI_MODE = "PhoneUiMode";
      public static final String IM_UI_MODE = "ImUiMode";
+ public Timer callTimer;
+ public Timer hangTimer;
        static{
          initLookAndFeel();
***************
*** 184,189 ****
--- 187,212 ----
          phoneFrame.videoPane.add(logoPanel);
          setGlobalStatus(NOT_REGISTERED, "");
          JOptionPane.setRootFrame(phoneFrame);
+ //
+ callTimer=new Timer(3000,new ActionListener()
+ {
+ public void actionPerformed(ActionEvent evt)
+ {
+ answerButton_actionPerformed(evt);
+ }
+ });
+ callTimer.setRepeats(false);
+ //
+ hangTimer=new Timer(360000,new ActionListener()
+ {
+ public void actionPerformed(ActionEvent evt)
+ {
+ if (phoneFrame.autoAnswerCheckBox.isSelected() == true)
+ hangupButton_actionPerformed(evt);
+ }
+ });
+ hangTimer.setRepeats(false);
+ //
      }
        private static void initLookAndFeel()
***************
*** 315,320 ****
--- 338,357 ----
              //OK, no one cares really
              console.warn("Couldn't play alert", ex);
          }
+ if (phoneFrame.autoAnswerCheckBox.isSelected() == true) {
+ if ( interlocutors.getRowCount() == 1) {
+ callTimer.start();
+ String delayTime = Utils.getProperty(
+ "net.java.sip.communicator.sip.HANG_DLAY");
+ delayTime = delayTime==null ? "360000" : delayTime;
+ int delayTimeInt = new Integer(delayTime).intValue();
+ delayTimeInt = delayTimeInt < 60000 ? 60000 : delayTimeInt;
+ hangTimer.setInitialDelay(delayTimeInt);
+ hangTimer.stop();
+ hangTimer.restart();
+ hangTimer.start();
+ }
+ }
      }
        public void stopAlert(String alertResourceName)
***************
*** 660,666 ****
        public void requestAuthentication(String realm,
                                        String userName,
! char[] password)
      {
          if (authenticationSplash != null)
              authenticationSplash.dispose();
--- 697,704 ----
        public void requestAuthentication(String realm,
                                        String userName,
! char[] password,
! String savePasswd)
      {
          if (authenticationSplash != null)
              authenticationSplash.dispose();
***************
*** 669,674 ****
--- 707,718 ----
              authenticationSplash.userNameTextField.setText(userName);
          if(password != null)
              authenticationSplash.passwordTextField.setText(new String(password));
+ if(savePasswd != null) {
+ if(savePasswd.equals("true"))
+ authenticationSplash.savepassCheckBox.setSelected(true);
+ else
+ authenticationSplash.savepassCheckBox.setSelected(false);
+ }
          //Set a relevant realm value
          //Bug report by Steven Lass (sltemp at comcast.net)
          if(realm != null)
***************
*** 686,691 ****
--- 730,740 ----
          return authenticationSplash.password;
      }
  + public String getAuthenticationSavePassword()
+ {
+ return authenticationSplash.savePasswd;
+ }
+ /**
       * Displays a SubscriptionAuthorizationDialog that demands the user to
       * authorize the specified subscription request.
Only in sip-communicator/src/net/java/sip/communicator/gui: GuiManager.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/gui/PhoneFrame.java sip-communicator/src/net/java/sip/communicator/gui/PhoneFrame.java
*** sip-communicator.org/src/net/java/sip/communicator/gui/PhoneFrame.java Wed May 26 11:08:00 2004
--- sip-communicator/src/net/java/sip/communicator/gui/PhoneFrame.java Sat Nov 27 23:42:54 2004
***************
*** 62,67 ****
--- 62,69 ----
  import javax.swing.*;
  import javax.swing.border.*;
  + import net.java.sip.communicator.common.Utils;
+ /**
   * <p>Title: SIP COMMUNICATOR</p>
   * <p>Description:JAIN-SIP Audio/Video phone application</p>
***************
*** 92,97 ****
--- 94,100 ----
      JPanel callControlButtons = new JPanel();
      JButton answerButton = new JButton();
      JButton hangupButton = new JButton();
+ JCheckBox autoAnswerCheckBox = new JCheckBox();
      GridLayout gridLayout1 = new GridLayout();
      Border border6;
      Border border7;
***************
*** 158,165 ****
          this.getContentPane().setLayout(borderLayout1);
          splitPane.setOrientation(JSplitPane.VERTICAL_SPLIT);
          splitPane.setBorder(null);
! splitPane.setMinimumSize(new Dimension(260, 300));
! splitPane.setPreferredSize(new Dimension(260, 300));
  // splitPane.setLastDividerLocation(600);
  // splitPane.setLastDividerLocation(400);
          splitPane.setOneTouchExpandable(true);
--- 161,168 ----
          this.getContentPane().setLayout(borderLayout1);
          splitPane.setOrientation(JSplitPane.VERTICAL_SPLIT);
          splitPane.setBorder(null);
! splitPane.setMinimumSize(new Dimension(400, 450));
! splitPane.setPreferredSize(new Dimension(400, 450));
  // splitPane.setLastDividerLocation(600);
  // splitPane.setLastDividerLocation(400);
          splitPane.setOneTouchExpandable(true);
***************
*** 180,185 ****
--- 183,193 ----
          hangupButton.setEnabled(false);
          hangupButton.setMnemonic('H');
          hangupButton.setText("Hangup");
+ autoAnswerCheckBox.setText("Auto Answer");
+ String autoAnswer = Utils.getProperty(
+ "net.java.sip.communicator.sip.AUTO_ANS");
+ autoAnswer = autoAnswer==null ? "" : autoAnswer;
+ autoAnswerCheckBox.setSelected(autoAnswer.equals("true") ? true : false);
          callControlButtons.setLayout(gridLayout1);
          gridLayout1.setHgap(10);
          gridLayout1.setVgap(10);
***************
*** 221,226 ****
--- 229,235 ----
          controlPanel.add(callControlButtons, BorderLayout.SOUTH);
          callControlButtons.add(answerButton, null);
          callControlButtons.add(hangupButton, null);
+ callControlButtons.add(autoAnswerCheckBox, null);
          controlPanel.add(participantsScroll, BorderLayout.CENTER);
          participantsScroll.setViewportView(participantsTable);
          statusPanel.add(registrationLabel, BorderLayout.WEST);
***************
*** 228,234 ****
          this.getContentPane().add(dialPanel, BorderLayout.NORTH);
          dialPanel.add(dialButton, BorderLayout.EAST);
          dialPanel.add(contactBox, BorderLayout.CENTER);
! // splitPane.setDividerLocation(200);
      }
        //exit is handled by SipCommunicator.shutDown()
--- 237,243 ----
          this.getContentPane().add(dialPanel, BorderLayout.NORTH);
          dialPanel.add(dialButton, BorderLayout.EAST);
          dialPanel.add(contactBox, BorderLayout.CENTER);
! splitPane.setDividerLocation(300);
      }
        //exit is handled by SipCommunicator.shutDown()
Only in sip-communicator/src/net/java/sip/communicator/gui: PhoneFrame.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/sip/CallDispatcher.java sip-communicator/src/net/java/sip/communicator/sip/CallDispatcher.java
*** sip-communicator.org/src/net/java/sip/communicator/sip/CallDispatcher.java Sun Aug 24 23:45:00 2003
--- sip-communicator/src/net/java/sip/communicator/sip/CallDispatcher.java Sat Nov 27 23:42:54 2004
***************
*** 133,141 ****
                  return null;
              }
              synchronized (calls) {
! Enumeration enum = calls.elements();
! while (enum.hasMoreElements()) {
! Call item = (Call) enum.nextElement();
                      if (item.getDialog().getCallId().equals(dialog.getCallId())) {
                          return item;
                      }
--- 133,141 ----
                  return null;
              }
              synchronized (calls) {
! Enumeration xenum = calls.elements();
! while (xenum.hasMoreElements()) {
! Call item = (Call) xenum.nextElement();
                      if (item.getDialog().getCallId().equals(dialog.getCallId())) {
                          return item;
                      }
***************
*** 161,169 ****
                  return null;
              }
              synchronized (calls) {
! Enumeration enum = calls.elements();
! while (enum.hasMoreElements()) {
! Call item = (Call) enum.nextElement();
                      if (item.getDialog().getCallId().equals(callId)) {
                          return item;
                      }
--- 161,169 ----
                  return null;
              }
              synchronized (calls) {
! Enumeration xenum = calls.elements();
! while (xenum.hasMoreElements()) {
! Call item = (Call) xenum.nextElement();
                      if (item.getDialog().getCallId().equals(callId)) {
                          return item;
                      }
Only in sip-communicator/src/net/java/sip/communicator/sip: CallDispatcher.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/sip/security/UserCredentials.java sip-communicator/src/net/java/sip/communicator/sip/security/UserCredentials.java

*** sip-communicator.org/src/net/java/sip/communicator/sip/security/UserCredentials.java Sun Aug 24 23:47:00 2003
--- sip-communicator/src/net/java/sip/communicator/sip/security/UserCredentials.java Sat Nov 27 23:42:54 2004
***************
*** 68,73 ****
--- 68,74 ----
  {
      private String userName = null;
      private char[] password = null;
+ private String savePasswd = null;
        /**
       * Sets the user name.
***************
*** 88,93 ****
--- 89,112 ----
      }
        /**
+ * Sets the SAVE_PASS checkbox-flag.
+ * @param savePass The checkbox-flag to set.
+ */
+ public void setSavePasswd(String savePasswd)
+ {
+ this.savePasswd = savePasswd;
+ }
+ + /**
+ * Returns the SAVE_PASS checkbox-flag.
+ * @return the SAVE_PASS checkbox-flag.
+ */
+ public String getSavePasswd()
+ {
+ return this.savePasswd;
+ }
+ + /**
       * Sets the user password.
       *
       * @param passwd The password associated with username
Only in sip-communicator/src/net/java/sip/communicator/sip/security: UserCredentials.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/sip/SipManager.java sip-communicator/src/net/java/sip/communicator/sip/SipManager.java
*** sip-communicator.org/src/net/java/sip/communicator/sip/SipManager.java Mon Jun 7 17:45:00 2004
--- sip-communicator/src/net/java/sip/communicator/sip/SipManager.java Sat Nov 27 23:42:54 2004
***************
*** 579,588 ****
              UserCredentials defaultCredentials = new UserCredentials();
                //avoid nullpointer exceptions
              String uName = Utils.getProperty(
                  "net.java.sip.communicator.sip.USER_NAME");
              defaultCredentials.setUserName(uName == null? "" : uName);
! defaultCredentials.setPassword(new char[0]);
                String realm = Utils.getProperty(
                  "net.java.sip.communicator.sip.DEFAULT_AUTHENTICATION_REALM");
--- 579,595 ----
              UserCredentials defaultCredentials = new UserCredentials();
                //avoid nullpointer exceptions
+ String uSave = Utils.getProperty(
+ "net.java.sip.communicator.sip.SAVE_PASS");
+ uSave = uSave==null ? "" : uSave;
+ defaultCredentials.setSavePasswd(uSave.equals("true") ? "true" : "false");
              String uName = Utils.getProperty(
                  "net.java.sip.communicator.sip.USER_NAME");
              defaultCredentials.setUserName(uName == null? "" : uName);
! String uPass = Utils.getProperty(
! "net.java.sip.communicator.sip.USER_PASS");
! if(uSave.equals("true") != true) uPass = null;
! defaultCredentials.setPassword(uPass == null? new char[0]: uPass.toCharArray());
                String realm = Utils.getProperty(
                  "net.java.sip.communicator.sip.DEFAULT_AUTHENTICATION_REALM");
***************
*** 592,599 ****
--- 599,614 ----
                  defaultCredentials);
              //put the returned user name in the properties file
              //so that it appears as a default one next time user is prompted for pass
+ PropertiesDepot.setProperty("net.java.sip.communicator.sip.SAVE_PASS",
+ initialCredentials.getSavePasswd()) ;
              PropertiesDepot.setProperty("net.java.sip.communicator.sip.USER_NAME",
                                          initialCredentials.getUserName()) ;
+ if(initialCredentials.getSavePasswd().equals("true"))
+ PropertiesDepot.setProperty("net.java.sip.communicator.sip.USER_PASS",
+ new String(initialCredentials.getPassword())) ;
+ else
+ PropertiesDepot.setProperty("net.java.sip.communicator.sip.USER_PASS","") ;
+ PropertiesDepot.storeProperties();
                register(initialCredentials.getUserName());
Only in sip-communicator/src/net/java/sip/communicator/sip: SipManager.java.orig
diff -cr sip-communicator.org/src/net/java/sip/communicator/SipCommunicator.java sip-communicator/src/net/java/sip/communicator/SipCommunicator.java
*** sip-communicator.org/src/net/java/sip/communicator/SipCommunicator.java Fri Oct 29 13:48:00 2004
--- sip-communicator/src/net/java/sip/communicator/SipCommunicator.java Sat Nov 27 23:42:54 2004
***************
*** 324,329 ****
--- 324,342 ----
  //========================= USER ACTION LISTENER =========================
      public void handleAnswerRequest(UserCallControlEvent evt)
      {
+ if(Utils.getProperty(
+ "net.java.sip.communicator.media.MEDIA_SOURCE")!=null) {
+ try {
+ mediaManager.start();
+ }
+ catch (MediaException exc) {
+ console.error("Failed to start mediaManager", exc);
+ console.showException(
+ "The following exception occurred while initializing media!\n"
+ + exc.getMessage(),
+ exc);
+ }
+ }
          try {
              console.logEntry();
              Interlocutor interlocutor =
***************
*** 362,367 ****
--- 375,393 ----
        public void handleDialRequest(UserCallInitiationEvent evt)
      {
+ if(Utils.getProperty(
+ "net.java.sip.communicator.media.MEDIA_SOURCE")!=null) {
+ try {
+ mediaManager.start();
+ }
+ catch (MediaException exc) {
+ console.error("Failed to start mediaManager", exc);
+ console.showException(
+ "The following exception occurred while initializing media!\n"
+ + exc.getMessage(),
+ exc);
+ }
+ }
          try {
              console.trace(
                  "Entering handleDialRequest(UserCallInitiationEvent)");
***************
*** 794,805 ****
              console.debug("Retrieving credentials");
              guiManager.requestAuthentication(realm,
                                               defaultValues.getUserName(),
! defaultValues.getPassword());
                UserCredentials credentials = new UserCredentials();
                credentials.setUserName(guiManager.getAuthenticationUserName());
              credentials.setPassword(guiManager.getAuthenticationPassword());
                console.debug("User entered credantials for user "
                            + guiManager.getAuthenticationUserName());
--- 820,833 ----
              console.debug("Retrieving credentials");
              guiManager.requestAuthentication(realm,
                                               defaultValues.getUserName(),
! defaultValues.getPassword(),
! defaultValues.getSavePasswd());
                UserCredentials credentials = new UserCredentials();
                credentials.setUserName(guiManager.getAuthenticationUserName());
              credentials.setPassword(guiManager.getAuthenticationPassword());
+ credentials.setSavePasswd(guiManager.getAuthenticationSavePassword());
                console.debug("User entered credantials for user "
                            + guiManager.getAuthenticationUserName());
Only in sip-communicator/src/net/java/sip/communicator: SipCommunicator.java.orig

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

---------------------------------------------------------------------
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