Menu Customizer: fix adding new menu items for changes in WordPress 4.1, and the new usage of the core JS API. Also fix JSHint errors.

See https://github.com/wp-plugins/menu-customizer/pull/1 for details.

Props westonruter. Fixes #2330, #2278. See #core-30701.

git-svn-id: https://plugins.svn.wordpress.org/menu-customizer/trunk@1044118 b8457f37-d9ea-0310-8a92-e5e31aec5664