Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(213)

Unified Diff: third_party/WebKit/Source/bindings/core/v8/DOMWrapperWorld.cpp

Issue 2628053003: Remove extension group from DOMWrapperWorld. (Closed)
Patch Set: Fix GCCallbackTest Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/bindings/core/v8/DOMWrapperWorld.cpp
diff --git a/third_party/WebKit/Source/bindings/core/v8/DOMWrapperWorld.cpp b/third_party/WebKit/Source/bindings/core/v8/DOMWrapperWorld.cpp
index 8a50f5e03569baaf23e62d88de789051b57daff8..d3ece36b6b92c158a17047504dc325f8398f7b8f 100644
--- a/third_party/WebKit/Source/bindings/core/v8/DOMWrapperWorld.cpp
+++ b/third_party/WebKit/Source/bindings/core/v8/DOMWrapperWorld.cpp
@@ -84,16 +84,12 @@ class DOMObjectHolder : public DOMObjectHolderBase {
unsigned DOMWrapperWorld::isolatedWorldCount = 0;
PassRefPtr<DOMWrapperWorld> DOMWrapperWorld::create(v8::Isolate* isolate,
- int worldId,
- int extensionGroup) {
- return adoptRef(new DOMWrapperWorld(isolate, worldId, extensionGroup));
+ int worldId) {
+ return adoptRef(new DOMWrapperWorld(isolate, worldId));
}
-DOMWrapperWorld::DOMWrapperWorld(v8::Isolate* isolate,
- int worldId,
- int extensionGroup)
+DOMWrapperWorld::DOMWrapperWorld(v8::Isolate* isolate, int worldId)
: m_worldId(worldId),
- m_extensionGroup(extensionGroup),
m_domDataStore(
WTF::wrapUnique(new DOMDataStore(isolate, isMainWorld()))) {}
@@ -101,17 +97,15 @@ DOMWrapperWorld& DOMWrapperWorld::mainWorld() {
ASSERT(isMainThread());
DEFINE_STATIC_REF(
DOMWrapperWorld, cachedMainWorld,
- (DOMWrapperWorld::create(v8::Isolate::GetCurrent(), MainWorldId,
- mainWorldExtensionGroup)));
+ (DOMWrapperWorld::create(v8::Isolate::GetCurrent(), MainWorldId)));
return *cachedMainWorld;
}
PassRefPtr<DOMWrapperWorld> DOMWrapperWorld::fromWorldId(v8::Isolate* isolate,
- int worldId,
- int extensionGroup) {
+ int worldId) {
if (worldId == MainWorldId)
return &mainWorld();
- return ensureIsolatedWorld(isolate, worldId, extensionGroup);
+ return ensureIsolatedWorld(isolate, worldId);
}
typedef HashMap<int, DOMWrapperWorld*> WorldMap;
@@ -207,8 +201,7 @@ static bool isIsolatedWorldId(int worldId) {
PassRefPtr<DOMWrapperWorld> DOMWrapperWorld::ensureIsolatedWorld(
v8::Isolate* isolate,
- int worldId,
- int extensionGroup) {
+ int worldId) {
ASSERT(isIsolatedWorldId(worldId));
WorldMap& map = isolatedWorldMap();
@@ -216,11 +209,10 @@ PassRefPtr<DOMWrapperWorld> DOMWrapperWorld::ensureIsolatedWorld(
RefPtr<DOMWrapperWorld> world = result.storedValue->value;
if (world) {
ASSERT(world->worldId() == worldId);
- ASSERT(world->extensionGroup() == extensionGroup);
return world.release();
}
- world = DOMWrapperWorld::create(isolate, worldId, extensionGroup);
+ world = DOMWrapperWorld::create(isolate, worldId);
result.storedValue->value = world.get();
isolatedWorldCount++;
return world.release();

Powered by Google App Engine
This is Rietveld 408576698