gecko-dev/extensions/wallet/editor/WalletUrlspecific.xul

115 строки
3.8 KiB
XML

<?xml version="1.0"?>
<!--
The contents of this file are subject to the Netscape Public
License Version 1.1 (the "License"); you may not use this file
except in compliance with the License. You may obtain a copy of
the License at http://www.mozilla.org/NPL/
implied. See the License for the specific language governing
rights and limitations under the License.
The Original Code is Mozilla Communicator client code, released
March 31, 1998.
The Initial Developer of the Original Code is Netscape
Communications Corporation. Portions created by Netscape are
Copyright (C) 1998-1999 Netscape Communications Corporation. All
Rights Reserved.
Contributor(s):
-->
<?xml-stylesheet href="chrome://communicator/skin/" type="text/css"?>
<!DOCTYPE window [
<!ENTITY % brandDTD SYSTEM "chrome://global/locale/brand.dtd" >
%brandDTD;
<!ENTITY % walletviewerDTD SYSTEM "chrome://communicator/locale/wallet/WalletViewer.dtd" >
%walletviewerDTD;
]>
<page xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
onload="generate();">
<script type="application/x-javascript">
<![CDATA[
var _elementIDs = [];
function generate() {
var colonIndex;
for (var schema in parent.schemaToValue) {
colonIndex = schema.indexOf(":");
if (colonIndex != -1) {
var rows = document.getElementById("rows");
var row = document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul", "row");
var text1 = document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul", "textbox");
var text2 = document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul", "textbox");
var menuList = document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul", "menulist");
var menuPopup = document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul", "menupopup");
var menuItem = document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul", "menuitem");
menuPopup.appendChild(menuItem);
menuList.appendChild(menuPopup);
row.appendChild(text1);
row.appendChild(text2);
row.appendChild(menuList);
rows.appendChild(row);
menuItem.setAttribute("label", "");
menuItem.setAttribute("len","0");
menuList.setAttribute("id", schema);
menuList.setAttribute("editable", "true");
menuList.setAttribute("disableautoselect", "true");
menuList.setAttribute("onchange", "Append(this)");
menuList.setAttribute("onmousedown", "Append(this)");
text1.setAttribute("value", schema.substring(0, colonIndex));
text2.setAttribute("value", schema.substring(colonIndex+1, schema.length));
text1.setAttribute("readonly", "true");
text2.setAttribute("readonly", "true");
_elementIDs[_elementIDs.length] = schema;
}
}
parent.initPanel();
}
]]>
</script>
<script type="application/x-javascript"
src="chrome://communicator/content/wallet/WalletViewer.js"/>
<groupbox>
<caption label="&urlspecific.title;"/>
<grid class="indent">
<columns>
<column width="115"/>
<column width="75"/>
<column width="115"/>
</columns>
<rows>
<row>
<label value="&urlspecificUrl.label;"/>
<label value="&urlspecificField.label;"/>
<label value="&urlspecificValue.label;"/>
</row>
</rows>
</grid>
<hbox style="overflow: auto; height: 335px; width: 350px;">
<grid class="indent">
<columns>
<column width="115"/>
<column width="75"/>
<column width="115"/>
</columns>
<rows id="rows">
</rows>
</grid>
</hbox>
</groupbox>
</page>