forrest-svn mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rgard...@apache.org
Subject svn commit: r356268 - in /forrest/trunk/tools/forrestbar/xpi/chrome/content: forrestbarOverlay.js forrestbarOverlay.xul
Date Mon, 12 Dec 2005 15:42:51 GMT
Author: rgardler
Date: Mon Dec 12 07:42:29 2005
New Revision: 356268

URL: http://svn.apache.org/viewcvs?rev=356268&view=rev
Log:
- do search when enter key is pressed
- default search is on MARC
- add MARC archive search
- add user list searching
- add forrest site searching


Modified:
    forrest/trunk/tools/forrestbar/xpi/chrome/content/forrestbarOverlay.js
    forrest/trunk/tools/forrestbar/xpi/chrome/content/forrestbarOverlay.xul

Modified: forrest/trunk/tools/forrestbar/xpi/chrome/content/forrestbarOverlay.js
URL: http://svn.apache.org/viewcvs/forrest/trunk/tools/forrestbar/xpi/chrome/content/forrestbarOverlay.js?rev=356268&r1=356267&r2=356268&view=diff
==============================================================================
--- forrest/trunk/tools/forrestbar/xpi/chrome/content/forrestbarOverlay.js (original)
+++ forrest/trunk/tools/forrestbar/xpi/chrome/content/forrestbarOverlay.js Mon Dec 12 07:42:29
2005
@@ -41,8 +41,29 @@
 
 function search(searchID)
 {
+  searchDev('aims', searchID);
+}
+
+function searchDev(engine, searchID)
+{
   var searchItem = document.getElementById(searchID);
-  navigate('http://www.mail-archive.com/cgi-bin/htsearch?method=and&format=short&config=dev_forrest_apache_org&restrict=&exclude=&words='
+ searchItem.value);
+  if (engine == 'aims') {
+    navigate('http://marc.theaimsgroup.com/?l=forrest-dev&w=2&r=1&q=b&s='
+ searchItem.value);
+  } else {
+    navigate('http://www.mail-archive.com/cgi-bin/htsearch?method=and&format=short&config=dev_forrest_apache_org&restrict=&exclude=&words='
+ searchItem.value);
+  }
+}
+
+function searchUser(searchID)
+{
+  var searchItem = document.getElementById(searchID);
+  navigate('http://www.mail-archive.com/cgi-bin/htsearch?method=and&format=short&config=user_forrest_apache_org&restrict=&exclude=&words='
+ searchItem.value);
+}
+
+function searchSite(searchID)
+{
+  var searchItem = document.getElementById(searchID);
+  navigate('http://www.google.com/search?sitesearch=forrest.apache.org&q=search&Search='
+ searchItem.value);
 }
 
 function contract(subUrl,searchID)

Modified: forrest/trunk/tools/forrestbar/xpi/chrome/content/forrestbarOverlay.xul
URL: http://svn.apache.org/viewcvs/forrest/trunk/tools/forrestbar/xpi/chrome/content/forrestbarOverlay.xul?rev=356268&r1=356267&r2=356268&view=diff
==============================================================================
--- forrest/trunk/tools/forrestbar/xpi/chrome/content/forrestbarOverlay.xul (original)
+++ forrest/trunk/tools/forrestbar/xpi/chrome/content/forrestbarOverlay.xul Mon Dec 12 07:42:29
2005
@@ -90,9 +90,18 @@
       <toolbarseparator/>
 
       <toolbaritem class="forrestbar" id="forrestbar-search">
-        <label value="Search Forrest:"/>
-        <textbox id="forrestbar-input" hidden="false"/>
-        <toolbarbutton label=" dev-mail" onclick="search('forrestbar-input');" hidden="false"/>
+        <label value="Search:"/>
+        <textbox id="forrestbar-input" onkeydown="if (event.which == 13) {searchDev('aims',
'forrestbar-input');}" hidden="false"/>
+        
+        <toolbarbutton label="Search" hidden="false" type="menu">
+          <menupopup>
+            <menuitem label="Dev (MARC)" onclick="searchDev('aims', 'forrestbar-input');"
hidden="false"/>
+            <menuitem label="Dev (The Mail Archive)" onclick="searchDev('mailArchive',
'forrestbar-input');" hidden="false"/>
+            <menuitem label="User (The Mail Archive)" onclick="searchUser('forrestbar-input');"
hidden="false"/>
+            <menuitem label="Forrest Site" onclick="searchSite('forrestbar-input');" hidden="false"/>
+          </menupopup>
+        </toolbarbutton>
+        
         <toolbarbutton label="contracts" hidden="false" type="menu">
           <menupopup>
              <menuitem label="resolve-contract" onclick="contract('resolve.contract.html.','forrestbar-input');"/>



Mime
View raw message