зеркало из https://github.com/mozilla/gecko-dev.git
More Search changes.
This commit is contained in:
Родитель
71f57e08a6
Коммит
cff5f78f40
|
@ -21,7 +21,7 @@
|
||||||
|
|
||||||
<html:script src="shared.js" />
|
<html:script src="shared.js" />
|
||||||
|
|
||||||
<titledbutton id="internetresultssummary" value="&results.title.label;" width="200" size="200" />
|
<titledbutton id="internetresultssummary" value="&results.title.label;" />
|
||||||
<html:p />
|
<html:p />
|
||||||
|
|
||||||
<tree id="internetresultstree" flex="100%" border="1" datasources="rdf:internetsearch" ondblclick="return OpenURL(event,event.target.parentNode);">
|
<tree id="internetresultstree" flex="100%" border="1" datasources="rdf:internetsearch" ondblclick="return OpenURL(event,event.target.parentNode);">
|
||||||
|
@ -85,5 +85,6 @@
|
||||||
</treehead>
|
</treehead>
|
||||||
|
|
||||||
<treebody open="true" />
|
<treebody open="true" />
|
||||||
|
|
||||||
</tree>
|
</tree>
|
||||||
</window>
|
</window>
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
]>
|
]>
|
||||||
|
|
||||||
|
|
||||||
<window title="&window.title.label;" style="width:100%; height:100%"
|
<window title="&window.title.label;" style="width:100%; height:100%; background-color:white"
|
||||||
xmlns:html="http://www.w3.org/TR/REC-html40"
|
xmlns:html="http://www.w3.org/TR/REC-html40"
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||||
|
|
|
@ -11,7 +11,7 @@ box {
|
||||||
|
|
||||||
tree {
|
tree {
|
||||||
display: table;
|
display: table;
|
||||||
background-color: #FFFFFF;
|
background-color: white;
|
||||||
border: 1;
|
border: 1;
|
||||||
border-spacing: 0px;
|
border-spacing: 0px;
|
||||||
width: 90%;
|
width: 90%;
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
<?xml version="1.0"?>
|
<?xml version="1.0"?>
|
||||||
<?xml-stylesheet href="resource:/res/samples/xul.css" type="text/css"?>
|
|
||||||
<?xml-stylesheet href="findresults.css" type="text/css"?>
|
<?xml-stylesheet href="findresults.css" type="text/css"?>
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@ tree[id="searchengines"] {
|
||||||
background-color: #FFFFFF;
|
background-color: #FFFFFF;
|
||||||
border: 1;
|
border: 1;
|
||||||
border-spacing: 0px;
|
border-spacing: 0px;
|
||||||
width: 300;
|
// width: 300;
|
||||||
align: center;
|
align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -89,3 +89,25 @@ function doUncheckAll()
|
||||||
|
|
||||||
return(true);
|
return(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function saveSearch()
|
||||||
|
{
|
||||||
|
var resultsTree = parent.frames[1].document.getElementById("internetresultstree");
|
||||||
|
if (!resultsTree) return(false);
|
||||||
|
x = resultsTree.childNodes.length;
|
||||||
|
if (x < 1) return(false);
|
||||||
|
// XXX shouldn't assume that treebody is the last child node in the tree!
|
||||||
|
var searchURL = resultsTree.childNodes[x-1].getAttribute("id");
|
||||||
|
if (!searchURL) return(false);
|
||||||
|
|
||||||
|
dump("Bookmark search URL: " + searchURL + "\n");
|
||||||
|
|
||||||
|
var bmks = Components.classes["component://netscape/browser/bookmarks-service"].getService();
|
||||||
|
bmks = bmks.QueryInterface(Components.interfaces.nsIBookmarksService);
|
||||||
|
// XXX should construct a more interesting/useful title
|
||||||
|
bmks.AddBookmark(searchURL, "Saved Internet Search");
|
||||||
|
|
||||||
|
return(true);
|
||||||
|
}
|
||||||
|
|
|
@ -10,6 +10,9 @@
|
||||||
|
|
||||||
<!ENTITY checkbox.column.label "On">
|
<!ENTITY checkbox.column.label "On">
|
||||||
<!ENTITY engine.column.label "Search Engines">
|
<!ENTITY engine.column.label "Search Engines">
|
||||||
|
|
||||||
|
<!ENTITY uncheckall.button.label "Uncheck All">
|
||||||
|
<!ENTITY savesearch.button.label "Save Search in Bookmarks">
|
||||||
]>
|
]>
|
||||||
|
|
||||||
|
|
||||||
|
@ -34,7 +37,7 @@
|
||||||
</html:tr>
|
</html:tr>
|
||||||
|
|
||||||
<html:tr><html:td>
|
<html:tr><html:td>
|
||||||
<tree id="searchengines" flex="100%" datasources="rdf:internetsearch" >
|
<tree id="searchengines" border="1" flex="100%" datasources="rdf:internetsearch" >
|
||||||
<treecol id="CheckboxColumn" />
|
<treecol id="CheckboxColumn" />
|
||||||
<treecol id="NameColumn" rdf:resource="http://home.netscape.com/NC-rdf#Name"/>
|
<treecol id="NameColumn" rdf:resource="http://home.netscape.com/NC-rdf#Name"/>
|
||||||
|
|
||||||
|
@ -62,16 +65,16 @@
|
||||||
</treeitem>
|
</treeitem>
|
||||||
</treehead>
|
</treehead>
|
||||||
|
|
||||||
<treebody id="NC:SearchEngineRoot" />
|
<treebody id="NC:SearchEngineRoot" open="true" />
|
||||||
</tree>
|
</tree>
|
||||||
</html:td></html:tr>
|
</html:td></html:tr>
|
||||||
|
|
||||||
<html:tr><html:td>
|
<html:tr><html:td>
|
||||||
<html:input type="button" value="Uncheck All" onclick="return doUncheckAll();" />
|
<html:input type="button" value="&uncheckall.button.label;" onclick="return doUncheckAll();" />
|
||||||
|
<html:input type="button" value="&savesearch.button.label;" onclick="return saveSearch();" />
|
||||||
</html:td></html:tr>
|
</html:td></html:tr>
|
||||||
</html:table>
|
</html:table>
|
||||||
</html:center>
|
</html:center>
|
||||||
<html:p />
|
<html:p />
|
||||||
<spring flex="100%" align="horizontal" />
|
|
||||||
</box>
|
</box>
|
||||||
</window>
|
</window>
|
||||||
|
|
|
@ -21,7 +21,7 @@
|
||||||
|
|
||||||
<html:script src="shared.js" />
|
<html:script src="shared.js" />
|
||||||
|
|
||||||
<titledbutton id="internetresultssummary" value="&results.title.label;" width="200" size="200" />
|
<titledbutton id="internetresultssummary" value="&results.title.label;" />
|
||||||
<html:p />
|
<html:p />
|
||||||
|
|
||||||
<tree id="internetresultstree" flex="100%" border="1" datasources="rdf:internetsearch" ondblclick="return OpenURL(event,event.target.parentNode);">
|
<tree id="internetresultstree" flex="100%" border="1" datasources="rdf:internetsearch" ondblclick="return OpenURL(event,event.target.parentNode);">
|
||||||
|
@ -85,5 +85,6 @@
|
||||||
</treehead>
|
</treehead>
|
||||||
|
|
||||||
<treebody open="true" />
|
<treebody open="true" />
|
||||||
|
|
||||||
</tree>
|
</tree>
|
||||||
</window>
|
</window>
|
||||||
|
|
|
@ -39,6 +39,6 @@
|
||||||
|
|
||||||
<html:script>
|
<html:script>
|
||||||
// load initial page
|
// load initial page
|
||||||
loadPage('internet');
|
loadPage('find');
|
||||||
</html:script>
|
</html:script>
|
||||||
</window>
|
</window>
|
||||||
|
|
Загрузка…
Ссылка в новой задаче