<?xml version="1.0"?>

<bindings id="htmlBindings"
   xmlns="http://www.mozilla.org/xbl"
   xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
 
  <binding id="inputFields" extends="chrome://global/content/htmlBindings.xml#inputFieldsBase">
    <handlers>
      <handler type="keypress" id="key_up" keycode="VK_UP" alt="false" shift="false" control="false"
        command="cmd_charPrevious"/>
      <handler type="keypress" id="key_down" keycode="VK_DOWN" alt="false" shift="false" control="false"
        command="cmd_charNext"/>
      <handler type="keypress" id="key_leftshift" keycode="VK_UP" shift="true" alt="false" control="false"
	      command="cmd_selectCharPrevious"/>
      <handler type="keypress" id="key_rightshift" keycode="VK_DOWN" shift="true" alt="false" control="false"
	      command="cmd_selectCharNext"/>

      <handler type="keypress" id="key_home" keycode="VK_HOME" alt="false" shift="false" control="false"
        command="cmd_beginLine"/>
      <handler type="keypress" id="key_end" keycode="VK_END" alt="false" shift="false" control="false"
        command="cmd_endLine"/>
      <handler type="keypress" id="key_homeshift" keycode="VK_HOME" shift="true" alt="false" control="false"
        command="cmd_selectBeginLine"/>
      <handler type="keypress" id="key_endshift" keycode="VK_END" shift="true" alt="false" control="false"
        command="cmd_selectEndLine"/>
      <handler type="keypress" id="key_leftcontrol" keycode="VK_LEFT" control="true" alt="false" shift="false"
        command="cmd_wordPrevious"/>
      <handler type="keypress" id="key_rightcontrol" keycode="VK_RIGHT" control="true" alt="false" shift="false"
        command="cmd_wordNext"/>
      <handler type="keypress" id="key_leftshiftcontrol" keycode="VK_LEFT" shift="true" control="true" alt="false" 
        command="cmd_selectWordPrevious"/>
      <handler type="keypress" id="key_rightshiftcontrol" keycode="VK_RIGHT" shift="true" control="true" alt="false" 
        command="cmd_selectWordNext"/>
      <handler type="keypress" id="key_redo" key="y" primary="true"
        command="cmd_redo"/>

      <handler type="keypress" id="key_altwincut" keycode="VK_DELETE" shift="true" control="false" alt="false"
        command="cmd_cut"/>
      <handler type="keypress" id="key_altwincopy" keycode="VK_INSERT" control="true" shift="false" alt="false"
        command="cmd_copy"/>
      <handler type="keypress" id="key_altwinpaste" keycode="VK_INSERT" shift="true" control="false" alt="false"
        command="cmd_paste"/>
    </handlers>
  </binding>

  <binding id="textAreas" extends="chrome://global/content/htmlBindings.xml#textAreasBase">
    <handlers>
      <handler type="keypress" id="key_home" keycode="VK_HOME" alt="false" shift="false" control="false"
        command="cmd_beginLine"/>
      <handler type="keypress" id="key_end" keycode="VK_END" alt="false" shift="false" control="false"
        command="cmd_endLine"/>
      <handler type="keypress" id="key_homeshift" keycode="VK_HOME" shift="true" alt="false" control="false"
        command="cmd_selectBeginLine"/>
      <handler type="keypress" id="key_endshift" keycode="VK_END" shift="true" alt="false" control="false"
        command="cmd_selectEndLine"/>
      <handler type="keypress" id="key_leftcontrol" keycode="VK_LEFT" control="true" alt="false" shift="false" 
        command="cmd_wordPrevious"/>
      <handler type="keypress" id="key_rightcontrol" keycode="VK_RIGHT" control="true" alt="false" shift="false" 
        command="cmd_wordNext"/>
      <handler type="keypress" id="key_leftshiftcontrol" keycode="VK_LEFT" shift="true" control="true" alt="false"
        command="cmd_selectWordPrevious"/>
      <handler type="keypress" id="key_rightshiftcontrol" keycode="VK_RIGHT" shift="true" control="true" alt="false"
        command="cmd_selectWordNext"/>
      <handler type="keypress" id="key_redo" key="y" primary="true"
        command="cmd_redo"/>

      <handler type="keypress" id="key_altwincut" keycode="VK_DELETE" shift="true" control="false" alt="false"
        command="cmd_cut"/>
      <handler type="keypress" id="key_altwincopy" keycode="VK_INSERT" control="true" shift="false" alt="false"
        command="cmd_copy"/>
      <handler type="keypress" id="key_altwinpaste" keycode="VK_INSERT" shift="true" control="false" alt="false"
        command="cmd_paste"/>
     </handlers>
  </binding>

</bindings>
