Refactoring the active item by mousemotion