View the DQSD CVS repository here:
http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/dqsd/

Update of /cvsroot/dqsd/dqsd
In directory usw-pr-cvs1:/tmp/cvs-serv27432

Modified Files:
        ChangeLog.txt defer_tools.js 
Log Message:
- added dontChangeTarget argument in submitForm function in defer_tools.js to allow 
searches to force a target window

- changed setiq.xml to use this change (more elegant than the previous version hack)

note: hoped this would have allowed to at last get sf.xml to allow authentication, by 
first opening a window to https://sourceforge.net/account/login.php to get a cookie 
then applying the login form into the same window, but no luck - I don't know why. :(

Index: ChangeLog.txt
===================================================================
RCS file: /cvsroot/dqsd/dqsd/ChangeLog.txt,v
retrieving revision 1.52
retrieving revision 1.53
diff -C2 -d -r1.52 -r1.53
*** ChangeLog.txt       24 Jul 2002 14:16:59 -0000      1.52
--- ChangeLog.txt       24 Jul 2002 15:59:57 -0000      1.53
***************
*** 15,18 ****
--- 15,19 ----
  
  * switches now can contain . and -. This is used here: jdk HashMap /1.3
+ * changed defer_tools.js for special searches like setiq.xml that need several forms 
+opened in one window
  
  Bug Fixes

Index: defer_tools.js
===================================================================
RCS file: /cvsroot/dqsd/dqsd/defer_tools.js,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** defer_tools.js      24 Jul 2002 09:03:13 -0000      1.11
--- defer_tools.js      24 Jul 2002 15:59:57 -0000      1.12
***************
*** 33,49 ****
  
  // Submit a form either with the default browser or with IE
! function submitForm(form)
  {
!   // Here's a safeguard for forgetting to put a target in the FORM
!   if ( (getReuseBrowserWindowMode() == 0) || !form.target || (form.target && 
form.target == '') )
!     form.target = '_blank';
! 
!   // Reuse a single window if the user wants to and the target is _blank
!   // Don't override targets with any other name because some searches may want
!   // their own window.
!   if ((getReuseBrowserWindowMode() > 0) && form.target && (form.target == '_blank'))
    {
!     // 1=same window always; 2=new window for each search type
!     form.target = ((getReuseBrowserWindowMode() == 1) ? DQSD_BROWSER_WINDOW_NAME : 
(DQSD_BROWSER_WINDOW_NAME + '_' + form.name));
    }
  
--- 33,53 ----
  
  // Submit a form either with the default browser or with IE
! function submitForm(form, dontChangeTarget)
  {
!   //allow the Override
!   if ( !dontChangeTarget )
    {
!     // Here's a safeguard for forgetting to put a target in the FORM
!     if ( (getReuseBrowserWindowMode() == 0) || !form.target || (form.target && 
form.target == '') )
!       form.target = '_blank';
! 
!     // Reuse a single window if the user wants to and the target is _blank
!     // Don't override targets with any other name because some searches may want
!     // their own window.
!     if ((getReuseBrowserWindowMode() > 0) && form.target && (form.target == 
'_blank'))
!     {
!       // 1=same window always; 2=new window for each search type
!       form.target = ((getReuseBrowserWindowMode() == 1) ? DQSD_BROWSER_WINDOW_NAME : 
(DQSD_BROWSER_WINDOW_NAME + '_' + form.name));
!     }
    }
  
***************
*** 146,150 ****
  
    // Regular expression that defines switches
!   var re_switch = /\/(([-.\w]+)(?::?(\S*)))\s*/;
    var re_res_args;
    var re_res_switch;
--- 150,154 ----
  
    // Regular expression that defines switches
!   var re_switch = /\/((\w+)(?::?(\S*)))\s*/;
    var re_res_args;
    var re_res_switch;
***************
*** 159,168 ****
        for (var j = 0; j < expectedSwitches.length && !re_res_switch; j++)
        {
!         var expect_regex = new RegExp(
!             '^(' + re_res_args[2].replace('.', '\\.') +
!              ')' + (expandSwitches ? '' : '$'), 'i');
! 
!         re_res_switch = expectedSwitches[j].match(expect_regex);
! 
          //  If there is a match, adjust the args_array, and save the values.
          if (re_res_switch)
--- 163,170 ----
        for (var j = 0; j < expectedSwitches.length && !re_res_switch; j++)
        {
!         if (expandSwitches)
!           re_res_switch = expectedSwitches[j].match(new RegExp('^(' + re_res_args[2] 
+ ')', 'i'));
!         else
!           re_res_switch = expectedSwitches[j].match(new RegExp('^(' + re_res_args[2] 
+ ')$', 'i'));
          //  If there is a match, adjust the args_array, and save the values.
          if (re_res_switch)




-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
DQSD-CVS mailing list
https://lists.sourceforge.net/lists/listinfo/dqsd-cvs
DQSD CVS repository:
http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/dqsd/

Reply via email to