z25/pyZOCP — pull request #15 by fieldOfView (2014-06-03 11:45:43+00:00)
Title: Feature enter to emit

The current urwZOCP shouts out changes in string-, int- and float-widgets while typing. For changes in (long) strings and ints, as well as keyboard-changes in floats, it would be better if there is one shout at a controllable point in.

This pull-request subclasses the urwid.Edit widget so it can listen to getting/losing focus and respond to pressing enter. The current value is emitted automatically when pressing enter, and - if the value has been changed by the user - when the widget looses focus.