hterm: Add 'desktop-notification-bell' option.

If true, terminal bells emitted while the terminal does not have focus
trigger web notifications (http://www.w3.org/TR/notifications/).

I've tried to make the behavior relatively unobtrusive: web
notifications respect the audio bell squelch, and are all cleared when
the terminal gets focus or if the user clicks any notification.

BUG=chromium:208710
Change-Id: Ic114e7e71a2ad5d82b13211bf93010b65c5131f3
Reviewed-on: https://chromium-review.googlesource.com/203003
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
Added some support for using default copy handling.

Fixes paste in FF by focusing a content editable element before doing a paste.  Also adds a preference setting to use the default window controlled handling of copy.

Change-Id: Ia95823e801fb113006998014ef3a2f14a6512532
Reviewed-on: https://chromium-review.googlesource.com/203271
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm: Remove extraneous commented-out lines.

I accidentally left these in from
<https://chromium-review.googlesource.com/203003>.

Change-Id: I48aeadd041f3555396accf8f3abbd731165a520e
Reviewed-on: https://chromium-review.googlesource.com/204886
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm: Don't request Notification permission.

Notification.requestPermission is not honored (by Chrome, at least) if
it is not the direct result of a user action, so don't call it. Instead,
log a warning if the pref is turned on but notifications will still not
be displayed. (I added a note about rginda's proposed workaround, as
well.)

Change-Id: I96bd32d440c74d7977cb37b7d0bde357d42ab98b
Reviewed-on: https://chromium-review.googlesource.com/205539
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
Fixes issue in Safari where lib.rtdep was parsing a section of the Error stack that does not exist in Safari.

Change-Id: I6b199a58d7af7090703b87b861606c4893e0b9e4

mend

Change-Id: Ie49548972b352beb79a9e4e34fe1772367fcef93
Reviewed-on: https://chromium-review.googlesource.com/206826
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm 1.42, nassh 0.8.27.9, doc updates

Update the changelogs and nassh/manifest.json.

Change-Id: I88e78478a7f539c34533bfb86e981e98a04d66bf
Reviewed-on: https://chromium-review.googlesource.com/208550
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm 1.43: Implement reverse wraparound.

* Implement reverse wraparound, add a test.

BUG=chromium:393737

Change-Id: I00841d6553408abbeae90d8d51fac9d6b1c7b003
Reviewed-on: https://chromium-review.googlesource.com/208551
Reviewed-by: Marvelous Marius <mschilder@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm: Hide terminal cursor when mouse cursor is over it

This make sure the mouse doesn't get in the way of text selection or
terminal clicks.

BUG=chromium:365910

Change-Id: I65d6b9b5d30ac4e32e69b5cbdc1a39502a34fa93
Reviewed-on: https://chromium-review.googlesource.com/208691
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm: Add cursor-blink-cycle pref

* Add a 'cursor-blink-cycle' preference which can be a number or a
  two-number array.  If two numbers are provided, the first is how
  long a blinking cursor should be on, the second is how long it
  should be off.  If a single number is given it's used for both
  on and off.  Anything else results in a fast blinking cursor.

BUG=chromium:366206

Change-Id: Ib5791ee21d8c5ba9209eb2b34ef86f6d9e9613d4
Reviewed-on: https://chromium-review.googlesource.com/208692
Reviewed-by: mukesh agrawal <quiche@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm: Fix reverse wrap behavior.

* Reverse wrap should happen regardless of whether or not the
  previous line was an overflow.
* Reversing when the cursor is in right margin should consume one
  backspace, but only when reverse wrap is enabled.

Change-Id: I716d40614b539877b4e45a6cd64716c104061d7f
Reviewed-on: https://chromium-review.googlesource.com/208739
Reviewed-by: Marvelous Marius <mschilder@chromium.org>
Commit-Queue: Marvelous Marius <mschilder@chromium.org>
Tested-by: Marvelous Marius <mschilder@chromium.org>
A fix for https://code.google.com/p/chromium/issues/detail?id=390357.

This was happening because we would always focus the pasteTarget on ctrl-v.
However, if we ctrl-v-paste wasn't true, the onPaste method would never run
and refocus the screen.  So don't try to prefocus the paste target if we
aren't using ctrl-v-paste.

BUG=chromium:390357
Change-Id: Id18ca7b0fe9eabf64cf6c83ce396c2553867e0f1
Reviewed-on: https://chromium-review.googlesource.com/207440
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm: Implement bracketed paste mode.

* DECSET/DECRST mode 2004 toggles bracketed paste mode.  When
  enabled, pastes are sent as
  "ESC [ 2 0 0 ~ <paste-data> ESC [ 2 0 1 ~".
* Add test.

Change-Id: Ibacf433c4bc3fe71566b78f26b374224d6704c32
Reviewed-on: https://chromium-review.googlesource.com/209156
Reviewed-by: Marvelous Marius <mschilder@chromium.org>
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm: Fix flash/scroll-up on paste.

* Flash-on-paste seems to have turned in to scroll-on-paste after
  https://chromium-review.googlesource.com/#/c/207440.  This fixes
  the issue by relocating the pasteTarget to be at the bottom of the
  document.
* Small tweaks to match hterm style.

BUG=chromium:390357
BUG=chromium:394568

Change-Id: I498d9d6de6d52272212e89a8d526ba1705874e87
Reviewed-on: https://chromium-review.googlesource.com/209157
Reviewed-by: Marvelous Marius <mschilder@chromium.org>
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm: Fix firefox check in ScrollPort..decorate

* Previous code relied on "if (window.mozInnerScreenX)" to test for
  Firefox, but this fails if innerScreenX is 0.  Change to
  "if (window.hasOwnProperty('mozInnerScreenX'))".

Change-Id: Id11ce0f09ede7f50025948cce9ca69b1297d32b1
Reviewed-on: https://chromium-review.googlesource.com/209158
Reviewed-by: Marvelous Marius <mschilder@chromium.org>
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm: Firefoxfixen

* Move pasteTarget even lower so it doesn't show up in ff.
* Fix 'mozInnerScreenX' test.

Change-Id: I938c1d30895689f6b4fa77a475954697bee14130
Reviewed-on: https://chromium-review.googlesource.com/209320
Reviewed-by: Edoardo Spadolini <kerio00@gmail.com>
Reviewed-by: Marvelous Marius <mschilder@chromium.org>
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
wam: Fix typo, conver lib.Event to wam.Event

* Fix UNEDFINED typo in wam_jsfs_remote_file_system.js.
* Convert lib.Event to wam.Event in same.

Change-Id: Ia7867c74d02b0482c4479e0d7e60691d91abb9d2
Reviewed-on: https://chromium-review.googlesource.com/209346
Reviewed-by: Hoa V. DINH <dvh@chromium.org>
Tested-by: Hoa V. DINH <dvh@chromium.org>
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>
hterm: Add doc/embed.md

Change-Id: Id604155e0b065440a001c834a0ca35639e55555d
Reviewed-on: https://chromium-review.googlesource.com/209387
Reviewed-by: Robert Ginda <rginda@chromium.org>
Tested-by: Robert Ginda <rginda@chromium.org>