Index: Source/core/frame/PlatformEventDispatcher.cpp |
diff --git a/Source/core/frame/PlatformEventDispatcher.cpp b/Source/core/frame/PlatformEventDispatcher.cpp |
index ef830041074bd43b1bae495015b1d10981c5ea2a..65909711fbfa4e1eddeeb78e780eab4a2acfb375 100644 |
--- a/Source/core/frame/PlatformEventDispatcher.cpp |
+++ b/Source/core/frame/PlatformEventDispatcher.cpp |
@@ -19,9 +19,13 @@ PlatformEventDispatcher::PlatformEventDispatcher() |
void PlatformEventDispatcher::addController(PlatformEventController* controller) |
{ |
ASSERT(controller); |
- ASSERT(!m_controllers.contains(controller)); |
+ // TODO: If we can avoid to register a same controller twice, we can change |
+ // this 'if' to ASSERT. |
+ if (m_controllers.contains(controller)) |
+ return; |
m_controllers.add(controller); |
+ |
if (!m_isListening) { |
startListening(); |
m_isListening = true; |