Fixed editing clicked and selected items.