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

Side by Side Diff: third_party/WebKit/Source/modules/ModulesInitializer.cpp

Issue 2862963003: Replace ASSERT with DCHECK in modules/ (Closed)
Patch Set: NOTREACHED instead of DCHECK(false) Created 3 years, 7 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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/audio_output_devices/SetSinkIdCallbacks.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ModulesInitializer.h" 5 #include "ModulesInitializer.h"
6 6
7 #include "bindings/modules/v8/ModuleBindingsInitializer.h" 7 #include "bindings/modules/v8/ModuleBindingsInitializer.h"
8 #include "core/EventTypeNames.h" 8 #include "core/EventTypeNames.h"
9 #include "core/css/CSSPaintImageGenerator.h" 9 #include "core/css/CSSPaintImageGenerator.h"
10 #include "core/dom/Document.h" 10 #include "core/dom/Document.h"
(...skipping 20 matching lines...) Expand all
31 #include "modules/webdatabase/DatabaseManager.h" 31 #include "modules/webdatabase/DatabaseManager.h"
32 #include "modules/webgl/WebGL2RenderingContext.h" 32 #include "modules/webgl/WebGL2RenderingContext.h"
33 #include "modules/webgl/WebGLRenderingContext.h" 33 #include "modules/webgl/WebGLRenderingContext.h"
34 #include "platform/mojo/MojoHelper.h" 34 #include "platform/mojo/MojoHelper.h"
35 #include "platform/wtf/PtrUtil.h" 35 #include "platform/wtf/PtrUtil.h"
36 #include "public/platform/InterfaceRegistry.h" 36 #include "public/platform/InterfaceRegistry.h"
37 37
38 namespace blink { 38 namespace blink {
39 39
40 void ModulesInitializer::Initialize() { 40 void ModulesInitializer::Initialize() {
41 ASSERT(!IsInitialized()); 41 DCHECK(!IsInitialized());
42 42
43 // Strings must be initialized before calling CoreInitializer::init(). 43 // Strings must be initialized before calling CoreInitializer::init().
44 const unsigned kModulesStaticStringsCount = 44 const unsigned kModulesStaticStringsCount =
45 EventNames::EventModulesNamesCount + 45 EventNames::EventModulesNamesCount +
46 EventTargetNames::EventTargetModulesNamesCount + 46 EventTargetNames::EventTargetModulesNamesCount +
47 IndexedDBNames::IndexedDBNamesCount; 47 IndexedDBNames::IndexedDBNamesCount;
48 StringImpl::ReserveStaticStringsCapacityForSize(kModulesStaticStringsCount); 48 StringImpl::ReserveStaticStringsCapacityForSize(kModulesStaticStringsCount);
49 49
50 EventNames::initModules(); 50 EventNames::initModules();
51 EventTargetNames::initModules(); 51 EventTargetNames::initModules();
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 // TODO(dominickn): This interface should be document-scoped rather than 93 // TODO(dominickn): This interface should be document-scoped rather than
94 // frame-scoped, as the resulting banner event is dispatched to 94 // frame-scoped, as the resulting banner event is dispatched to
95 // frame()->document(). 95 // frame()->document().
96 frame->GetInterfaceRegistry()->AddInterface(WTF::Bind( 96 frame->GetInterfaceRegistry()->AddInterface(WTF::Bind(
97 &AppBannerController::BindMojoRequest, WrapWeakPersistent(frame))); 97 &AppBannerController::BindMojoRequest, WrapWeakPersistent(frame)));
98 }); 98 });
99 99
100 HTMLMediaElement::RegisterMediaControlsFactory( 100 HTMLMediaElement::RegisterMediaControlsFactory(
101 WTF::MakeUnique<MediaControlsImpl::Factory>()); 101 WTF::MakeUnique<MediaControlsImpl::Factory>());
102 102
103 ASSERT(IsInitialized()); 103 DCHECK(IsInitialized());
104 } 104 }
105 105
106 } // namespace blink 106 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/audio_output_devices/SetSinkIdCallbacks.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698