mail/components/addrbook/content/abContactsPanel.xul
author Misak Khachatryan <misak.bugzilla@gmail.com>
Tue, 10 Dec 2013 11:18:27 +0400
changeset 16983 63baf8270c1cb8b380784b61c43905c688e051d6
parent 16208 eb2a926e6fb5549425a9c5184486d420a5bda82d
child 17115 f17645888cd0d912f9fc8576addd289b80a8a739
permissions -rw-r--r--
Bug 948293 - Build bustage after bug 713082. r+a=Neil CLOSED TREE

<?xml version="1.0"?>

<!--  -*- Mode: xml; indent-tabs-mode: nil; -*-
   - This Source Code Form is subject to the terms of the Mozilla Public
   - License, v. 2.0. If a copy of the MPL was not distributed with this
   - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->

<?xml-stylesheet href="chrome://messenger/skin/addressbook/abContactsPanel.css" type="text/css"?>

<!DOCTYPE page [
<!ENTITY % abResultsPaneOverlayDTD SYSTEM "chrome://messenger/locale/addressbook/abResultsPaneOverlay.dtd" >
%abResultsPaneOverlayDTD;
<!ENTITY % abContactsPanelDTD SYSTEM "chrome://messenger/locale/addressbook/abContactsPanel.dtd" >
%abContactsPanelDTD;
]>

<page id="abContactsPanel"
      xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
      onload="AbPanelLoad();"
      onunload="AbPanelUnload();"
      selectedaddresses="true">

  <stringbundleset id="stringbundleset">
    <stringbundle id="bundle_addressBook" src="chrome://messenger/locale/addressbook/addressBook.properties"/>
  </stringbundleset>

  <script type="application/javascript" src="chrome://global/content/nsDragAndDrop.js"/>
  <script type="application/javascript" src="chrome://global/content/globalOverlay.js"/>
  <script type="application/javascript" src="chrome://messenger/content/addressbook/addressbook.js"/>
  <script type="application/javascript" src="chrome://messenger/content/addressbook/abDragDrop.js"/>
  <script type="application/javascript" src="chrome://messenger/content/addressbook/abCommon.js"/>
  <script type="application/javascript" src="chrome://messenger/content/addressbook/abResultsPane.js"/>
  <script type="application/javascript" src="chrome://messenger/content/addressbook/abContactsPanel.js"/>

  <command id="cmd_delete" oncommand="goDoCommand('cmd_delete');"/>

  <!-- These keys do not really run any command, but they are used to show
       the hotkeys at the corresponding menuitems -->
  <key id="key_delete" keycode="VK_DELETE"/>

  <menupopup id="cardProperties">
    <menuitem label="&deleteAddrBookCard.label;"
              accesskey="&deleteAddrBookCard.accesskey;"
              key="key_delete"
              command="cmd_delete"/>
    <menuitem label="&addrBookCardProperties.label;"
              accesskey="&addrBookCardProperties.accesskey;"
              oncommand="AbEditSelectedCard();"/>
    <menuseparator/>
    <menuitem label="&addtoToFieldMenu.label;"
              accesskey="&addtoToFieldMenu.accesskey;"
              oncommand="addSelectedAddresses('addr_to');"/>
    <menuitem label="&addtoCcFieldMenu.label;"
              accesskey="&addtoCcFieldMenu.accesskey;"
              oncommand="addSelectedAddresses('addr_cc');"/>
    <menuitem label="&addtoBccFieldMenu.label;"
              accesskey="&addtoBccFieldMenu.accesskey;"
              oncommand="addSelectedAddresses('addr_bcc');"/>
  </menupopup>

  <vbox id="results_box" flex="1">
    <separator class="thin"/>
    <label value="&addressbookPicker.label;" accesskey="&addressbookPicker.accesskey;" control="addressbookList"/>
    <hbox id="panel-bar" class="toolbar" align="center">
      <menulist id="addressbookList"
                oncommand="AddressBookMenuListChange();" flex="1"
                persist="value">
        <menupopup id="addressbookList-menupopup" class="addrbooksPopup"/>
      </menulist>
    </hbox>

    <separator class="thin"/>

    <vbox>
      <label value="&searchInput.label;" accesskey="&searchInput.accesskey;"
             control="peopleSearchInput"/>
      <textbox id="peopleSearchInput" flex="1" type="search" timeout="800"
               placeholder="&SearchNameOrEmail.label;" clickSelectsAll="true"
               oncommand="onEnterInSearchBar();"/>
    </vbox>

    <separator class="thin"/>

    <tree id="abResultsTree" flex="1" context="cardProperties" class="plain" sortCol="GeneratedName" persist="sortCol"
          onclick="contactsListOnClick(event);">
      <treecols>
        <!-- these column ids must match up to the mork column names, see nsIAddrDatabase.idl -->
        <treecol id="GeneratedName"
                 persist="hidden ordinal width sortDirection" flex="1" label="&GeneratedName.label;" primary="true"/>
        <splitter class="tree-splitter"/>
        <treecol id="PrimaryEmail"
                 persist="hidden ordinal width sortDirection" hidden="true"
                 flex="1" label="&PrimaryEmail.label;"/>
      </treecols>
      <treechildren ondraggesture="nsDragAndDrop.startDrag(event, abResultsPaneObserver);"/>
    </tree>

    <separator class="thin"/>

    <hbox>
      <spring flex="1"/>
      <button id="toButton" label="&toButton.label;" accesskey="&toButton.accesskey;" oncommand="addSelectedAddresses('addr_to')"/>
      <spring flex="1"/>
    </hbox>
    <hbox>
      <spring flex="1"/>
      <button id="ccButton" label="&ccButton.label;" accesskey="&ccButton.accesskey;" oncommand="addSelectedAddresses('addr_cc')"/>
      <spacer class="thin"/>
      <button id="bccButton" label="&bccButton.label;" accesskey="&bccButton.accesskey;" oncommand="addSelectedAddresses('addr_bcc')"/>
      <spring flex="1"/>
    </hbox>

    <separator class="thin"/>

  </vbox>
</page>