bug 353470 - Stops propagating ENTER and DELETE key events when an item is selected in the todo list. Patch by jminta, r1=lilmatt, r2=dmose

This commit is contained in:
mattwillis%gmail.com 2006-09-20 22:47:01 +00:00
Родитель 94b8a67d23
Коммит 7c69f8ae93
1 изменённых файлов: 2 добавлений и 0 удалений

Просмотреть файл

@ -234,9 +234,11 @@
const kKE = Components.interfaces.nsIDOMKeyEvent;
if (event.keyCode == kKE.DOM_VK_RETURN ||
event.keyCode == kKE.DOM_VK_ENTER) {
event.stopPropagation();
this.fireEvent("item-open");
} else if (event.keyCode == kKE.DOM_VK_BACK_SPACE ||
event.keyCode == kKE.DOM_VK_DELETE) {
event.stopPropagation();
this.fireEvent("item-delete");
} else if (event.keyCode == kKE.DOM_VK_SPACE) {
var selected = this.selectedItem;