Use the status bar at the bottom of the internet search pane: when a result is clicked on, put its true URL into the status bar.

This commit is contained in:
rjc%netscape.com 1999-11-24 11:14:14 +00:00
parent 30c94599dc
commit a1dd235c23
4 changed files with 34 additions and 8 deletions

View File

@ -22,6 +22,11 @@ function doEngineClick(node)
if (!resultsTree) return;
var contentArea = document.getElementById("content");
if (!contentArea) return;
var statusNode = document.getElementById("status-button");
if (statusNode)
{
statusNode.setAttribute("value", "");
}
var html="";
@ -92,14 +97,22 @@ function doResultClick(node)
if (internetSearchStore)
{
var src = rdf.GetResource(theID, true);
// var urlProperty = rdf.GetResource("http://home.netscape.com/NC-rdf#URL", true);
var urlProperty = rdf.GetResource("http://home.netscape.com/NC-rdf#URL", true);
var bannerProperty = rdf.GetResource("http://home.netscape.com/NC-rdf#Banner", true);
var htmlProperty = rdf.GetResource("http://home.netscape.com/NC-rdf#HTML", true);
/*
var url = internetSearchStore.GetTarget(src, urlProperty, true);
if (url) url = url.QueryInterface(Components.interfaces.nsIRDFLiteral);
if (url) url = url.Value;
*/
if (url)
{
var statusNode = document.getElementById("status-button");
if (statusNode)
{
statusNode.setAttribute("value", url);
}
}
var banner = internetSearchStore.GetTarget(src, bannerProperty, true);
if (banner) banner = banner.QueryInterface(Components.interfaces.nsIRDFLiteral);
if (banner) banner = banner.Value;

View File

@ -87,6 +87,6 @@ the scrollbar is visible. Yes, I know this is not necessary for win32 or gtk, bu
use this area for information (maybe full URL of selected item or the like) in the future.
-->
<box id="status-bar" style="min-height:15px; max-height:15px;">
<titledbutton class="status-bar" align="left" value=""/>
<titledbutton id="status-button" class="status-bar" align="left" value=""/>
</box>
</window>

View File

@ -22,6 +22,11 @@ function doEngineClick(node)
if (!resultsTree) return;
var contentArea = document.getElementById("content");
if (!contentArea) return;
var statusNode = document.getElementById("status-button");
if (statusNode)
{
statusNode.setAttribute("value", "");
}
var html="";
@ -92,14 +97,22 @@ function doResultClick(node)
if (internetSearchStore)
{
var src = rdf.GetResource(theID, true);
// var urlProperty = rdf.GetResource("http://home.netscape.com/NC-rdf#URL", true);
var urlProperty = rdf.GetResource("http://home.netscape.com/NC-rdf#URL", true);
var bannerProperty = rdf.GetResource("http://home.netscape.com/NC-rdf#Banner", true);
var htmlProperty = rdf.GetResource("http://home.netscape.com/NC-rdf#HTML", true);
/*
var url = internetSearchStore.GetTarget(src, urlProperty, true);
if (url) url = url.QueryInterface(Components.interfaces.nsIRDFLiteral);
if (url) url = url.Value;
*/
if (url)
{
var statusNode = document.getElementById("status-button");
if (statusNode)
{
statusNode.setAttribute("value", url);
}
}
var banner = internetSearchStore.GetTarget(src, bannerProperty, true);
if (banner) banner = banner.QueryInterface(Components.interfaces.nsIRDFLiteral);
if (banner) banner = banner.Value;

View File

@ -87,6 +87,6 @@ the scrollbar is visible. Yes, I know this is not necessary for win32 or gtk, bu
use this area for information (maybe full URL of selected item or the like) in the future.
-->
<box id="status-bar" style="min-height:15px; max-height:15px;">
<titledbutton class="status-bar" align="left" value=""/>
<titledbutton id="status-button" class="status-bar" align="left" value=""/>
</box>
</window>