Remove V8GarbageCollected in favor of DOMWrapperWorld::DOMObjectHolder

This CL removes V8GarbageCollected because V8GarbageCollected was a source of memory leaks in serviceworker objects.

For example, WaitUntilObserver::ThenFunction inherits from V8GarbageCollected. The ThenFunction object is collected when a V8 GC collects the wrapper of the ThenFunction object. This means that the ThenFunction object is not collected when a worker thread shuts down because the worker thread doesn't trigger a V8 GC before shutting down. To avoid this kind of leak, we should keep track of a list of ThenFunctions and explicitly dispose the wrappers before shutting down the worker thread (instead of relying on the V8 GC to collect the wrappers).

With that motivation, this CL introduces DOMWrapperWorld::DOMObjectHolder. By calling DOMWrapperWorld::registerDOMObjectHolder(T* object, v8::Handle<v8::Value> wrapper), we can associate the lifetime of the object with the wrapper. Specifically, the object is guaranteed to be kept alive as long as (1) the wrapper is alive and (2) the DOMWrapperWorld is alive. Since the DOMObjectHolder gets disposed when the DOMWrapperWorld gets disposed (e.g., when the worker thread shuts down), we can avoid the leak I mentioned above.

BUG=340522
TEST=serviceworker/ tests pass in oilpan builds (oilpan builds have an ASSERT to check leaks of ThenFunction objects).

Review URL: https://codereview.chromium.org/526973002

git-svn-id: svn://svn.chromium.org/blink/trunk@181183 bbb929c8-8fbe-4397-9dbb-9b2b20218538