Partially solves issue #20

When an inline admin form is added, sortedm2m functionality is broken (i.e. values are not saved until next full page load). This patch solves the issue.
Refactored function so it does not use $.fn namespace
Removed closures. Using camelCase now.
Merge pull request #37 from outime/patch-1

Partially solves issue #20