I don't know that this will ever be possible. There is a whole tasks.js file that handles all of this on a dedicated site (
tasks.google.com) which is integrated with Gmail behind the scenes. By their nature, Add-ons can't do very much outside their sandboxed iframe. So you can't even create "addEventListener" type things since you don't have access to the main browser object. The kinds of things you are trying to do sounds like it would fit better as a browser add-on, not a Gmail add-on. Look at "
Drag" for a browser-based Gmail add-on.