removing unused files, r=neil bug 238818 not part of build
@ -1,85 +0,0 @@
|
||||
// ----------------------
|
||||
// DumpDOM(node)
|
||||
//
|
||||
// Call this function to dump the contents of the DOM starting at the specified node.
|
||||
// Use node = document.documentElement to dump every element of the current document.
|
||||
// Use node = top.window.document.documentElement to dump every element.
|
||||
//
|
||||
// 8-13-99 Updated to dump almost all attributes of every node. There are still some attributes
|
||||
// that are purposely skipped to make it more readable.
|
||||
// ----------------------
|
||||
function DumpDOM(node)
|
||||
{
|
||||
dump("--------------------- DumpDOM ---------------------\n");
|
||||
|
||||
DumpNodeAndChildren(node, "");
|
||||
|
||||
dump("------------------- End DumpDOM -------------------\n");
|
||||
}
|
||||
|
||||
|
||||
// This function does the work of DumpDOM by recursively calling itself to explore the tree
|
||||
function DumpNodeAndChildren(node, prefix)
|
||||
{
|
||||
dump(prefix + "<" + node.nodeName);
|
||||
|
||||
var attributes = node.attributes;
|
||||
|
||||
if ( attributes && attributes.length )
|
||||
{
|
||||
var item, name, value;
|
||||
|
||||
for ( var index = 0; index < attributes.length; index++ )
|
||||
{
|
||||
item = attributes.item(index);
|
||||
name = item.nodeName;
|
||||
value = item.nodeValue;
|
||||
|
||||
if ( (name == 'lazycontent' && value == 'true') ||
|
||||
(name == 'xulcontentsgenerated' && value == 'true') ||
|
||||
(name == 'id') ||
|
||||
(name == 'instanceOf') )
|
||||
{
|
||||
// ignore these
|
||||
}
|
||||
else
|
||||
{
|
||||
dump(" " + name + "=\"" + value + "\"");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ( node.nodeType == 1 )
|
||||
{
|
||||
// id
|
||||
var text = node.getAttribute('id');
|
||||
if ( text && text[0] != '$' )
|
||||
dump(" id=\"" + text + "\"");
|
||||
}
|
||||
|
||||
if ( node.nodeName == "#text" )
|
||||
dump(" = \"" + node.data + "\"");
|
||||
|
||||
dump(">\n");
|
||||
|
||||
// dump IFRAME && FRAME DOM
|
||||
if ( node.nodeName == "IFRAME" || node.nodeName == "FRAME" )
|
||||
{
|
||||
if ( node.name )
|
||||
{
|
||||
var wind = top.frames[node.name];
|
||||
if ( wind && wind.document && wind.document.documentElement )
|
||||
{
|
||||
dump(prefix + "----------- " + node.nodeName + " -----------\n");
|
||||
DumpNodeAndChildren(wind.document.documentElement, prefix + " ");
|
||||
dump(prefix + "--------- End " + node.nodeName + " ---------\n");
|
||||
}
|
||||
}
|
||||
}
|
||||
// children of nodes (other than frames)
|
||||
else if ( node.childNodes )
|
||||
{
|
||||
for ( var child = 0; child < node.childNodes.length; child++ )
|
||||
DumpNodeAndChildren(node.childNodes[child], prefix + " ");
|
||||
}
|
||||
}
|
Before Width: | Height: | Size: 437 B |
Before Width: | Height: | Size: 51 B |
Before Width: | Height: | Size: 59 B |
Before Width: | Height: | Size: 51 B |
Before Width: | Height: | Size: 54 B |
Before Width: | Height: | Size: 62 B |
Before Width: | Height: | Size: 54 B |
@ -1,165 +0,0 @@
|
||||
/** Contains style definitions for the navigator application
|
||||
**/
|
||||
|
||||
titledbutton#print-button {
|
||||
list-style-image:url(resource:/res/toolbar/print.gif);
|
||||
}
|
||||
|
||||
titledbutton#back-button {
|
||||
list-style-image:url(resource:/res/toolbar/back.gif);
|
||||
}
|
||||
|
||||
titledbutton#forward-button {
|
||||
list-style-image:url(resource:/res/toolbar/forward.gif);
|
||||
}
|
||||
|
||||
titledbutton#stop-button {
|
||||
list-style-image:url(resource:/res/toolbar/stop.gif);
|
||||
}
|
||||
|
||||
titledbutton#reload-button {
|
||||
list-style-image:url(resource:/res/toolbar/reload.gif);
|
||||
}
|
||||
|
||||
titledbutton#home-button {
|
||||
list-style-image:url(resource:/res/toolbar/home.gif);
|
||||
}
|
||||
|
||||
titledbutton#netscape-button {
|
||||
list-style-image:url(resource:/res/toolbar/mynetscape.gif);
|
||||
}
|
||||
|
||||
titledbutton#security-button {
|
||||
list-style-image:url(resource:/res/toolbar/StatusBar-secure.gif);
|
||||
}
|
||||
|
||||
titledbutton#Throbber
|
||||
{
|
||||
list-style-image:url(resource:/res/throbber/anims00.gif);
|
||||
}
|
||||
|
||||
titledbutton#Throbber[busy="true"] {
|
||||
list-style-image:url(resource:/res/throbber/throbbingN.gif);
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton{
|
||||
color:#CCCCFF;
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton[pseudoclass~="active"] {
|
||||
|
||||
text-decoration:none;
|
||||
border: 1px inset;
|
||||
|
||||
padding-left: 2px;
|
||||
padding-right: 0px;
|
||||
padding-top: 2px;
|
||||
padding-bottom: 0px;
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton[pseudoclass~="hover"] {
|
||||
border: 1px outset #666699;
|
||||
color:white;
|
||||
/*text-decoration:underline;*/
|
||||
padding: 1px;
|
||||
}
|
||||
|
||||
toolbar#taskbar {
|
||||
display:block;
|
||||
background-color: #666699;
|
||||
border-bottom: solid #333366 1px;
|
||||
border-top: solid #9999AA 1px;
|
||||
border-left: solid #9999AA 1px;
|
||||
border-right: solid #333366 1px;
|
||||
font: 10pt sans-serif;
|
||||
min-height: 16px;
|
||||
color: white;
|
||||
}
|
||||
|
||||
|
||||
box[class=insecure] {
|
||||
margin-top: 2px;
|
||||
border-top: 0px;
|
||||
}
|
||||
|
||||
box[class=secure] {
|
||||
border-top: 2px solid yellow;
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
box#status-bar titledbutton {
|
||||
font: 2.5mm sans-serif;
|
||||
}
|
||||
|
||||
titledbutton[class=secure] {
|
||||
background-color: yellow;
|
||||
}
|
||||
|
||||
titledbutton[class=insecure] {
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton[pseudoclass~="active"] {
|
||||
|
||||
text-decoration:none;
|
||||
border: 1px inset;
|
||||
|
||||
padding-left: 2px;
|
||||
padding-right: 0px;
|
||||
padding-top: 2px;
|
||||
padding-bottom: 0px;
|
||||
}
|
||||
|
||||
titledbutton[class="popup"]
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-popup-arrow.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-nav
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-navigator.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-mail
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-mail.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-addr
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-addressbook.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-comp
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-composer.gif);
|
||||
}
|
||||
|
||||
box[type="secure"] {
|
||||
border-top: 2px solid yellow;
|
||||
}
|
||||
|
||||
box[type="unsecure"] {
|
||||
margin-top: 1px;
|
||||
}
|
||||
|
||||
toolbar[class="main-bar"] {
|
||||
}
|
||||
|
||||
window#main-window {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
box#outer-box {
|
||||
width: 100%;
|
||||
height:100%;
|
||||
}
|
||||
|
||||
iframe#content-frame {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
}
|
||||
|
||||
toolbar titledbutton[pseudoclass~="hover"] {
|
||||
border-width: 10px;
|
||||
}
|
@ -1,185 +0,0 @@
|
||||
/** Contains style definitions for the navigator application
|
||||
**/
|
||||
|
||||
titledbutton#print-button {
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/home.gif);
|
||||
}
|
||||
|
||||
titledbutton#back-button {
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/back.gif);
|
||||
}
|
||||
|
||||
titledbutton#forward-button {
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/forward.gif);
|
||||
}
|
||||
|
||||
titledbutton#stop-button {
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/stop.gif);
|
||||
}
|
||||
|
||||
titledbutton#reload-button {
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/reload.gif);
|
||||
}
|
||||
|
||||
titledbutton#home-button {
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/home.gif);
|
||||
}
|
||||
|
||||
titledbutton#netscape-button {
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/mynetscape.gif);
|
||||
}
|
||||
|
||||
titledbutton#security-button {
|
||||
list-style-image:url(resource:/res/toolbar/StatusBar-secure.gif);
|
||||
}
|
||||
|
||||
titledbutton#Throbber
|
||||
{
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/mozstat.gif);
|
||||
}
|
||||
|
||||
titledbutton#Throbber[busy="true"] {
|
||||
list-style-image:url(resource:/res/throbber/throbbingN.gif);
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton{
|
||||
color:#CCCCFF;
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton[pseudoclass~="active"] {
|
||||
|
||||
text-decoration:none;
|
||||
border: 1px inset;
|
||||
|
||||
padding-left: 2px;
|
||||
padding-right: 0px;
|
||||
padding-top: 2px;
|
||||
padding-bottom: 0px;
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton[pseudoclass~="hover"] {
|
||||
border: 1px outset #666699;
|
||||
color:white;
|
||||
/*text-decoration:underline;*/
|
||||
padding: 1px;
|
||||
}
|
||||
|
||||
toolbar#taskbar {
|
||||
background-color: black;
|
||||
font: 10pt sans-serif;
|
||||
min-height: 16px;
|
||||
color: red;
|
||||
}
|
||||
|
||||
|
||||
box[class=insecure] {
|
||||
margin-top: 2px;
|
||||
border-top: 0px;
|
||||
}
|
||||
|
||||
box[class=secure] {
|
||||
border-top: 2px solid yellow;
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
box#status-bar titledbutton {
|
||||
font: 2.5mm sans-serif;
|
||||
}
|
||||
|
||||
titledbutton[class=secure] {
|
||||
background-color: yellow;
|
||||
}
|
||||
|
||||
titledbutton[class=insecure] {
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton[pseudoclass~="active"] {
|
||||
|
||||
text-decoration:none;
|
||||
border: 1px inset;
|
||||
|
||||
padding-left: 2px;
|
||||
padding-right: 0px;
|
||||
padding-top: 2px;
|
||||
padding-bottom: 0px;
|
||||
}
|
||||
|
||||
titledbutton[class="popup"]
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-popup-arrow.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-nav
|
||||
{
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/taskbar-navigator.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-mail
|
||||
{
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/taskbar-mail.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-addr
|
||||
{
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/taskbar-addressbook.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-comp
|
||||
{
|
||||
list-style-image:url(http://www.mozillazine.org/toolbar/taskbar-composer.gif);
|
||||
}
|
||||
|
||||
box[type="secure"] {
|
||||
border-top: 2px solid yellow;
|
||||
}
|
||||
|
||||
box[type="unsecure"] {
|
||||
margin-top: 1px;
|
||||
}
|
||||
|
||||
toolbar {
|
||||
background-color: black;
|
||||
border-color: black;
|
||||
}
|
||||
|
||||
window#main-window {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
box#outer-box {
|
||||
width: 100%;
|
||||
height:100%;
|
||||
background-color: black;
|
||||
}
|
||||
|
||||
iframe#content-frame {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
margin: 5px;
|
||||
}
|
||||
|
||||
titledbutton {
|
||||
color: red;
|
||||
}
|
||||
|
||||
toolbox:toolbox-normal {
|
||||
background-color: black;
|
||||
background-image: none;
|
||||
border: none;
|
||||
}
|
||||
|
||||
toolbox:toolbox-rollover {
|
||||
background-color: rgb(255,0,0);
|
||||
background-image: none;
|
||||
border: none;
|
||||
}
|
||||
|
||||
progressmeter {
|
||||
border: 1px solid black;
|
||||
color : rgb(128,0,0);
|
||||
}
|
||||
|
||||
:progressmeter-stripe {
|
||||
color: rgb(0,128,0);
|
||||
}
|
@ -1,164 +0,0 @@
|
||||
/** Contains style definitions for the navigator application
|
||||
**/
|
||||
|
||||
titledbutton#print-button {
|
||||
list-style-image:url(resource:/res/toolbar/print.gif);
|
||||
}
|
||||
|
||||
titledbutton#back-button {
|
||||
list-style-image:url(resource:/res/toolbar/back.gif);
|
||||
}
|
||||
|
||||
titledbutton#forward-button {
|
||||
list-style-image:url(resource:/res/toolbar/forward.gif);
|
||||
}
|
||||
|
||||
titledbutton#stop-button {
|
||||
list-style-image:url(resource:/res/toolbar/stop.gif);
|
||||
}
|
||||
|
||||
titledbutton#reload-button {
|
||||
list-style-image:url(resource:/res/toolbar/reload.gif);
|
||||
}
|
||||
|
||||
titledbutton#home-button {
|
||||
list-style-image:url(resource:/res/toolbar/home.gif);
|
||||
}
|
||||
|
||||
titledbutton#netscape-button {
|
||||
list-style-image:url(resource:/res/toolbar/mynetscape.gif);
|
||||
}
|
||||
|
||||
titledbutton#security-button {
|
||||
list-style-image:url(resource:/res/toolbar/StatusBar-secure.gif);
|
||||
}
|
||||
|
||||
titledbutton#Throbber
|
||||
{
|
||||
list-style-image:url(resource:/res/throbber/anims00.gif);
|
||||
}
|
||||
|
||||
titledbutton#Throbber[busy="true"] {
|
||||
list-style-image:url(resource:/res/throbber/throbbingN.gif);
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton{
|
||||
color:#CCCCFF;
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton[pseudoclass~="active"] {
|
||||
|
||||
text-decoration:none;
|
||||
border: 1px inset;
|
||||
|
||||
padding-left: 2px;
|
||||
padding-right: 0px;
|
||||
padding-top: 2px;
|
||||
padding-bottom: 0px;
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton[pseudoclass~="hover"] {
|
||||
border: 1px outset #666699;
|
||||
color:white;
|
||||
/*text-decoration:underline;*/
|
||||
padding: 1px;
|
||||
}
|
||||
|
||||
toolbar#taskbar {
|
||||
display:block;
|
||||
background-color: #666699;
|
||||
border-bottom: solid #333366 1px;
|
||||
border-top: solid #9999AA 1px;
|
||||
border-left: solid #9999AA 1px;
|
||||
border-right: solid #333366 1px;
|
||||
font: 10pt sans-serif;
|
||||
min-height: 16px;
|
||||
color: white;
|
||||
}
|
||||
|
||||
|
||||
box[class=insecure] {
|
||||
margin-top: 2px;
|
||||
border-top: 0px;
|
||||
}
|
||||
|
||||
box[class=secure] {
|
||||
border-top: 2px solid yellow;
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
box#status-bar titledbutton {
|
||||
font: 2.5mm sans-serif;
|
||||
}
|
||||
|
||||
titledbutton[class=secure] {
|
||||
background-color: yellow;
|
||||
}
|
||||
|
||||
titledbutton[class=insecure] {
|
||||
}
|
||||
|
||||
toolbar#taskbar titledbutton[pseudoclass~="active"] {
|
||||
|
||||
text-decoration:none;
|
||||
border: 1px inset;
|
||||
|
||||
padding-left: 2px;
|
||||
padding-right: 0px;
|
||||
padding-top: 2px;
|
||||
padding-bottom: 0px;
|
||||
}
|
||||
|
||||
titledbutton[class="popup"]
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-popup-arrow.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-nav
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-navigator.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-mail
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-mail.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-addr
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-addressbook.gif);
|
||||
}
|
||||
|
||||
titledbutton#mini-comp
|
||||
{
|
||||
list-style-image:url(resource:/res/toolbar/taskbar-composer.gif);
|
||||
}
|
||||
|
||||
box[type="secure"] {
|
||||
border-top: 2px solid yellow;
|
||||
}
|
||||
|
||||
box[type="unsecure"] {
|
||||
margin-top: 1px;
|
||||
}
|
||||
|
||||
toolbar[class="main-bar"] {
|
||||
background-image: url(raindrops_light.gif);
|
||||
}
|
||||
|
||||
window#main-window {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
box#outer-box {
|
||||
width: 100%;
|
||||
height:100%;
|
||||
background-image: url(bg.jpg);
|
||||
}
|
||||
|
||||
iframe#content-frame {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
margin: 10px;
|
||||
}
|
@ -1,773 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<?xml-stylesheet href="chrome://navigator/skin/navigator.css" type="text/css"?>
|
||||
|
||||
<!DOCTYPE window>
|
||||
|
||||
<window id="main-window" xmlns:html="http://www.w3.org/1999/xhtml"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
onload="Startup()" title="Mozilla">
|
||||
|
||||
<script>
|
||||
function Startup()
|
||||
{
|
||||
dump("Doing Startup...\n");
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
dump("Looking up BrowserAppCore...\n");
|
||||
if (appCore == null) {
|
||||
dump("Creating BrowserAppCore...\n");
|
||||
appCore = new BrowserAppCore();
|
||||
if (appCore != null) {
|
||||
dump("BrowserAppCore has been created.\n");
|
||||
appCore.Init("BrowserAppCore");
|
||||
appCore.setContentWindow(window.frames[0]);
|
||||
appCore.setWebShellWindow(window);
|
||||
appCore.setToolbarWindow(window);
|
||||
appCore.setDisableCallback("DoDisableButtons();");
|
||||
appCore.setEnableCallback("DoEnableButtons();");
|
||||
dump("Adding BrowserAppCore to AppCoreManager...\n");
|
||||
dump("...probably for a second time, because the constructor of nsBaseAppCore does this!\n");
|
||||
XPAppCoresManager.Add(appCore);
|
||||
}
|
||||
} else {
|
||||
dump("BrowserAppCore has already been created! Why?\n");
|
||||
}
|
||||
}
|
||||
|
||||
function DoDisableButtons()
|
||||
{
|
||||
// Find buttons in the UI and disable them
|
||||
dump("Browser disabling buttons\n");
|
||||
document.getElementById('urlbar')
|
||||
}
|
||||
|
||||
function DoEnableButtons()
|
||||
{
|
||||
// Find buttons in the UI and enable them
|
||||
dump("Browser enabling buttons\n");
|
||||
}
|
||||
|
||||
function RefreshUrlbar()
|
||||
{
|
||||
//Refresh the urlbar bar
|
||||
document.getElementById('urlbar').value = window.frames[0].location.href;
|
||||
}
|
||||
|
||||
function BrowserBack()
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
dump("Going Back\n");
|
||||
appCore.back();
|
||||
RefreshUrlbar();
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function BrowserForward()
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
dump("Going Forward\n");
|
||||
appCore.forward();
|
||||
RefreshUrlbar();
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function BrowserHome()
|
||||
{
|
||||
window.frames[0].home();
|
||||
RefreshUrlbar();
|
||||
}
|
||||
|
||||
function OpenBookmarkURL(node)
|
||||
{
|
||||
if (node.getAttribute('type') !=
|
||||
"http://home.netscape.com/NC-rdf#Bookmark") {
|
||||
return false;
|
||||
}
|
||||
url = node.getAttribute('id');
|
||||
|
||||
// Ignore "NC:" urls.
|
||||
if (url.substring(0, 3) == "NC:") {
|
||||
return false;
|
||||
}
|
||||
|
||||
window.frames[0].location.href = url;
|
||||
RefreshUrlbar();
|
||||
}
|
||||
|
||||
function BrowserNewWindow()
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
dump("Opening New Window\n");
|
||||
appCore.newWindow();
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function BrowserAddBookmark(url,title)
|
||||
{
|
||||
// get RDF Core service
|
||||
var rdfCore = XPAppCoresManager.Find("RDFCore");
|
||||
if (!rdfCore) {
|
||||
rdfCore = new RDFCore();
|
||||
if (!rdfCore) {
|
||||
return(false);
|
||||
}
|
||||
rdfCore.Init("RDFCore");
|
||||
XPAppCoresManager.Add(rdfCore);
|
||||
}
|
||||
// Add it
|
||||
rdfCore.addBookmark(url,title);
|
||||
}
|
||||
|
||||
function BrowserEditBookmarks()
|
||||
{
|
||||
var toolkitCore = XPAppCoresManager.Find("toolkitCore");
|
||||
if (!toolkitCore) {
|
||||
toolkitCore = new ToolkitCore();
|
||||
if (toolkitCore) {
|
||||
toolkitCore.Init("toolkitCore");
|
||||
}
|
||||
}
|
||||
if (toolkitCore) {
|
||||
toolkitCore.ShowWindow("resource:/res/rdf/bookmarks.xul",window);
|
||||
}
|
||||
}
|
||||
|
||||
function BrowserPrintPreview()
|
||||
{
|
||||
// Borrowing this method to show how to
|
||||
// dynamically change icons
|
||||
dump("BrowserPrintPreview\n");
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
dump("Changing Icons\n");
|
||||
appCore.printPreview();
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function BrowserSetDocumentCharacterSet(aCharset)
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
appCore.SetDocumentCharset(aCharset);
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function BrowserClose()
|
||||
{
|
||||
dump("BrowserClose\n");
|
||||
}
|
||||
|
||||
function BrowserExit()
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
dump("Exiting\n");
|
||||
appCore.exit();
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function BrowserLoadURL()
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore == null)
|
||||
{
|
||||
dump("BrowserAppCore has not been initialized\n");
|
||||
return;
|
||||
}
|
||||
|
||||
// rjc: added support for URL shortcuts (3/30/1999)
|
||||
|
||||
// get RDF Core service
|
||||
var rdfCoreFound = false;
|
||||
var rdfCore = XPAppCoresManager.Find("RDFCore");
|
||||
if (rdfCore)
|
||||
{
|
||||
rdfCoreFound = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
rdfCore = new RDFCore();
|
||||
if (rdfCore)
|
||||
{
|
||||
rdfCore.Init("RDFCore");
|
||||
XPAppCoresManager.Add(rdfCore);
|
||||
rdfCoreFound = true;
|
||||
}
|
||||
}
|
||||
if (rdfCoreFound == true)
|
||||
{
|
||||
var shortcutURL = rdfCore.findBookmarkShortcut(document.getElementById('urlbar').value);
|
||||
|
||||
dump("FindBookmarkShortcut: in='" + document.getElementById('urlbar').value + "' out='" + shortcutURL + "'\n");
|
||||
|
||||
if ((shortcutURL != null) && (shortcutURL != ""))
|
||||
{
|
||||
document.getElementById('urlbar').value = shortcutURL;
|
||||
}
|
||||
}
|
||||
|
||||
appCore.loadUrl(document.getElementById('urlbar').value);
|
||||
|
||||
}
|
||||
|
||||
function WalletEditor()
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
dump("Wallet Editor\n");
|
||||
appCore.walletEditor();
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function WalletSafeFillin()
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
dump("Wallet Safe Fillin\n");
|
||||
appCore.walletSafeFillin();
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function WalletQuickFillin()
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
dump("Wallet Quick Fillin\n");
|
||||
appCore.walletQuickFillin();
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function WalletRequestToCapture()
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
dump("Wallet Request To Capture\n");
|
||||
appCore.walletRequestToCapture();
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function WalletSamples()
|
||||
{
|
||||
appCore = XPAppCoresManager.Find("BrowserAppCore");
|
||||
if (appCore != null) {
|
||||
dump("Wallet Samples\n");
|
||||
appCore.walletSamples();
|
||||
} else {
|
||||
dump("BrowserAppCore has not been created!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function OpenMessenger()
|
||||
{
|
||||
var toolkitCore = XPAppCoresManager.Find("ToolkitCore");
|
||||
if (!toolkitCore) {
|
||||
toolkitCore = new ToolkitCore();
|
||||
if (toolkitCore) {
|
||||
toolkitCore.Init("ToolkitCore");
|
||||
}
|
||||
}
|
||||
if (toolkitCore) {
|
||||
toolkitCore.ShowWindow("resource:/res/mailnews/messenger/mailshell.xul",
|
||||
window);
|
||||
}
|
||||
}
|
||||
|
||||
function DoPreferences()
|
||||
{
|
||||
var toolkitCore = XPAppCoresManager.Find("ToolkitCore");
|
||||
if (!toolkitCore) {
|
||||
toolkitCore = new ToolkitCore();
|
||||
if (toolkitCore) {
|
||||
toolkitCore.Init("ToolkitCore");
|
||||
}
|
||||
}
|
||||
if (toolkitCore) {
|
||||
toolkitCore.ShowWindow("resource:/res/samples/PrefsWindow.html",
|
||||
window);
|
||||
}
|
||||
}
|
||||
|
||||
function OpenEditor()
|
||||
{
|
||||
var toolkitCore = XPAppCoresManager.Find("ToolkitCore");
|
||||
if (!toolkitCore) {
|
||||
toolkitCore = new ToolkitCore();
|
||||
if (toolkitCore) {
|
||||
toolkitCore.Init("ToolkitCore");
|
||||
}
|
||||
}
|
||||
if (toolkitCore) {
|
||||
toolkitCore.ShowWindow("resource:/res/samples/EditorAppShell.xul",
|
||||
window);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<broadcaster id="canGoBack"/>
|
||||
<broadcaster id="canGoForward"/>
|
||||
<broadcaster id="canReload"/>
|
||||
<broadcaster id="canStop"/>
|
||||
<broadcaster id="canPrint"/>
|
||||
|
||||
<menubar>
|
||||
<menu name="File">
|
||||
<menuitem name="New Browser Window" onclick="BrowserNewWindow();"/>
|
||||
<menu name="New">
|
||||
<menuitem name="Mail Message" onclick="MsgNewMessage();"/>
|
||||
<menuitem name="Chat Window" onclick=""/>
|
||||
<separator />
|
||||
<menuitem name="Blank Page" onclick="BrowserNewWindow();"/>
|
||||
<menuitem name="Page Using Template..." onclick="BrowserNewWindow();"/>
|
||||
<menuitem name="Page Using Draft..." onclick="BrowserNewWindow();"/>
|
||||
</menu>
|
||||
<menuitem name="Open" onclick="BrowserNewWindow();"/>
|
||||
<separator />
|
||||
<menuitem name="Send Page" onclick="BrowserReload();"/>
|
||||
<menuitem name="Edit Page" onclick="BrowserReload();" />
|
||||
<separator />
|
||||
<menu name="Offline">
|
||||
<menuitem name="Go Offline" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="Synchronize..." onclick="BrowserReload();"/>
|
||||
</menu>
|
||||
<separator />
|
||||
<menuitem name="Print Setup" onclick=""/>
|
||||
<menuitem name="Print Preview" onclick=""/>
|
||||
<menuitem name="Print" onclick=""/>
|
||||
<separator />
|
||||
<menuitem name="Close" onclick="BrowserClose();"/>
|
||||
<menuitem name="Quit" onclick="BrowserExit();"/>
|
||||
</menu>
|
||||
<menu name="Edit">
|
||||
<menuitem name="Undo" onclick="BrowserReload();"/>
|
||||
<menuitem name="Redo" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="Cut" onclick="BrowserReload();"/>
|
||||
<menuitem name="Copy" onclick="BrowserReload();"/>
|
||||
<menuitem name="Paste" onclick="BrowserReload();"/>
|
||||
<menuitem name="Delete" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menu name="Wallet">
|
||||
<menuitem name="Safe Form Fill" onclick="WalletSafeFillin();"/>
|
||||
<menuitem name="Quick Form Fill" onclick="WalletQuickFillin();"/>
|
||||
<menuitem name="Capture Form" onclick="WalletRequestToCapture();"/>
|
||||
<separator />
|
||||
<menuitem name="Wallet Contents" onclick="WalletEditor();"/>
|
||||
<separator />
|
||||
<menuitem name="Samples" onclick="WalletSamples();"/>
|
||||
</menu>
|
||||
<separator />
|
||||
<menuitem name="Select All" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="Preferences..." onclick="DoPreferences();"/>
|
||||
</menu>
|
||||
|
||||
<menu name="View">
|
||||
<menuitem name="Toolbars" onclick="BrowserReload();"/>
|
||||
<menuitem name="Sidebar" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="Enlarge Text Size" onclick="BrowserReload();"/>
|
||||
<menuitem name="Reduce Text Size" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menu name="Use Stylesheet" onclick="BrowserReload();">
|
||||
<menuitem name="Default" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="Easy Reading" onclick="BrowserReload();"/>
|
||||
<menuitem name="Maximum Information" onclick="BrowserReload();"/>
|
||||
<menuitem name="Bizarre" onclick="BrowserReload();"/>
|
||||
</menu>
|
||||
<separator />
|
||||
<menuitem name="Reload" onclick="BrowserReload();"/>
|
||||
<menuitem name="Show Images" onclick="BrowserReload();"/>
|
||||
<menuitem name="Stop" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="Page Source" onclick="BrowserReload();"/>
|
||||
<menuitem name="Page Info" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menu name="Translate">
|
||||
<menuitem name="French To English" onclick="BrowserReload();"/>
|
||||
<menuitem name="German To English" onclick="BrowserReload();"/>
|
||||
<menuitem name="Spanish To English" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="English To French" onclick="BrowserReload();"/>
|
||||
<menuitem name="German To French" onclick="BrowserReload();"/>
|
||||
<menuitem name="Spanish To French" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="English To German" onclick="BrowserReload();"/>
|
||||
<menuitem name="French To German" onclick="BrowserReload();"/>
|
||||
<menuitem name="Spanish To German" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="English To Spanish" onclick="BrowserReload();"/>
|
||||
<menuitem name="French To Spanish" onclick="BrowserReload();"/>
|
||||
<menuitem name="German To Spanish" onclick="BrowserReload();"/>
|
||||
</menu>
|
||||
<menu name="Character Set">
|
||||
<menuitem name="Latin1" onclick="BrowserSetDocumentCharacterSet('ISO-8859-1');"/>
|
||||
<menuitem name="ISO-2022-JP" onclick="BrowserSetDocumentCharacterSet('ISO-2022-JP');"/>
|
||||
<menuitem name="Shift_JIS" onclick="BrowserSetDocumentCharacterSet('Shift_JIS');"/>
|
||||
<menuitem name="EUC-JP" onclick="BrowserSetDocumentCharacterSet('EUC-JP');"/>
|
||||
</menu>
|
||||
</menu>
|
||||
<menu name="Search">
|
||||
<menuitem name="Find On This page..." onclick="BrowserReload();"/>
|
||||
<menuitem name="Find Again" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="Search Parent Item..." onclick="BrowserReload();"/>
|
||||
<menuitem name="Search Parent2 Item..." onclick="BrowserReload();"/>
|
||||
<menuitem name="App Specific" onclick="BrowserReload();"/>
|
||||
<menuitem name="App Specific" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="Search The Internet..." onclick="BrowserReload();"/>
|
||||
<menuitem name="Search All Mail..." onclick="BrowserReload();"/>
|
||||
<menuitem name="Search Bookmarks" onclick="BrowserReload();"/>
|
||||
<menuitem name="Search People" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="Search On This Computer..." onclick="BrowserReload();"/>
|
||||
</menu>
|
||||
<menu name="Go">
|
||||
<menuitem name="Back" onclick="BrowserBack();"/>
|
||||
<menuitem name="Forward" onclick="BrowserForward();" />
|
||||
<menuitem name="Home" onclick="BrowserHome();"/>
|
||||
<separator />
|
||||
<menuitem name="Previous Site 1" onclick="BrowserBack();"/>
|
||||
<menuitem name="Previous Site 2" onclick="BrowserBack();"/>
|
||||
<menuitem name="Previous Site n" onclick="BrowserBack();"/>
|
||||
</menu>
|
||||
<menu name="Bookmarks" onclick="OpenBookmarkURL(event.target)"
|
||||
datasources="rdf:bookmarks" id="NC:BookmarksRoot" open="true">
|
||||
<menuitem name="Add Current Page" onclick="BrowserAddBookmark(window.frames[0].location.href,window.frames[0].document.title);"/>
|
||||
<menuitem name="Manage Bookmarks..." onclick="BrowserEditBookmarks();"/>
|
||||
<separator/>
|
||||
</menu>
|
||||
<menu name="Tasks">
|
||||
<menuitem name="Navigator" onclick="BrowserReload();"/>
|
||||
<menuitem name="Messenger" onclick="OpenMessenger();" />
|
||||
<menuitem name="Editor" onclick="OpenEditor();" />
|
||||
<menuitem name="Chat" onclick="BrowserReload();"/>
|
||||
<menuitem name="Shopping Cart" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="Services A" onclick="BrowserReload();"/>
|
||||
<menuitem name="Services B" onclick="BrowserReload();" />
|
||||
<menuitem name="Services C" onclick="BrowserReload();"/>
|
||||
<menuitem name="Services D" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menu name="Tools">
|
||||
<menuitem name="Plugins Info" onclick="BrowserReload();"/>
|
||||
<menuitem name="Server Tools" onclick="BrowserReload();" />
|
||||
<menuitem name="Java/JS Console" onclick="BrowserReload();"/>
|
||||
<menuitem name="JavaScript Debugger" onclick="BrowserReload();"/>
|
||||
</menu>
|
||||
<separator />
|
||||
<menuitem name="Security Info" onclick="BrowserReload();"/>
|
||||
<separator/>
|
||||
<menuitem name="Window 1" onclick="BrowserReload();" key="1"/>
|
||||
<menuitem name="Window 2" onclick="BrowserReload();" />
|
||||
<menuitem name="Window 3" onclick="BrowserReload();" />
|
||||
</menu>
|
||||
|
||||
<menu name="Help">
|
||||
<menuitem name="Help Contents" onclick="BrowserReload();"/>
|
||||
<separator />
|
||||
<menuitem name="How To Tutorial" onclick="BrowserReload();"/>
|
||||
<menuitem name="Help Channel" onclick="BrowserReload();" />
|
||||
<separator />
|
||||
<menuitem name="Software Updates" onclick="BrowserReload();"/>
|
||||
<menuitem name="Technical Support" onclick="BrowserReload();"/>
|
||||
<menuitem name="Release Notes"
|
||||
onclick="window.frames[0].location.href='http://www.mozilla.org/projects/seamonkey/release-notes/index.html'"/>
|
||||
|
||||
<separator />
|
||||
<menuitem name="About Communicator Prototype"
|
||||
onclick="window.frames[0].location.href='http://www.mozilla.org/projects/seamonkey/release-notes/index.html'"/>
|
||||
</menu>
|
||||
|
||||
// Menu for testing.
|
||||
<menu name="Debug">
|
||||
|
||||
<menu name="Verification"> // Build verification sites.
|
||||
<menuitem name="Mozilla" onclick="window.frames[0].location.href='http://www.mozilla.org'"/>
|
||||
<menuitem name="Yahoo" onclick="window.frames[0].location.href='http://www.yahoo.com'"/>
|
||||
<menuitem name="Netscape" onclick="window.frames[0].location.href='http://www.netscape.com'"/>
|
||||
</menu>
|
||||
|
||||
<menu name="Viewer"> // Viewer tests.
|
||||
<menuitem name="Demo #0" onclick="window.frames[0].location.href='resource:/res/samples/test0.html'"/>
|
||||
<menuitem name="Demo #1" onclick="window.frames[0].location.href='resource:/res/samples/test1.html'"/>
|
||||
<menuitem name="Demo #2" onclick="window.frames[0].location.href='resource:/res/samples/test2.html'"/>
|
||||
<menuitem name="Demo #3" onclick="window.frames[0].location.href='resource:/res/samples/test3.html'"/>
|
||||
<menuitem name="Demo #4" onclick="window.frames[0].location.href='resource:/res/samples/test4.html'"/>
|
||||
<menuitem name="Demo #5" onclick="window.frames[0].location.href='resource:/res/samples/test5.html'"/>
|
||||
<menuitem name="Demo #6" onclick="window.frames[0].location.href='resource:/res/samples/test6.html'"/>
|
||||
<menuitem name="Demo #7" onclick="window.frames[0].location.href='resource:/res/samples/test7.html'"/>
|
||||
<menuitem name="Demo #8" onclick="window.frames[0].location.href='resource:/res/samples/test8.html'"/>
|
||||
<menuitem name="Demo #9" onclick="window.frames[0].location.href='resource:/res/samples/test9.html'"/>
|
||||
<menuitem name="Demo #10" onclick="window.frames[0].location.href='resource:/res/samples/test10.html'"/>
|
||||
<menuitem name="Demo #11" onclick="window.frames[0].location.href='resource:/res/samples/test11.html'"/>
|
||||
<menuitem name="Demo #12" onclick="window.frames[0].location.href='resource:/res/samples/test12.html'"/>
|
||||
<menuitem name="Demo #13" onclick="window.frames[0].location.href='resource:/res/samples/test13.html'"/>
|
||||
</menu>
|
||||
|
||||
<menu name="XPToolkit"> // XPToolkit tests.
|
||||
<menuitem name="Toolbar" onclick="window.frames[0].location.href='resource:/res/samples/toolbarTest1.xul'"/>
|
||||
<menuitem name="Tree" onclick="window.frames[0].location.href='resource:/res/samples/treeTest1.xul'"/>
|
||||
</menu>
|
||||
|
||||
</menu>
|
||||
|
||||
</menubar>
|
||||
|
||||
<vbox id="outer-box">
|
||||
<hbox style="margin: 5px;">
|
||||
<vbox flex="100%">
|
||||
<spacer flex="100%"/>
|
||||
<html:input id="urlbar" type="text" style="min-width: 100px; min-height: 25px"
|
||||
onkeyup="if (event.keyCode == 13) { BrowserLoadURL(); }"/>
|
||||
<spacer flex="100%"/>
|
||||
</vbox>
|
||||
<button id="Throbber" onclick="window.frames[0].home()">
|
||||
<observes element="Browser:Throbber" attribute="busy"/>
|
||||
</button>
|
||||
</hbox>
|
||||
|
||||
<hbox flex="100%">
|
||||
|
||||
<toolbox orient="horizontal">
|
||||
<toolbar class="main-bar" orient="vertical">
|
||||
<button id="back-button" align="bottom" label="Back" onclick="BrowserBack()">
|
||||
<observes element="canGoBack" attribute="disabled"/>
|
||||
</button>
|
||||
|
||||
<button id="forward-button" align="bottom" label="Forward"
|
||||
onclick="BrowserForward()">
|
||||
<observes element="canGoForward" attribute="disabled"/>
|
||||
</button>
|
||||
|
||||
<button id="reload-button" align="bottom" label="Reload"
|
||||
onclick="window.frames[0].location.reload()">
|
||||
<observes element="canReload" attribute="disabled"/>
|
||||
</button>
|
||||
|
||||
<button id="stop-button" align="bottom" label="Stop"
|
||||
onclick="window.frames[0].stop()">
|
||||
<observes element="canStop" attribute="disabled"/>
|
||||
</button>
|
||||
|
||||
<button id="print-button" align="bottom" label="Print"
|
||||
onclick="">
|
||||
<observes element="canPrint" attribute="disabled"/>
|
||||
</button>
|
||||
|
||||
</toolbar>
|
||||
|
||||
<toolbar class="main-bar" orient="vertical">
|
||||
<button id="home-button" align="bottom" label="Home"
|
||||
onclick="BrowserHome()"/>
|
||||
<button id="netscape-button" align="bottom" label="Netscape"
|
||||
onclick="window.frames[0].location.href='http://my.netscape.com'"/>
|
||||
<spacer flex="100%"/>
|
||||
</toolbar>
|
||||
</toolbox>
|
||||
|
||||
|
||||
|
||||
<html:iframe id="content-frame" name="content" src="BrowserInitPage.html" flex="100%" />
|
||||
</hbox>
|
||||
|
||||
<script>
|
||||
var bindCount = 0;
|
||||
function onStatus() {
|
||||
var status = document.getElementById("Browser:Status");
|
||||
if ( status ) {
|
||||
var text = status.getAttribute("text");
|
||||
var statusText = document.getElementById("statusText");
|
||||
if ( statusText ) {
|
||||
statusText.setAttribute( "label", text );
|
||||
}
|
||||
/*
|
||||
if ( bindCount == 0 ) {
|
||||
// This presumably precedes the first onStartBinding, spin
|
||||
// the progress meter.
|
||||
var meter = document.getElementById("Browser:LoadingProgress");
|
||||
if ( meter ) {
|
||||
meter.setAttribute( "mode", "undetermined" );
|
||||
}
|
||||
}
|
||||
*/
|
||||
} else {
|
||||
dump("Can't find status broadcaster!\n");
|
||||
}
|
||||
}
|
||||
|
||||
function onSecurity() {
|
||||
var security = document.getElementById("Browser:Security");
|
||||
var indicator = document.getElementById("security-box");
|
||||
var icon = document.getElementById("security-button");
|
||||
|
||||
if ( security.getAttribute("secure") == "true" ) {
|
||||
indicator.setAttribute("class","secure");
|
||||
icon.setAttribute("class","secure");
|
||||
} else {
|
||||
indicator.setAttribute("class","insecure");
|
||||
icon.setAttribute("class","insecure");
|
||||
}
|
||||
}
|
||||
|
||||
function securityOn() {
|
||||
var security = document.getElementById("Browser:Security");
|
||||
if ( security.getAttribute("secure") == "false" ) {
|
||||
security.setAttribute("secure","true");
|
||||
// Temporary till onchange handlers work.
|
||||
onSecurity();
|
||||
}
|
||||
}
|
||||
function securityOff() {
|
||||
var security = document.getElementById("Browser:Security");
|
||||
if ( security.getAttribute("secure") == "true" ) {
|
||||
security.setAttribute("secure","false");
|
||||
// Temporary till onchange handlers work.
|
||||
onSecurity();
|
||||
}
|
||||
}
|
||||
function doTests() {
|
||||
// Turn security on.
|
||||
securityOn();
|
||||
}
|
||||
function onStartBinding() {
|
||||
bindCount++;
|
||||
if ( bindCount == 1 ) {
|
||||
// Something is going on, turn on progress meter.
|
||||
var meter = document.getElementById("Browser:LoadingProgress");
|
||||
if ( meter ) {
|
||||
meter.setAttribute( "mode", "undetermined" );
|
||||
}
|
||||
}
|
||||
}
|
||||
function onStopBinding() {
|
||||
bindCount--;
|
||||
if ( bindCount < 0 ) {
|
||||
// Something unusual occurred (stop/back?).
|
||||
bindCount = 0;
|
||||
}
|
||||
var stop = document.getElementById("Browser:OnStopBinding");
|
||||
if ( bindCount == 0 ) {
|
||||
// Turn off progress meter.
|
||||
var meter = document.getElementById("Browser:LoadingProgress");
|
||||
var status = document.getElementById("Browser:Status");
|
||||
status.setAttribute("label","Document: Done");
|
||||
meter.setAttribute("value","0");
|
||||
meter.setAttribute("mode","normal");
|
||||
}
|
||||
}
|
||||
function onProgress() {
|
||||
var throbber = document.getElementById("Browser:Throbber");
|
||||
var meter = document.getElementById("Browser:LoadingProgress");
|
||||
if ( throbber && meter ) {
|
||||
var busy = throbber.getAttribute("busy");
|
||||
if ( busy == "true" ) {
|
||||
mode = "undetermined";
|
||||
} else {
|
||||
mode = "normal";
|
||||
}
|
||||
meter.setAttribute("mode",mode);
|
||||
if ( mode == "normal" ) {
|
||||
var status = document.getElementById("Browser:Status");
|
||||
if ( status ) {
|
||||
status.setAttribute("label","Document: Done");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
function dumpProgress() {
|
||||
var broadcaster = document.getElementById("Browser:LoadingProgress");
|
||||
var meter = document.getElementById("meter");
|
||||
dump( "bindCount=" + bindCount + "\n" );
|
||||
dump( "broadcaster mode=" + broadcaster.getAttribute("mode") + "\n" );
|
||||
dump( "broadcaster value=" + broadcaster.getAttribute("value") + "\n" );
|
||||
dump( "meter mode=" + meter.getAttribute("mode") + "\n" );
|
||||
dump( "meter value=" + meter.getAttribute("value") + "\n" );
|
||||
}
|
||||
</script>
|
||||
|
||||
<hbox id="status-bar">
|
||||
|
||||
<broadcaster id="Browser:LoadingProgress"/>
|
||||
<broadcaster id="Browser:Status"/>
|
||||
<broadcaster id="Browser:OnStartBinding"/>
|
||||
<broadcaster id="Browser:OnStopBinding"/>
|
||||
<broadcaster id="Browser:Security" secure="false"/>
|
||||
<broadcaster id="Browser:Throbber" busy="false"/>
|
||||
|
||||
<button label="[Notification Component]" onclick="doTests()"/>
|
||||
|
||||
<hbox id="security-box" class="insecure" flex="100%">
|
||||
<vbox style="width:100px">
|
||||
<spacer flex="100%"/>
|
||||
<progressmeter id="statusbar-icon" mode="normal" value="0" onclick="dumpProgress()">
|
||||
<observes element="Browser:LoadingProgress" attribute="mode"/>
|
||||
<observes element="Browser:Throbber" attribute="busy" onbroadcast="onProgress()"/>
|
||||
</progressmeter>
|
||||
<spacer flex="100%"/>
|
||||
</vbox>
|
||||
|
||||
<button id="statusText" align="right" flex="1%" label="Document: Done" style="font-family:sans-serif;font-size:2.5mm">
|
||||
<observes element="Browser:Status" attribute="label" onbroadcast="onStatus()"/>
|
||||
</button>
|
||||
|
||||
<spacer flex="100%"/>
|
||||
|
||||
<button align="right" label="Build ID: 99032911" style="font-family:sans-serif;font-size:2.5mm">
|
||||
</button>
|
||||
|
||||
<button id="security-button" class="insecure" label="Secure Conn" align="right" onclick="securityOff();"/>
|
||||
</hbox>
|
||||
</hbox>
|
||||
|
||||
<toolbox>
|
||||
<toolbar id="taskbar">
|
||||
<hbox>
|
||||
<button align="left" class="popup" label="Web" />
|
||||
<button align="left" class="popup" label="Mail" />
|
||||
<button align="left" class="popup" label="Chat" />
|
||||
</hbox>
|
||||
<spacer flex="100%"/>
|
||||
<hbox>
|
||||
<button align="left" class="popup" label="DayPlanner" />
|
||||
<button align="left" class="popup" label="Shopping" />
|
||||
<button align="left" class="popup" label="My Desk" />
|
||||
</hbox>
|
||||
<spacer flex="100%"/>
|
||||
<hbox>
|
||||
<button align="left" class="popup" label="Open Windows" />
|
||||
<button align="left" id="mini-nav" label="" />
|
||||
<button align="left" id="mini-mail" label="" onclick="OpenMessenger()"/>
|
||||
<button align="left" id="mini-addr" label="" />
|
||||
<button align="left" id="mini-comp" label="" />
|
||||
</hbox>
|
||||
</toolbar>
|
||||
</toolbox>
|
||||
</vbox>
|
||||
</window>
|
@ -1,20 +0,0 @@
|
||||
function onerror(msg, URL, lineNum) {
|
||||
var errWind = window.open("","errors","HEIGHT=270,WIDTH=400");
|
||||
var wintxt = "<HTML><BODY BGCOLOR=RED>";
|
||||
wintxt += "<B>An error has occurred on this page.</B>";
|
||||
|
||||
wintxt += "<FORM METHOD=POST ENCTYPE='text-plain'>";
|
||||
|
||||
wintxt += "<TEXTAREA COLS=45 ROWS=8 WRAP=VIRTUAL>";
|
||||
wintxt += "Error: " + msg + "\n";
|
||||
wintxt += "URL: " + URL + "\n";
|
||||
wintxt += "Line: " + lineNum + "\n";
|
||||
wintxt += "Client: " + navigator.userAgent + "\n";
|
||||
wintxt += "-----------------------------------------\n";
|
||||
wintxt += "</TEXTAREA><P>";
|
||||
wintxt += "<INPUT TYPE=button VALUE='Close' onClick='self.close()'>";
|
||||
wintxt += "</FORM></BODY></HTML>";
|
||||
errWind.document.write(wintxt);
|
||||
errWind.document.close();
|
||||
return true;
|
||||
}
|
Before Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 56 B |
Before Width: | Height: | Size: 65 B |
Before Width: | Height: | Size: 56 B |
Before Width: | Height: | Size: 64 B |
Before Width: | Height: | Size: 67 B |
Before Width: | Height: | Size: 64 B |
Before Width: | Height: | Size: 56 B |
Before Width: | Height: | Size: 65 B |
Before Width: | Height: | Size: 56 B |
@ -1,49 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
|
||||
<!DOCTYPE window>
|
||||
|
||||
<window xmlns:html="http://www.w3.org/1999/xhtml"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<script>
|
||||
function applySkin(url)
|
||||
{
|
||||
dump("Retrieving data source.\n");
|
||||
var ds = document.rdf.GetDataSource("rdf:chrome");
|
||||
|
||||
dump("Getting the source.\n");
|
||||
var s = document.rdf.GetResource("chrome://navigator/skin/navigator.css");
|
||||
|
||||
dump("Getting the property.\n");
|
||||
var p = document.rdf.GetResource("http://chrome.mozilla.org/rdf#main");
|
||||
|
||||
dump("Getting the original target.\n");
|
||||
var originalTarget = ds.GetTarget(s, p, true);
|
||||
|
||||
dump("Doing the unassert.\n");
|
||||
ds.Unassert(s, p, originalTarget);
|
||||
|
||||
dump("Getting the literal.\n");
|
||||
var newTarget = document.rdf.GetLiteral(url);
|
||||
|
||||
dump("Doing the assert.\n");
|
||||
ds.Assert(s, p, newTarget, true);
|
||||
|
||||
dump("Saving the chrome to disk.\n");
|
||||
ds.Flush();
|
||||
|
||||
dump("Done. Open a new window to see the chrome.\n");
|
||||
}
|
||||
</script>
|
||||
|
||||
<html:button onclick="applySkin('navigator-mozillazine0.css')">
|
||||
Click to switch to MozillaZine skin.
|
||||
</html:button>
|
||||
|
||||
<html:button onclick="applySkin('navigator.css')">
|
||||
Click to switch to default skin.
|
||||
</html:button>
|
||||
|
||||
|
||||
</window>
|
@ -1,48 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
|
||||
<!-- <!DOCTYPE window> -->
|
||||
|
||||
<window xmlns:html="http://www.w3.org/1999/xhtml"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<script>
|
||||
var mode = "undetermined";
|
||||
function kickProgressMeter() {
|
||||
var meter = document.getElementById("Browser:LoadingProgress");
|
||||
dump( "Meter was mode=" + meter.getAttribute("mode") + " value=" + meter.getAttribute("value") + "\n" );
|
||||
if ( mode == "undetermined" ) {
|
||||
mode = "normal";
|
||||
var random = Math.round( Math.random() * 100 )
|
||||
dump("Setting meter to (" + mode + ") " + random.toString() + "\n" );
|
||||
meter.setAttribute( "value", random.toString() );
|
||||
} else {
|
||||
mode = "undetermined";
|
||||
dump("Setting meter to (undetermined)\n");
|
||||
}
|
||||
meter.setAttribute( "mode", mode );
|
||||
}
|
||||
</script>
|
||||
|
||||
<broadcaster id="Browser:LoadingProgress"/>
|
||||
|
||||
<html:center>
|
||||
<html:table border="" cols="3" width="99%" style="color-background:rgb(192,192,192);">
|
||||
<html:tr>
|
||||
<html:td width="3%" nowrap="" style="border: 1px inset rgb(192,192,192);">
|
||||
<html:button onclick="kickProgressMeter()" height="12">
|
||||
X
|
||||
</html:button>
|
||||
</html:td>
|
||||
<html:td width="15%" nowrap="" style="border: 1px inset rgb(192,192,192);">
|
||||
<progressmeter id="meter" mode="normal" value="61">
|
||||
<observes element="Browser:LoadingProgress" attribute="value" />
|
||||
<observes element="Browser:LoadingProgress" attribute="mode" />
|
||||
</progressmeter>
|
||||
</html:td>
|
||||
<html:td width="82%" nowrap="" style="border: 1px inset rgb(192,192,192);">
|
||||
Document: Done (even a stopped clock is right twice a day)
|
||||
</html:td>
|
||||
</html:tr>
|
||||
</html:table>
|
||||
</html:center>
|
||||
</window>
|