zotero/chrome/chromeFiles/content/scholar/overlay.xul
Dan Stillman f07ff9ac2a Renamed "Files" to "Attachments" -- since Files could be links as well as actually files (or both, for web page snapshots), things were getting just about as confusing as when Items were called Objects.
If you have attachments to the old terminology, feel free to file a complaint.

Changed interface code too, since David is gone (or at the very least has more important things to do with his remaining time)
2006-08-12 00:18:20 +00:00

233 lines
No EOL
11 KiB
XML

<?xml version="1.0"?>
<!--
Scholar
Copyright (C) 2006 Center for History and New Media, George Mason University, Fairfax, VA
http://chnm.gmu.edu/
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-->
<?xml-stylesheet href="chrome://scholar/skin/overlay.css" type="text/css"?>
<!DOCTYPE window SYSTEM "chrome://scholar/locale/scholar.dtd">
<overlay id="scholar"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
<?xul-overlay href="itemPane.xul" ?>
<!-- Include the global XPCOM object -->
<script src="include.js"/>
<script src="overlay.js"/>
<script src="itemTreeView.js"/>
<script src="collectionTreeView.js"/>
<script src="fileInterface.js"/>
<commandset id="mainCommandSet">
<command id="cmd_scholar_newItem" oncommand="ScholarPane.newItem(2);"/>
<command id="cmd_scholar_newCollection" oncommand="ScholarPane.newCollection();"/>
<command id="cmd_scholar_search" oncommand="ScholarPane.search();"/>
</commandset>
<toolbarpalette id="BrowserToolbarPalette">
<toolbarbutton id="scholar-toolbar-button" class="toolbarbutton-1"
label="&scholar.name;"
oncommand="ScholarPane.toggleDisplay();"/>
</toolbarpalette>
<vbox id="appcontent">
<!-- Changes to attributes of scholar-splitter and scholar-pane must be mirrored on overlay.js's onLoad() function -->
<splitter id="scholar-splitter" resizebefore="closest" resizeafter="closest" collapsed="true"/>
<hbox id="scholar-pane" persist="height" collapsed="true" flex="1">
<popupset>
<popup id="scholar-collectionmenu" onpopupshowing="ScholarPane.buildCollectionContextMenu();">
<menuitem label="&toolbar.newCollection.label;" command="cmd_scholar_newCollection"/>
<menuseparator/>
<menuitem label="&toolbar.renameCollection.label;" oncommand="ScholarPane.renameSelectedCollection();"/>
<menuitem label="&toolbar.removeCollection.label;" oncommand="ScholarPane.deleteSelectedCollection();"/>
<menuseparator/>
<menuitem label="&toolbar.exportCollection.label;" oncommand="Scholar_File_Interface.exportProject();"/>
<menuitem label="&toolbar.createBibCollection.label;" oncommand="Scholar_File_Interface.bibliographyFromProject();"/>
</popup>
<popup id="scholar-itemmenu" onpopupshowing="ScholarPane.buildItemContextMenu();">
<menuitem label="&toolbar.newItem.label;" command="cmd_scholar_newItem"/>
<menuseparator/>
<menuitem oncommand="ScholarPane.deleteSelectedItem();"/>
<menuseparator/>
<menuitem oncommand="Scholar_File_Interface.exportItems();"/>
<menuitem oncommand="Scholar_File_Interface.bibliographyFromItems();"/>
</popup>
</popupset>
<vbox id="collections-pane" persist="width" flex="1">
<toolbar>
<toolbarbutton id="tb-collection-add" tooltiptext="&toolbar.newCollection.label;" command="cmd_scholar_newCollection"/>
<toolbarbutton id="tb-collection-addsearch" tooltiptext="&toolbar.newSearch.label;" oncommand="ScholarPane.newSearch();"/>
<toolbarbutton id="tb-collection-rename" tooltiptext="&toolbar.renameCollection.label;" oncommand="ScholarPane.renameSelectedCollection();" disabled="true"/>
<spacer flex="1"/>
<toolbarbutton id="tb-collection-menu" type="menu">
<menupopup>
<menuitem label="&toolbar.import.label;" oncommand="Scholar_File_Interface.importFile();"/>
<menuitem label="&toolbar.export.label;" oncommand="Scholar_File_Interface.exportFile();"/>
</menupopup>
</toolbarbutton>
</toolbar>
<tree id="collections-tree" hidecolumnpicker="true" context="scholar-collectionmenu"
onselect="ScholarPane.onCollectionSelected();" seltype="single"
ondragdrop="nsDragAndDrop.drop(event,ScholarPane.getCollectionsView())"
ondraggesture="if (event.target.localName == 'treechildren') nsDragAndDrop.startDrag(event,ScholarPane.getCollectionsView());"
onkeypress="if(event.keyCode == event.DOM_VK_BACK_SPACE){ ScholarPane.deleteSelectedCollection(); return false; }"
flex="1">
<treecols>
<treecol
id="name_column"
label="&collections.name_column;"
flex="1"
primary="true"/>
</treecols>
<treechildren/>
</tree>
</vbox>
<splitter id="scholar-tree-splitter" resizebefore="closest" resizeafter="closest"/>
<vbox id="items-pane" persist="width" flex="1">
<toolbar align="center">
<toolbarbutton id="tb-add" tooltiptext="&toolbar.newItem.label;" type="menu">
<menupopup/>
</toolbarbutton>
<toolbarbutton id="tb-attachment-add" type="menu" tooltiptext="&toolbar.attachment.standalone;">
<menupopup>
<menuitem label="&toolbar.attachment.linked;" oncommand="ScholarPane.addAttachmentFromDialog(true);"/>
<menuitem label="&toolbar.attachment.add;" oncommand="ScholarPane.addAttachmentFromDialog();"/>
<menuitem label="&toolbar.attachment.weblink;" oncommand="ScholarPane.addAttachmentFromPage(true);"/>
<menuitem label="&toolbar.attachment.snapshot;" oncommand="ScholarPane.addAttachmentFromPage();"/>
</menupopup>
</toolbarbutton>
<toolbarbutton id="tb-note-add" tooltiptext="&toolbar.note.standalone;" oncommand="ScholarPane.newNote();"/>
<spacer flex="1"/>
<label value="&toolbar.search.label;" control="tb-search"/>
<textbox id="tb-search" type="timed" timeout="250" command="cmd_scholar_search" dir="reverse" onkeypress="if(event.keyCode == event.DOM_VK_ESCAPE) { this.value = ''; this.doCommand('cmd_scholar_search'); return false; }">
<toolbarbutton id="tb-search-cancel" oncommand="this.parentNode.value='';" hidden="true"/>
</textbox>
</toolbar>
<tree
id="items-tree" context="scholar-itemmenu"
ondblclick="ScholarPane.onDoubleClick(event, this);"
enableColumnDrag="true" onkeypress="if(event.keyCode == event.DOM_VK_BACK_SPACE){ ScholarPane.deleteSelectedItem(); return false; }"
onselect="ScholarPane.itemSelected();"
ondraggesture="if (event.target.localName == 'treechildren') nsDragAndDrop.startDrag(event,ScholarPane.getItemsView());"
ondragover="nsDragAndDrop.dragOver(event,ScholarPane.getItemsView())"
ondragdrop="nsDragAndDrop.drop(event,ScholarPane.getItemsView())"
flex="1">
<treecols>
<treecol
id="title" primary="true"
label="&items.title_column;"
flex="4" persist="width ordinal hidden sortActive sortDirection"/>
<splitter class="tree-splitter"/>
<treecol
id="firstCreator"
label="&items.creator_column;"
flex="1" persist="width ordinal hidden sortActive sortDirection"/>
<splitter class="tree-splitter"/>
<treecol
id="numNotes"
label="&items.numNotes_column;"
persist="width ordinal hidden sortActive sortDirection"/>
<splitter class="tree-splitter"/>
<treecol
id="typeIcon" hidden="true"
label="&items.type_column;"
width="40" persist="width ordinal hidden sortActive sortDirection"/>
<splitter class="tree-splitter"/>
<treecol
id="source" hidden="true"
label="&items.source_column;"
flex="1" persist="width ordinal hidden sortActive sortDirection"/>
<splitter class="tree-splitter"/>
<treecol
id="rights" hidden="true"
label="&items.rights_column;"
flex="1" persist="width ordinal hidden sortActive sortDirection"/>
<splitter class="tree-splitter"/>
<treecol
id="dateAdded" hidden="true"
label="&items.dateAdded_column;"
flex="1" persist="width ordinal hidden sortActive sortDirection"/>
<splitter class="tree-splitter"/>
<treecol
id="dateModified" hidden="true"
label="&items.dateModified_column;"
flex="1" persist="width ordinal hidden sortActive sortDirection"/>
</treecols>
<treechildren/>
</tree>
</vbox>
<splitter id="scholar-view-splitter" resizebefore="closest" resizeafter="closest"/>
<vbox>
<toolbar align="right">
<toolbarbutton id="tb-fullscreen" tooltiptext="&toolbar.fullscreen.tooltip;" oncommand="ScholarPane.fullScreen();"/>
<toolbarbutton class="tabs-closebutton" oncommand="ScholarPane.toggleDisplay()"/>
</toolbar>
<groupbox flex="1">
<caption>
<tabs id="scholar-view-tabs" onselect="document.getElementById('scholar-view-item').selectedIndex = this.selectedIndex;" hidden="true">
<tab label="&tabs.info.label;"/>
<tab label="&tabs.notes.label;"/>
<tab label="&tabs.attachments.label;"/>
<tab label="&tabs.tags.label;"/>
<tab label="&tabs.related.label;"/>
</tabs>
</caption>
<deck id="item-pane" selectedIndex="0" flex="1" onselect="document.getElementById('scholar-view-tabs').setAttribute('hidden',(this.selectedIndex != 1));">
<box pack="center" align="center">
<label id="scholar-view-selected-label"/>
</box>
<deck id="scholar-view-item" flex="1"/>
<vbox id="scholar-view-note" flex="1">
<noteeditor id="scholar-note-editor" flex="1"/>
<button id="scholar-view-note-button" label="&notes.separate;" oncommand="ScholarPane.openNoteWindow(this.getAttribute('noteID')); if(this.hasAttribute('sourceID')) ScholarPane.selectItem(this.getAttribute('sourceID'));"/>
</vbox>
<vbox id="scholar-view-attachment" flex="1">
<label id="scholar-attachment-label"/>
<button id="scholar-attachment-view" label="View Attachment" oncommand="ScholarPane.viewSelectedAttachment();"/>
<linksbox id="scholar-attachment-links" flex="1"/>
</vbox>
</deck>
</groupbox>
</vbox>
</hbox>
</vbox>
<statusbar id="status-bar">
<statusbarpanel id="scholar-load-status" label="Scholar is NOT loaded" onclick="ScholarPane.toggleDisplay();"/>
</statusbar>
<script>
window.addEventListener('load', function(e){
if (Scholar){
document.getElementById('scholar-load-status').setAttribute('label', 'Scholar is loaded');
}
}, false);
</script>
<menupopup id="menu_ToolsPopup">
<menuseparator id="scholarSeparator" insertbefore="devToolsSeparator"/>
<menuitem id="tools-scholar" insertbefore="devToolsSeparator"
oncommand="ScholarPane.toggleDisplay();" label="&scholar.name;"
key="key_openScholar"/>
</menupopup>
<keyset id="mainKeyset">
<key id="key_openScholar"
key="S"
oncommand="ScholarPane.toggleDisplay();"
modifiers="shift accel" />
</keyset>
</overlay>