Beautify and tidy up copyright message

This commit is contained in:
Simon Kornblith 2012-04-08 15:24:39 -04:00
parent 3a6b95a0f3
commit 12964b550a
2 changed files with 111 additions and 117 deletions

View File

@ -2,10 +2,16 @@
<!--
***** BEGIN LICENSE BLOCK *****
Copyright © 2009 Center for History and New Media
Copyright © 2012 Center for History and New Media
George Mason University, Fairfax, Virginia, USA
http://zotero.org
The Initial Developer of this code is Gracile. Portions created by the
Initial Developer are Copyright © 2012 the Initial Developer.
This file contains code derived from Mozilla's tree.xml, © 2012 its
developers.
This file is part of Zotero.
Zotero is free software: you can redistribute it and/or modify
@ -39,8 +45,7 @@
<xul:menupopup anonid="zotero-items-column-sub-menu"/>
</xul:menu>
<xul:menuseparator/>
<xul:menuitem anonid="menuitem"
label="&zotero.items.restoreColumnOrder.label;"/>
<xul:menuitem anonid="menuitem" label="&zotero.items.restoreColumnOrder.label;"/>
</xul:menupopup>
</content>
@ -67,19 +72,15 @@
var refChild2 = bPopup.firstChild;
var tree = this.parentNode.parentNode;
for (var currCol = tree.columns.getFirstColumn(); currCol;
currCol = currCol.getNext()) {
for (var currCol = tree.columns.getFirstColumn(); currCol; currCol = currCol.getNext()) {
var currElement = currCol.element;
// Construct an entry for each column in the row, unless
// it is not being shown.
if ((!currElement.hasAttribute("ignoreincolumnpicker")) &&
(!currElement.hasAttribute("submenu"))) {
if ((!currElement.hasAttribute("ignoreincolumnpicker")) && (!currElement.hasAttribute("submenu"))) {
var popupChild = document.createElement("menuitem");
popupChild.setAttribute("type", "checkbox");
var columnName = currElement.getAttribute("display") ||
currElement.getAttribute("label");
var columnName = currElement.getAttribute("display") || currElement.getAttribute("label");
popupChild.setAttribute("label", columnName);
popupChild.setAttribute("colindex", currCol.index);
if (currElement.getAttribute("hidden") != "true") {
@ -92,12 +93,10 @@
}
//Idem for the submenu
if ((!currElement.hasAttribute("ignoreincolumnpicker")) &&
(currElement.hasAttribute("submenu"))) {
if ((!currElement.hasAttribute("ignoreincolumnpicker")) && (currElement.hasAttribute("submenu"))) {
var popupChild = document.createElement("menuitem");
popupChild.setAttribute("type", "checkbox");
var columnName = currElement.getAttribute("display") ||
currElement.getAttribute("label");
var columnName = currElement.getAttribute("display") || currElement.getAttribute("label");
popupChild.setAttribute("label", columnName);
popupChild.setAttribute("colindex", currCol.index);
if (currElement.getAttribute("hidden") != "true") {
@ -115,31 +114,26 @@
<handler event="command">
<![CDATA[
if (event.originalTarget == this) {
var popup = document.getAnonymousElementByAttribute(this, "anonid",
"zotero-items-column-main-menu");
var popup2 = document.getAnonymousElementByAttribute(this, "anonid",
"zotero-items-column-sub-menu");
var popup = document.getAnonymousElementByAttribute(this, "anonid", "zotero-items-column-main-menu");
var popup2 = document.getAnonymousElementByAttribute(this, "anonid", "zotero-items-column-sub-menu");
this.buildPopup(popup, popup2);
popup.showPopup(this, -1, -1, "popup", "bottomright", "topright");
}
else {
} else {
var tree = this.parentNode.parentNode;
tree.stopEditing(true);
var menuitem = document.getAnonymousElementByAttribute(this, "anonid", "menuitem");
if (event.originalTarget == menuitem) {
tree.columns.restoreNaturalOrder();
tree._ensureColumnOrder();
}
else {
} else {
var colindex = event.originalTarget.getAttribute("colindex");
var column = tree.columns[colindex];
if (column) {
var element = column.element;
if (element.getAttribute("hidden") == "true") {
element.setAttribute("hidden", "false");
}
else {
} else {
element.setAttribute("hidden", "true");
}
}

@ -1 +1 @@
Subproject commit afb3b9397b907c78f16694c589553fb767fb40fd
Subproject commit 6dfd753bb5dfabca0837d2b57c93c0c41afa7d0a