Ticket #2978: fix for Home, End, Shift+Fn problems under screen/tmux.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Merge branch '2978_tmux_keys'

* 2978_tmux_keys:
  Ticket #2978: fix for Home, End, Shift+Fn problems under screen/tmux.