Automatic drag/drop fix

Fixes a bug where the matching column on upload would be dragged way beneath where it was supposed to go 

Also, code cleanup
Merge pull request #954 from isuftin/master

Automatic drag/drop fix