Bug 867341 - Replace AutoObjectRooter with RootedObject. r=smaug

--HG--
extra : rebase_source : b5dc27c6dfbc219980739314a22ff691a1b25032
Bug 867341 - Replace NULL with nullptr in Rooted<JSObject*> lines. r=vladan

This is the rebased remnants of an earlier patch replacing AutoObjectRooter with Rooted<JSObject*>, after dzbarsky landed a patch doing the same thing.

--HG--
extra : rebase_source : c138f3de547c95a01aee62262bff467e5f5f2e81
Bug 867341 - Remove AutoObjectRooter, replace with RootedObject where needed. r=terrence

--HG--
extra : rebase_source : 009cf235e9c05d6379ee5267856b3f7832ceab0e